Jump to content
Sign in to follow this  
unidad2pete

spawn BIS_fnc_MP stops working

Recommended Posts

Hi,

Sometimes, all functions called by "spawn BIS_fnc_MP" stop working.

I have no idea why this happens and forces me to restart the mission to recover.

I have read on google, hackers can paralyze the libraries.

Is there any way to recover the function "spawn BIS_fnc_MP" without having to restart the mission?

I do not detect errors in scripts, which can happen for "spawn BIS_fnc_MP" stop working?

Thank you and sorry for my English level

Share this post


Link to post
Share on other sites

Post your scripts and explain when it stops working.

Share this post


Link to post
Share on other sites

It is a mission with many scripts, and it's all very untidy, is a practice mission while learning script, so do not know which particular script which I post or should look for errors.

This is the complete mission:

MEGA:

https://mega.co.nz/#!Z0wHxCAb!NleZrgj5axRx8v2UhYTCxmqkUA4hUi-bJRvNC7WpBTQ

Mediafire:

http://www.mediafire.com/?c9jugf0skot2z6u

Edit: Another error that rarely happens is that all players of the same team crash game at a time

Edit: scripts\loopserver.sqf is the most suspicious in my opinion

Edited by unidad2pete

Share this post


Link to post
Share on other sites

mega.co.nz

Why is that host trying to "save files for offline use" rather than just downloading the file to me?

Share this post


Link to post
Share on other sites
Why is that host trying to "save files for offline use" rather than just downloading the file to me?

I posted new link

Share this post


Link to post
Share on other sites
Hi,

Sometimes, all functions called by "spawn BIS_fnc_MP" stop working.

I have no idea why this happens and forces me to restart the mission to recover.

I have read on google, hackers can paralyze the libraries.

Is there any way to recover the function "spawn BIS_fnc_MP" without having to restart the mission?

I do not detect errors in scripts, which can happen for "spawn BIS_fnc_MP" stop working?

Thank you and sorry for my English level

Well, you probably have way too much going on in your mission. The fact that you made it a big mess doesn't help the situation either... as you can now see... ALWAYS ORGANIZE YOUR SCRIPTS!!!!! The second issue is the fact that BIS_fnc_MP is flawed... its been broken for a while now and BIS has completely ignored it. Probably because they are rushing to meet a deadline for 3rd quarter...

Share this post


Link to post
Share on other sites
The second issue is the fact that BIS_fnc_MP is flawed... its been broken for a while now and BIS has completely ignored it.

How exactly is it broken? I'm not aware of any problems, there are also no reported issues in the feedback tracker.

Share this post


Link to post
Share on other sites
How exactly is it broken? I'm not aware of any problems, there are also no reported issues in the feedback tracker.

From what I've seen, it stops working after about half and hour/hour and a half (only sometimes it seems, time before it breaks is kinda random, also possibly depends on what your using it for...)

this kinda screws up longer missions like Stratis-RP:Ultimate because the vehicle spawning uses BIS_fnc_MP and eventually it just stops sending anything over the network... Which then leads to players being stuck on the debug island. There is also a theory floating around that a script kiddie can do something to break this function as well...

Heres the buy vehicle scripts from his mission:

BuyVehicleServer.sqf:

/*
[[_nearVehicle,_pos,_dir,_player],"fn_BuyVehicleServer",isServer,false] spawn BIS_fnc_MP;
*/
buyVehicle_ToClient = objNull;
buyVehicle_ToServer = [];

