Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

How to force PC's appearance?

Page: 1 of 1
 JebusJM
05-09-2011, 7:41 AM
#1
Is there a script or something that will force the PC to have already set clothes, weapons, ect? And how would it work?

Thanks
 MDX
05-09-2011, 8:04 AM
#2
Perhaps there is, but why do you need to mess about with it? You can simply add anything to your inventory using KSE.
 Ferc Kast
05-09-2011, 8:44 AM
#3
Is there a script or something that will force the PC to have already set clothes, weapons, ect? And how would it work?

Thanks

At the beginning of the game, or in a specific module? Also, do you want the items equipped or just in the inventory?
 JebusJM
05-09-2011, 8:57 AM
#4
Perhaps there is, but why do you need to mess about with it?

I am in the modding section of the forum am I not? It's for my mod.

At the beginning of the game, or in a specific module? Also, do you want the items equipped or just in the inventory?

Both the beginning of the game and specific modules. If possible, I'd like to have the items equipped. If not, just the inventory will do fine.

Thanks.
 MDX
05-09-2011, 9:44 AM
#5
I am in the modding section of the forum am I not? It's for my mod.
Yes, you are, but putting something in your character's inventory at the beginning of both games contradicts the storyline, is it not?

Or you wanna make KotOR III personally? If so, I'm all attention.
 Ferc Kast
05-09-2011, 10:01 AM
#6
Here's scripts to do that. First, here's the way to only them add to the inventory:

void main() {
// Define the weapon(s), clothes, etc.
string sClothes = "clothes_tag";
string sWeapon = "weapon_tag";
object oPC = GetFirstPC();
// This way will only add the items to the inventory
CreateItemOnObject(sClothes, oPC, 1);
CreateItemOnObject(sWeapon, oPC, 2);
// Now, we need the old on-enter script to run
ExecuteScript("old_enter101PER", OBJECT_SELF);
}

Here's how to just equip them:
void main() {
// Define the weapon(s), clothes, etc.
string sClothes = "clothes_tag";
string sWeapon = "weapon_tag";
object oPC = GetFirstPC();
// Below is how you would equip the items to the PC
AssignCommand(oPC, ActionEquipItem(CreateItemOnObject(sClothes), INVENTORY_SLOT_BODY, TRUE));
AssignCommand(oPC, ActionEquipItem(CreateItemOnObject(sWeapon), INVENTORY_SLOT_RIGHTWEAPON, TRUE));
AssignCommand(oPC, ActionEquipItem(CreateItemOnObject(sWeapon), INVENTORY_SLOT_LEFTWEAPON, TRUE));
// Now, we need the old on-enter script to run
ExecuteScript("old_enter101PER", OBJECT_SELF);
}

They should work for both games; You just need to extract the original on-enter script for the module & rename it. Also, you just need to plug in the file of the clothes/armor & weapon(s) (without typing ".uti" at the end). Hope that helps you out. :)
 JoFlashStudios
05-09-2011, 10:04 AM
#7
@MDX: There are many different mods that place items in the inventory at the beginning of the game. For instance, the "All-in-one Force powers mod" places the VFX armband and the Holowan Extradimensional Emporium armband in the inventory at start up, among other things. Adding items at the beginning of the game does not neccecarilly contradict the storyline. And even if it does, sometimes that's what the modder wants to do.

@JebusJM: I'm not sure about exactly where to call this script from. I don't know how to make scripts fire on the entry to a module, but you could just edit End_Trask01.dlg to fire a script such as the following:


void main()
{
object oPC = GetPartyMemberByIndex(0);
//You can repeat this as many times as necessary to equip the character, just use different objects and different slots.
object myClothes = CreateItemOnObject("<some_clothes_object>", oPC);
object myGloves = CreateItemOnObject("<some_gloves_object>", oPC);
AssignCommand(oPC, ActionEquipItem(myClothes, INVENTORY_SLOT_BODY, TRUE));
AssignCommand(oPC, ActionEquipItem(myGloves, INVENTORY_SLOT_HANDS, TRUE));
}


The only issue with this is that you won't start with the clothes on, you will just suddenly be wearing them at the point of the dialog where you add the script. It's rather unsightly. For modules other than the Ebon Hawk, you'll have to figure out how to run it on entry, but I can't help you with that.

Edit: Just saw your post Ferc. I guess I'm a bit slow.
 JebusJM
05-09-2011, 10:07 AM
#8
Thank you so much for the scripts, Ferc. I'm having a little trouble following the on-enter script part of it. Do those script/s replace the on-enter script for the module? Or do I merge them together?

:EDIT: Just did a re-read of Ferc's scripts and think I understand how to work the on-enter scripts now.

Also, would it be possible to change their skin/head appearance? I should have been more clearer in my first post.

Thanks Ferc & JFS.
 MDX
05-09-2011, 3:18 PM
#9
There are many different mods that place items in the inventory at the beginning of the game. For instance, the "All-in-one Force powers mod" places the VFX armband and the Holowan Extradimensional Emporium armband in the inventory at start up, among other things.
I know. I'm just somewhat prejudiced about this kind of mods. Such games are too... integral. A modmaker must be careful even with slightest changes.
Adding items at the beginning of the game does not neccecarilly contradict the storyline.And even if it does, sometimes that's what the modder wants to do.
I told it specifically about KotORs' storylines, not about all games.

Also, would it be possible to change their skin/head appearance?
Yeah, such mods are widely created for NWN 2. And installed by mere placing the files into the Override directory. The same thing with eyes and hairstyle. Potentially even race mods are possible, but in this case to many plot changes are to be done.
 Fallen Guardian
05-09-2011, 8:44 PM
#10
I know. I'm just somewhat prejudiced about this kind of mods. Such games are too... integral. A modmaker must be careful even with slightest changes.

I told it specifically about KotORs' storylines, not about all games.


Yeah, such mods are widely created for NWN 2. And installed by mere placing the files into the Override directory. The same thing with eyes and hairstyle. Potentially even race mods are possible, but in this case to many plot changes are to be done.

Modding does not have to agree with the plot in any way shape or form. The mod can be whatever the author feels like.
 JebusJM
05-09-2011, 9:09 PM
#11
Also, would it be possible to change their model/skin/head/hair appearance?.

What script would I use for this one?

Thanks.

Friendly bump.
 MDX
05-11-2011, 12:31 PM
#12
Modding does not have to agree with the plot in any way shape or form. The mod can be whatever the author feels like.
No, they don't. But because of it they also don't look good quite often.
 Fallen Guardian
05-11-2011, 7:49 PM
#13
No, they don't. But because of it they also don't look good quite often.


What your saying is that even a simple item mod contradicts the storyline far too much to be used. But then that would make mods that are much more important also contradictory to the storyline and thus, bad as well.
 MDX
05-12-2011, 4:03 PM
#14
What your saying is that even a simple item mod contradicts the storyline far too much to be used.
Not "contradicts", but "may contradict".
But then that would make mods that are much more important also contradictory to the storyline and thus, bad as well.

Creating a new storyline and uncareful changing of an existing one are two great differences.
Page: 1 of 1