Carry Capacity Question

Post a reply

Smilies
:D :) :( :o :shock: :? 8) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :!: :?: :idea: :arrow: :| :mrgreen: :angel: :angry: :beer: :bfg: :chaingun: :cheers: :blergh:
View more smilies

BBCode is ON
[img] is ON
[url] is ON
Smilies are ON

Topic review
   

If you wish to attach one or more files enter the details below.

Maximum filesize per attachment: 1.5 MiB.

Expand view Topic review: Carry Capacity Question

Re: Carry Capacity Question

by Herculine » Tue May 17, 2011 21:22

Yes, replacing the ammo types was quite a bugger. I finally decided (with some help from NeuralStunner over at the ZDoom Forums) to use the default ammo types and a DEHACKED patch. Now it seems to be working quite splendidly.

The only issues really holding me up now are trying to keep one from picking up a Soulsphere unless one needs it, and getting the Armor Bonuses to go beyond 200.

I'm using Ghastly_dragon's ArmorSphere and Infirnex's ArmorShards, so ideally I'd like the ArmorShards to be useable beyond the default 200. So far it's just not working out...

Re: Carry Capacity Question

by Gez » Tue May 17, 2011 19:20

For reference, max ammo amount always use the values for the top-most ammo type; so when you have an Actor Newclip : Clip, the Ammo.MaxAmount will be ignored since instead Clip's value will be used.

The other issue to note is that when you entirely replace the ammo without using inheritance (as in your second try), you then need to also change the weapon definitions to tell them to use the new types instead of the old. And you probably should have used the "replaces" keyword too so that these new ammos actually get spawned.

It is all around quite complicated. It's the one thing for which using a DEHACKED lump is still a better solution; even if one that only works with Doom (i.e., not in Heretic and other games).

Re: Carry Capacity Question

by Herculine » Mon May 16, 2011 3:56

I think I've figured out how to do this with a DeHackEd patch. It seems to be working.

Re: Carry Capacity Question

by Herculine » Mon May 16, 2011 0:34

I've also tried this:

actor NewClip : AMMO
{
+COUNTITEM
Inventory.PickupMessage "$GOTCLIP"
Inventory.Amount 10
Inventory.MaxAmount 200
Ammo.BackpackAmount 10
Ammo.BackpackMaxAmount 600
Inventory.Icon "CLIPA0"
States
{
Spawn:
CLIP A -1
Stop
}
}

Still it doesn't go beyond the vanilla defaults...

Re: Carry Capacity Question

by Herculine » Sun May 15, 2011 20:00

Okay. I've tried doing it like this:

actor NewClip : Clip
{
Inventory.Amount 10
Inventory.MaxAmount 600
}

...but it's not working. What am I doing wrong?

Re: Carry Capacity Question

by Herculine » Sun May 15, 2011 17:53

Got it. This info will be quite useful. Thanks!

Re: Carry Capacity Question

by Enjay » Sun May 15, 2011 11:21

How much ammo a backpack gives and how much it increases the carrying capacity of an ammo type is set in the definition for the ammo, not the backpack. So, if you want to alter these values, you will have to change the DECORATE definition of the ammo, not the backpack.

[zwiki]Classes:Ammo[/zwiki]

[zwiki]Classes:BackpackItem[/zwiki]

Carry Capacity Question

by Herculine » Sun May 15, 2011 3:22

Does anyone know how to increase the maximum ammo carry capacity beyond the defaults in Doom, like when the backpack is picked up?

I'm guessing it would have to be done with DECORATE and modify the backpack item, but I'm still kind of a noob at that and have no clue what the code would be.

Thanx.

Top