fn_BuyVehicleServer =
{
	_nearVehicle = _this select 0;
	_pos = _this select 1;
	_dir = _this select 2;
	_player = _this select 3;
	_masterArrayInfo = _nearVehicle getVariable 'masterArrayInfo';
	_nearVehicle setPos [0,0,-50];
	hideObjectVar = [_nearVehicle,240];
	publicVariable 'hideObjectVar';
	[_nearVehicle,240] spawn fn_HideObject;
	waitUntil {_nearVehicle distance _pos > 50};
	_veh = createVehicle [(typeOf _nearVehicle),vehicleSpawnLogic, [], 0, 'CAN_COLLIDE'];
	_veh setPos [position vehicleSpawnLogic select 0, position vehicleSpawnLogic select 1, 5000 + random 500];
	_veh allowDamage false;
	_policeVeh = _nearVehicle getVariable ['policeVeh',false];
	_color = _nearVehicle getVariable ['color',nil];
	_veh setVariable ['masterArrayInfo',_masterArrayInfo,true];
	_veh setVariable ['policeVeh',_policeVeh,true];
	if(_policeVeh) then 
	{
		_veh setVariable ["lightPattern",0,true];
		if(!isNil "_color") then {[_veh,_color] call fn_PoliceTruck;};
	};
	_veh setVariable ['licensePlate',call fn_LicenseGen,true];
	_veh setVariable ['playRadio',0,true];
	_player allowDamage false;
	_player moveInDriver _veh;
	_veh disableCollisionWith _nearVehicle;
	sleep 3.5;	
	_veh setVelocity [0,0,0];
	_veh setDir _dir;
	_veh setPosATL [_pos select 0, _pos select 1, (_pos select 2) + 0.2];
	_veh setVariable ['owner',getPlayerUID _player,true];
	_veh allowDamage false;
	_player allowDamage false;
	_veh setDamage 0;
	buyVehicle_ToClient = _veh;
	(owner _player) publicVariableClient "buyVehicle_ToClient";
	//[[_veh],"fn_BuyVehicleReturn",_player,false] spawn BIS_fnc_MP;
};

"buyVehicle_ToServer" addPublicVariableEventHandler {(_this select 1) spawn fn_BuyVehicleServer;};


buyVehicleServerSideReady = 1;

BuyVehicle.sqf:

buyVehicle_ToClient = objNull;
buyVehicle_ToServer = [];

fn_BuyVehicle =
{
_nearVehicles = nearestObjects [player,['AllVehicles'],5];
if(count _nearVehicles == 0) exitWith 
	{
		closeDialog 0;
		hintSilent 'No vehicle nearby';
		playSound 'error';
	};

{
	if((!((typeOf _x) in vehicleClassMaster))) then {_nearVehicles = _nearVehicles - [_x];}
} forEach _nearVehicles;
if(count _nearVehicles == 0) exitWith 
{
	closeDialog 0;
	hintSilent 'No vehicle nearby'; 
	playSound 'error';
};


{if(_x getVariable 'hidden' == 1) then {_nearVehicles = _nearVehicles - [_x];};} forEach _nearVehicles;
if(count _nearVehicles == 0) exitWith 
{
	closeDialog 0;
	hintSilent 'No vehicle nearby'; 
	playSound 'error';
};


_nearVehicle = _nearVehicles select 0;
_forSale = _nearVehicle getVariable ['masterArrayInfo',nil];
if(isNil '_forSale') exitWith 
{
	closeDialog 0;
	hintSilent 'No vehicle nearby'; 
	playSound 'error';
};

_cost = [_nearVehicle,1] call fn_Cost;
_purchase = [_cost,(_nearVehicle getVariable 'masterArrayInfo')] call fn_Purchase;
if(_purchase select 0) then
{
	titleText ['','BLACK OUT',0.8];
	_masterArrayInfo = _nearVehicle getVariable 'masterArrayInfo';
	sleep 1;
	player setPos (position playerAwayLogic);
	playSound 'carDoor';
	_pos = position _nearVehicle;
	_dir = direction _nearVehicle;
	buyVehicle_ToServer = [_nearVehicle,_pos,_dir,player];
	publicVariableServer "buyVehicle_ToServer";
	//[[_nearVehicle,_pos,_dir,player],"fn_BuyVehicleServer",isServer,false] spawn BIS_fnc_MP;
};
};


fn_BuyVehicleReturn =
{
_veh = _this select 0;
player moveInDriver _veh;
_policeVeh = _veh getVariable ['policeVeh',false];
_color = _veh getVariable ['color',nil];
if(_policeVeh) then 
{
	if(!isNil "_color") then {[_veh,_color] call fn_PoliceTruck;};
};
_veh setVariable ["trunk",[],true];
_veh allowDamage true;
player allowDamage true;
sleep 0.1;
titleText ['','BLACK IN',0.8];
if(_veh getVariable ["policeVeh",false]) then
{
	[_veh] spawn fn_PoliceRadioLoop;
};

_veh setVariable ["coOwners",[],true];
};

