• 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!

Modders in the Game

I take it you already made good use of the following pieces of quests_reaction.c?<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->        case "return_idol_from_frigate_complete":
            pchar.quest.before_storm.win_condition.l1 = "MapEnter";
            pchar.quest.before_storm.win_condition = "before_storm";
        break;

        case "prepare_for_storm":
            bQuestDisableMapEnter = false;
        break;

        case "before_storm":
            bMainMenuLaunchAfterVideo = true;
            CI_CreateAndSetControls( "WorldMapControls", "WMapCancel", -1, 0, true );// TIH worldmap cancel screwup prevention Sep3'06
            PostVideoAndQuest("storm",1, "storm_complete");
        break;
        
        case "storm_complete":
            ControlsInit(GetTargetPlatform(), false);LoadGameOptions();// TIH return the key settings to the user Sep3'06
            PostEvent("DoInfoShower",100,"s","");
            DoQuestReloadToLocation("Douwesen_shore_01", "reload", "reload1", "to_douwesen_shore_complete");
        break;<!--c2--></div><!--ec2-->Note: only reload-related code posted; all else left out.
I haven't yet found where "prepare_for_storm" is called. <img src="style_emoticons/<#EMO_DIR#>/unsure.gif" style="vertical-align:middle" emoid=":?" border="0" alt="unsure.gif" />
 
"prepare_for_storm" is called by the Researcher's dialog (in Build 13) and others in other versions.

The code I am using (with no related lines removed) is:

<div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'> case "before_storm":
Pchar.quest.before_storm4.win_condition.l1 = "MapEnter";
Pchar.quest.before_storm4.win_condition = "before_storm4";
SetNextWeather("Black Pearl Fight");
bQuestDisableMapEnter = false;
break;

case "before_storm4":
CI_CreateAndSetControls( "WorldMapControls", "WMapCancel", -1, 0, true );// TIH worldmap cancel screwup prevention Sep3'06
StorePassengers("Blaze");
PostVideoAndQuest("storm",1, "storm_complete"); // was 25
bMainMenuLaunchAfterVideo = true;
SetNextWeather("Black Pearl Fight");
break;

case "storm_complete":
ControlsInit(GetTargetPlatform(), false);LoadGameOptions();// TIH return the key settings to the user Sep3'06
locations[FindLocation("Douwesen_town")].reload.l3.disable = true;
PostEvent("DoInfoShower",100,"s","");
pchar.location.from_sea = "Douwesen_shore_01";
StorePassengers("Blaze");
pchar.tempmoney = pchar.money;
pchar.money = 0;
SetShipRemovable(pchar, true);
GiveShip2Character(pchar,"BlackPearl","Black Pearl",ENGLAND,true,true);
pchar.quest.main_line = "speak_with_peasant";
// bQuestDisableMapEnter = true;
LAi_QuestDelay("storm_complete2XXX", 0.0); //LAi_QuestDelay("to_douwesen_shore_complete", 0.0); //
break;

case "storm_complete2XXX":
DoQuestReloadToLocation("Douwesen_shore_01", "reload", "reload1", "to_douwesen_shore_complete");
ChangeCharacterAddressGroup(characterFromID("Davy Jones"), "Douwesen_shore_01", "goto", "locator10");
LAi_QuestDelay("to_douwesen_shore_complete", 0.0);
break;

case "to_douwesen_shore_complete":
pchar.quest.main_line = "speak_with_peasant";
LAi_SetActorType(pchar);
LAi_SetActorType(characterFromID("Davy Jones"));
LAi_ActorFollow(pchar, characterFromID("Davy Jones"), "", 2.0);
LAi_ActorFollow(characterFromID("Davy Jones"), pchar, "to_douwesen_shore_complete_2", 2.0);
break;

</div>
The problem I am having is that: case "storm_complete2XXX" should in fact be part of the case: case "storm_complete"
However, if I do not separate them as shown above, I just get a black screen.
Any thoughts?
 
Can you show the remaining code in <i>before_storm4</i> and the following quest cases?
 
