Search the Community
Showing results for tags 'initialisation'.
Found 2 results
-
initializtion Where to place my script
rkemsley posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hi all, I have created a short piece of code that makes the Curator Editing Area follow the Curator player around the map. I have four potential Curator players (BLUFOR_Player001 to BLUFOR_Player004) who all have the exact same code linked to them except for their names and Curator Editing Area code. Each of the four BLUFOR Curator players are not created on map initialisation. Instead, I wanted the player unit to be created when a player decides to play that role. I initially had my script in the init.sqf, however, when testing, I would get errors saying that the other BLUFOR Curators did not exist (because I was only playing as BLUFOR_Player001). What I am wondering is how/where do I place my script so that it is added to every new BLUFOR player when they join the game (It must be unique to them, see below).- 27 replies
-
- arma 3
- addcuratoreditingarea
- (and 6 more)
-
basic selection of connected Player help
Tom507 posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
I got this to work (at least partially): in the init: if (isServer) then { addMissionEventHandler["PlayerConnected",{_this execVM "playerInit.sqf"}]; }; in playerInit.sqf: thisPlayer = objNull; playerId = (_this select 4); for "_x" from 0 to (count allPlayers) -1 step 1 do { if (owner _x == playerId) then { thisplayer = (allPlayers select _x); }; }; thisPlayer = _this publicVariable "thisplayer"; publicVariable "playerId"; the Id is correctly transfered the problem is thisPlayer returns nothing the if never returns true so either the player is not in the list allPlayers at the time or i have no clue I tested everything seperately and everything works so Ihave nu f*king idea why it doesn't work Please help thanks in advance- 11 replies
-
- multiplayer
- jip
-
(and 4 more)
Tagged with: