Jump to content
Sign in to follow this  
sanctuary

multiplayer behavior of a simple script

Recommended Posts

Hello,

I have wrote this script

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">?(local server):exit

_this setfuel 0;removeallweapons _this

BOOOM = "SANC_Shell73" camcreate [(getpos _this select 0), (getpos _this select 1), (getpos _this select 2)]; Fuze = "FxExploGround1" camcreate getpos BOOOM;

_burnlight = "SANC_LIGHTDES" camcreate getpos _this; _burnlight inflame true

_ii = 0

#lop

***here were a simple loop using some drop command to generate fire and smoke***

***removed for better visibility on the forum***

goto "lop"

#end

deletevehicle _burnlight

exit

(note the 2nd script executed is just generating a fireball fx by drop command)

From what i understood, the camcreate command is local, meaning it does not run on server.

But for the effect i do, i need the object creation to be camcreated instead of createvehicled.

As in the case of the lighting invisible object "sanc_lightdes" if it was createvehicled it would had the "put out fire" action added to it if the player come close.

I do not want this action here, and because it is not possible to use a removeaction (derived from the fire object that has a hardcoded user action for this) , the camcreate is needed (as the object cease to give the user action to the player in such case).

But, while in single player this script work correctly and without a performance loss in big armor battles, i remembered having read some people in multiplayer talking about the explosions script being multiplied ingame by the amount of people in there.

As i have no way at all to test my mod that comes with this optional script in multiplayer situation and have nearly 0 experience of MP scripting limitations, i ask the question about the viability in MP of my script :

in such state (with the ?(local server):exit condition added to prevent the server to run this script as it will not be able to use the camcreate command) will the script work correctly only on local , without being multiplied by the amount of player ?

Or should i just remove the script for an alternative MP version of my mod config ?

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×