Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

DayZ ArenA v.0.54.125645 (Based on 0.45 Source with addons)

Newbie Spellweaver
Joined
Jan 18, 2015
Messages
30
Reaction score
2
When i remove these // m'y server stop generate loot..

It seems the while loop prevents the rest of the script to execute.
Take the 3 lines of code and place them at the very bottom of your init.sqf to make everything spawn again.
 
Junior Spellweaver
Joined
Jan 15, 2015
Messages
113
Reaction score
13
Or you could create a function inside init.sqf of DZ folder, name it whatever you want, then don't call it, but spawn it.
 
Newbie Spellweaver
Joined
Jan 18, 2015
Messages
30
Reaction score
2
Or you could create a function inside init.sqf of DZ folder, name it whatever you want, then don't call it, but spawn it.

Do you have an example code?
And you seem to have a lot of knowledge, could you point me in the right direction when it comes to adding stuff?
I managed to "import" the digital gloves from 0.53 but the CMAG for example doesnt work.
I also tried importing the field shovel, same way i did with the gloves, but that doesnt work either :S
 
Junior Spellweaver
Joined
Jan 15, 2015
Messages
113
Reaction score
13
Yo you should first, check in the RPT for any errors related to:
- model .p3d
- textures
- cannot create non-ai vehicle problems

For scripts, open your init.sqf in DZ\server\scripts folder, at the end (before the last diag_log) add this:

Code:
myfunctionname =
{
    _var1 = _this select 0;
    _var2 = _this select 1;
    _var3 = _this select 2;    //you can add as many variables as you want
    
    CODE HERE...
};

Now, there are two ways of executing a function:
1) CALLING that function
2) SPAWNING that function.

First case, you need to use call command in this way:
Code:
[var1,var2,var3...] call myfunctionname;

Second case is the same, but with command spawn:
Code:
[var1,var2,var3...] spawn myfunctionname;

Difference? A BIG ONE.
When you call a function, you execute inside the main script the code of that function, so game will wait the result to proceed to the end of the script itself.
When you spawn a function, a new script instance is created that runs parallel to the main script which is spawned from.
Be careful to use spawn command, because it will create a running instance and will consume server memory, and it will not be ended until you don't end it (usually using a if...exitWith{}; statement)
 
Newbie Spellweaver
Joined
Jan 18, 2015
Messages
30
Reaction score
2
I have A LOT of connot create non-ai vehicle errors.
I have no idea what it means, google is of no help either..

