Another noob DECORATE question:

Need help with your project? Ask here.
User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Another noob DECORATE question:

Post by Herculine » Sun May 15, 2011 17:58

In my mod I'm using the LifeSphere power-up from the Realm667 Item Store.

What I would like to do (but am not sure exactly how to) is rig the Soulsphere so that it won't be picked up unless the player's health is below 200.

Any help will be much appreciated!

PeskySaurus
Awesome
Posts: 64
Joined: Sun May 10, 2009 1:50
Location: ?????

Re: Another noob DECORATE question:

Post by PeskySaurus » Thu Jun 02, 2011 20:28

I think you need to put

inventory.maxamount 200

under neath the inventory.amount and pickupmessage (i'm not sure if the order even matters.)
"Maybe one day I can figure it out, till then I just put another cigarette out, pull up a chair, open a brew, sit on the porch, and do what I do..." -Rehab

User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Re: Another noob DECORATE question:

Post by Herculine » Thu Jun 02, 2011 20:30

Thanks. I'll give that a shot.

PeskySaurus
Awesome
Posts: 64
Joined: Sun May 10, 2009 1:50
Location: ?????

Re: Another noob DECORATE question:

Post by PeskySaurus » Thu Jun 02, 2011 20:36

No problem. Also, make sure +INVENTORY.ALWAYSPICKUP isn't in there, because... well it looks self explanatory to me. I've never made any health items but I have custom weapons/monsters/lights and stuff in my .wad I'm making... I'm kind of going on assumption here looking on the ZDoom wiki. If none of this works let me know.
"Maybe one day I can figure it out, till then I just put another cigarette out, pull up a chair, open a brew, sit on the porch, and do what I do..." -Rehab

User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Re: Another noob DECORATE question:

Post by Herculine » Thu Jun 02, 2011 22:43

I think I've got that one worked out now:

Code: Select all

actor NewSoulSphere : Health
{
  Game Doom
  +COUNTITEM
  +FLOATBOB
  +INVENTORY.AUTOACTIVATE
  +INVENTORY.FANCYPICKUPSOUND
  Inventory.Amount 100
  Inventory.MaxAmount 200
  Inventory.PickupMessage "SUPERCHARGE!"
  Inventory.PickupSound "misc/p_pkup"
  States
  {
  Spawn:
    SOUL ABCDCB 6 Bright
    Loop
  }
}
(I used it in a random spawner that replaced the SoulSphere so of course I didn't need to specify that in this bit of code; and I didn't want it to use inheritance anyway.)

Now I wish I could figure out how to do the same with the armor bonuses. In my head it seems like they should work just like regular armor, but I'm just not getting it for some reason. I've figured out how to increase their maximum, but not how to prevent DoomGuy from picking them up after he's reached that maximum.

User avatar
Rex Claussen
Developer
Developer
Posts: 2491
Joined: Tue Jul 11, 2006 18:36
Contact:

Re: Another noob DECORATE question:

Post by Rex Claussen » Thu Jun 02, 2011 23:23

Herculine wrote:Now I wish I could figure out how to do the same with the armor bonuses.... I've figured out how to increase their maximum, but not how to prevent DoomGuy from picking them up after he's reached that maximum.
Are you including the following instruction:

Armor.Maxsaveamount xxx?

(Simply substitute 'xxx' with the armor number you want. The default for armor bonuses is 200.)

User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Re: Another noob DECORATE question:

Post by Herculine » Thu Jun 02, 2011 23:44

When I tried that it made them like the other armor types, i.e. as if the Green Armor was only worth 5 points and I couldn't pick up another armor bonus until I had taken enough damage to drop my armor back below 5.

Post Reply

Return to “Editing Help”