Dayz Explorer 1.29.162510
Loading...
Searching...
No Matches
mosin9130.c
Go to the documentation of this file.
5class Mosin9130_Base extends BoltActionRifle_InnerMagazine_Base
6{
7 void Mosin9130_Base ()
8 {
9 }
10
11 override bool CanEnterIronsights()
12 {
13 ItemOptics optic = GetAttachedOptics();
14 if (optic && PUScopeOptic.Cast(optic))
15 return true;
16 return super.CanEnterIronsights();
17 }
18};
19
20
22{
23 override RecoilBase SpawnRecoilObject()
24 {
25 return new MosinRecoil(this);
26 }
27
28
29 //Debug menu Spawn Ground Special
30 override void OnDebugSpawn()
31 {
32 SpawnAmmo("Ammo_762x54",SAMF_DEFAULT);
33 GameInventory inventory = GetInventory();
34
35 inventory.CreateInInventory( "PUScopeOptic" );
36 inventory.CreateInInventory( "Mosin_Compensator" );
37
38 EntityAI entity;
39 if ( Class.CastTo(entity, this) )
40 {
41 entity.SpawnEntityOnGroundPos("Ammo_762x54", entity.GetPosition());
42 }
43 }
44};
45
46class SawedoffMosin9130_Base extends Mosin9130_Base
47{
48 override RecoilBase SpawnRecoilObject()
49 {
50 return new MosinSawedOffRecoil(this);
51 }
52
53
54 //Debug menu Spawn Ground Special
55 override void OnDebugSpawn()
56 {
57 SpawnAmmo("Ammo_762x54",SAMF_DEFAULT);
58 GameInventory inventory = GetInventory();
59
60 inventory.CreateInInventory( "PUScopeOptic" );
61
62 EntityAI entity;
63 if ( Class.CastTo(entity, this) )
64 {
65 entity.SpawnEntityOnGroundPos("Ammo_762x54", entity.GetPosition());
66 }
67 }
68};
class LogManager EntityAI
AugOptic CanEnterIronsights
Definition aug.c:63
Super root of all classes in Enforce script.
Definition enscript.c:11
script counterpart to engine's class Inventory
Definition inventory.c:81
EntityAI CreateInInventory(string type)
creates entity somewhere in inventory
Definition inventory.c:876
base for Mosin @NOTE name copies config base class
class Hatchback_02_Blue extends Hatchback_02 OnDebugSpawn