DayZWasteLandZ

Sounds like a plan, what ever i get working ill post, have a diffrent intent i think helps get more things working
 
Very interesting, also have a server and am moving into arma2 scripting. Particularly interested in the gun shop I have read about.. merging these two would make an awesome game.. watching this space :)
 
Dumb question but how are you setting up your shortcut to run a dedicated server for Wasteland ?

Does it use the Beta expansions and am not sure how to specify the Mission file, -cfg, -config or -profile.

ta.
 
You need cpbo or pbo manager to make pbo files it also extracts the contents, im editing my dayz mission file to match that of wasteland. You can also just put a folder with the mission files on the server in the same place
 
I can do that but how do I reference the MPMission in the dedicated server shortcut so that the server is running Wasteland ?

I am assuming that I am using D:\arma 2\Expansion\beta\Arma2OAserver.exe

thanks.
 
Yay, sussed it, is in the config file :)

For anyone else trying:

Startup:
Code:
D:\arma2~1\arma2oaserver.exe -name=Wasteland -cfg=Wasteland_v1db.Chernarus\basic.cfg -config=Wasteland_v1db.Chernarus\config_wland.cfg -world=chernarus" -cpuCount=2 -noSplash -showScriptErrors

Line in config_wland.cfg:

Code:
template = Wasteland_v1db.Chernarus;

I suspect it may not be perfect as I had a dayZ vehicles error but the server is working :)
 
sorry i was at work, yup your right on mark all the settings you need are on the startup, you should be able to just add "D:\arma 2\MPMissions\Wasteland_v1db.Chernarus.pbo" at the end and it should autolaunch with that.

I have steam installed on my C drive, my D drive is a 2ndary 1tb drive that i run my home arma server on, what i did is copy all of my arma 2 folder into "d:\arma 2" then copied my arma 2 OA folder into that folder and just replaced anything that gave me problems.

Then i downloaded the bliss server and installed strawberry perl, i did not however install mysql from the mysql website, what i did instead was install EasyPHP 12.1 which has the version of mysql required by dayz bliss, i dont know if this is going to work or cause problems but im testing it out atm.

then i followed the instructions on the dayzbliss website on github. which made be run perl build.pl then update the db and then spawn the vehicles.

the issue is im on a bliss server, i dont know if the ability to spawn a vehicle and publish it to the hive works or not from the server itself while its running, even on our production server we have to run a perl script which still requires a restart, so atm im currently testing how to get around the restrictions in place and not screw up my live server.
 
Have read that vehicle spawning is possible but with weird effects. vehicles not lasting, player booted from vehicle, blowing up etc. Maybe adding the vehicle into the database at the same time as spawning it into the game would help. Am assuming there would be some ID that would need to match up..

I usually add vehicles into the database manually and then 'soft restart' the server (with restart rcon command through BE), I get vehicle details with:

Code:
SELECT instance_vehicle.id, instance_vehicle.inventory, instance_vehicle.parts, instance_vehicle.fuel, instance_vehicle.damage, vehicle.class_name, instance_vehicle.last_updated FROM vehicle RIGHT JOIN (instance_vehicle LEFT JOIN world_vehicle ON instance_vehicle.world_vehicle_id = world_vehicle.id) ON vehicle.id = world_vehicle.vehicle_id WHERE instance_vehicle.damage > 0

Have also got a way to move them just before a server restart from a webpage with:

Code:
UPDATE instance_vehicle SET worldspace='"+strLocation+"' WHERE id='"+strVehID+"'

Have not had any issues creating and moving vehicles like this except the rare occasion BE moans and boots once. I think is because the worldspace is identical to the survivor the vehicle is 'spawned on'. To be fixed soon by offsetting the vehicle a tiny bit..
 
Im still tring to figure out the publishing with out having to modify anything other than the mission file. last night(if you call 4 hours ago last night) i managed to get a working spawn in game however the issue is it still is a "illegal" vehicle, the problem is getting back into the fsm to set the value of the _safety array.

So far what i have tried is creating a eventhandler for the server and then having it call a sqf file that is supposed to be able to call fsm and update it but it seems to never get called and never updates.. i haven't played with fsm's so im unfamilair with them in general, heck with arma code in general lol....
 
Am pretty sure the illegal vehicles are built into the dayZ code now. Adding any non standard ones in would mean changing and redistributing the code, not ideal. Thats what is great about the missions as they are downloaded.

