News:

Come Chat with us live! Learn how HERE!

Main Menu

Grenade Launcher ( Gravity / actual Range )

Started by Noyesdude, May 28, 2012, 07:48:19 AM

Noyesdude

I'm working on the coding side of a grenade launcher and I'm trying to find out how to give it a farther range than the grenade and not something that flys across the screen to hit the wall or entity then explode. Any help here would be awesome.

Thanks
  Noyesdude
Co-creater of the Pbot installation guide(http://xserverx.com/forum/viewtopic.php?f=44&t=2352) on XserverX, and Tremulous player. and btw its No-yes-dude :D

/dev/humancontroller

Quote from: Noyesdude on May 28, 2012, 07:48:19 AM
I'm working on the coding side of a grenade launcher and I'm trying to find out how to give it a farther range than the grenade
see the launch_grenade() function in g_missile.c, which gets called when a "grenade weapon" is fired. there, in the creation and setup of a new grenade (a missile entity), the velocity of the grenade is set based on the GRENADE_SPEED constant (and the firing direction). in your "copy" of the launch_grenade() function, increase that number.
Quote from: Noyesdude on May 28, 2012, 07:48:19 AM
not something that flys across the screen
what the clockfuck does that mean?

Noyesdude

Quote from: /dev/humancontroller on May 28, 2012, 03:10:10 PM
see the launch_grenade() function in g_missile.c, which gets called when a "grenade weapon" is fired. there, in the creation and setup of a new grenade (a missile entity), the velocity of the grenade is set based on the GRENADE_SPEED constant (and the firing direction). in your "copy" of the launch_grenade() function, increase that number.

Thanks I missed that.
Quote from: /dev/humancontroller on May 28, 2012, 03:10:10 PM
Quote from: Noyesdude on May 28, 2012, 07:48:19 AM
not something that flys across the screen
what the clockfuck does that mean?

I meant map, Like all the other weapons that, seemingly, have no maximum range.
Co-creater of the Pbot installation guide(http://xserverx.com/forum/viewtopic.php?f=44&t=2352) on XserverX, and Tremulous player. and btw its No-yes-dude :D