Dayz Explorer
1.24.157551 (v105080)
Dayz Code Explorer by Zeroy
petrollighter.c
Go to the documentation of this file.
1
class
PetrolLighter
extends
ItemBase
2
{
3
override
bool
CanIgniteItem(
EntityAI
ignite_target = NULL )
4
{
5
if
(
GetQuantity
() > 0 )
6
return
true
;
7
else
8
return
false
;
9
}
10
11
override
void
OnIgnitedTarget(
EntityAI
ignited_item )
12
{
13
if
(
GetGame
().IsServer() )
14
{
15
AddQuantity
( -0.5 );
16
}
17
}
18
19
override
void
OnIgnitedTargetFailed(
EntityAI
target_item )
20
{
21
if
(
GetGame
().IsServer() )
22
{
23
AddQuantity
( -0.5 );
24
}
25
}
26
27
/*
28
override bool IsTargetIgnitionSuccessful( EntityAI item_target = NULL )
29
{
30
}
31
*/
32
33
override
void
SetActions
()
34
{
35
super.SetActions();
36
37
AddAction
(
ActionLightItemOnFire
);
38
}
39
}
ItemBase
Definition:
inventoryitem.c:730
GetGame
proto native CGame GetGame()
AddQuantity
bool AddQuantity(float value, bool destroy_config=true, bool destroy_forced=false)
add item quantity[related to varQuantity... config entry], destroy_config = true > if the quantity re...
Definition:
itembase.c:3221
GetQuantity
override float GetQuantity()
Definition:
itembase.c:3316
ActionLightItemOnFire
ActionLightItemOnFireCB ActionContinuousBaseCB ActionLightItemOnFire()
Definition:
actionlightitemonfire.c:11
AddAction
void AddAction(typename actionName)
Definition:
advancedcommunication.c:86
SetActions
void SetActions()
Definition:
advancedcommunication.c:79
EntityAI
Definition:
building.c:5
DAYZ
scripts_v1.24.157551
scripts
world
entities
itembase
petrollighter.c
Generated by
1.8.17