Jump to content

How to change default player model for specific SP map?


Go to solution Solved by Lazarus,

Recommended Posts

Hello everyone! I'm trying to make changes to some SP maps and after so much researching (and failing) I need to ask for help. Does anybody know how to change default player model for specific SP map?

Let me be more specific, I've added a MOD to be able to play JO in JA. In that mod you play as Kyle so the playermodel uses default Kyle model. In cinematic there's a way to change the models and I've done so already, but not sure how exactly to make it work for the actual gameplay.

I know there's a way since in JA SP we have the different playermodel for the Hoth missions.

I've even found the script in hoth2.bsp

{
"targetname" "wintergear"
"usescript" "hoth2/playerwintergear"
"origin" "-2280 9976 1032"
"classname" "target_scriptrunner"
}

and tried adding it to the .ent file and compiling it to the .bsp (with q3map2.exe)

I've even added torso_g1.skin in playermodel\kyle.

What I want is to have Kyle appear in different clothes for a couple of missions (e.g. with jacket on).

Any help would be appreciated. 🙂

 

Link to comment
  • 2 weeks later...
  • Solution

Actually, the trigger here is here the wintergear
 

// Generated by DEvaheb v1.0
// Decompiled from file "E:\Externe harde Schijf\Star Wars Jedi Knight Jedi Academy\GameData\base\scripts\base_scripts\hoth3\setup.ibi"


affect ( "player", FLUSH )
{
    set ( "SET_WINTER_GEAR", "true" );
}

Now i can be mistaken, but I think the Jaden model comes already with winter gear that is triggered on the variable winter gear. You could actually maybe Frankenstein a model with Kyle and the winter clothing and just swap it to that specific model for that map.

image.thumb.png.45d46bb9d7df5663094e69c04d45188b.png

RobiWanKen0bi likes this
Link to comment

I see. So I need to add that bit to a script (set_winter_gear TRUE) in the beginning of a level and it will keep that code for winter gear until I change it in another level ((set_winter_gear FALSE)). I saw that the winter gear script triggers in hoth2.bsp (map) and there's no set_winter_gear part in the scripts of hoth3.bsp. So I'm guiessing the script to turn off the winter gear was called in a cutscene in the aftermath of the Hoth missions.

On the other hand I've managed to add this to the beginning of the game:

exec autoexec.cfg

and autoexec.cfg is:

seta g_char_model "Kyle"
seta g_char_skin_head "model_default"
seta g_char_skin_torso "model_default"
seta g_char_skin_legs "model_default"
seta snd "Kyle"
seta sex "m"
seta name "Kyle"
seta g_saber "saber_rahn"
seta g_saber_color "green"

Maybe in mid game I can call another autoexec (e.g. autoexec2.cfg) to change g_char_skin_torso?

Btw my Kyle model already has different skins (with jacket on, without etc.). I think it's the model from the user, Tompa.

Link to comment

Hoth gear changes is SPECIFICALLY for SP Player chars... that is, models which use the "jedi_charname" folder format, with partial skin files, with names like head_a1, torso_a1, lower_a1.

Thee way you seem to be doing things with "model_default" skins, suggests you are using the MP folder convention, say "base/models/players/mycustomkyle47" or whatever, with a 'whole char skin" like model_default.

Just adding a torso_g1 skin file to that almost certainly won't work.

 

First you need to rename your custom kyle model folder to say...

base/models/players/jedi_mycustomkyle47

Then you will need not only a torso_g1 skin but also a lower_e1 skin and at least one non Hoth head skin, torso skin and lower skin, say a head_a1 torso_a1 lower_a1, you'd make up similar head,torso and lower skins for your other kyle costumes.

What happens then is that when you start that first Hoth Mission, or your own "pretend its Hoth" mission, the game switches from whatever player model  selection you made at the start of the game (or later with the playermodel command) and uses the head skin you chose, WITH the torso_g1/lower_e1 Hoth versions, but it REMEMBERS what the non hoth appearance was (it's stored in the jasp cfg file) and when you are not Hoth-ing it switches back to that.

Grab a copy of my "Sintra Messon" mod from the downloads here, open up the pk3 files in a copy of winrar /whatever, and look at the way I put the various skins together.

 

if you want to use the keybind load a config file method then something like this...

seta g_char_model "jedi_adsms"
seta g_char_skin_head "head_a4"
seta g_char_skin_torso "torso_c2a"
seta g_char_skin_legs "lower_b4"

 

Or there's the bind a Hoth/non-hoth appearance to a couple of keys method...

bind [ "playermodel jedi_adsms head_a2 torso_c2c lower_b4;saber ad-darklance-sp;sabercolor 1 red red;"
bind ] "playermodel jedi_adsms head_a2 torso_g1 lower_e1;saber ad-darklance-sp;sabercolor 1 red red;"
 

RobiWanKen0bi likes this
Link to comment
  • 2 weeks later...
On 5/24/2023 at 11:10 PM, Lazarus said:

Actually, the trigger here is here the wintergear
 

// Generated by DEvaheb v1.0
// Decompiled from file "E:\Externe harde Schijf\Star Wars Jedi Knight Jedi Academy\GameData\base\scripts\base_scripts\hoth3\setup.ibi"


affect ( "player", FLUSH )
{
    set ( "SET_WINTER_GEAR", "true" );
}

Now i can be mistaken, but I think the Jaden model comes already with winter gear that is triggered on the variable winter gear. You could actually maybe Frankenstein a model with Kyle and the winter clothing and just swap it to that specific model for that map.

image.thumb.png.45d46bb9d7df5663094e69c04d45188b.png

This appears to be the best solution, but for now I'm having trouble in creating IBI files. My BehavED.exe Saves and exports TXT files, but doesn't generate IBI. After searching tutorials on that, I'm missing something. Compile doesn't really do anything visible to me.

Link to comment

it always saves as txt file, running the compiler should create an ibi file with it .... did you set it up correctly. Its important that it knows where ibize.exe is, since thats the compiler. I i am not sure about the source safe ini btw in my stuff, but i never have encountered an issue.

image.png.0d4a867ed96a08370b9744d50986a16e.png

image.png.64d566db22deddc544f1e5ca0b3cd000.png

RobiWanKen0bi likes this
Link to comment

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