I have spent a lot of time trying to find non standard vehicles to add to dayZ, have found 3 that don't return the cannot create non ai vehicle in the .rpt log.

Found this discussion of sqf vs fsm: http://forums.bistudio.com/archive/index.php/t-87450.html

And this on fsm: http://community.bistudio.com/wiki/FSM

Looks like fsm returns better performance on fps.

How are you merging the two, are you trying to run the wasteland mission on a dayZ server ? If so, personally I would stick with the standard dayZ vehicles.
 
Or, on vehicle banning, is it possible to overwrite the dayZ function that checks for vehicles in a new mission..? Am going to see if I can find what bans vehicles in the dayZ code. Would like to have some extra vehicles on my server.

Rocket banned them in the code originally to stop the hackers spawning tanks n parachutting cows etc. BE seems to have the vehicle spawning fairly covered now.

Covered here: http://www.tunngle.net/community/topic/82911-arma-2-vehicles-in-dayz-mod/
 
should add the zombies from the UNdead mod. those are more realistic. people will need to download more add ons
 
When i say illegal i dont me banned, at the moment i have started working with my server owner since he is more fluent with the mysql and also knows more c++ than me, i had him download the hive source code so we could look at the vehicle spawning system and see if it is possible to publish the vehicle data base into the hive with out modifying @hive.

So far i have been able to spawn a vehicle with this dirty code:
Code:
waitUntil{allowConnection};
    _type = "UH1H_DZ";
    _dir = (random 360);
    _pos =[13485,4421,0];
    _newPos = [_pos, 0, 100, 10, 0, 500, 0] call BIS_fnc_findSafePos;
    diag_log format["Attempting to spawn new vehicle: %1 at location %2",_type,str(_newPos)];
  // _newVehicle = ["UH1H_DZ",_newPosr] call object_spawnGoodVehicle;  //object_spawnDamVehicle;
 
    _veh = _type createVehicle _newPos; // [,, [], 0, "CAN_COLLIDE"];
    _veh setDir _dir;
    _veh setPos getPos _veh;
 
    //_veh setVariable ["ObjectID",1,true];
   
    _veh setVariable ["ObjectID", [_dir,_newPos] call dayz_objectUID2, true];
 
    _hitpoints = _veh call vehicle_getHitpoints;
    _dam = 0.05;
    _veh setFuel 1;
    _veh call fnc_vehicleEventHandler;
    {
        _hit = [_veh,_x] call object_getHit;
        _selection = getText (configFile >> "CfgVehicles" >> (typeOf _veh) >> "HitPoints" >> _x >> "name");
        if (_hit > 0) then {_array set [count _array,[_selection,_hit]]};
    } forEach _hitpoints;
       
      dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_veh];
      [_veh,_type] spawn server_updateObject;

This spawns the uh1, it is able to take damage i see that in the log files that the server is trying to update its info. however when i land im unable to view the damage, i believe it is because the vehicle is not in the hive. So i need to find out how to add it to the hive. so now im back to taking apart the hive.dll.

I might need to add :
Code:
    dayzVehicleInit = _veh;
    publicVariable "dayzVehicleInit";

To the above i see that call in another script that isn't currently used.

This is the spawning routine that creates everything on the server, both vehicles and deployables.

