Jump to content
  • 0

Fn_selfaction.sqf clientside .rpt error any help :) ?


StiflersM0M

Question

Hey guys,

i installed this here:

and now i get theese errors in my client rpt,

"Error Nicht definierte Variable in Ausdruck = Error not defined variable in expression"

} else {
dayz_addsirens removeAction s_player_sir>
  Error position: <dayz_addsirens removeAction s_player_sir>
  Error Nicht definierte Variable in Ausdruck: dayz_addsirens
File mpmissions\__CUR_MP.Chernarus\custom\fn_selfActions.sqf, line 35
Error in expression <sirens,2,false,true,"",""];
};
} else {
dayz_addsirens removeAction s_player_sir>
  Error position: <dayz_addsirens removeAction s_player_sir>
  Error Nicht definierte Variable in Ausdruck: dayz_addsirens
File mpmissions\__CUR_MP.Chernarus\custom\fn_selfActions.sqf, line 35
Error in expression <sirens,2,false,true,"",""];
};

here is my fn_selfaction.sqf -> http://pastebin.com/EiR2qcjs script start at line 35 and finished at 51

any help would be nice :)

 

Link to comment
Share on other sites

12 answers to this question

Recommended Posts

  • 0

//Sirens
_isCopcar = typeOf _vehicle in ["SUV_TK_CIV_EP1","SUV_TK_CIV_EP1_DZE1","SUV_TK_CIV_EP1_DZE2","SUV_TK_CIV_EP1_DZE3","SUV_TK_CIV_EP1_DZE4","LadaLM","LadaLM_DZE1","LadaLM_DZE2","LadaLM_DZE3","LadaLM_DZE4","policecar"];

if (_inVehicle and (driver _vehicle == player)) then {
        dayz_addsirens = _vehicle;
		if (_isCopcar) then {	
    if (s_player_sirens_on < 0) then {
        s_player_sirens_on = dayz_addsirens addAction ["Sirens on","Scripts\sirens\sirens_on.sqf",dayz_addsirens,2,false,true,"",""];
        s_player_sirens_off = dayz_addsirens addAction ["Sirens off","Scripts\sirens\sirens_off.sqf",dayz_addsirens,2,false,true,"",""];
        };        <------------------------------------ 1 too many
	};
    } else {
        dayz_addsirens removeAction s_player_sirens_on;
        dayz_addsirens removeAction s_player_sirens_off;
        s_player_sirens_on = -1;
        s_player_sirens_off = -1;
    };	
	

 just had a quick scan over the script installation instructions and seems you have 1 }; too many

 

 

worth a try

  

 

sukkaeds instruction

//Sirens
_isCopcar = typeOf _vehicle in ["SUV_TK_CIV_EP1","SUV_TK_CIV_EP1_DZE1","SUV_TK_CIV_EP1_DZE2","SUV_TK_CIV_EP1_DZE3","SUV_TK_CIV_EP1_DZE4","LadaLM","LadaLM_DZE1","LadaLM_DZE2","LadaLM_DZE3","LadaLM_DZE4","policecar"];

if (_inVehicle and _isCopcar and (driver _vehicle == player)) then {
        dayz_addsirens = _vehicle;
    if (s_player_sirens_on < 0) then {
        s_player_sirens_on = dayz_addsirens addAction ["Sirens on","Scripts\sirens\sirens_on.sqf",dayz_addsirens,2,false,true,"",""];
        s_player_sirens_off = dayz_addsirens addAction ["Sirens off","Scripts\sirens\sirens_off.sqf",dayz_addsirens,2,false,true,"",""];
        };
    } else {
        dayz_addsirens removeAction s_player_sirens_on;
        dayz_addsirens removeAction s_player_sirens_off;
        s_player_sirens_on = -1;
        s_player_sirens_off = -1;
    };
Link to comment
Share on other sites

  • 0

This is mine and i still get the error?

