145{
147
149 {
152 m_Text = "#open";
153 }
154
156 {
157 m_ConditionItem =
new CCINone();
159 }
160
162 {
163 return true;
164 }
165
167 {
168 return true;
169 }
170
172 {
173 if (!target)
174 return false;
175
176 if (!IsBuilding(target))
177 return false;
178
179 Building building;
181 {
182 int doorIndex = building.GetDoorIndex(target.GetComponentIndex());
183 if (doorIndex != -1)
184 {
186 return false;
187
189
190 }
191 }
192
193 return false;
194 }
195
197 {
198 super.OnStartServer(action_data);
199
200 Building building;
201 if (
Class.
CastTo(building, action_data.m_Target.GetObject()))
202 {
203 int doorIndex = building.GetDoorIndex(action_data.m_Target.GetComponentIndex());
204 if (doorIndex != -1)
205 {
207 {
208 building.OpenDoor(doorIndex);
209 }
210 }
211 }
212 }
213
215 {
216 super.OnEndServer(action_data);
217
219 m_NoisePar.LoadFromPath(
"CfgVehicles SurvivorBase NoiseActionDefault");
222 {
223 if (action_data.m_Player)
225 }
226 }
227
229 {
230 return false;
231 }
232}
233
235{
237 {
238 return false;
239 }
240
242 {
243 return false;
244 }
245};
override bool IsLockTargetOnUse()
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
override void OnStartServer(ActionData action_data)
override void OnEndServer(ActionData action_data)
ref NoiseParams m_NoisePar
override void CreateConditionComponents()
ActionOpenDoors ActionInteractBase CheckIfDoorIsLocked()
void ActionTarget(Object object, Object parent, int componentIndex, vector cursorHitPos, float utility, string surfaceName="")
class NoiseSystem NoiseParams()
bool CheckIfDoorIsLocked()
proto native NoiseSystem GetNoiseSystem()
Super root of all classes in Enforce script.
static float GetNoiseReduction(Weather weather)
proto void AddNoisePos(EntityAI source_entity, vector pos, NoiseParams noise_params, float external_strenght_multiplier=1.0)
DayZPlayerConstants
defined in C++
proto native CGame GetGame()
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.