Search the Community
Showing results for tags 'profilenamespace'.
Found 3 results
-
Saving player position with profilenamespace
kibaBG posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hi, I am trying to save players position on a mission map using prifilenamespace of each player. Its working fine in editor, but refuse to work on dedicated server ... I wonder where is the problem? //PERSISTENT PLAYER POS AND RATING //saves players pos and rating every five min //loads players pos and rating when they join server //initServer.sqf []execVM "stats.sqf"; //stats.sqf while {true} do { _kibaPos = getPosATL kiba3x; profileNamespace setVariable ["KIB_kibaPos", _kibaPos]; _kibaRating = rating kiba3x; profileNamespace setVariable ["KIB_kibaRating",_kibaRating]; _kavhanPos = getPosATL kavhan; profileNamespace setVariable ["KIB_kavhanPos", _kavhanPos]; _kavhanRating = rating kavhan; profileNamespace setVariable ["KIB_kavhanRating", _kavhanRating]; _konalPosition = getPosATL konal; profileNamespace setVariable ["KIB_konalPos", _konalPosition]; _konalRating = rating konal; profileNamespace setVariable ["KIB_konalRating", _konalRating]; sleep 300; }; //initPlayerLocal.sqf //playable units are given variable names "kiba3x","kavhan","konal" in the editor if ((str player) == "kiba3x") then { _kibaPos = profileNamespace getVariable "KIB_kibaPos"; player setPosATL _kibaPos; _kibaRating = profileNamespace getVariable "KIB_kibaRating"; player addRating _kibaRating; } else { if ((str player) == "kavhan") then { _kavhanPos = profileNamespace getVariable "KIB_kavhanPos"; player setPosATL _namalskPos; _kavhanRating = profileNamespace getVariable "KIB_kavhanRating"; player addRating _kavhanRating; } else { _konalPos = profileNamespace getVariable "KIB_konalPos"; player setPosATL _konalPos; _konalRating = profileNamespace getVariable "KIB_konalRating"; player addRating _konalRating; }; }; -
screenshot Need a help with save parameters file (log file) somewhere
5mpower posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hello for everyone! I have a trouble: my script takes screenshot of object and i need to create log file with full dimensions of this object (basically, i need a four points of object: upper left, upper right, lower left, lower right). How can i save it? I read about saveProfileNamespace, but i cant find where i can find file with logs in arma 3 directory. Or maybe there are any way of creating .txt file with each screensot? Thanks for help before! -
serverside Hiding script from client as a server
Lordeath19 posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
I have recently created a local server (just hosting from the server browser), this server has some scripts that i don't want to expose to the player (due to them stealing it). I found out you can use the profileNamespace to save data to the profile of the player and as such i am able to store strings, arrays and stuff like that. My problem arises after i try to save scripts into the namespace -> saving them using the saveProfileNamespace (script is callable and is fine so far) -> shutting down the server after finishing playing. Now, when i start the server i am able to load the variables from the namespace and use them, but i can't call\spawn code that i stored inside the profile namespace as it raises this error: Global namespace not passed during: hint "test" Error Local variable in global space in order for you to replicate do the following: 1. start the debug console in an editor mission 2. enter these 2 lines: profileNamespace setVariable ["testFunction",{hint "test";}]; saveProfileNamespace; 3. restart the game 4. start the debug console again 5. enter this line: [] spawn (profileNamespace getVariable "testFunction"); 6. wonder desperately why the function isn't being executed- 22 replies
-
- 1
-
- server
- profilenamespace
-
(and 1 more)
Tagged with: