Jump to content
  • 0

[SOLVED] Flyby Script from 1.0.5.1 for 1.0.6.1 Need Help


Thug

Question

[SOLVED]

Would like to run the old 1.0.5.1 flyby.sqf  on my servers. Don't know what I need to make it work with 1.0.6.1

Also, does anyone have any of the old events working and willing to share?

Here is the link to the script

https://pastebin.com/eRk5phkc

If anyone is willing to help, I will buy you a beer in game  Heck I will buy you a case.  lol

EDITED 4 PM EST 7/10/2017 

Can someone tell me where the supply_drop and crash_spawner is located. I went to dayz_server\modules and the only thing in the scripts was this;

// Using vanilla care packages now. 
// The 1.0.5.1 version was outdated and needs a full rewrite.

These files have to be somewhere, just need a little help with finding them.

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0
Just now, Thug said:

Would like to run the old 1.0.5.1 flyby.sqf  on my servers. Don't know what I need to make it work with 1.0.6.1

Also, does anyone have any of the old events working and willing to share?

Here is the link to the script

https://pastebin.com/eRk5phkc

If anyone is willing to help, I will buy you a beer in game  Heck I will buy you a case.  lol

EDITED 4 PM EST 7/10/2017 

Can someone tell me where the supply_drop and crash_spawner is located. I went to dayz_server\modules and the only thing in the scripts was this;

// Using vanilla care packages now. 
// The 1.0.5.1 version was outdated and needs a full rewrite.

These files have to be somewhere, just need a little help with finding them.

 

Spoiler

private["_model","_startpos","_endpos","_rand_player"];
 
//_model = "AN2_DZ";
_model = ["A10","AH64D_EP1","AV8B","C130J_US_EP1","F35B","Ka137_MG_PMC","Ka52","L39_TK_EP1","MQ9PredatorB_US_EP1","MV22","Mi24_D","Su25_CDF",
"Su25_TK_EP1","pook_H13_gunship"] call BIS_fnc_selectRandom;
       
_startpos = [
    [1000.0,2.0],
    [3500.0,2.0],
    [5000.0,2.0],
    [7500.0,2.0],
    [9712.0,663.067],
    [12304.0,1175.07],
    [14736.0,2500.0],
    [16240.0,5000.0],
    [16240.0,7500.0],
    [16240.0,10000.0]
            ] call BIS_fnc_selectRandom;
           
_rand_player    = playableUnits call BIS_fnc_selectRandom;
 
if (isNil "EPOCH_EVENT_RUNNING") then {
EPOCH_EVENT_RUNNING = false;
};
 

if (EPOCH_EVENT_RUNNING) exitWith {
diag_log("Event already running");
};

EPOCH_EVENT_RUNNING = true;

if((isPlayer _rand_player) && (alive _rand_player)) then {
 
    _rand_num        = ceil(random 5);
    _playerpos        = [_rand_player] call FNC_GetPos;
    _number            = 0;
 
    for "_i" from 1 to _rand_num do {
   
        _number = (_number + 1);
 
        [_number,_model,_startpos,_playerpos] spawn {
 
            private["_aircraft","_aigroup","_pilot","_wp1","_wp2","_cor_y","_cor_x"];
           
            _number     = _this select 0;
            _model         = _this select 1;
            _startpos     = _this select 2;
            _playerpos     = _this select 3;            
            _endpos        = [0,16000,200];
 
            call {
                if(_number == 1) exitWith {
                    _cor_y = 0;
                    _cor_x = 0;
                };
 
                if(_number == 2) exitWith {
                    _cor_y = -60;
                    _cor_x = -60;
                };
 
                if(_number == 3) exitWith {
                    _cor_y = -60;
                    _cor_x = 60;
                };
 
                if(_number == 4) exitWith {
                    _cor_y = -120;
                    _cor_x = -120;
                };
 
                if(_number == 5) exitWith {
                    _cor_y = -120;
                    _cor_x = 120;
                };
            };
 
            _aircraft     = createVehicle [_model,[((_startpos select 0) + _cor_y),((_startpos select 1) + _cor_x),200],[],0,"FLY"];
            _aircraft     engineOn true;
            _aircraft     flyInHeight 200;
			_aircraft 		addEventHandler ["GetOut",{(_this select 0) setFuel 0;(_this select 0) setDamage 1;}];
_aircraft addEventHandler ["handleDamage", {false}];

dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_aircraft];
 
            _aigroup     = creategroup civilian;
 
            _pilot         = _aigroup createUnit ["SurvivorW2_DZ",[_aircraft] call FNC_GetPos,[],0,"FORM"];
            _pilot         setCombatMode "BLUE";
            _pilot         moveindriver _aircraft;
            _pilot         assignAsDriver _aircraft;
 
            _wp1         = _aigroup addWaypoint [[((_playerpos select 0) + _cor_y),((_playerpos select 1) + _cor_x),200],0];
            _wp1         setWaypointType "MOVE";
            _wp1        setWaypointBehaviour "CARELESS";
 
            _wp2         = _aigroup addWaypoint [[(_endpos select 0),(_endpos select 1),200],0];
            _wp2         setWaypointType "MOVE";
            _wp2         setWaypointBehaviour "CARELESS";
 
            waitUntil { (_aircraft distance _endpos < 500) };
 
            deleteVehicle _aircraft;
            deleteGroup _aigroup;
            deleteVehicle _pilot;
 

        };
    };
     EPOCH_EVENT_RUNNING = false;                                                     
};

 

 

Link to comment
Share on other sites

  • 0
Just now, Thug said:

I also started adding in other planes. So far 

"A10","Su25_CDF","AN2_DZ"  working great

Yup u can add any kind of flying veh since the line about obj monitor was added.

dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_aircraft];

This prevent the veh sched destroy your veh cuz is not signed . I say flying veh cuz cannot imagine landveh in this script. Explain it before cleandirella comes to say me you can add anykind of veh.:tongue:

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Discord

×
×
  • Create New...