Jump to content

Jedi Academy turned 20 this year! We celebrated in a ton of different ways: mod contest, server event, podcast, etc. Thank you to all who have been a part of this game for the last two decades. Check out the anniversary content!

Read more

Welcome to JKHub

This community is dedicated to the games Star Wars: Jedi Outcast (2002) and Jedi Academy (2003). We host over 3,000 mods created by passionate fans around the world, and thousands of threads of people showcasing their works in progress and asking for assistance. From mods to art to troubleshooting help, we probably have it. If we don't, request or contribute!

Get started

This game turned 20 years old this year, and it is still one of the greatest Star Wars games of all time. If you're new or returning from a long hiatus, here are the basics of getting started with Star Wars Jedi Knight Jedi Academy in 2023.

Read more

Make any weapon usable from a swoop [MP/SP]


eezstreet

Welcome to part three of the FAQ (Frequently Asked Questions) series.

 

This is a very simple, one step process.

Open up bg_pmove.c (or bg_pmove.cpp in SP), and in the function PM_WeaponOkOnVehicle (it will look like this:),

 

 

 

 

//see if a weapon is ok to use on a vehicle

 

qboolean PM_WeaponOkOnVehicle( int weapon )

 

{

 

//FIXME: check g_vehicleInfo for our vehicle?

 

switch ( weapon )

 

{

 

//case WP_NONE:

 

case WP_MELEE:

 

case WP_SABER:

 

case WP_BLASTER:

 

//case WP_THERMAL:

 

return qtrue;

 

break;

 

}

 

return qfalse;

 

}

 

 

Add whatever weapons you want to be included here. So for instance, if we wanted to make the Repeater usable on a swoop, you might want to add it thusly:

 

 

 

//see if a weapon is ok to use on a vehicle

 

qboolean PM_WeaponOkOnVehicle( int weapon )

 

{

 

//FIXME: check g_vehicleInfo for our vehicle?

 

switch ( weapon )

 

{

 

//case WP_NONE:

 

case WP_MELEE:

 

case WP_SABER:

 

case WP_BLASTER:

case WP_REPEATER: // eezstreet add

 

//case WP_THERMAL:

 

return qtrue;

 

break;

 

}

 

return qfalse;

 

}

 

 

That's all you need to do! There's nothing else needed here.


User Feedback

Recommended Comments

There are no comments to display.



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

×
×
  • Create New...