[EDIT 07/24/05] DECORATE Weapons Support Guide

Archive of the old editing forum
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Locked

did you find this guide helpful

yes
39
91%
no
4
9%
 
Total votes: 43

User avatar
Beoghztt
Posts: 52
Joined: Sat Oct 08, 2005 5:27 am
Location: Kobe, Japan

Post by Beoghztt »

The "Upgradable Weapon" is cool, except the problem is that you can pick up the weapon even when the ammo is full. It would be great if anyone can give a fix for that. :thumb:
User avatar
DoomRater
Posts: 8270
Joined: Wed Jul 28, 2004 8:21 am
Preferred Pronouns: He/Him
Location: WATR HQ
Contact:

Post by DoomRater »

That doesn't sound very hard: (okay maybe it does take some thinking)

Code: Select all

ACTOR ShotgunPlaceHolder : CustomInventory //insert number for shotgun here
{
//other values intentionally removed
//I am also assuming this for Grubber's class code
states {
Pickup:
TNT1 A 0 A_JumpIfClass("Xaser",2)
TNT1 A 0 A_Jump(255,5)  //relative jump
TNT1 A 0 A_JumpIfInventory("PumpShotgun",1,3)
TNT1 A 0 A_JumpIfInventory("Shell",0,2)
TNT1 A 0 A_GiveInventory("PumpShotgun")
Stop
TNT1 A 0 
Fail
TNT1 A 0 A_JumpIfClass("WildWeasel",2)
TNT1 A 0 A_Jump(255,5)  //relative jump
TNT1 A 0 A_JumpIfInventory("Locksmith",1,3)
TNT1 A 0 A_JumpIfInventory("Shell",0,2)
TNT1 A 0 A_GiveInventory("Locksmith")
Stop
TNT1 A 0
Fail
//and so forth
}
}
An adaptation would be simply to remove the Class checks and only check for the weapon in inventory, and against full ammo (0 means max ammo), and if they both return full the inventory item should fail pickup with Fail.
User avatar
ShadesMaster
Posts: 658
Joined: Thu Jun 12, 2008 2:05 am

Re: [EDIT 07/24/05] DECORATE Weapons Support Guide

Post by ShadesMaster »

Say, what's the command to assign a weapon to a particular slot?I have the weapon precedence command but I still can't change TO the weapon after I switch away from it or run out of ammo, only if I run out of ammo on all OTHER weapons lol.

Also is there a way for me to add a Tome of Power-only mode to weapons fire? (it's a multi-part final weapon weapon for Heretic)
User avatar
Remmirath
Posts: 2562
Joined: Sun Dec 23, 2007 3:53 am
Graphics Processor: nVidia with Vulkan support
Location: My house
Contact:

Re: [EDIT 07/24/05] DECORATE Weapons Support Guide

Post by Remmirath »

1st answer: KEYCONF
2nd answer: +POWERED_UP flag...

Check the wiki for more infos...

And, please, don't bump so much old topics...this is 2 years old... :lol:
User avatar
ShadesMaster
Posts: 658
Joined: Thu Jun 12, 2008 2:05 am

Re: [EDIT 07/24/05] DECORATE Weapons Support Guide

Post by ShadesMaster »

Thanks, your help allowed to to know WHAT to look for so I got the weapon working! ;) I'm making something with new monsters and weapons for Heretic but I'm not going to say anymore until I have more to show.
User avatar
DoomRater
Posts: 8270
Joined: Wed Jul 28, 2004 8:21 am
Preferred Pronouns: He/Him
Location: WATR HQ
Contact:

Re: [EDIT 07/24/05] DECORATE Weapons Support Guide

Post by DoomRater »

Well one benefit of this bump is to see just how long I have delayed in even starting GGR. The above code was in fact supposed to be for it.
Locked

Return to “Editing (Archive)”