"buyVehicle_ToClient" addPublicVariableEventHandler {[(_this select 1)] spawn fn_BuyVehicleReturn};

buyVehReady = 1;

Edited by austin_medic

Share this post


Link to post
Share on other sites
How exactly is it broken? I'm not aware of any problems, there are also no reported issues in the feedback tracker.

it's not broken.. :rolleyes:

i'm using this function regularly in loops (with delay) and i never experienced any troubles with that.. :cool:

btw.. thanks for great game.. :o

Share this post


Link to post
Share on other sites

Heres the buy vehicle scripts from his mission:

BuyVehicleServer.sqf:

I bet all his problems would be solved if he replaced all that with:

car = "Car" createVehicle getPos player; // better even NOT using cv array.

:) So much nonsense in those scripts.

Share this post


Link to post
Share on other sites

The error is very random. It may be 12 hours working well, but sometimes also occurs within seconds of starting the mission. My suspicion is that when users enter certain this error happens. I was testing with suspected of using some kind of hack, and they entered the server, BIS_fnc_MP stops.

it's not broken.. :rolleyes:

i'm using this function regularly in loops (with delay) and i never experienced any troubles with that.. :cool:

btw.. thanks for great game.. :o

You use some kind of script Antihack on your server?

Share this post


Link to post
Share on other sites
There is also a theory floating around that a script kiddie can do something to break this function as well...

at the end... they always can... :(

...crucial informations are stored in variables (for example BIS_fnc_MP_queue) and if they manage to change it......

and there is also not big magic around this functions.. it uses publicVariable..

Share this post


Link to post
Share on other sites
I bet all his problems would be solved if he replaced all that with:

car = "Car" createVehicle getPos player; // better even NOT using cv array.

:) So much nonsense in those scripts.

thats just one thing that uses BIS_fnc_MP... LOADS of other scripts in his mission are dependant on it (as he's built lots of the systems in it around BIS_fnc_MP... hes also stated in his mission thread that he's a bit ticked that it just stops working somewhat randomly)

It looks like BIS_fnc_MP is very broken now. After a while it stops working completely - nothing gets sent across the network with it. Broke quite a bit of stuff in my mission - I guess it's time to either wait for the function to be fixed or convert these to my own PVEH's.

Also loaded the mission in dev build only to find that it spits out tons of errors about undefined variables. It makes no sense since my variables get defined during the initialization process. Also these errors didn't show in stable build. I'm honestly feeling like just waiting for the final release of the game and just redoing the entire mission but I doubt I'll have time then...

-Zooloo75(Stealthstick)

The latest patch broke almost everything in my mission and I don't know why... The same build worked perfectly 2 days ago.

---------- Post added at 04:05 PM ---------- Previous post was at 03:37 PM ----------

I fixed the undefined vars that happen only in dev build right now. Even though the variables get defined during the initialization process in my mission, they still don't get defined. Had to define them in a separate script. Now to get rid of all BIS_fnc_MP's due to their unreliability.

Also I'm not sure if the dev build is broken or if its my mission but I'm hoping its the dev build as I'm finding a lot of bugs in the game itself such as when you freelook and stop freelooking, your player turns.

EDIT: I'm seeing lots of errors in other people's work too. I guess it's safe to assume that BIS broke something? -Zooloo75 (Stealthstick)

Edited by austin_medic

Share this post


Link to post
Share on other sites
I bet all his problems would be solved if he replaced all that with:

car = "Car" createVehicle getPos player; // better even NOT using cv array.

:) So much nonsense in those scripts.

Yeah, I need to redo the vehicle purchasing. Made that on the first days of developing the mission a few months ago - I improved tons over the course of the mission's development. But I can confirm that BIS_fnc_MP ceases to work after about an hour. I tested it on a few missions and saw that it is consistently doing this after the mission has been running for a while. I have to convert all my usage of BIS_fnc_MP with PVEH's instead which is less convenient :P

Although the code could be done simpler, most of it is not nonsense as it's crucial for the vehicle to spawn and work properly within my mission. In RP:Ultimate the player purchases a vehicle by going up to predefined vehicles on the map and buying them. The predefined vehicle is moved to an unknown spot on the map and the info needed to spawn the vehicle is taken from the predefined vehicle and then used to create the new vehicle. The player is given the illusion that they just bought the vehicle on the lot instead of having a newly spawned vehicle. All the variables tied to the vehicle defines if the vehicle is owned by the player and if the vehicle is a police vehicle and if it has a predefined color/texture,etc.

