Jump to content

Home

add a key


douanier007

Recommended Posts

You need to do it in g_cmds.c. Make your function toggle some server flag for the caller. I made a new value for pm_flags in playerState_t since the client code shares bg_pmove.c, which is where your jetpack functions will be. Check for the flag in here and launch (no pun intended) the function is it is set.

Link to comment
Share on other sites

Yep, you also need to build both cgame and game after messing with bg_pmove.c.

 

There are two ways of attacking the jetpack problem. The way I'm doing is to have a command "jetpack" which turns the jetpack on. When it's active, jump and duck will control thrust. The other way is to make a new button as you described and apply thrust when it is pressed. That way you can have a separate command while still retaining jump and duck.

 

The way I'm doing just seems more sensible to me (which is why I'm doing it, duh!) but the key way is still perfectly valid. I also didn't like to use a whole new button when I can get away without doing so in case anyone ever wanted to incorporate the jetpack in a mod which NEEDED a new button. I don't want to waste them...

Link to comment
Share on other sites

my JetPack is different...

when you turn it on, you jump back (higher than a forcejump) .

Imagine if you use it with the rocket launcher (that I ameliorated 2) !

I don't want it to be fully controllable. You'll probably just be able to move forward and backward (like in Episode 2).

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...