if (_inVehicle and _isCopcar and (driver _vehicle == player)) then {
        dayz_addsirens = _vehicle;
    if (s_player_sirens_on < 0) then {
        s_player_sirens_on = dayz_addsirens addAction ["Siren on","Custom\Siren\sirens_on.sqf",dayz_addsirens,2,false,true,"",""];
        s_player_sirens_off = dayz_addsirens addAction ["Siren off","Custom\Siren\sirens_off.sqf",dayz_addsirens,2,false,true,"",""];
        };
    } else {
        dayz_addsirens removeAction s_player_sirens_on;
        dayz_addsirens removeAction s_player_sirens_off;
        s_player_sirens_on = -1;
        s_player_sirens_off = -1;
    };
Link to comment
Share on other sites

  • 0

Try this:

//Sirens

_isCopcar = typeOf _vehicle in ["SUV_TK_CIV_EP1","SUV_TK_CIV_EP1_DZE1","SUV_TK_CIV_EP1_DZE2","SUV_TK_CIV_EP1_DZE3","SUV_TK_CIV_EP1_DZE4","LadaLM","LadaLM_DZE1","LadaLM_DZE2","LadaLM_DZE3","LadaLM_DZE4","policecar"];


if (_inVehicle and (driver _vehicle == player)) then {
        dayz_addsirens = _vehicle;
if (_isCopcar) then { 
    if (s_player_sirens_on < 0) then {
        s_player_sirens_on = dayz_addsirens addAction ["Sirens on","Scripts\sirens\sirens_on.sqf",dayz_addsirens,2,false,true,"",""];
        s_player_sirens_off = dayz_addsirens addAction ["Sirens off","Scripts\sirens\sirens_off.sqf",dayz_addsirens,2,false,true,"",""];
};
    } else {
        dayz_addsirens removeAction s_player_sirens_on;
        dayz_addsirens removeAction s_player_sirens_off;
        s_player_sirens_on = -1;
        s_player_sirens_off = -1;
    };
}; 

Pry

