Jump to content

[RELEASE] Banker NPCs (to replace ATM objects)


Recommended Posts

So you want this dude below to be your Banker instead of a laptop? Great idea!

 

Arma2_civ_functionary.jpg

 

I have been trying to set this up for a while now (2 minute job for the PROs here but for the rest of us not so easy!).

In the end peipo118 came to the rescue and provided me with the working code. It is working perfectly on our servers now and he is a very busy man I am releasing this solution on his behalf.

 

 

 

 

 

STEP 1

In your mission PBO banks file (dayz_server\bankzones\banks.sqf) define the banker NPC agents like this:

// Banker - in Stary Trade City
_unit_1301 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [6324.71, 7787, 0.00143433], [], 0, "CAN_COLLIDE"];
  _unit_1301 = _this;
    _this setDir 64;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

 

 

Should you wish to use my existing Chernarus 11 banker positions (in Trade Cities) file below it is at your service.

Please note the last one (Banker in Bor Trade City) is a custom addon and if you do not have that custom trade city at that exact coordinates, remember to remove that last dude.

// Banker - in Stary Trade City
_unit_1301 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [6324.71, 7787, 0.00143433], [], 0, "CAN_COLLIDE"];
  _unit_1301 = _this;
	_this setDir 64;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

// Banker - in Bash Trade City
_unit_1302 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [4057.35, 11662.7, 0.000128174], [], 0, "CAN_COLLIDE"];
  _unit_1302 = _this;
  _this setDir 47;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

// Banker - in Klen Trade City
_unit_1303 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [11461, 11348.6, 0.00143433], [], 0, "CAN_COLLIDE"];
  _unit_1303 = _this;
  _this setDir 312;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

// Banker - in Bor Trade City
_unit_1304 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [3284.84,3432.41,0.001], [], 0, "CAN_COLLIDE"];
  _unit_1304 = _this;
  _this setDir 244;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

AllBankersOnServer = AllBankersOnServer + [_unit_1301] + [_unit_1302] + [_unit_1303] + [_unit_1304];
publicVariable "AllBankersOnServer";

 

 

 

 

 

STEP 2 - Add this code bit to the end of lovely fn_selfActions.sqf file:

_banker = _cursorTarget getVariable["BankerBot",0];

if((_banker == 1) and (player distance _cursorTarget < 3)) then {		
		if (s_bank_dialog9 < 0) then {
			s_bank_dialog9 = player addAction ["DYCORE Bank Menu", "gold\bank_dialog.sqf",_cursorTarget, 3, true, true, "", ""];
		};			
	} else {		
		player removeAction s_bank_dialog9;
		s_bank_dialog9 = -1;
	};

 

 

 

 

 

STEP 3 - In the same file selfactions, find A, then add B under A.

 

A

s_player_downgrade_build = -1;
    player removeAction s_player_towing;
    s_player_towing = -1;
    player removeAction s_player_fuelauto;
    s_player_fuelauto = -1;
    player removeAction s_player_fuelauto2;
    s_player_fuelauto2 = -1;

 

 

B

player removeAction s_bank_dialog3;
s_bank_dialog3 = -1;

 

Should you wish to get creative with Banker NPC model, here is the menu => https://community.bistudio.com/wiki/ArmA_2:_Infantry

 

If you like this above, don't like my post as I'm merely posting this.

Instead, find one of peippo's posts (for example ) and LIKE it so that he gets some positive reputation for his work even though in another thread!

 

Thank you

 

 

 

 

P.S.: I also added the same NPC Banker to server_traders.sqf so that when a player 'speaks' with a Banker they can not only do banking operations (deposit/withdraw) but also exchange gold coins with gold bar/10oz bar/briefcases.

If you want that one too, you can use this code bit here [only bold & underlined bit is added to the file, the rest should be there already]:


