Jump to content

Home

What is the player's name in relation to scripts?


la$her

Recommended Posts

Help me, please! I can't get any scripts to directly affect the player (ie - me) because I don't know how to address him! To put it another way, if I wanted to command an NPC, I just give it an NPC_targetname. But obviously that can't be done with the player.... I've tried kyle, munro, player, nothing seems to work! Please help me, my maps are at a huge obstacle here!

Link to comment
Share on other sites

If you want a script to run on the player's spawn, create a target_scriptrunner and target the info_player_start at it (not the other way around).

 

In the script itself, you can state global variables however you want (showobjectives, etc), but anything directly affecting the player must be in a affect() clause targetted at "kyle".

 

For example...

 

affect ( "kyle", /*@AFFECT_TYPE*/ FLUSH )

{

set ( "SET_FORCE_JUMP_LEVEL", "3" );

set ( "SET_FORCE_PUSH_LEVEL", "2" );

}

 

(etc.)

Link to comment
Share on other sites

Thanks, I've got most things working now, with the notable exceptions of the print command (just never works) and the camera functions, which no matter how I arrange them, just go into camera mode then immediately go out of it again, ignoring any commands in between. Any further ideas are of course welcome.....

Link to comment
Share on other sites

Originally posted by la$her

Thanks, I've got most things working now, with the notable exceptions of the print command (just never works) and the camera functions, which no matter how I arrange them, just go into camera mode then immediately go out of it again, ignoring any commands in between. Any further ideas are of course welcome.....

 

If your'e having trouble with cutscenes (I assume thats what you mean with cameras)

 

Then check out this tutorial

 

http://www.geocities.com/rellenbroek/tutorials/tutorial_3/tutorial_3.html

 

And this tutorial

 

http://www.geocities.com/rellenbroek/tutorials/tutorial_4/tutorial_4.html

 

For some good cutscene tutorials.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...