(EDITED TO ADD LINE BREAK AFTER //SIRENS)

Edited by PryMary
Link to comment
Share on other sites

  • 0

Try this:

//Sirens_isCopcar = typeOf _vehicle in ["SUV_TK_CIV_EP1","SUV_TK_CIV_EP1_DZE1","SUV_TK_CIV_EP1_DZE2","SUV_TK_CIV_EP1_DZE3","SUV_TK_CIV_EP1_DZE4","LadaLM","LadaLM_DZE1","LadaLM_DZE2","LadaLM_DZE3","LadaLM_DZE4","policecar"];


if (_inVehicle and (driver _vehicle == player)) then {
        dayz_addsirens = _vehicle;
if (_isCopcar) then { 
    if (s_player_sirens_on < 0) then {
        s_player_sirens_on = dayz_addsirens addAction ["Sirens on","Scripts\sirens\sirens_on.sqf",dayz_addsirens,2,false,true,"",""];
        s_player_sirens_off = dayz_addsirens addAction ["Sirens off","Scripts\sirens\sirens_off.sqf",dayz_addsirens,2,false,true,"",""];
};
    } else {
        dayz_addsirens removeAction s_player_sirens_on;
        dayz_addsirens removeAction s_player_sirens_off;
        s_player_sirens_on = -1;
        s_player_sirens_off = -1;
    };
}; 

Pry

 

How would this work if _iscopcar is commented out?

Link to comment
Share on other sites

  • 0
//Sirens

_isCopcar = typeOf _vehicle in ["SUV_TK_CIV_EP1","SUV_TK_CIV_EP1_DZE1","SUV_TK_CIV_EP1_DZE2","SUV_TK_CIV_EP1_DZE3","SUV_TK_CIV_EP1_DZE4","LadaLM","LadaLM_DZE1","LadaLM_DZE2","LadaLM_DZE3","LadaLM_DZE4","policecar"];


if (_inVehicle and (driver _vehicle == player)) then {
        dayz_addsirens = _vehicle;
if (_isCopcar) then {
    if (s_player_sirens_on < 0) then {
        s_player_sirens_on = dayz_addsirens addAction ["Sirens on","Scripts\sirens\sirens_on.sqf",dayz_addsirens,2,false,true,"",""];
        s_player_sirens_off = dayz_addsirens addAction ["Sirens off","Scripts\sirens\sirens_off.sqf",dayz_addsirens,2,false,true,"",""];
};
    } else {
        dayz_addsirens removeAction s_player_sirens_on;
        dayz_addsirens removeAction s_player_sirens_off;
        s_player_sirens_on = -1;
        s_player_sirens_off = -1;
    };
};

Don't know why it copied like that but not hard to work out what to do, just needed to press enter after: //Sirens

 

Now try!

 

Pry

Link to comment
Share on other sites

  • 0
//Sirens

_isCopcar = typeOf _vehicle in ["SUV_TK_CIV_EP1","SUV_TK_CIV_EP1_DZE1","SUV_TK_CIV_EP1_DZE2","SUV_TK_CIV_EP1_DZE3","SUV_TK_CIV_EP1_DZE4","LadaLM","LadaLM_DZE1","LadaLM_DZE2","LadaLM_DZE3","LadaLM_DZE4","policecar"];


if (_inVehicle and (driver _vehicle == player)) then {
        dayz_addsirens = _vehicle;
if (_isCopcar) then {
    if (s_player_sirens_on < 0) then {
        s_player_sirens_on = dayz_addsirens addAction ["Sirens on","Scripts\sirens\sirens_on.sqf",dayz_addsirens,2,false,true,"",""];
        s_player_sirens_off = dayz_addsirens addAction ["Sirens off","Scripts\sirens\sirens_off.sqf",dayz_addsirens,2,false,true,"",""];
};
    } else {
        dayz_addsirens removeAction s_player_sirens_on;
        dayz_addsirens removeAction s_player_sirens_off;
        s_player_sirens_on = -1;
        s_player_sirens_off = -1;
    };
};

Don't know why it copied like that but not hard to work out what to do, just needed to press enter after: //Sirens

 

Now try!

 

Pry

 

Mhh yes it works but also it doesnt work xD

now i get theese:

Error in expression <ens,2,false,true,"",""];
};
};
} else {
dayz_addsirens removeAction s_player_sir>
  Error position: <dayz_addsirens removeAction s_player_sir>
  Error Nicht definierte Variable in Ausdruck: dayz_addsirens
File mpmissions\__CUR_MP.Chernarus\custom\fn_selfActions.sqf, line 49
Link to comment
Share on other sites

  • 0

If you are using the latest steam update then you will get this. It seems as though more variables need to be defined. You would need to let the mod maker aware that it is creating an error in the client RPT.

 

It's even happening with the elevator mod and also a few others that I have seen.

 

Pry

Link to comment
Share on other sites

  • 0
//Sirens

_isCopcar = typeOf _vehicle in ["SUV_TK_CIV_EP1","SUV_TK_CIV_EP1_DZE1","SUV_TK_CIV_EP1_DZE2","SUV_TK_CIV_EP1_DZE3","SUV_TK_CIV_EP1_DZE4","LadaLM","LadaLM_DZE1","LadaLM_DZE2","LadaLM_DZE3","LadaLM_DZE4","policecar"];


if (_inVehicle and (driver _vehicle == player)) then {
        dayz_addsirens = _vehicle;
if (_isCopcar) then {
    if (s_player_sirens_on < 0) then {
        s_player_sirens_on = dayz_addsirens addAction ["Sirens on","Scripts\sirens\sirens_on.sqf",dayz_addsirens,2,false,true,"",""];
        s_player_sirens_off = dayz_addsirens addAction ["Sirens off","Scripts\sirens\sirens_off.sqf",dayz_addsirens,2,false,true,"",""];
};
    } else {
        dayz_addsirens removeAction s_player_sirens_on;
        dayz_addsirens removeAction s_player_sirens_off;
        s_player_sirens_on = -1;
        s_player_sirens_off = -1;
    };
};

Don't know why it copied like that but not hard to work out what to do, just needed to press enter after: //Sirens

 

Now try!

 

Pry

 

 

Worked for me,

 

Thanks!

Link to comment
Share on other sites

  • 0

yes, elevator its the same but i removed it from my server cause nobody used it, but i dont use the latest steam update..... still a gamespy server.

 

so you're still using 1.62.103718?

 

Again you will have to speak to the MOD maker about the undefined variable. I have never seen the cop siren script so would not be able to tell you or help you any further than I already have.

 

Kind Regards,

 

Pry

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Discord

×
×
  • Create New...