Case "before_storm4": is complete as I posted it, as are the others - EXCEPT:
The only one I foreshortened was case "before_storm": and that expanded is:
<div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'> case "before_storm":
Pchar.quest.before_storm4.win_condition.l1 = "MapEnter";
Pchar.quest.before_storm4.win_condition = "before_storm4";
SetNextWeather("Black Pearl Fight");
LAi_group_SetRelation("DOUWESEN_PIRATE_SOLDIERS", LAI_GROUP_PLAYER, LAI_GROUP_NEITRAL);
if(GetOfficersIndex(Pchar, 1) == -1)
{
Pchar.Temp.Officer.idx1 = GetCharacterIndex("Blaze_Crewmember_01");
}
else
{
Pchar.Temp.Officer.idx1 = getOfficersIndex(Pchar, 1);
Pchar.Temp.Officer.idx1.Dialog = Characters[getOfficersIndex(Pchar, 1)].Dialog.Filename;
Pchar.Temp.Officer.idx1.CurrentNode = Characters[getOfficersIndex(Pchar, 1)].Dialog.CurrentNode;
}
if(GetOfficersIndex(Pchar, 2) == -1)
{
Pchar.Temp.Officer.idx2 = GetCharacterIndex("Blaze_Crewmember_02");
}
else
{
Pchar.Temp.Officer.idx2 = getOfficersIndex(Pchar, 2);
Pchar.Temp.Officer.idx2.Dialog = Characters[getOfficersIndex(Pchar, 2)].Dialog.Filename;
Pchar.Temp.Officer.idx2.CurrentNode = Characters[getOfficersIndex(Pchar, 2)].Dialog.CurrentNode;
}
if(GetOfficersIndex(Pchar, 3) == -1)
{
Pchar.Temp.Officer.idx3 = GetCharacterIndex("Blaze_Crewmember_03");
}
else
{
Pchar.Temp.Officer.idx3 = getOfficersIndex(Pchar, 3);
Pchar.Temp.Officer.idx3.Dialog = Characters[getOfficersIndex(Pchar, 3)].Dialog.Filename;
Pchar.Temp.Officer.idx3.CurrentNode = Characters[getOfficersIndex(Pchar, 3)].Dialog.CurrentNode;
}
if (GetCompanionIndex(pchar,1) > 0)
{
Pchar.Temp.Companion.idx1 = GetCompanionIndex(pchar,1);
iPassenger = GetCompanionIndex(pchar,1);
RemoveCharacterCompanion(Pchar, &Characters[iPassenger]);
}
else
{
Pchar.Temp.Companion.idx1 = -1;
}
if (GetCompanionIndex(pchar,2) > 0)
{
Pchar.Temp.Companion.idx2 = GetCompanionIndex(pchar,2);
iPassenger = GetCompanionIndex(pchar,2);
RemoveCharacterCompanion(Pchar, &Characters[iPassenger]);
}
else
{
Pchar.Temp.Companion.idx2 = -1;
}
if (GetCompanionIndex(pchar,3) > 0)
{
Pchar.Temp.Companion.idx3 = GetCompanionIndex(pchar,3);
iPassenger = GetCompanionIndex(pchar,3);
RemoveCharacterCompanion(Pchar, &Characters[iPassenger]);
}
else
{
Pchar.Temp.Companion.idx3 = -1;
}
bQuestDisableMapEnter = false;
break;
</div>
After the rest of that which I posted comes:
<div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'> case "to_douwesen_shore_complete_2":
LAi_ActorWaitDialog(pchar, characterFromID("Davy Jones"));
LAi_ActorDialog(characterFromID("Davy Jones"), pchar, "pchar_back_to_player", 2.0, 1.0);
SetCharacterShipLocation(Pchar, "Douwesen_shore_01");
bQuestDisableMapEnter = false;
break;
</div>
Hope that helps.
 
I've managed to make your code work by removing the '//' in PROGRAM\WorldMap\worldmap_reload.c, on line 230
( Event("QuitFromWorldMap"); ), and without having to split your "storm_complete2" in two parts. Does it solve the problem in your game too?
 
<!--quoteo(post=294749:date=Dec 30 2008, 03:46 PM:name=a simple virtual sailor)--><div class='quotetop'>QUOTE (a simple virtual sailor @ Dec 30 2008, 03:46 PM) <a href="index.php?act=findpost&pid=294749"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->I've managed to make your code work by removing the '//' in PROGRAM\WorldMap\worldmap_reload.c, on line 230
( Event("QuitFromWorldMap"); ), and without having to split your "storm_complete2" in two parts. Does it solve the problem in your game too?<!--QuoteEnd--></div><!--QuoteEEnd-->Thanks - I will try it.
 
