3l0ckad3 17 Posted March 28, 2019 I don't even know how to go about asking this, but, should I be passing most if not all player syntax through the initPlayerLocal.sqf including markers ? and more ai related stuff through initServer.sqf to avoid, whatever, and if so or not, why ? You could post me links to stuff till you're red in the face, I'm ADHD, so I do have some issues focusing on technical things, so I'm kinda looking for more of a explanation on the matter. I guess what I'm really asking, after the game has been started, with JIP in mind, should I try to be passing most if not all of my negotiations through their respective inits ? And what are some good rules to keep in mind, I know nothing is written in stone, and things change by the circumstance. And I've heard SQFs handle the payload and transfer a lot better than in game, is that because it rests, or, is somewhat suspended when it's not on the server, but if it's on the server there is more checks that need to be done adding the the scheduler ?? And the last question, is what are some things to keep in mind about how you pass some negotiations on, how do we tell the difference between global, how I understand it is _unite blahBlah blah; is local to where it is used unless you define it somewhere else, and global is defined as just unit blahBlah..blah;, but I don't understand the ramifications or impacts they have on the server or people's machines I'm fairly decent at what I do with the limited experience I have, I just have to get people to clean up my work so it's more stable. Anyways, I'll stop rambling. Cheers. Q Share this post Link to post Share on other sites
pierremgi 4737 Posted March 28, 2019 I didn't understand all your interrogations/negociations, but you can start with: https://community.bistudio.com/wiki/Initialization_Order https://community.bistudio.com/wiki/Variables https://community.bistudio.com/wiki/Multiplayer_Scripting https://community.bistudio.com/wiki/Code_Optimisation As a good habit, always check the arguments , server exec only , and effects for commands. Some commands have their local or global (public) scope, like: createMarkerLocal and createMarker Now, roughly, use: initPlayerLocal.sqf for all things concerning player (or his locality/ PC). Example: HUDs can display personal data, at the player's hand sometime. initServer.sqf for codes on server like spawning units (you don't want to spawn them everywhere = multiplicate them). init.sqf : very immediate for single player session, can be used in MP with this warning: all JIP will run it at their own start. So, some codes (like unit loadout) could be re-run for all without caution. On the other hand, that's a good place for common scripts (execVMed sqf, compiled codes..) A locality is not a "barrier". You can remoteExec some scripts, or publicVariable some variables. Have a good reading for these links and their related pages. 1 Share this post Link to post Share on other sites
sarogahtyp 1104 Posted March 28, 2019 some more important stuff: https://community.bistudio.com/wiki/Event_Scripts https://community.bistudio.com/wiki/Scheduler as you told //global string to the machine where the script is executed globalVar = "global"; //local string to the machine where the script is executed _localVar = "local"; local and global here means the relation for the machine where the script is executed. to get a variable global to all machines you can use https://community.bistudio.com/wiki/publicVariable to just send a variable from client to server https://community.bistudio.com/wiki/publicVariableServer to send it from server to one client or from one to another client https://community.bistudio.com/wiki/publicVariableClient also it is possible to execute a command/script/function remotely: https://community.bistudio.com/wiki/Arma_3_Remote_Execution https://community.bistudio.com/wiki/remoteExec https://community.bistudio.com/wiki/remoteExecCall 1 Share this post Link to post Share on other sites
3l0ckad3 17 Posted March 28, 2019 3 hours ago, pierremgi said: I didn't understand all your interrogations/negociations, but you can start with: https://community.bistudio.com/wiki/Initialization_Order https://community.bistudio.com/wiki/Variables https://community.bistudio.com/wiki/Multiplayer_Scripting https://community.bistudio.com/wiki/Code_Optimisation As a good habit, always check the arguments , server exec only , and effects for commands. Some commands have their local or global (public) scope, like: createMarkerLocal and createMarker Now, roughly, use: initPlayerLocal.sqf for all things concerning player (or his locality/ PC). Example: HUDs can display personal data, at the player's hand sometime. initServer.sqf for codes on server like spawning units (you don't want to spawn them everywhere = multiplicate them). init.sqf : very immediate for single player session, can be used in MP with this warning: all JIP will run it at their own start. So, some codes (like unit loadout) could be re-run for all without caution. On the other hand, that's a good place for common scripts (execVMed sqf, compiled codes..) A locality is not a "barrier". You can remoteExec some scripts, or publicVariable some variables. Have a good reading for these links and their related pages. Nice! I'll remember to check with the wiki more, thnx. Now, I wouldn't spawn units through the initPlayerLocal, I see no need for that when I could use bis function for that, but, I might pass negotiations through it because I'm aware, at least from what KK said, that utilizing sqfs is noticeably faster, so, I'm assuming that code or function(s) could get duplicated ? and I'm assuming this is where dedi/server/local shells come into play ? What would happen if I fired a global function through a local function or vice versa ? would it just spit out an error, or would the server start degrading ? I'm not afraid to do some reading and watch videos, the problem is I don't even know where to start is all, and arma has it's own unique language, from what I know, so you can only bug those with experience. Thnx for your reply, much appreciated. Share this post Link to post Share on other sites
3l0ckad3 17 Posted March 28, 2019 3 hours ago, sarogahtyp said: some more important stuff: https://community.bistudio.com/wiki/Event_Scripts https://community.bistudio.com/wiki/Scheduler as you told //global string to the machine where the script is executed globalVar = "global"; //local string to the machine where the script is executed _localVar = "local"; local and global here means the relation for the machine where the script is executed. to get a variable global to all machines you can use https://community.bistudio.com/wiki/publicVariable to just send a variable from client to server https://community.bistudio.com/wiki/publicVariableServer to send it from server to one client or from one to another client https://community.bistudio.com/wiki/publicVariableClient also it is possible to execute a command/script/function remotely: https://community.bistudio.com/wiki/Arma_3_Remote_Execution https://community.bistudio.com/wiki/remoteExec https://community.bistudio.com/wiki/remoteExecCall I'm going to read your links later today before I wrap my head around that Thank you for taking the time to point me in the right directions Share this post Link to post Share on other sites
3l0ckad3 17 Posted March 28, 2019 3 hours ago, pierremgi said: I didn't understand all your interrogations/negociations, but you can start with: https://community.bistudio.com/wiki/Initialization_Order https://community.bistudio.com/wiki/Variables https://community.bistudio.com/wiki/Multiplayer_Scripting https://community.bistudio.com/wiki/Code_Optimisation As a good habit, always check the arguments , server exec only , and effects for commands. Some commands have their local or global (public) scope, like: createMarkerLocal and createMarker Now, roughly, use: initPlayerLocal.sqf for all things concerning player (or his locality/ PC). Example: HUDs can display personal data, at the player's hand sometime. initServer.sqf for codes on server like spawning units (you don't want to spawn them everywhere = multiplicate them). init.sqf : very immediate for single player session, can be used in MP with this warning: all JIP will run it at their own start. So, some codes (like unit loadout) could be re-run for all without caution. On the other hand, that's a good place for common scripts (execVMed sqf, compiled codes..) A locality is not a "barrier". You can remoteExec some scripts, or publicVariable some variables. Have a good reading for these links and their related pages. I got back in my editor and it hit me, I shouldn't be passing anything through the playerlocalinit.sqf that isn't player related, like stamina, or recoil or whatnot, I should just write out those function in another sqf file, and exec them from there. I mean, I do do some scripting and such, but sometimes there is fall out from the my ignorance lol , Share this post Link to post Share on other sites