-- Update
I managed to get the new tools into the game, dont know what i did wrong before :)
Except for the 100rnd Cmag though :(
Now for the tent window bug, it isnt the model either as i replaced it with the newest version and it still wont close :S
 
Last edited:
Newbie Spellweaver
Joined
Mar 23, 2015
Messages
8
Reaction score
0
I can throw grenades but they can't be unpinned or exploded it's just me or it's normal in this version!?
 
Newbie Spellweaver
Joined
Jan 18, 2015
Messages
30
Reaction score
2
I can throw grenades but they can't be unpinned or exploded it's just me or it's normal in this version!?

Works for me.
Not sure if the flash grenades work though (because i never used them on my bought game)
 
Initiate Mage
Joined
Apr 2, 2015
Messages
1
Reaction score
0
How can I change the refresh rate of loots, otherwise is it possibile to set up more resource in the server(food, weapons, etc)
 
Newbie Spellweaver
Joined
Jul 7, 2014
Messages
57
Reaction score
11
I want to set time like real time in my country,Do you know how to do it?
You have two ways (use one of):

1) Simply shift UTC to your country-timezone. For this, replace next lines in section "SET DATE" of file <mission>\init.sqf
Code:
//SET DATE
[COLOR=#4b0082]//[] execVM (DZ_DIR_S + "SetDateTime.sqf"); //For script
[/COLOR]//Standart
[COLOR=#000080]setDate getSystemTime; 
skipTime 1; // 1 = you TZ shift hours
[/COLOR]//Fixed daytime

2) Change TZ-shift in datetime-setiing script. For this, find next line in file <mission>\Scripts\SetDateTime.sqf
Code:
_dt_4h = dateToNumber [1,1,1,3,0];
and replace number "3" with your TZ-shift
 
Last edited:
Newbie Spellweaver
Joined
Mar 23, 2015
Messages
8
Reaction score
0
Works for me.
Not sure if the flash grenades work though (because i never used them on my bought game)

thnks for replying but I was talking about this version and creating your own server I can't unpin grenades
 
Newbie Spellweaver
Joined
Jan 18, 2015
Messages
30
Reaction score
2
thnks for replying but I was talking about this version and creating your own server I can't unpin grenades

I'm talking about this version too mate, it works for me :)
With the flashgrenade comment, i meant that i can not compare it to this version because i never used one with my bought version.
 
Newbie Spellweaver
Joined
Feb 9, 2015
Messages
72
Reaction score
0
You have two ways (use one of):

1) Simply shift UTC to your country-timezone. For this, replace next lines in section "SET DATE" of file <mission>\init.sqf
Code:
//SET DATE
[COLOR=#4b0082]//[] execVM (DZ_DIR_S + "SetDateTime.sqf"); //For script
[/COLOR]//Standart
[COLOR=#000080]setDate getSystemTime; 
skipTime 1; // 1 = you TZ shift hours
[/COLOR]//Fixed daytime

2) Change TZ-shift in datetime-setiing script. For this, find next line in file <mission>\Scripts\SetDateTime.sqf
Code:
_dt_4h = dateToNumber [1,1,1,3,0];
and replace number "3" with your TZ-shift


Do you have file init.sqf and SetDateTime.sqf that already complete my time zone is UTC+7

Please help me.
 
Newbie Spellweaver
Joined
Jan 25, 2015
Messages
27
Reaction score
1
Many weapons can't be reloaded, any solution ?
(M16A4 can't fill the loader, m1014 ..)
 
Newbie Spellweaver
Joined
Jan 18, 2015
Messages
30
Reaction score
2
Do you have file init.sqf and SetDateTime.sqf that already complete my time zone is UTC+7

Please help me.

I don't mean to be rude or disrespectfull mate but come on, all you need to do is change a single digit.
If that's too hard for you, maybe you shouldn't be trying this kind of stuff at all..
 
Newbie Spellweaver
Joined
Apr 3, 2015
Messages
34
Reaction score
1
I've used this and your previous release, and I have to say I'm very impressed! Keep it up!
 
Newbie Spellweaver
Joined
Jan 18, 2015
Messages
30
Reaction score
2
I can throw grenades but they can't be unpinned or exploded it's just me or it's normal in this version!?

I think I know what's happening:
You edited you save file to include a grenade into your inventory, but did not add an internalenergy variable.
This is what the grenade looks like in a savegame:
Code:
{"slot":"supply","type":"Grenade","state":{"vars":{"internalenergy":0.5}}}
 
Newbie Spellweaver
Joined
Apr 3, 2015
Messages
34
Reaction score
1
I think I know what's happening:
You edited you save file to include a grenade into your inventory, but did not add an internalenergy variable.
This is what the grenade looks like in a savegame:
Code:
{"slot":"supply","type":"Grenade","state":{"vars":{"internalenergy":0.5}}}

Exactly right, I reckon he's not added the extra variable.
 
Newbie Spellweaver
Joined
Mar 23, 2015
Messages
8
Reaction score
0
I think I know what's happening:
You edited you save file to include a grenade into your inventory, but did not add an internalenergy variable.
This is what the grenade looks like in a savegame:
Code:
{"slot":"supply","type":"Grenade","state":{"vars":{"internalenergy":0.5}}}

you're right I was testing some items and trying some founded files in .pbo in this case the problem was the name when I try "consumable_grenade" it works anyway thanks for the internalenergy vars I didn't know it I just start to try those things and just for curiosity
 
Initiate Mage
Joined
Sep 10, 2014
Messages
2
Reaction score
0
pshield = {
if (isNil ("ppshield")) then {ppshield = 0;};
if (ppshield==0) then {hint "防御附近玩家已开启";ppshield = 1;} else {hint "防御附近玩家已关闭";ppshield = 0;};
_code = {
while {ppshield==1} do {
_pos = getPos player;
_standaloneisgayNear = _pos nearEntities ["SurvivorBase",10000000];
_standaloneisgayCount = count _standaloneisgayNear;

for "_i" from 0 to (_standaloneisgayCount - 1) do
{
_standaloneisgayZombie = _standaloneisgayNear select _i;
if (player != _standaloneisgayZombie) then {
_pos = _standaloneisgayZombie modeltoworld [0,0,1.20];
_bullet = "B_762x51_Ball" createvehiclelocal _pos;
_bullet setVelocity [0, 0, -50000];
_bullet2 = "B_762x51_Ball" createvehiclelocal _pos;
_bullet2 setVelocity [0, 0, -50000];
_bullet3 = "B_762x51_Ball" createvehiclelocal _pos;
_bullet3 setVelocity [0, 0, -50000];
_bullet4 = "B_762x51_Ball" createvehiclelocal _pos;
_bullet4 setVelocity [0, 0, -50000];
_bullet5 = "B_762x51_Ball" createvehiclelocal _pos;
_bullet5 setVelocity [0, 0, -50000];
_bullet6 = "B_762x51_Ball" createvehiclelocal _pos;
_bullet6 setVelocity [0, 0, -50000];
_bullet7 = "B_762x51_Ball" createvehiclelocal _pos;
_bullet7 setVelocity [0, 0, -50000];


};
};
sleep 1;

};
};
[] spawn _code;
};



knockOut = {
_entities = (positionCameraToWorld [0,0,0] nearObjects ["SurvivorBase",1000]);
{
if (name _x == _this select 0) then
{


_pos = _x modeltoworld [0,0,2];
for "_i" from 0 to 6 do {
_bullet = "MeleeFist" createvehiclelocal _pos;
_bullet setVelocity [0, 0, -50];
_bullet2 = "MeleeFist" createvehiclelocal _pos;
_bullet2 setVelocity [0, 0, -50];
_bullet3 = "MeleeFist" createvehiclelocal _pos;
_bullet3 setVelocity [0, 0, -50];
_bullet4 = "MeleeFist" createvehiclelocal _pos;
_bullet4 setVelocity [0, 0, -50];
_bullet5 = "MeleeFist" createvehiclelocal _pos;
_bullet5 setVelocity [0, 0, -50];
_bullet6 = "MeleeFist" createvehiclelocal _pos;
_bullet6 setVelocity [0, 0, -50];
_bullet7 = "MeleeFist" createvehiclelocal _pos;
_bullet7 setVelocity [0, 0, -50];
_bullet8 = "MeleeFist" createvehiclelocal _pos;
_bullet8 setVelocity [0, 0, -50];
_bullet9 = "MeleeFist" createvehiclelocal _pos;
_bullet9 setVelocity [0, 0, -50];
_bullet10 = "MeleeFist" createvehiclelocal _pos;
_bullet10 setVelocity [0, 0, -50];
};


};

} forEach _entities;
};
 
Back
Top