OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: mac_2007 on 27 Mar 2003, 10:54:43
-
>:( can someone tell me where to put a script because i have got the chris ofp script edited but when i make it and type the code in the INITIALIZATION nothing happens.
do i have to put something in the game directory
-
Humm... U wanna exec a script, ah? OK:
AT INITIALIZATION:
<param> exec "MyScript.sqs"
Where 'param' are the paramters needed to execute your script; for example an array or an object.
Init: player exec "eject.sqs"
;---eject.sqs---[sample]
_this action ["eject",vehicle _this]
exit
Where '_this' is the object which executes da script - in this case, the player.
do i have to put something in the game directory
Sure you have!
When you compress the mission into .pbo, only the files placed on the mission's directory will be compiled!
Therefore you must copy your script onto the mission's directory - if you place it at a sub-directory you'll have to change the 'exec' syntax: something exec "scripts/MyScript.sqs" - Check it out, might not be right.