Ouchface
Register | User Profile | Member List | F.A.Q | Privacy Policy | New Blog | Search Forums | Forums Home
Doomworld Forums : Powered by vBulletin version 2.2.5 Doomworld Forums > Classic Doom > Doom Editing > HUD ammo display (mod weapon)
 
Author
All times are GMT. The time now is 01:36. Post New Thread    Post A Reply
Doggo120
Mini-Member


Posts: 88
Registered: 10-12


Hello!! Hello? Hello!

I'm trying to make a really silly Doom weapon pack (via Decorate). Right now I'm replacing the Shotgun with a less reliable one and I want to change its max ammo.

I created new actors replacing the Shotgun and Shell items, but I have three problems:

1) The HUD does not display the ammount of new "ammo".
2) I also changed the property Inventory.MaxAmmount to 200 in the new Shell actor, but the HUD doesn't change its value (50).
3) For some reason, even though I have the property Weapon.AmmoUse to 1 the amount of ammo stays the same.

Thank you all, y'all, for your time!

Old Post 10-20-12 01:06 #
Doggo120 is offline Profile || Blog || PM || Email || Search || Add Buddy IP || Edit || Quote
Blue Shadow
Member


Posts: 310
Registered: 09-12


Can you post the DECORATE code so we can take a look at it and see what's wrong?

Old Post 10-20-12 06:04 #
Blue Shadow is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
Doggo120
Mini-Member


Posts: 88
Registered: 10-12


Of course! Here it is:

Actor UselessShotgun : Weapon Replaces Shotgun 20024
{

Weapon.SelectionOrder 350
Weapon.AmmoType "Shelly"
Weapon.AmmoGive 30
Weapon.AmmoUse 1
Weapon.SlotNumber 3
Weapon.KickBack 80

Inventory.PickupSound "GetIt"
AttackSound "ShootIt"

States
{
Spawn:
YSKU A -1
Loop

Ready:
SHTG A 1 A_WeaponReady
Loop

Deselect:
SHTG A 1 A_Lower
Loop

Select:
SHTG A 1 A_Raise
Loop

Fire:
SHTG A 3 A_Jump(5,"AltFire")
SHTG B 5 A_CheckReload
SHTG B 10 A_PlaySoundEx ("ShootIt","Weapon")
SHTG A 5 A_ReFire
Goto Ready

AltFire:
SHTG A 0 A_CheckReload
SHTG A 2 A_Recoil(100)
SHTG A 0 A_FireBullets (6,0,7,5000,"BulletPuff",FBF_NORANDOM)
SHTG A 0 A_PlaySound("BoomIt",CHAN_WEAPON)
SHTG A 7 A_GunFlash
SHTG BC 5
SHTG CCCC 5
SHTG CB 5
SHTG A 7 A_ReFire
Goto Ready

Flash:
SHTF A 4 Bright A_Light1
SHTF B 3 Bright A_Light2
Goto LightDone

}
}

Actor Shelly : Ammo Replaces Shell
{
Inventory.PickupMessage "$GOTPOOP"
Inventory.Amount 5
Inventory.MaxAmount 200
Ammo.BackpackAmount 10
Ammo.BackpackMaxAmount 400
Inventory.Icon "SHELA0"
States
{

Spawn:
SHEL A -1
Stop
}
}

Old Post 10-20-12 06:12 #
Doggo120 is offline Profile || Blog || PM || Email || Search || Add Buddy IP || Edit || Quote
Blue Shadow
Member


Posts: 310
Registered: 09-12


When you say "HUD", do you mean Doom's status bar with the mugshot (Doom guy's face) or ZDoom's fullscreen one? If it's the former, then you require to modify the status bar to make it display your new ammo type in place of the original shotgun shells, and to do that you want to use SBARINFO.


Doggo120 said:
3) For some reason, even though I have the property Weapon.AmmoUse to 1 the amount of ammo stays the same.

Weapon.AmmoUse(1) is for primary attack (Fire), while Weapon.AmmoUse2 is for secondary attack (AltFire). To make it work in your case, you need three things:

Old Post 10-20-12 07:48 #
Blue Shadow is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
Doggo120
Mini-Member


Posts: 88
Registered: 10-12


Of course!!! The Primary Fire uses no bullets :P

Now, I would like the HUD with the doomguy's face and all to keep track of the max. bullets :)

Gracias!

Old Post 10-20-12 07:59 #
Doggo120 is offline Profile || Blog || PM || Email || Search || Add Buddy IP || Edit || Quote
All times are GMT. The time now is 01:36. Post New Thread    Post A Reply
 
Doomworld Forums : Powered by vBulletin version 2.2.5 Doomworld Forums > Classic Doom > Doom Editing > HUD ammo display (mod weapon)

Show Printable Version | Email this Page | Subscribe to this Thread

 

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are OFF
[IMG] code is ON
 

< Contact Us - Doomworld >

Powered by: vBulletin Version 2.2.5
Copyright ©2000, 2001, Jelsoft Enterprises Limited.