// DayZ Epoch TRADERS for 11
serverTraders = ["Functionary1_EP1_DZ","Tanny_PMC","GUE_Commander","RU_Citizen2","Worker1","Damsel5","ValentinaVictim","RU_Functionary1","RU_Citizen3","Rocker4","Profiteer4","Rita_Ensler_EP1","CIV_EuroMan01_EP1","CIV_EuroMan02_EP1","TK_GUE_Soldier_5_EP1","GUE_Soldier_MG","Worker2","Worker3","Soldier_GL_M16A2_PMC","Woodlander1","UN_CDF_Soldier_Pilot_EP1","RU_WorkWoman1","Dr_Annie_Baker_EP1","RU_Citizen4","RU_WorkWoman5","RU_Citizen1","RU_Villager3","TK_CIV_Takistani04_EP1","Pilot_EP1","RU_Profiteer4","Woodlander3","Dr_Hladik_EP1","Doctor","HouseWife1","GUE_Woodlander2"];
// Banker NPCs
menu_Functionary1_EP1_DZ = [
    [["Coin/Gold Exchange",700]],
    [],
    "neutral"
];

Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...

This is useful. I'm thinking of actually switching from laptop to this one, looks much better.

 

Edit// Just noticed this npc gives you the "Give money to.." option if you don't add it to the trader list.

Can you elaborate on that please?

Link to comment
Share on other sites

Hey there, thanks for the script!

Having an issue though, only able to get my banker to spawn once. He is only spawning at the first instance of the code and not for the other two spots. What am I doing wrong?


// Banker - Selca
_unit_1301 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [8697.4,3172.6,0.002], [], 0, "CAN_COLLIDE"];
  _unit_1301 = _this;
  _this setDir 180;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

/ Banker - Pikia
_unit_1302 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [4416.1,1621.53,0.001], [], 0, "CAN_COLLIDE"];
  _unit_1302 = _this;
  _this setDir 270;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

/ Banker - Planica
_unit_1303 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [4322.2,6311.09,0.001], [], 0, "CAN_COLLIDE"];
  _unit_1303 = _this;
  _this setDir 270;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

Link to comment
Share on other sites

 

Hey there, thanks for the script!

Having an issue though, only able to get my banker to spawn once. He is only spawning at the first instance of the code and not for the other two spots. What am I doing wrong?


// Banker - Selca
_unit_1301 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [8697.4,3172.6,0.002], [], 0, "CAN_COLLIDE"];
  _unit_1301 = _this;
  _this setDir 180;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

/ Banker - Pikia <<------ *hust* must be // not /
_unit_1302 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [4416.1,1621.53,0.001], [], 0, "CAN_COLLIDE"];
  _unit_1302 = _this;
  _this setDir 270;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

/ Banker - Planica <<------ *hust* must be // not /
_unit_1303 = objNull;
if (true) then
{
  _this = createAgent ["Functionary1_EP1_DZ", [4322.2,6311.09,0.001], [], 0, "CAN_COLLIDE"];
  _unit_1303 = _this;
  _this setDir 270;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0; this setVariable [""BankerBot"",1,true];";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0; _this enableSimulation false;_this setVariable ["BankerBot",1,true];};

Link to comment
Share on other sites

  • 2 weeks later...

Quick question MGM. If I want to add more bankers, to areas like hero and bandit camps etc. I just copy the code for the banker in (dayz_server\bankzones\banks.sqf) and change the worldpsace coords? And does the "_this setDir" control the direction the NPC is facing? Thanks in advance.

Link to comment
Share on other sites

nice, thanks for this

what is this ?

AllBankersOnServer = AllBankersOnServer + [_unit_1301] + [_unit_1302] + [_unit_1303] + [_unit_1304];
publicVariable "AllBankersOnServer";

can i take this out ? get an error on rpt "undefined variable"

Yeah I'm getting this RPT error as well. I think the code is necessary but there is an error in it.

 8:17:56   Error position: <};>

 8:17:56   Error Missing {

Link to comment
Share on other sites

nice, thanks for this

what is this ?

AllBankersOnServer = AllBankersOnServer + [_unit_1301] + [_unit_1302] + [_unit_1303] + [_unit_1304];
publicVariable "AllBankersOnServer";

can i take this out ? get an error on rpt "undefined variable"

 

it's not required for the npc banker, you can delete it
Link to comment
Share on other sites

I have this working. Setup hookers all over my servers, at trader cities and wholesalers. Works great. My only problem is that when I interact with them then walk away. Doesn't matter how far away I go, I get the bank action menu showing up when I scroll my mouse wheel. Doesn't go away till I interact with something else. Anyone else experiencing this?

Link to comment
Share on other sites

I have this working. Setup hookers all over my servers, at trader cities and wholesalers. Works great. My only problem is that when I interact with them then walk away. Doesn't matter how far away I go, I get the bank action menu showing up when I scroll my mouse wheel. Doesn't go away till I interact with something else. Anyone else experiencing this?

 

If you haven't done STEP 3 this will happen

Link to comment
Share on other sites

I have this working. Setup hookers all over my servers, at trader cities and wholesalers. Works great. My only problem is that when I interact with them then walk away. Doesn't matter how far away I go, I get the bank action menu showing up when I scroll my mouse wheel. Doesn't go away till I interact with something else. Anyone else experiencing this?

 

If you haven't done STEP 3 this will happen

I have done step 3 and still have this error as well.

Link to comment
Share on other sites

Got another problem. I went over all the code again and I've got it all setup properly as per the instructions.

 

Client ArmA2OA.RPT file is being spammed (200,000+ lines) with the following when I'm not looking at a banker NPC:
 

_banker = _cursorTarget getVariable["BankerBot",0]>
  Error position: <_cursorTarget getVariable["BankerBot",0]>
  Error Undefined variable in expression: _cursortarget
File mpmissions\__CUR_MP.Chernarus\Scripts\Fn_SelfActions\fn_selfActions.sqf, line 927
Error in expression <
s_player_calldog = 		-1;
};

