Mod questions

NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Forum rules
NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Locked
total immortal

Mod questions

Post by total immortal »

I am trying to play around with a mod where newly created NPC's can join you. If anything, I know the newly created automatons have a usecode where they will join you when you talk to them. I have changed some NPC's to that just as a generic fix, but does anyone know how to make a code to make newly created NPC's join your party?
Donfrow
Posts: 308
Joined: Thu May 14, 2020 1:34 pm

Re: Mod questions

Post by Donfrow »

It sounds like what you're looking for is UI_add_to_party(actor npc) or npc->add_to_party()

If that's the case, in whatever condition you want the NPC to join the party add that intrinsic with the NPC's number(make sure it's negative).
Wizardry Dragon
Posts: 1241
Joined: Thu May 14, 2020 1:34 pm

Re: Mod questions

Post by Wizardry Dragon »

In the character's dialogue, you'll want to do something like this, from Dupre's UCC in TFL:

case "join" (remove):
say("@It would be both an honor and a pleasure to join thee on thine adventures once again.@");
item->add_to_party();
add("leave");

Cheers, Wizardry Dragon
Lead Designer, The Feudal Lands
www.thefeudallands.ca
Cheers, Wizardry Dragon
Lead Designer, Ultima VII: The Feudal Lands
www.thefeudallands.ca
Locked