Forum Jump :

Author Message


Posts: 2
Rank:


Level: Member

Country: ru
Location:
Occupation:
Age:
In-game name:

 
#1 Posted at 2015-11-27 12:55        
     
Sup m8's i have a little trouble here and i need ur help.
I decided to implement the ability 2 open and close da door (lock unlock), but not 2 BIS houses, this feature is implemented using with variable "bis_disabled_Door_1, but unfortunately, this variable work apparently only with BIS houses.
K i decided 2 do differently in the cfg file, do check on UserAction, that if the house is closed, do not show UserAction "Scroll menu".
class open_door_1 {
displayName = "Open Door";
position = "Interact1";
radius = 1;
onlyForplayer = "true";
condition = "((this animationPhase 'Door_1') < 0.5) && (this getVariable 'tc_house_unlock')";
statement = "this animate ["Door_1", 1]";
};
this getVariable 'tc_house_unlock'
K, u see this now, but unfortunately the cfg generates an error when i add the second condition, a possible reason that "this" here is the door, not the house.
Guys i ask ur help, why this error is appears and there are options whether to remove she?
P.s - sorry 4 my bad eng.


Author Message


Posts: 1589
Rank:


Level: Member

Country: pf
Location: Tahiti
Occupation: too many Arma
Age: 57
In-game name: Kobayashi Maru

 
#2 Posted at 2015-11-28 00:12        
     
'tc_house_unlock' ? Are you sure this variable is already defined before trying to get it?
You could at least write a default value (defining it). Try (this getVariable ['tc_house_unlock,false])
I don't know the context, so feel free to change false for true, 0 or 1 or a workable value.

PLEASE CONTACT ME ON BI FORUMS FOR ANY SCRIPT / MOD QUESTION. TKS





Tags: #house #help