Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Sign in to follow this  
Pure Hellspawn

ACS GetWeapon()

Recommended Posts

any alternative to GetWeapon()? I need a function that gets equipped weapon.

i also could use a new zcommon.acs or something but i need help with that.

Share this post


Link to post

I guess you want Zandronum compatibility?

There is an alternative, but requires to alter DECORATE codes for all weapons. Basically, in their "Select" state, use A_GiveInventory() to give a certain dummy inventory to the player when he selects the weapon. Each weapon must have a different inventory, or different amount of the inventory. Also, use A_TakeInventory() in the weapon's "Deselect" state to take this inventory when player deselects the weapon. Then, whenever and whereever you want, check if the player has this dummy inventory (and which one) by CheckInventory() in ACS.

EDITED

Share this post


Link to post

I made my post clearer about DECORATE x ACS.

EDIT: I don't think I can help you with zcommon.acs anyhow.

Share this post


Link to post
scifista42 said:

I made my post clearer about DECORATE x ACS.


oh wait i meant the getweapon() function. if there's a way to make that compile then i can just use that.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  
×