Dayz Explorer 1.29.162510
Loading...
Searching...
No Matches
m79.c
Go to the documentation of this file.
1class M79_Base extends RifleSingleShotManual_Base
2{
3 void M79_Base ()
4 {
5 }
6
7 override bool ShootsExplosiveAmmo()
8 {
9 return true;
10 }
11
12 override RecoilBase SpawnRecoilObject()
13 {
14 return new M79Recoil(this);
15 }
16
17 override void OnDebugSpawn()
18 {
19 SpawnAmmo("Ammo_40mm_Explosive",SAMF_DEFAULT);
20
21 EntityAI entity;
22 if ( Class.CastTo(entity, this) )
23 {
24 entity.SpawnEntityOnGroundPos("Ammo_40mm_Explosive", entity.GetPosition());
25 entity.SpawnEntityOnGroundPos("Ammo_40mm_Explosive", entity.GetPosition());
26 entity.SpawnEntityOnGroundPos("Ammo_40mm_Explosive", entity.GetPosition());
27 }
28 }
29
30};
31
32class M79 extends M79_Base
33{
34
35 override void AssembleGun()
36 {
37 super.AssembleGun();
38
39 if ( !FindAttachmentBySlotName("weaponOpticsAug") )
40 {
41 GetInventory().CreateAttachment("M79DummyOptics");
42 }
43 }
44
45};
46
47class M79DummyOptics extends ItemOptics
48{
49 override bool CanPutAsAttachment( EntityAI parent )
50 {
51 return true;
52 }
53
54 override bool IsSightOnly()
55 {
56 return true;
57 }
58};
59
override bool ShootsExplosiveAmmo()
override void AssembleGun()
Definition aug.c:68
Super root of all classes in Enforce script.
Definition enscript.c:11
bool IsSightOnly()
Definition itemoptics.c:213
Definition m79.c:33
class Hatchback_02_Blue extends Hatchback_02 OnDebugSpawn
override bool CanPutAsAttachment(EntityAI parent)
Definition itembase.c:9066