Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
  • 0
Mad Dal 85

Throw Grenades without having to equip them

Question

I'm trying to get Doomguy to throw Grenades without having them equipped like you do with other weapons, but the grenades won't work and I get this on the top of the screen [pictured] and in case of if you're wondering about the file, it looks like this;

 

ADDMENUKEY "Throw Grenade" ThrowGrenade

Alias ThrowGrenade "Puke"

DEFAULTBIND G ThrowGrenade

 

Ps. I have no idea what the "Puke" is about but I know it's something to do with that. Help please?

IMG_20200818_224654.jpg

Share this post


Link to post

8 answers to this question

Recommended Posts

  • 0

"puke" is for manually running map scripts. (It's based on a cheat code in Hexen, where for example "puke08" runs script 8 of the current level.) So that's the wrong tree to be climbing here, at least.

Share this post


Link to post
  • 0

There are a few (GZDoom) mods that introduce a kicking boot to Doomguy's arsenal, similar to Duke Nukem 3D's 'Mighty Boot' feature. I think you should take a peek at how those work.

Share this post


Link to post
  • 0

What about having something like the Hexen Flechettes? They're items in your inventory which you can throw by using them. Modern ports like GZDoom even let you assign hotkeys to use them even when they're not selected.

Share this post


Link to post
  • 0
3 hours ago, Mordeth said:

There are a few (GZDoom) mods that introduce a kicking boot to Doomguy's arsenal, similar to Duke Nukem 3D's 'Mighty Boot' feature. I think you should take a peek at how those work.

I tried having an extra melee attack but it wouldn't work. Kept getting errors with it so I removed it from the mod altogether.

Share this post


Link to post
  • 0
2 hours ago, printz said:

What about having something like the Hexen Flechettes? They're items in your inventory which you can throw by using them. Modern ports like GZDoom even let you assign hotkeys to use them even when they're not selected.

Never played Hexen before. My mod is for GZDoom only because it won't work on ZDoom or Zandronum. I got other inventory items for attacking (swarmers, ElecPods, etc.) but I was hoping to throw grenades like in the CF mod so battling the tough monsters can be more interesting rather than straight up shoot them. Would turning them into a inventory item work? I've managed to create and turn other things into inventory items for my mod. I'm hoping to do the same thing with mines.

Share this post


Link to post
  • 0
On 8/19/2020 at 7:43 AM, Mad Dal 85 said:

Never played Hexen before. My mod is for GZDoom only because it won't work on ZDoom or Zandronum.

ZDooM, and its derivative GZDooM, draw upon many of Hexen's features. I believe printz was merely pointing to Hexen and its flechettes to illustrate how your grenades might work.

 

On 8/19/2020 at 7:43 AM, Mad Dal 85 said:

Would turning them into a inventory item work? I've managed to create and turn other things into inventory items for my mod. I'm hoping to do the same thing with mines.

Yes, grenades can be set up as inventory items. Using the inventory item will trigger whatever sprite animation you've set up for tossing and exploding the grenade via DECORATE or ZScript.

Share this post


Link to post
  • 0

Ok adding custom KEYBINDS isn't my specialty but I know a work-around that has the same effect as a custom keybind.

Replace A_WeaponReady with A_WeaponReady(WRF_ALLOW####) . Replace #### with reload, zoom, user1, user2, user3 or user4.

 

"How do I bind this though?" 

Bind the keys according to this list.

 

Reload = Reload

Zoom = Zoom

User1/2/3/4 : Weapon State 1/2/3/4

 

Now create a state named as any of the previous examples.

 

Actor Grenadebase : weapon

States

{

 User1:

 Grnf ABC 2

 Grnf D A_firecustommissile(grenade)

 Grnf EFG

  goto Ready

}

 

And just like that you now have a grenade quick throw keybind.

You could also use this example as inheritance for your weapons , giving all weapons the ability to throw grenades while also decluttering your decorate script.

Edited by Mr.S Retro

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
×