Edited by zooloo75

Share this post


Link to post
Share on other sites
Although the code could be done simpler, most of it is not nonsense as it's crucial for the vehicle to spawn and work properly within my mission.

I demand a return to the OFP days of scripting! All these "functions" are just turning our brains to mush. If we were intended to buy a vehicle it would be placed on the map from the start and we'd just have to hope it didn't blow up! Predefined colors? Hogwash! Blurry green and/or brown was good enough for my grandpappy and it's good enough for me! :)

Share this post


Link to post
Share on other sites
How exactly is it broken? I'm not aware of any problems, there are also no reported issues in the feedback tracker.

Your system works fine, the issue is BIS_fnc_MP becomes broken by cheaters. There is nothing wrong with BIS_fnc_MP.

Cheaters are telling the server to constantly write to BIS_fnc_MP_packet

Basically they do

while {true} do
{
    "BIS_fnc_MP_packet"addPublicVariableEventHandler{};
     BIS_fnc_MP_packet={};
};

I mean other then cheaters breaking it there is absolutely no issues with it.

Share this post


Link to post
Share on other sites
Your system works fine, the issue is BIS_fnc_MP becomes broken by cheaters. There is nothing wrong with BIS_fnc_MP.

Cheaters are telling the server to constantly write to BIS_fnc_MP_packet

Basically they do

while {true} do
{
    "BIS_fnc_MP_packet"addPublicVariableEventHandler{};
     BIS_fnc_MP_packet={};
};

I mean other then cheaters breaking it there is absolutely no issues with it.

That's a shame :(

I'll do some more studies on this command in a passworded/closed server with my mission and see if it still happens.

Share this post


Link to post
Share on other sites
That's a shame :(

I'll do some more studies on this command in a passworded/closed server with my mission and see if it still happens.

Yes, it is a shame because the ones that 'Wrote the bypass' don't realize how bad they break servers just so they can let their script kiddie users get past some anti-cheat systems.

The most commonly used menu to date which is mainly causing this issue is Wookie V5, you can compileFinal the variable so it stops them from creating the var.

I do:

W_O_O_K_I_E_ANTI_ANTI_HAX = compileFinal """";

Some other servers know about this issue and also compileFinal the variable before they initialize it. We really need Battleye on the stable branch ASAP because cheaters them selves are just getting out of control. Thankfully I've flagged about 70% of them so the server I code for doesn't run into issues.

Share this post


Link to post
Share on other sites
Yes, it is a shame because the ones that 'Wrote the bypass' don't realize how bad they break servers just so they can let their script kiddie users get past some anti-cheat systems.

The most commonly used menu to date which is mainly causing this issue is Wookie V5, you can compileFinal the variable so it stops them from creating the var.

I do:

W_O_O_K_I_E_ANTI_ANTI_HAX = compileFinal """";

Some other servers know about this issue and also compileFinal the variable before they initialize it. We really need Battleye on the stable branch ASAP because cheaters them selves are just getting out of control. Thankfully I've flagged about 70% of them so the server I code for doesn't run into issues.

Thanks Tonic! That Wookie guy is a pain in the ass.

Share this post


Link to post
Share on other sites

Can't you compilefinal to send the guid to the server and do a enablesimulation false;? :)

---------- Post added at 12:35 AM ---------- Previous post was at 12:34 AM ----------

Edit: that was meant as a "you should" :)

Share this post


Link to post
Share on other sites
Can't you compilefinal to send the guid to the server and do a enablesimulation false;? :)

---------- Post added at 12:35 AM ---------- Previous post was at 12:34 AM ----------

Edit: that was meant as a "you should" :)

Clever! :P

Share this post


Link to post
Share on other sites

Tho I'm not sure if anything runs or is logged if something tries to override functions

Share this post


Link to post
Share on other sites

Instead of enablesimulation false.

Make his keyboard useless.

disableSerialization;

_display = findDisplay 46;

_display displayAddEventHandler ["KeyDown", "true"];

There are other ways to do stuff, but this will cause his game to break and crash on start up. 2 wrongs doesn't make a right.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×