Code:
diag_log("SERVER: Starting spawn routine.");
//Spawn objects
_countr = 0;
_count_veh = 0;
{
    //Parse individual vehicle row
    _countr = _countr + 1;
 
    _idKey =    _x select 1;
    _type =        _x select 2;
    _ownerID =    _x select 3;
   
    _worldspace = _x select 4;
    _dir = 0;
    _pos = [0,0,0];
    _wsDone = false;
    if (count _worldspace >= 2) then
    {
        _dir = _worldspace select 0;
        if (count (_worldspace select 1) == 3) then {
            _pos = _worldspace select 1;
            _wsDone = true;
        }
    };           
    if (!_wsDone) then {
        if (count _worldspace >= 1) then { _dir = _worldspace select 0; };
        _pos = [getMarkerPos "center",0,4000,10,0,2000,0] call BIS_fnc_findSafePos;
        if (count _pos < 3) then { _pos = [_pos select 0,_pos select 1,0]; };
        diag_log ("MOVED OBJ: " + str(_idKey) + " of class " + _type + " to pos: " + str(_pos));
    };
   
    _intentory=    _x select 5;
    _hitPoints=    _x select 6;
    _fuel =        _x select 7;
    _damage =    _x select 8;
   
    if (_damage < 1) then {
        diag_log("Spawned: " + str(_idKey) + " " + _type);
       
        _object = createVehicle [_type, _pos, [], 0, "CAN_COLLIDE"];
        _object setVariable ["lastUpdate",time];
 
        // Don't set objects for deployables to ensure proper inventory updates
        if (_ownerID == "0") then {
            _object setVariable ["ObjectID", str(_idKey), true];
        } else {
            _object setVariable ["ObjectUID", _worldspace call dayz_objectUID2, true];
        };
 
        _object setVariable ["CharacterID", _ownerID, true];
       
        clearWeaponCargoGlobal  _object;
        clearMagazineCargoGlobal  _object;
       
        if (_object isKindOf "TentStorage") then {
            _pos set [2,0];
            _object setpos _pos;
        };
        _object setdir _dir;
        _object setDamage _damage;
       
        if (count _intentory > 0) then {
            //Add weapons
            _objWpnTypes = (_intentory select 0) select 0;
            _objWpnQty = (_intentory select 0) select 1;
            _countr = 0;                   
            {
                _isOK =    isClass(configFile >> "CfgWeapons" >> _x);
                if (_isOK) then {
                    _block =    getNumber(configFile >> "CfgWeapons" >> _x >> "stopThis") == 1;
                    if (!_block) then {
                        _object addWeaponCargoGlobal [_x,(_objWpnQty select _countr)];
                    };
                };
                _countr = _countr + 1;
            } forEach _objWpnTypes;
           
            //Add Magazines
            _objWpnTypes = (_intentory select 1) select 0;
            _objWpnQty = (_intentory select 1) select 1;
            _countr = 0;
            {
                _isOK =    isClass(configFile >> "CfgMagazines" >> _x);
                if (_isOK) then {
                    _block =    getNumber(configFile >> "CfgMagazines" >> _x >> "stopThis") == 1;
                    if (!_block) then {
                        _object addMagazineCargoGlobal [_x,(_objWpnQty select _countr)];
                    };
                };
                _countr = _countr + 1;
            } forEach _objWpnTypes;
 
            //Add Backpacks
            _objWpnTypes = (_intentory select 2) select 0;
            _objWpnQty = (_intentory select 2) select 1;
            _countr = 0;
            {
                _isOK =    isClass(configFile >> "CfgVehicles" >> _x);
                if (_isOK) then {
                    _block =    getNumber(configFile >> "CfgVehicles" >> _x >> "stopThis") == 1;
                    if (!_block) then {
                        _object addBackpackCargoGlobal [_x,(_objWpnQty select _countr)];
                    };
                };
                _countr = _countr + 1;
            } forEach _objWpnTypes;
        };   
       
        if (_object isKindOf "AllVehicles") then {
            {
                _selection = _x select 0;
                _dam = _x select 1;
                if (_selection in dayZ_explosiveParts and _dam > 0.8) then {_dam = 0.8};
                [_object,_selection,_dam] call object_setFixServer;
            } forEach _hitpoints;
            _object setvelocity [0,0,1];
            _object setFuel _fuel;
            if (getDammage _object == 1) then {
                _position = ([(getPosATL _object),0,100,10,0,500,0] call BIS_fnc_findSafePos);
                if (count _pos < 3) then { _pos = [_pos select 0,_pos select 1,0]; };
                _object setPosATL _position;
            };
                    _object call fnc_vehicleEventHandler;   
                    _count_veh = _count_veh + 1;
        };
 
        //Monitor the object
        //_object enableSimulation false;
        dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_object];
    };
} forEach _objList;
 
diag_log ("SERVER: Spawned " + str(_count_veh) + " vehicles!");

That is after changing my server_cleanup.fsm which runs on the server_code.pbo file on the server itself.

That is i changed the general clean up to no longer check the dayz_serverObjectMonitor array and "kill the hacker", however while typing this response i just looked at my code and noticed a typo with test run 3 of not modifying the server code........

yeah that what i get for coding at 4am on 3 hours of sleep......

