[zscript] modifying armor amount

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!

Moderator: GZDoom Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
User avatar
zrrion the insect
Posts: 2416
Joined: Thu Jun 25, 2009 1:58 pm
Location: Time Station 1: Moon of Glendale

[zscript] modifying armor amount

Post by zrrion the insect »

I am attempting to make a function that gets the amount of armor you has, does some math, and then modifies the amount of armor you have. Normally I would use CheckInventory for the first step, but that function behaves differently in zscript so I am unsure where to start.
Blue Shadow
Posts: 4951
Joined: Sun Nov 14, 2010 12:59 am

Re: [zscript] modifying armor amount

Post by Blue Shadow »

Use [wiki]CountInv[/wiki]("BasicArmor").

Return to “Scripting”