Barada Posted September 8, 2004 Share Posted September 8, 2004 aye, yup, disabling the saber.. but can't figure out best way to do this. changing the cvar default for g_weapondisable in g_main accomplishes nothing. Any other attempts either crash or don't compile. This has got to be a simple one, and it's not like I haven't seen a mod with a disabled saber. anyone know the best way to disable a weapon?? Also could be accomplished by disabling FP_SABER_OFFENSE, but I can't seem to even disable that, even with a g_weapondisable number. Again, multiple errors and no compile. thx in advance! Link to comment Share on other sites More sharing options...
razorace Posted September 8, 2004 Share Posted September 8, 2004 OJP has code that allows you go use the weapon disable cvar to disable any of the weapons. Link to comment Share on other sites More sharing options...
Barada Posted September 8, 2004 Author Share Posted September 8, 2004 same problem. Using G_weapondisable does not work on the saber as far as I have gotten. Most people just take points off of saber attack to access melee. Typing g_weapon disable 8 (the value for saber) doesn't work. And it wigs out and disables EVERYTHING EXCEPT the saber. However typing 2048 (rocket) for instance, works fine. I noticed in the INSTAGIB mod, the default for G_weapondisable and G_forcepowerdisable were both 0. The mod disables weapons and certain force without the cvar command. That's what I'm missing. Link to comment Share on other sites More sharing options...
razorace Posted September 9, 2004 Share Posted September 9, 2004 So, are you saying that you actually tried OJP? When I fixed the weapondisable code for OJP, it worked even for the saber. Link to comment Share on other sites More sharing options...
Barada Posted September 9, 2004 Author Share Posted September 9, 2004 Maybe I'm not looking in the right place on your site. I'm going to Documentation>Open Jedi Project Cvars and using - g_weaponDisable 0 Multiplayer, Weapons Description: Controls which weapons are useable in etc... g_weapondisable 8 for saber. Link to comment Share on other sites More sharing options...
razorace Posted September 9, 2004 Share Posted September 9, 2004 You have to actually RUN OJP for the fixes to work. gees. Link to comment Share on other sites More sharing options...
Barada Posted September 9, 2004 Author Share Posted September 9, 2004 ok, I'm not understanding what OJP is. Reading documents now. Link to comment Share on other sites More sharing options...
count_coder Posted September 12, 2004 Share Posted September 12, 2004 so uhh.. is there no easy way to do this without downloading OJP? Link to comment Share on other sites More sharing options...
razorace Posted September 12, 2004 Share Posted September 12, 2004 yep Link to comment Share on other sites More sharing options...
GangsterAngel Posted September 16, 2004 Share Posted September 16, 2004 There is a real easy way. look in g_client.c ClientSpawn then find: WP_SABER) just stick a boolen in there Link to comment Share on other sites More sharing options...
count_coder Posted September 18, 2004 Share Posted September 18, 2004 Thanks angel for the replay.. I'm a little confused though.. You said stick a boolean in there, could you be a little obvious? I know what booleans are of course but I fail to see what to do with it.. Anyway.. Thanks Link to comment Share on other sites More sharing options...
Barada Posted September 19, 2004 Author Share Posted September 19, 2004 count_coder, in g_client.. Around line 3418 (I don't know how many changes I made here, so just look around that line) { if (client->ps.fd.forcePowerLevel[FP_SABER_OFFENSE]) { client->ps.stats[sTAT_WEAPONS] |= ( 1 << WP_SABER ); //these are precached in g_items, ClearRegisteredItems() } else { //if you don't have saber attack rank then you don't get a saber client->ps.stats[sTAT_WEAPONS] |= (1 << WP_MELEE); } } Altering that will remove the saber, downside is melee takes a hike too. I'm over removing the saber, instead I removed the deflect missle function which is pretty much all I wanted to accomplish in the first place. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.