this is my update fsm code:
Code:
private ["_id","_vehicle","_fsmcount"];
diag_log("Attempting to update FSM");
_id = _this select 0;
_vehicle = _this select 1;
_fsmcount = _thisFSM getFSMVariable "_safety";
diag_log ("Found FSM array with" + str(_fsmcount) + " objects");
_fsmcount set [count _fsmcount,_vehicle];
dayz_safety = _fsmcount;
_id setFSMVariable["_safety",_fsmcount];
_fsmcount = _thisFSM getFSMVariable "_safety";
diag_log ("updated FSM array has" + str(_fsmcount) + " objects");
if(true) exitWith{};

The change is in server_monitor.sqf to include a handle:
Code:
if (isDedicated) then {
    _fsmid = [] execFSM "\z\addons\dayz_server\system\server_cleanup.fsm";   
    "dayzUpdateCleanFSM"    addPublicVariableEventHandler {[_fsmid,[_this select 1]] execVM "fixes\updateFSM.sqf"}; 
};

P.S. Sorry audio for hijacking your thread i would make another post but i think it is relevant to what your doing, i figure your working on mission stuff since i haven't heard anything about vehicles from you.
 
Rocket uses the FSM to ban mission vehicles thats what i was talking about above in my nonsense post.

should add the zombies from the UNdead mod. those are more realistic. people will need to download more add ons
the above work im doing only require more mods if you DONT modify wasteland to ONLY generate dayz vehicles, it will be entirely possible to use wasteland with VanillaZ,

It will be in a config file for the spawning, if you want dayz to stop blowing up your vehilces you spawn because of hackers then you need a patched FSM here is the one from my server i created:
https://docs.google.com/file/d/0By9zTEuk5q1EdU9hVXloUVBTSFE/edit

This file goes in the follow location:

"???\Arma 2 server\@bliss_1.chernarus\addons\dayz_server.pbo > system\server_cleanup.fsm"

You need to unpack you pbo file using pbo manager or eliteness and replace the one that is there with that one.

I take no responsibility for anything anyone does to their own servers using the information i have provided.


If you want to modify the file your self download the BI tools and open it with the FSM editor the change is in the general clean box and the code should be changed to the following:

Code:
//Clean groups
{
    //diag_log ("CLEANUP: CHECKING GROUP WITH " + str(count units _x) + " UNITS");
    if (count units _x==0) then {
        deleteGroup _x;
        //diag_log ("CLEANUP: DELETING A GROUP");
    };
} forEach allGroups;
 
//Check for hackers
// {
//      if(vehicle _x != _x && !(vehicle _x in _safety) && (typeOf vehicle _x) != "ParachuteWest") then {
//        diag_log ("CLEANUP: KILLING A HACKER " + (name _x) + " " + str(_x) + " IN " + (typeOf vehicle _x));
//          (vehicle _x) setDamage 1;
//          _x setDamage 1;
//    };
// } forEach allUnits;
//
//dayz_serverObjectMonitor = _safety;

repack that, change your old server pbo to dayz_server.old and upload this one in its place, restart your server.
(yes i did just tell you to back up your server file instead of merely suggesting it)

Personally i dont care about a less restrictive DayZ because all i really want dayz for is the hive system, if could have the hive as a addon with out dayz i wouldn't even be here, yes i have already looked at MSO it doesn't sync skins you dont have to eat thats the rper in me.

Right now im trying to learn the dayz code so i can modify it, if the hive system was a addon then i wouldn't even be having issues because this would be document, well it is a add on but i haven't found the documentation for the key codes
 
Don't forget, the independent team on wasteland is allowed to teamkill to their hearts content. Shove everyone on independent, get rid of nameplates and the colored dot above their head and you are good to go.
 
The issue is that their is a trigger created in dayz on each city you enter that is set to turn on the "dezombify" function for each city, its tied to WEST so you have to have a bluefor person in order to trigger the zombies and when you dont have one it triggers the despawn.

This is the code itself:

Code:
_trigger = createTrigger["EmptyDetector",_position];
_trigger setTriggerArea[dayz_zSpawnDistance,dayz_zSpawnDistance,0,false];
_trigger setTriggerActivation["WEST","NOT PRESENT",false];

now the easy fix would be to just simply change that side to GUER, i thinking depending on the zombie code i might make zombies guer and bandits east and npcs civilian.
 
i'm searching for a ingame vehicle spawn script that handled with the hive...so thats not despawned/blowed up when i restart the server. (Spawning Vehicles for events....)

:)
 
Im working on that code in the "need help with @hive" thread. Im hoping to have something ready by tonight
 
Back
Top