0 Members and 1 Guest are viewing this topic.
//CSCC Class basePain.GouHadou:"----" H 0 A_SpawnItemEx("MessatsuHit")goto Painactor MessatsuHit{Height 0Radius 0+NOINTERACTION-SOLID+NOGRAVITY+MISSILEStates{Spawn:TNT1 A 0TNT1 A 0 A_GiveToTarget("MessatsuHitPickup",1)stop}}actor MessatsuHitPickup : CustomInventory{inventory.amount 1inventory.maxamount 1States{Spawn:TNT1 A 0stopPickup:TNT1 A 0 A_GiveToTarget("MessatsuAmmo",4)stop}}
There are a few options. Most actually define ammo regeneration in the class' weapon. The easiest method is to stick on ammo regeneration to the ready state of the weapon like so.Code: [Select]TRHU A 3 A_WeaponReadyCOOW B 0 A_GiveInventory("BlueFireAmmo",2)//it's important to stick your wait time on the A_WeaponReady part and not the A_GiveInventory part because otherwise your weapon will only fire some of the timeThe downside is that you have to not fire your weapon to get ammo. Viz implements his ammo regen through a flash state like so.Code: [Select]Ready:OBUS A 0 ACS_ExecuteAlways(998,0,600)OBUS A 0 A_GunFlash...Flash:TNT1 A 0 A_JumpIfInventory("VizPadTimer", 1, 2)TNT1 A 0 A_GiveInventory("VoltLaserAmmo", 1)TNT1 A 35loopCalling A_GunFlash enters the "Flash" state. This is where ammo regen occurs, independent of movement or firing your weapon. Ammo is always regenerated.
TRHU A 3 A_WeaponReadyCOOW B 0 A_GiveInventory("BlueFireAmmo",2)//it's important to stick your wait time on the A_WeaponReady part and not the A_GiveInventory part because otherwise your weapon will only fire some of the time
Ready:OBUS A 0 ACS_ExecuteAlways(998,0,600)OBUS A 0 A_GunFlash...Flash:TNT1 A 0 A_JumpIfInventory("VizPadTimer", 1, 2)TNT1 A 0 A_GiveInventory("VoltLaserAmmo", 1)TNT1 A 35loop
SPAR A 1 A_FaceTargetWSPA D 0 A_JumpIf(floorz-z!=0,1)WSPA D 7 A_ChangeVelocity(8.0,0.0,11.0,CVF_REPLACE|CVF_RELATIVE) //Jumping lineWSPA D 0 A_JumpIf(floorz-z==0,"AttackChance")
WSPA D 0 A_JumpIf(floorz-z!=0,1)