And when I am looking at a banker NPC it spams this:
 

"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"

Here's the end of my fn_selfActions.sqf file:

	player removeAction s_bank_dialog;
	s_bank_dialog = -1;
	player removeAction s_bank_dialog2;
	s_bank_dialog2 = -1;
	player removeAction s_bank_dialog9;
	s_bank_dialog9 = -1;
	player removeAction s_player_packOBJ;
	s_player_packOBJ = -1;
};

_dogHandle = player getVariable ["dogID", 0];

if (_dogHandle > 0) then {
	_dog = _dogHandle getFSMVariable "_dog";
	_ownerID = "0";
	if (!isNull cursorTarget) then { _characterID = cursorTarget getVariable ["CharacterID","0"]; };
	if (_canDo && !_inVehicle && alive _dog && _characterID != dayz_characterID) then {
		if (s_player_movedog < 0) then {
			s_player_movedog = player addAction [localize "str_actions_movedog", "\z\addons\dayz_code\actions\dog\move.sqf", player getVariable ["dogID", 0], 1, false, true, "", ""];
		};
		if (s_player_speeddog < 0) then {
			_text = (localize "str_epoch_player_249");
			_speed = 0;
			if (_dog getVariable ["currentSpeed",1] == 0) then { _speed = 1; _text = (localize "str_epoch_player_250"); };
			s_player_speeddog = player addAction [format[localize "str_actions_speeddog", _text], "\z\addons\dayz_code\actions\dog\speed.sqf",[player getVariable ["dogID", 0],_speed], 0, false, true, "", ""];
		};
		if (s_player_calldog < 0) then {
			s_player_calldog = player addAction [localize "str_actions_calldog", "\z\addons\dayz_code\actions\dog\follow.sqf", [player getVariable ["dogID", 0], true], 2, false, true, "", ""];
		};
	};
} else {
	player removeAction s_player_movedog;		
	s_player_movedog =		-1;
	player removeAction s_player_speeddog;
	s_player_speeddog =		-1;
	player removeAction s_player_calldog;
	s_player_calldog = 		-1;
};

_banker = _cursorTarget getVariable["BankerBot",0];

if((_banker == 1) and (player distance _cursorTarget < 3)) then {		
		if (s_bank_dialog9 < 0) then {
			s_bank_dialog9 = player addAction ["Hooker Savings", "Scripts\Gold_Coin_system\Bank_Dialog\bank_dialog.sqf",_cursorTarget, 3, true, true, "", ""];
		};			
	} else {		
		player removeAction s_bank_dialog9;
		s_bank_dialog9 = -1;
	};
Link to comment
Share on other sites

I have done step 3 and still have this error as well.

In step 3 Notice it has: s_bank_dialog3 has a 3

 

player removeAction s_bank_dialog3;

s_bank_dialog3 = -1;

 

but in the fn_selfactions section of code

      

 

_banker = _cursorTarget getVariable["BankerBot",0];

