Patou
-
Content Count
11 -
Joined
-
Last visited
-
Medals
Posts posted by Patou
-
-
Thank you for the explanation.
I tried setVehicleVarname in an alternative script and it wasn't working. After your answer i checked the script and i saw i made the damn typo error i often make, writing vehicule (as in french) instead of vehicle. :(
-
Finally solved my problem by using the excellent respawn script by Tophe http://www.armaholic.com/page.php?id=6082
-
Always better to declare public variable at start to avoid errors. My self for ojectives i use boolean variables so i can just put the variable as condition in some triggers or waypoints for AI.
-
I'm still stuck on this. If anyone have an idea he would be welcome ;)
-
My goal is to detect a player driving a specific vehicle he doesn't own at start.
I made a empty vehicle nammed "tanka" that respawn with this script
?!(isServer) : exitprivate ["_ap","_temps","_ve","_dir","_pos"]
_ap = _this select 0
_temps = _this select 1
_nom = _this select 2
_ve = typeOf _ap
_dir = getDir _ap
_pos = getPos _ap
if(isNil("_temps")) then {_temps = 30};
#boucle
@ ((!alive _ap) || (!canMove _ap))
if((!alive _ap) || (!canMove _ap)) then{goto "detruitrespawn"}
~0.1
goto "boucle"
#detruitrespawn
~_temps
deleteVehicle _ap
~0.1
?(isServer):_ap=_ve createVehicle _pos
_ap setDir _dir
_ap setIdentity "tanka"
~0.1
goto "boucle"
I use triggers activated by side and with condition:
this && tanka in thisListI works fine if the tank doesn't respawn but once it has respawn the triggers doesn't work. Any solutions?
What i want is:
-It triggers only with this vehicle and not other vehicles.
-It detects side of player driving or it puts side of player driving in a variable.
-
resolved all problem. So it was that.group player reveal this -
I will try this and report if it works fine. thank you for the answer.
-
I made a mp mission with three side:
At the beginning players have to choose to enter a sedan or a motorcycle.
The problem that happens in multiplayer is some vehicles seem lock at the beginning and after few seconde to 2 minutes they randomly unlock.
When i try the mission in the editor this problem never happen. All vehicle are unlock.
Someone have a idea why it is happening ?
Should i try to force the unlocking by puting in the init: vehicle_name lock false; ?
Or should i made an intro to be sure all vehicules are unlock?
-
Now it works fine. Thank you very much.
for the briefing i just copied what i found in tutorial. it works so i didn't search further.
-
Hello, i try to make a rally's mpmission.
I made a script that calculate the time done and get the player name.
Now i want this script to insert the time of the player in a public list when he cross the line.
So i made a publicVariable i called _classement. I declare it in the init.sqf
_classement = [];publicVariable "_classement";
nul=[] execVM "briefing.sqf";
My problem is when i want to use this _classement it show only a list of "any"
If i change my scripts to use _classement as a local variable it works fine and show what it should.
Do i do wrong to declare the publicvariable?
Publicvariable problem
in ARMA 2 & OA : ADDONS - Configs & Scripting
Posted · Edited by Patou
I forgot about jip.
This init should work with jip. No?
obj0=false; obj1=false; obj2=false; obj3=false; obj4=false; obj5=false; if ( isServer ) then { PublicVariable "obj0"; PublicVariable "obj1"; PublicVariable "obj2"; PublicVariable "obj3"; PublicVariable "obj4"; PublicVariable "obj5"; }; if (isServer) then { onPlayerConnected "[] execVM "update.sqf""; }; [] execVm "briefing.sqf";with update.sqf being
if ( isServer ) then { PublicVariable "obj0"; PublicVariable "obj1"; PublicVariable "obj2"; PublicVariable "obj3"; PublicVariable "obj4"; PublicVariable "obj5"; };