Jump to content

Further options for improving the original single player campaign.


Recommended Posts

Posted

So my first love with Jedi Academy was always the single player campaign. :shrug:

A few years back I made some basic quality of life improvements, editing the NPC config files under ext_data. Most changes were just  common sense QOL stuff, like normalizing enemies health to 100 like the player, giving various enemies new force abilities (think the low level disciples you encounter in pairs where one has grip or lightning and the other has lightsaber), or weapons, etc. I called it NPC++ and left it.

If you want to try it you can download it here.

I also made some modifications to the blaster fire speed and damage as discussed in this thread on jkhub. Needless to say the experience is a lot better, basic stormtroopers are somewhat dangerous in groups, the weapons below the concussion rifle are actually useful; since concentrated weapons fire from say 6-7 stormtroopers at once will gradually overwhelm a level 1 player, dashing in pouring fire with blasters from cover before using the lightsaber actually makes sense now. The original game as shipped was way too lightsaber heavy, with tweaks it finally feels like Dark Forces 2, where you frequently change weapons based on situation.

Anyways, Im looking for some thoughts on how feasible various ways of further improving the base game may be.

For things that can be done without modifying the source (priority as this can be shipped as a mod that anyone can use easily without having to recompile):

The base game still feels a bit empty to me. The number of enemies per level could have been higher, but was probably limited by the hardware capabilities of 2003. IIRC the placement and number of enemies is probably defined in the map BSP files which arent a realistic candidate for recompiling since we dont have the sources to open in the editor? If we did have the sources (I think the editor has the Korriban #1 map available?) we could recompile with more enemies and overwrite some of the map bsp files in assets0.pk3.

Is there any way there could be say a script hook that triggers every time the game creates say a stormtrooper, so instead of creating that single stormtrooper we create an entire squad? Or a hazardtrooper comes with a support squad of stormtroopers, etc, etc,

How exactly does the game trigger the end of 1 level returning to the map selection screen or point the game to load the next map between hoth parts 1, 2, korriban parts 1, 2. Is it possible to insert additional levels in between? I seem to recall some talk of a mod adding the feature of walking around the jedi temple for fun in between missions a few years ago?

Posted

There's a limited bsp editor in the files section, though I think the version on GitHub is newer. It cannot change the level geometry, but you should be able to edit the enemy placements.

I believe you cannot increase the number of selectable levels per tier without coding, but it's probably possible to insert additional levels in the multi-level sequences in-between (Hoth/Vjun/Taspir). You can also replace existing levels entirely.

Look for a target_levelchange using the bsp editor, that should define which level to load next, or if the game should go back to the level selection.

Cellprocesses likes this
  • 4 weeks later...
Posted
On 7/22/2024 at 4:09 PM, mrwonko said:

There's a limited bsp editor in the files section, though I think the version on GitHub is newer. It cannot change the level geometry, but you should be able to edit the enemy placements.

I believe you cannot increase the number of selectable levels per tier without coding, but it's probably possible to insert additional levels in the multi-level sequences in-between (Hoth/Vjun/Taspir). You can also replace existing levels entirely.

Look for a target_levelchange using the bsp editor, that should define which level to load next, or if the game should go back to the level selection.

Thank you for that reference, I dont have a windows machine handy, but I will definitely try it when I have one available

Im pretty sure youd have to be careful which NPCs you delete and add, as certain NPCs in the game are needed to be or not be for the cutscenes to work right, off the top of my head, if you dont kill the stormtroopers in the smelting room on taspir, npc kyles cutscene will get stuck reacting to the enemies and not play right, in the last taspir cutscene where alora taunts you before encountering rosh theres a reborn standing next to her that jumps down to fight you at the end of the cutscene, if you kill the reborn before the cutscene starts, it gets stuck etc.

How are the scripted motions for things like that assigned to npcs, when you compile the map in radiant you have to link it?

On 7/22/2024 at 4:09 PM, mrwonko said:

There's a limited bsp editor in the files section, though I think the version on GitHub is newer. It cannot change the level geometry, but you should be able to edit the enemy placements.

I believe you cannot increase the number of selectable levels per tier without coding, but it's probably possible to insert additional levels in the multi-level sequences in-between (Hoth/Vjun/Taspir). You can also replace existing levels entirely.

Look for a target_levelchange using the bsp editor, that should define which level to load next, or if the game should go back to the level selection.

Also also, for the level selection screen, isnt that stored in a lua or whatever compiled script type the sdk uses? Has anyone tried creating a template for that so that the between levels menu could be modified? Also could allow for options like selecting points in the core force abilities like push/pull/lightsaber defense/jump, etc.

Posted

Im attaching the little bit of changes Ive got so far if anyone wants to try building their own copy of my tuned build of jedi academy:
 

Changelog, repeated from the post:

 

-Redefined all weapons damage, muzzle velocity, shots per blast for shotgun, etc. Strongly reccomend Ultimate Weapons mod with this for best experience
-Defined scale factors in wp_saber.h for scaling up or down force push range, how hard force push knocks back, force choke range, force choke damage, force protect duration, force absorb duration, force see duration. Mostly just housekeeping the code there so force powers can be tuned easily with new builds.
-Force push now has a sliding scale of how hard it pushes back opponents. Level 1 is the basic knock them on their ass  youre used to, level 3 literally hurls them across the room like The Force Unleashed.

 

int forceKnockbackByPushLevel(int pushLevel)
{
	switch(pushLevel)
	{
		case 0:
			return 0;
		case 1:
			return forceKnockbackBase;
			// base value is 200
		case 2:
			return multiplyAndRoundInteger(1.5, forceKnockbackBase);
		case 3:
			return multiplyAndRoundInteger(2.5, forceKnockbackBase);
		case 4:
			return multiplyAndRoundInteger(3.5, forceKnockbackBase);
		// quadding up to 800 knockback  was a bit insane, just force pull
		// on a group of stormtroopers was literally sending them 200 m
		// off a cliff behind the player			
	}
}

-Force push blocking isnt 100% effective in duels. Added a probability function for dice rolls, jedi opponents have to pass a weighted dice roll to not be pushed back by force push.
-If youve ever been annoyed by how jedi\reborn opponents can stand there all day and shrug at you while you fire the sniper rifle at them, today is your lucky day! Added a probability check for the sniper rifle dodge move so it only happens some of the time. Obviously not weighted correctly right now at 50/50.

Part of the logic of probability checks is to make the saber wielding opponents seem more human, it doesnt make any sense how the player usually gets dissolved 3-4 times a game by a well timed sniper blast but the same weapon in the hands of the player is useless against jedi opponents. Same idea for force push, etc, etc.

Posted
Quote

Thank you for that reference, I dont have a windows machine handy, but I will definitely try it when I have one available

It doesn't come with an official Linux/Mac release, but the tool is written in Python, so chances are you can get it running without too much trouble.

Quote

How are the scripted motions for things like that assigned to npcs, when you compile the map in radiant you have to link it?

These are done using the scripting language Icarus, which is typically written using the behavED editor that comes with the JKA SDK. The compiled .ibi versions of the scripts can be found in the scripts folder, and they get referenced by the map by using target_scriptrunner or by setting the spawnscript/usescript/...script property on an NPC. There's a tool called DEvaheb for decompiling .ibi.

Quote

Also also, for the level selection screen, isnt that stored in a lua or whatever compiled script type the sdk uses?

The menus don't use Icarus, they use an extended version of Quake 3 Team Arena's .menu files. For level selection, there's a bunch of hardcoded logic in the engine related to storing progress in a cvar and retrieving it again, but I'm not familiar with the details. I don't think anyone has generalized it for modding yet, but it would be a good idea. Same for the force selection menu.

Quote

it doesnt make any sense how the player usually gets dissolved 3-4 times a game by a well timed sniper blast but the same weapon in the hands of the player is useless against jedi opponents.

I think you can just use force sight to get the dodge ability yourself.

  • 2 weeks later...
Posted

Okay some further ideas so far...

Want to add to the base class for all NPCs and player base attributes on the model used in Knights of the Old Republic. @mrwonko, is there any map of the base classes for npcs and entities in jedi academy? Ie I think theres a base class for entities so medpacs and npcs can both be force pulled, all npcs inherit from a common parent class?

So in this base class for npcs that all other Npcs inherit from Ill include

npc.strength (could affect probability of winning saber locks, isnt there already an attribute for this somewhere?)
npc.dexterity (affect blasters and saber deflection?)
npc.constitution (kinda pointless since hitpoints are already defined in the npc configuration files)
npc.intelligence
npc.wisdom
npc.charisma (WIS/CHARISMA is used in KOTOR to decide if certain force powers will work on a target, I cant remember if there are some similar checks to decide if certain force powers will work on a target in Jedi Academy?)
npc.vitality
 

Posted

Okay, so some exciting news, I have the first new force power working, force body is now a thing in jedi academy:

 

if ( self->client->ps.forcePowerLevel[FP_BODY] == FORCE_LEVEL_1)
	{	if(self->health >= 70)
		{
			self->health -= 20;
			int currentForcePoints = self->client->ps.forcePower;
			self->client->ps.forcePower = increaseToAMax(currentForcePoints, 40, 100);
			return;
		}
	}
	else if ( self->client->ps.forcePowerLevel[FP_BODY] == FORCE_LEVEL_2)
	{
		if(self->health >= 60)
		{
			self->health -= 10;
			int currentForcePoints = self->client->ps.forcePower;
			self->client->ps.forcePower = increaseToAMax(currentForcePoints, 50, 100);
			return;
		}
	}
	else if ( self->client->ps.forcePowerLevel[FP_BODY] == FORCE_LEVEL_3)
	{
		if(self->health >= 55)
		{
			self->health -= 5;
			int currentForcePoints = self->client->ps.forcePower;
			self->client->ps.forcePower = increaseToAMax(currentForcePoints, 60, 100);
			return;
		}
	}


The most obvious use is to chain with spamming force lightning blasts on level 3 since you can just stand there and overwhelm a jedi opponent by repeatedly hitting them with a never ending stream of lightning.

Still has a few minor bugs, cant figure out how to keybind it, it doesnt show up in the menu for assigning force powers to keys, and the icon doesnt have a string associated with it when you select it from the force powers carousel.

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...