ShootingBlanks
OpenDayZ Guru!
wut wut wut?
the file above worked (hence Proof of Concept), all it required was separating the two parts to serverside and clientside. So we take the busroute.sqf for serverside and add a script that constantly updates the bus location and a clientside that constantly updates the marker. So we need two very simple, short and easy bits of code.
add this to the bottom of your busroute.sqf, any busroute should work ... actually any item at all you want to track could use this
move the marker script to its own file busmarker.sqf and exec it from the init.sqf
Untested but should work. Next features would be to give different orders at certain waypoints. Like have them pull up at the fuel pump, get out and stand by the pump as if they are pumping. Or run into the general store and buy cigarettes ...
the file above worked (hence Proof of Concept), all it required was separating the two parts to serverside and clientside. So we take the busroute.sqf for serverside and add a script that constantly updates the bus location and a clientside that constantly updates the marker. So we need two very simple, short and easy bits of code.
add this to the bottom of your busroute.sqf, any busroute should work ... actually any item at all you want to track could use this
Code:
while {true} do{
thebuslocation = getpos thebus;
publicvariable "thebuslocation";
sleep 3;
};
move the marker script to its own file busmarker.sqf and exec it from the init.sqf
Code:
if (isserver) exitwith{};
_markerpos = createmarker["busmarker",theBuslocation];
_markerpos setMarkerType "mil_dot";
_markerpos setMarkerColor "ColorRed";
while {true} do {
"busmarker" setMarkerPosLocal theBuslocation;
sleep 3;
};
Untested but should work. Next features would be to give different orders at certain waypoints. Like have them pull up at the fuel pump, get out and stand by the pump as if they are pumping. Or run into the general store and buy cigarettes ...
Last edited: