GamingPrince83 Posted March 19, 2017 Posted March 19, 2017 Is there a way to editi the Jedi Academy Saber wielders AI to match the AI in Jedi Outcast especially the Reborn and Tavion AI. In JK2 each Reborn for grunt to Boss had a unique way of fighting, especially Tavion and the Reborn Acrobat, both used acrobats a lot which made the Battles very exciting and dangerous. Has anybody tried this before and if yes could you help me out?
the_raven Posted March 23, 2017 Posted March 23, 2017 I think it's quite possible. You'll need the JO .npc files for the characters you want, copy the behavior information (reflex, speed, force powers, saber styles) into the same .npc files in JA, and you should be good to go. At least, if I understood your question correctly. If not, then I guess coding and animations are involved. Those, I don't know how to edit. GamingPrince83 likes this
Fuse294 Posted March 26, 2017 Posted March 26, 2017 I think it's quite possible. You'll need the JO .npc files for the characters you want, copy the behavior information (reflex, speed, force powers, saber styles) into the same .npc files in JA, and you should be good to go. At least, if I understood your question correctly. If not, then I guess coding and animations are involved. Those, I don't know how to edit.I think the main issue however is that the .NPC files are different, the outcast NPCS have no Force Powers listed in their files cos it's hard coded (?) into them, so you'd have to manually readd all the powers you want them to use, plus all the outcast NPC's are listed in the same file called npcs.cfg. I'll post an example. Jedi Outcast: Kyle { fullName "Katarn, Kyle" playerModel kyle saberColor blue reactions 4 aim 5 move 3 aggression 5 evasion 5 intelligence 5 playerTeam player // race human class kyle snd kyle sndcombat kyle sndjedi kyle dismemberProbHead 1 dismemberProbArms 1 dismemberProbHands 20 dismemberProbLegs 1 dismemberProbWaist 1 }Jedi Academy: Kyle { playerModel kyle saber kyle rank commander health 1000 weapon WP_BRYAR_PISTOL weapon WP_SABER saberStyle 1 saberStyle 3 saberStyle 2 FP_HEAL 3 FP_LEVITATION 3 FP_SPEED 3 FP_PUSH 3 FP_PULL 3 FP_TELEPATHY 3 FP_GRIP 3 FP_LIGHTNING 2 FP_SABERTHROW 3 FP_RAGE 0 FP_PROTECT 3 FP_ABSORB 3 FP_DRAIN 0 FP_SEE 3 FP_SABER_DEFENSE 3 FP_SABER_OFFENSE 3 forcePowerMax 200 reactions 4 aim 5 move 3 aggression 5 evasion 5 intelligence 5 playerTeam TEAM_PLAYER class CLASS_KYLE snd kyle sndcombat kyle sndjedi kyle dismemberProbHead 0 dismemberProbArms 0 dismemberProbHands 0 dismemberProbLegs 0 dismemberProbWaist 0 }The way they are coded is different so you can't just simply copy and paste, you'd have to add in what's missing otherwise they'll not work as intended. As I said originally, Outcast uses .cfg for it's npcs where as the Academy version is .npc. MB2 Beta Tester / MB2 FA Assistant Dev
the_raven Posted March 26, 2017 Posted March 26, 2017 I think the main issue however is that the .NPC files are different, the outcast NPCS have no Force Powers listed in their files cos it's hard coded (?) into them, so you'd have to manually readd all the powers you want them to use, plus all the outcast NPC's are listed in the same file called npcs.cfg. I'll post an example. Jedi Outcast: Kyle { fullName "Katarn, Kyle" playerModel kyle saberColor blue reactions 4 aim 5 move 3 aggression 5 evasion 5 intelligence 5 playerTeam player // race human class kyle snd kyle sndcombat kyle sndjedi kyle dismemberProbHead 1 dismemberProbArms 1 dismemberProbHands 20 dismemberProbLegs 1 dismemberProbWaist 1 }Jedi Academy: Kyle { playerModel kyle saber kyle rank commander health 1000 weapon WP_BRYAR_PISTOL weapon WP_SABER saberStyle 1 saberStyle 3 saberStyle 2 FP_HEAL 3 FP_LEVITATION 3 FP_SPEED 3 FP_PUSH 3 FP_PULL 3 FP_TELEPATHY 3 FP_GRIP 3 FP_LIGHTNING 2 FP_SABERTHROW 3 FP_RAGE 0 FP_PROTECT 3 FP_ABSORB 3 FP_DRAIN 0 FP_SEE 3 FP_SABER_DEFENSE 3 FP_SABER_OFFENSE 3 forcePowerMax 200 reactions 4 aim 5 move 3 aggression 5 evasion 5 intelligence 5 playerTeam TEAM_PLAYER class CLASS_KYLE snd kyle sndcombat kyle sndjedi kyle dismemberProbHead 0 dismemberProbArms 0 dismemberProbHands 0 dismemberProbLegs 0 dismemberProbWaist 0 }The way they are coded is different so you can't just simply copy and paste, you'd have to add in what's missing otherwise they'll not work as intended. As I said originally, Outcast uses .cfg for it's npcs where as the Academy version is .npc.I suppose, but then, if you figured it out, there shouldn't be a problem, no?Also, Kyle isn't the best example to use in this regard because he's the player character, and his force power gain is indeed coded. It's the same for the player.npc in JKA, though that one has even less info on the character. Eh, doesn't matter, I guess.
GamingPrince83 Posted April 1, 2017 Author Posted April 1, 2017 I mean i'd like to have certain NPCs fight light the Jedi in JKII, i think it can only be done by coding.
the_raven Posted April 1, 2017 Posted April 1, 2017 I mean i'd like to have certain NPCs fight light the Jedi in JKII, i think it can only be done by coding.Frankly, I don't remember how they fought, so I can't tell you anything. Sorry.
Solution GamingPrince83 Posted April 3, 2017 Author Solution Posted April 3, 2017 Frankly, I don't remember how they fought, so I can't tell you anything. Sorry. The Jedi use acrobatic movements more often in JK2, but no problem i've found a solution myself. the_raven likes this
Guest Redemption Posted April 3, 2017 Posted April 3, 2017 @@SaberBlade83 Soooo... How did you go about solving it? I'm interested the_raven likes this
GamingPrince83 Posted April 4, 2017 Author Posted April 4, 2017 @@SaberBlade83 Soooo... How did you go about solving it? I'm interested I just did some code editing to make the Jedi Npcs use some of the old JK2 moves more often, like Jump flip attack, Lunge and jump forward attack. This is what i did in bg_panimate.cpp //----------------------------------- Old JK2 Moves if (enemyDist > !Q_irand(128, 200) && pm->gent && pm->gent->client && (pm->gent->NPC->rank == RANK_CREWMAN || pm->gent->NPC->rank == RANK_COMMANDER) && !Q_irand(0, 2)) { autoMove = PM_SaberFlipOverAttackMove(); } else if (enemyDist > !Q_irand(256, 300) && pm->gent && pm->gent->client && (pm->gent->NPC->rank == RANK_LT || pm->gent->NPC->rank == RANK_CAPTAIN) && !Q_irand(0, 2)) { autoMove = PM_SaberJumpForwardAttackMove(); } else if (enemyDist > !Q_irand(128, 200) && pm->gent && pm->gent->client && (pm->gent->NPC->rank == RANK_LT_JG || pm->gent->NPC->rank == RANK_LT_COMM || pm->gent->NPC->rank == RANK_COMMANDER || pm->gent->NPC->rank == RANK_CAPTAIN) && !Q_irand(0, 2)) { autoMove = PM_SaberLungeAttackMove(qtrue); } I'm still working on it, the game crashes sometimes when i use the player, but with npcs it's ok.
Guest Redemption Posted April 4, 2017 Posted April 4, 2017 @@SaberBlade83 Well done. Did you look in AI_Jedi.cpp? I thought thats where you would call this - since thats where it is in the Outcast source; saw it earlier on pal.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now