if((_banker == 1) and (player distance _cursorTarget < 3)) then {        

        if (s_bank_dialog9 < 0) then {

            s_bank_dialog9 = player addAction ["Hooker Savings", "Scripts\Gold_Coin_system\Bank_Dialog\bank_dialog.sqf",_cursorTarget, 3, true, true, "", ""];

        };            

    } else {        

        player removeAction s_bank_dialog9;

        s_bank_dialog9 = -1;

    };

 

it has player removeAction s_bank_dialog9;  s_bank_dialog9 = -1;

 

so to fix the BANK menu appearing in the scroll menu all the time in step 3 change the 3 to a 9

 

Step 3 should look like this

player removeAction s_bank_dialog9;

s_bank_dialog9 = -1;

Link to comment
Share on other sites

  • 2 weeks later...

 

Got another problem. I went over all the code again and I've got it all setup properly as per the instructions.

 

Client ArmA2OA.RPT file is being spammed (200,000+ lines) with the following when I'm not looking at a banker NPC:

 

_banker = _cursorTarget getVariable["BankerBot",0]>
  Error position: <_cursorTarget getVariable["BankerBot",0]>
  Error Undefined variable in expression: _cursortarget
File mpmissions\__CUR_MP.Chernarus\Scripts\Fn_SelfActions\fn_selfActions.sqf, line 927
Error in expression <
s_player_calldog = 		-1;
};

And when I am looking at a banker NPC it spams this:

 

"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModular: false] [typeOfCursorTarget: Hooker1]"
"fn_actons: [PlayerUID: 76561197970729264] [_ownerID: 0] [_isModularDoor: false] [typeOfCursorTarget: Hooker1]"

Here's the end of my fn_selfActions.sqf file:

	player removeAction s_bank_dialog;
	s_bank_dialog = -1;
	player removeAction s_bank_dialog2;
	s_bank_dialog2 = -1;
	player removeAction s_bank_dialog9;
	s_bank_dialog9 = -1;
	player removeAction s_player_packOBJ;
	s_player_packOBJ = -1;
};

_dogHandle = player getVariable ["dogID", 0];

if (_dogHandle > 0) then {
	_dog = _dogHandle getFSMVariable "_dog";
	_ownerID = "0";
	if (!isNull cursorTarget) then { _characterID = cursorTarget getVariable ["CharacterID","0"]; };
	if (_canDo && !_inVehicle && alive _dog && _characterID != dayz_characterID) then {
		if (s_player_movedog < 0) then {
			s_player_movedog = player addAction [localize "str_actions_movedog", "\z\addons\dayz_code\actions\dog\move.sqf", player getVariable ["dogID", 0], 1, false, true, "", ""];
		};
		if (s_player_speeddog < 0) then {
			_text = (localize "str_epoch_player_249");
			_speed = 0;
			if (_dog getVariable ["currentSpeed",1] == 0) then { _speed = 1; _text = (localize "str_epoch_player_250"); };
			s_player_speeddog = player addAction [format[localize "str_actions_speeddog", _text], "\z\addons\dayz_code\actions\dog\speed.sqf",[player getVariable ["dogID", 0],_speed], 0, false, true, "", ""];
		};
		if (s_player_calldog < 0) then {
			s_player_calldog = player addAction [localize "str_actions_calldog", "\z\addons\dayz_code\actions\dog\follow.sqf", [player getVariable ["dogID", 0], true], 2, false, true, "", ""];
		};
	};
} else {
	player removeAction s_player_movedog;		
	s_player_movedog =		-1;
	player removeAction s_player_speeddog;
	s_player_speeddog =		-1;
	player removeAction s_player_calldog;
	s_player_calldog = 		-1;
};

_banker = _cursorTarget getVariable["BankerBot",0];

if((_banker == 1) and (player distance _cursorTarget < 3)) then {		
		if (s_bank_dialog9 < 0) then {
			s_bank_dialog9 = player addAction ["Hooker Savings", "Scripts\Gold_Coin_system\Bank_Dialog\bank_dialog.sqf",_cursorTarget, 3, true, true, "", ""];
		};			
	} else {		
		player removeAction s_bank_dialog9;
		s_bank_dialog9 = -1;
	};

Hi,

 

I am getting the same error on my server, did you find a fix for this?

 

Thanks

Dave

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
  • Advertisement
  • Discord

×
×
  • Create New...