• New Horizons on Maelstrom
    Maelstrom New Horizons


    Visit our website www.piratehorizons.com to quickly find download links for the newest versions of our New Horizons mods Beyond New Horizons and Maelstrom New Horizons!

Gentlemen Of Fortune add a starting character/companion

vlad nikol

Landlubber
hello to all


i would like to add at a very beginning of the game additional character (officer/companion). so when my character goes to shore that he has company.

i do presume that there is a way to do so. if anybody can help i would be very happy.


thank you for your interest
vlad
 
Hi,

You've to open StartGame_Dialog.c , find line : case "Finish_2" and modify like this :

Code:
case "Finish_2":
  DoQuestFunctionDelay("Tut_locCamera_2", 0.1);
       NextDiag.CurrentNode = NextDiag.TempNode;
       DialogExit();
       LAi_RemoveCheckMinHP(Pchar); // ñíèìåì ïðîâåðêè
       LAi_SetImmortal(pchar, false);
       LAi_SetPlayerType(pchar);
       InterfaceStates.Buttons.Save.enable = true;
  sld = GetCharacter(NPC_GenerateCharacter("Friend", "Pirate_1", "man", "man", 1, Pchar.nation, -1, true));// Philippe test
  AddPassenger(pchar, sld, false);
  LAi_SetOfficerType(sld);
  LAi_group_MoveCharacter(sld, LAI_GROUP_PLAYER);
  LAi_ActorFollowEverywhere(sld, "", -1);
  sld.dialog.filename = "Enc_Officer_dialog.c";
    sld.Dialog.CurrentNode = "hired";
       DoReloadCharacterToLocation(Pchar.HeroParam.Location, Pchar.HeroParam.Group, Pchar.HeroParam.Locator);
  sTemp = Pchar.HeroParam.Location;
  ChangeCharacterAddressGroup(sld, sTemp, "reload",  "reload1_back");
     break;
 
ahoy jean

thank you very very much! the spell worked like a charm
:)

i wander is there a way to choose companion, eg from list of playable characters (or some other list maybe)
??
 
i wander is there a way to choose companion, eg from list of playable characters (or some other list maybe)

??

Of course you can. You just need to know the 3D model and the animation used to, so check the list
of playable charactes ( resource/ini/texts/russian/HeroDescribe.txt) and modify the code :

sld = GetCharacter(NPC_GenerateCharacter(Character id, model, sex, animation, rank, nation, LifeDay, armed/unarmed))

eg Davy Jones :
sld = GetCharacter(NPC_GenerateCharacter("Davy", "DavyJones", "man", "man3", 21, Pchar.nation, -1, true))

Angelica:
sld = GetCharacter(NPC_GenerateCharacter("Angelica"," Angelica", " woman", " woman3_ab", 14, Pchar.nation, -1, true))

You also can name your character and give him items :
sld.name = "Angelica";
sld.lastname = "Smith";
GiveItem2Character(sld, "blade4");// you give the sword you want
EquipCharacterbyItem(sld, "blade4");
GiveItem2Character(sld, "pistol4");
EquipCharacterbyItem(sld, "Pistol4");
TakeNItems(sld, "bullet", 10);
 
hi again,


i've tried with this:


Code:
case "Finish_2":
  DoQuestFunctionDelay("Tut_locCamera_2", 0.1);
       NextDiag.CurrentNode = NextDiag.TempNode;
       DialogExit();
       LAi_RemoveCheckMinHP(Pchar); // ñíèìåì ïðîâåðêè
       LAi_SetImmortal(pchar, false);
       LAi_SetPlayerType(pchar);
       InterfaceStates.Buttons.Save.enable = true;
  sld = GetCharacter(NPC_GenerateCharacter("YokoDias", "YokoDias", "woman", "YokoDias", 1, Pchar.nation, -1, true));// Philippe test
  AddPassenger(pchar, sld, false);
  LAi_SetOfficerType(sld);
  LAi_group_MoveCharacter(sld, LAI_GROUP_PLAYER);
  LAi_ActorFollowEverywhere(sld, "", -1);
  sld.dialog.filename = "Enc_Officer_dialog.c";
    sld.Dialog.CurrentNode = "hired";
       DoReloadCharacterToLocation(Pchar.HeroParam.Location, Pchar.HeroParam.Group, Pchar.HeroParam.Locator);
  sTemp = Pchar.HeroParam.Location;
  ChangeCharacterAddressGroup(sld, sTemp, "reload",  "reload1_back");
break;

and everything seems to be fine, except there is no correct name/face/icon when i press F2

Clipboard01.jpg


maybe something else should be changed too, or i am doing something wrongly
: )
 
one more question
:)

where (what file) i can change this:

Code:
    You also can name your character and give him items :
    sld.name = "Angelica";
    sld.lastname = "Smith";
    GiveItem2Character(sld, "blade4");// you give the sword you want
    EquipCharacterbyItem(sld, "blade4");
    GiveItem2Character(sld, "pistol4");
    EquipCharacterbyItem(sld, "Pistol4");
    TakeNItems(sld, "bullet", 10);
 
You already have "sld." stuff in your post #6 above. Probably you can add that together.
 
aha, i think i got it
:)
i can add items/names to sld but i do not need to..

but how can i solve this problem with missing picture/face
?

:)
 
another (big) problem: additional starting character has extremely high value of abilities..

with clean gof 2.0 install and code from post #2 here is the screenshot:


Clipboard01.jpg




it would be ideal if i could somehow manage to put
main and companion character (officer) @ start of the game
with no experience - level 1

the only thing i need to find is how
:)
 
Last edited:
If you want your companion without experience you add these lines and change numbers :

SetSelfSkill(sld, 95, 95, 95, 95, 95);// personal skill, 1 to 100
SetShipSkill(sld, 95, 95, 95, 95, 95, 95, 95, 95, 95);// ship skill, 1 to 100
SetSPECIAL(sld, 1,1,1,1,1,1,1); // Capabilities, 1 to 10

And for picture you add :

sld.Face ID = 250

250 is for Angelica, you find the needed number also in HeroDescribe.txt coded like this : heroFace_31 {250}

And in PROGRAM/Characters/Characters_Face.c you'll find the others 3D characters with face number (for exemple if you want Morgan...).
 
Back
Top