Hi there,
I'm currently working hard to understand as much arma code as possible as I customize my server much and want to reach the fully potencial which is available.
There are some things I don't understand in Scripting with dayz with arma code maybe someone would be kind and explain some things to me
Often in Scripts of the server.pbo or the dayz client files there are commands with _this select. I choose an example from the server_playerdied.sqf which is used for the deathmessages and stuff.
So as far as I read about the _this select function it is used to get informations from a special object. But how I know from which object the _this select 0 commands try to get the informations.
Also I read that the command _this select 0; would put the first information in the array of the object into the _characterID variable.
But how can I know or learn which info is stored where? If I look at other scripts there are often _this select commands and I don't know how to detect which info is stored in the object and which number I have to use if I want to have a special information.
Thanks in advance for all users who are willing to help me out!
Regards
kikyou2
I'm currently working hard to understand as much arma code as possible as I customize my server much and want to reach the fully potencial which is available.
There are some things I don't understand in Scripting with dayz with arma code maybe someone would be kind and explain some things to me
Often in Scripts of the server.pbo or the dayz client files there are commands with _this select. I choose an example from the server_playerdied.sqf which is used for the deathmessages and stuff.
Code:
private["_characterID","_minutes","_newObject","_playerID","_key","_playerName","_playerID","_myGroup","_group","_victim", "_killer", "_weapon", "_message", "_distance","_loc_message","_victimName","_killerName","_killerPlayerID"];
//[unit, weapon, muzzle, mode, ammo, magazine, projectile]
_characterID =_this select 0;
_minutes =_this select 1;
_newObject =_this select 2;
_playerID =_this select 3;
_playerName =_this select 4;
So as far as I read about the _this select function it is used to get informations from a special object. But how I know from which object the _this select 0 commands try to get the informations.
Also I read that the command _this select 0; would put the first information in the array of the object into the _characterID variable.
But how can I know or learn which info is stored where? If I look at other scripts there are often _this select commands and I don't know how to detect which info is stored in the object and which number I have to use if I want to have a special information.
Thanks in advance for all users who are willing to help me out!
Regards
kikyou2