<!--quoteo(post=294755:date=Dec 30 2008, 04:01 PM:name=Pieter Boelen)--><div class='quotetop'>QUOTE (Pieter Boelen @ Dec 30 2008, 04:01 PM) <a href="index.php?act=findpost&pid=294755"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Why do you have a LAi_QuestDelay before the DoQuestReloadToLocation?<!--QuoteEnd--></div><!--QuoteEEnd-->That is because I had to split the DoQuestReloadToLocation out of case "storm_complete" and into case "storm_complete2XXX" to get the action of appearing on the beach to function.
 
Errr... No, Pieter Boelen is right, there is indeed an unecessary 'LAi_QuestDelay' :

<!--quoteo--><div class='quotetop'>QUOTE </div><div class='quotemain'><!--quotec-->case "storm_complete2XXX":
DoQuestReloadToLocation("Douwesen_shore_01", "reload", "reload1", "to_douwesen_shore_complete");
ChangeCharacterAddressGroup(characterFromID("Davy Jones"), "Douwesen_shore_01", "goto", "locator10");
LAi_QuestDelay("to_douwesen_shore_complete", 0.0);
break;<!--QuoteEnd--></div><!--QuoteEEnd-->
"to douwesen_shore_complete" is indeed called two times.
 
<!--quoteo(post=294759:date=Dec 30 2008, 04:34 PM:name=a simple virtual sailor)--><div class='quotetop'>QUOTE (a simple virtual sailor @ Dec 30 2008, 04:34 PM) <a href="index.php?act=findpost&pid=294759"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Errr... No, Pieter Boelen is right, there is indeed an unnecessary 'LAi_QuestDelay' :

<!--quoteo--><div class='quotetop'>QUOTE </div><div class='quotemain'><!--quotec-->case "storm_complete2XXX":
DoQuestReloadToLocation("Douwesen_shore_01", "reload", "reload1", "to_douwesen_shore_complete");
ChangeCharacterAddressGroup(characterFromID("Davy Jones"), "Douwesen_shore_01", "goto", "locator10");
LAi_QuestDelay("to_douwesen_shore_complete", 0.0);
break;<!--QuoteEnd--></div><!--QuoteEEnd-->
"to douwesen_shore_complete" is indeed called two times.
<!--QuoteEnd--></div><!--QuoteEEnd-->OOPS!... THAT QuestDelay.... yes indeed, I missed that one. I thought Pieter was talking about the previous one.
Corrected now. <img src="style_emoticons/<#EMO_DIR#>/whippa.gif" style="vertical-align:middle" emoid=":whipa" border="0" alt="whippa.gif" />

Your mod to worldmap_reload.c does indeed clear the issue for me. THANKS <img src="style_emoticons/<#EMO_DIR#>/doff.gif" style="vertical-align:middle" emoid=":doff" border="0" alt="doff.gif" /> <img src="style_emoticons/<#EMO_DIR#>/doff.gif" style="vertical-align:middle" emoid=":doff" border="0" alt="doff.gif" /> <img src="style_emoticons/<#EMO_DIR#>/doff.gif" style="vertical-align:middle" emoid=":doff" border="0" alt="doff.gif" />
And appologies to you both for the misunderstanding over the Quest Delay.

Also sorry for the intermittent replies... we are having numerous power outages around here today.
Luckily, always just AFTER I have saved what I am doing.
 
So problem solved?
In emperor Palpatine's voice: "Goooooooodddddd......" <img src="style_emoticons/<#EMO_DIR#>/razz.gif" style="vertical-align:middle" emoid=":razz" border="0" alt="razz.gif" />
 
<!--quoteo(post=294767:date=Dec 30 2008, 05:20 PM:name=Pieter Boelen)--><div class='quotetop'>QUOTE (Pieter Boelen @ Dec 30 2008, 05:20 PM) <a href="index.php?act=findpost&pid=294767"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->So problem solved?
In emperor Palpatine's voice: "Goooooooodddddd......" <img src="style_emoticons/<#EMO_DIR#>/razz.gif" style="vertical-align:middle" emoid=":razz" border="0" alt="razz.gif" /><!--QuoteEnd--></div><!--QuoteEEnd-->Think so - and maybe some others I wasn't too happy with.
I will play them out again and see.
Thanks again.
 
Back
Top