UGX-Mods

Call of Duty 5: World at War => Help Desk => Scripting => Topic started by: Eggies on September 10, 2015, 10:48:38 pm

Title: Door Text
Post by: Eggies on September 10, 2015, 10:48:38 pm
So I was testing my map and I realized my doors say "Press F to Clear Debris" rather than "Press F to open door".

Is there a way I can change the text to anything I want? I looked in the trigger in front of the door and maybe it's "cursorhint" or "hintstring"?

For the most part I just want "Press F to open door" but there is ONE door that I want to have custom text for.

Thanks!  :)
Title: Re: Door Text
Post by: ProGamerzFTW on September 10, 2015, 10:54:25 pm
So I was testing my map and I realized my doors say "Press F to Clear Debris" rather than "Press F to open door".

Is there a way I can change the text to anything I want? I looked in the trigger in front of the door and maybe it's "cursorhint" or "hintstring"?

For the most part I just want "Press F to open door" but there is ONE door that I want to have custom text for.

Thanks!  :)

Sounds like you made a zombie_debris rather than a zombie_door in the KVPs
Title: Re: Door Text
Post by: Eggies on September 10, 2015, 11:19:11 pm
How to I turn it into a door?  :poker:
Title: Re: Door Text
Post by: ProGamerzFTW on September 10, 2015, 11:24:29 pm
This contains some of the basics. http://ugx-mods.com/wiki/index.php?title=Main_Page (http://ugx-mods.com/wiki/index.php?title=Main_Page) Including doors and blockers.

Edit: However it's noted you need to use the UGX Modtools patch in this tutorial.

Edit2: This is how WaW does it by default.

1) Make a Script_Brushmodel by right clicking in 2D view and having a brush selected. Go to script > brushmodel.
2) Give the model KVP's

Code Snippet
Plaintext
"script_vector" "100 0 0" //This is the direction the door will slide.
"targetname" "door_name" //Name of the door.
"spawnflags" "1"

3) Now make a Trigger_use. Right click in 2D view and go to trigger > use
4) Give it KVP's

Code Snippet
Plaintext
"script_noteworthy" "magic_door"
"zombie_cost" "" //Put price in quotes, by default you can only use 100, 200, 250, 500, 750, 1000, 1250, 1500, 1750, 2000
"target" "door_name" //This will be same as the targetname of the model.
Title: Re: Door Text
Post by: Eggies on September 10, 2015, 11:36:00 pm
I went to the "Creating a swinging door" page to see if I could find out how to make one there, but it says to create a door script_brushmodel. I only know how to make a script brushmodel. Is it just a script brushmodel with a door texture? Also, this doesn't tell me how to change the text ;-;
Title: Re: Door Text
Post by: ProGamerzFTW on September 11, 2015, 12:06:04 am
I went to the "Creating a swinging door" page to see if I could find out how to make one there, but it says to create a door script_brushmodel. I only know how to make a script brushmodel. Is it just a script brushmodel with a door texture? Also, this doesn't tell me how to change the text ;-;

It is a script_brushmodel with a door texture. The text will be the open door text if you use a door instead of debris, like so:
(https://www.ugx-mods.com/forum/proxy.php?request=http%3A%2F%2Fi.imgur.com%2FSkuznzJ.png&hash=4e230648437152803a4aa14d42db93ce02597116)



If you want to change the text, you can

1) Open zombie.str in \raw\english\localizedstrings
2) Search for open_door and you can change what you need there.

Example:

Code Snippet
Plaintext
REFERENCE           BUTTON_BUY_OPEN_DOOR_100
LANG_ENGLISH        "Press & hold &&1 to Open Door [Cost: 100]"

to

Code Snippet
Plaintext
REFERENCE           BUTTON_BUY_OPEN_DOOR_100
LANG_ENGLISH        "Press & hold &&1 to Open Zombie Door [Cost: 100]"



You can also do this instead if you'd like:

1) Go to _zombiemode.gsc
2) Search for open_door.
3) You can change text like:
Code Snippet
Plaintext
add_zombie_hint( "default_buy_door_100", &"ZOMBIE_BUTTON_BUY_OPEN_DOOR_100" );
to
Code Snippet
Plaintext
add_zombie_hint( "default_buy_door_100", "Press & hold &&1 to Open Door [Cost: 100]" ); // Make sure you remove & sign. 
Title: Re: Door Text
Post by: Eggies on September 11, 2015, 12:21:14 am
I created a script_brushmodel and went to textures > Usage > Door. When I pick a texture it doesn't change the text  :poker:
Title: Re: Door Text
Post by: ProGamerzFTW on September 11, 2015, 03:43:54 am
I created a script_brushmodel and went to textures > Usage > Door. When I pick a texture it doesn't change the text  :poker:

Choosing a texture doesn't change the text... making a proper door instead of debris like i said earlier does...
Title: Re: Door Text
Post by: Eggies on September 11, 2015, 03:48:36 am
Idk how to make a proper door XD
Title: Re: Door Text
Post by: ProGamerzFTW on September 11, 2015, 04:05:43 am
Idk how to make a proper door XD

I said exactly how in a previous post.  :poker:
Title: Re: Door Text
Post by: Eggies on September 12, 2015, 07:46:58 am
Thanks a lot :)