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

Devlin Opera for the 65742th time

1: Try putting this into the quest code before you go to talk to the governor:
Code:
DeleteAttribute(CharacterFromID("Edmund Christobel Shaw"), "Dialog.Filename.GroupDialog");
Then, when you restore the governor to normal:
Code:
Characters[GetCharacterIndex("Edmund Christobel Shaw")].Dialog.Filename.GroupDialog = "governor.c";

2: At the top of "quests_reaction.c", directly under the variable declarations, add:
Code:
int n;
Then, at case "Fake_Bea_removes2", try this:
Code:
for (n=1; n<4; n++)
{
    if(GetOfficersIndex(PChar, n) != -1)
    {
        ChangeCharacterAddressGroup(Characters[GetOfficersIndex(PChar, n)], "Cayman_Shore_01", "officers", "reload1_"+n);
    }
}
Normally for a search through officers, I'd use 'for (n=1; n<OFFICER_MAX; n++)', as it's possible to change OFFICER_MAX to allow more than the usual party of 4 - not recommended as it can do silly things, but some people may want to try it. But there's no point in checking past 4 here because there are no "officers" locators past 3.

3: The other thing about "questchar" is that it protects the character from the levelling process. The skills you give him in his definition are the exact skills he will have in the game. At present all his skills are 1, which means he's going to be no more effective at fighting or sailing than a little old lady wandering around the town. ;)

4: No need. Just assign the sword to the captain. At present you've given him "blade25", which is a French nobility sword. If he surrenders, he should hand it to you. If you kill a character in melee then you automatically loot his equipped weapons. If someone else kills him in melee, loot the body. If you sink the ship then you don't duel the captain and you don't get his sword. That's how I get Barbossa's Dragon's Head - there's nothing in quest code to give it to me, it's simply assigned to him, and I take it from him when he's dead. The one problem is that some people may disable corpse looting, in which case they won't be able to get the sword if a crewman or officer kills the captain. That's their choice - they're also missing out on a lot of other free weapons. :p
 
No need. Just assign the sword to the captain.
But currently, the normal NPC Blaze Devlin gets the sword assigned to him after your player character turns into Beatrice again and NPC officer Blaze re-appears.

Code:
GiveItem2Character(characterFromID("Blaze Devlin"), "blade25");
EquipCharacterByItem(characterFromID("Blaze Devlin"), "blade25");

When you defeat the captain, you get his sword. But "you" in this case is the player character Beatrice, "disguised" as Blaze Devlin. There are two possibilities: In story-logic, Blaze took the sword, so the first would be to give NPC Blaze the blade like in the code above, when the character switch happens. I would also add a line to take the same sword from the player character, who is now Beatrice. Else there would be two French nobility swords.

The second option would be to just leave out GiveItem2Character. Then, after the character switch, your player character, now Beatrice, still has the sword. You would have to give it to Blaze manually. Works too, but I thought the first possibility would be a nice touch: After this chapter, Blaze Devlin automatically has the new weapon. But that would bring us back to the "problem" that in one route, he might not have faced the captain. And to the question of a check.

At present all his skills are 1, which means he's going to be no more effective at fighting or sailing than a little old lady wandering around the town.
Which is quite handy when testing the quest with a jumpstart at beginner level. ;) Else I would have died much more often while just testing the code in action. But in the end, Godefroi Bonamy can of course get a few more points, his two officers as well.
 
But currently, the normal NPC Blaze Devlin gets the sword assigned to him after your player character turns into Beatrice again and NPC officer Blaze re-appears.

Code:
GiveItem2Character(characterFromID("Blaze Devlin"), "blade25");
EquipCharacterByItem(characterFromID("Blaze Devlin"), "blade25");

When you defeat the captain, you get his sword. But "you" in this case is the player character Beatrice, "disguised" as Blaze Devlin. There are two possibilities: In story-logic, Blaze took the sword, so the first would be to give NPC Blaze the blade like in the code above, when the character switch happens. I would also add a line to take the same sword from the player character, who is now Beatrice. Else there would be two French nobility swords.

The second option would be to just leave out GiveItem2Character. Then, after the character switch, your player character, now Beatrice, still has the sword. You would have to give it to Blaze manually. Works too, but I thought the first possibility would be a nice touch: After this chapter, Blaze Devlin automatically has the new weapon. But that would bring us back to the "problem" that in one route, he might not have faced the captain. And to the question of a check.
This actually raises a wider problem. Whether by defeating a quest character, defeating random enemies in the jungle, or raiding a dungeon, either Blaze or Bonnie may return with better weapons than they had when they left. NPC Blaze/Bonnie should then get those weapons. So, at case "Switch_to_Beatrice", right at the top before the character changes model and sex:
Code:
if (PChar.sex == "woman") NPChar = CharacterFromID("Bonnie Devlin");
else NPChar = CharacterFromID("Blaze Devlin");
if(GetCharacterEquipByGroup(PChar, BLADE_ITEM_TYPE) != "" && GetCharacterEquipByGroup(PChar, BLADE_ITEM_TYPE) != "bladeX4")
{
    GiveItem2Character(NPChar, GetCharacterEquipByGroup(PChar, BLADE_ITEM_TYPE));
    EquipCharacterByItem(NPChar, GetCharacterEquipByGroup(PChar, BLADE_ITEM_TYPE));
}
if(GetCharacterEquipByGroup(PChar, GUN_ITEM_TYPE) != "")
{
    GiveItem2Character(NPChar, GetCharacterEquipByGroup(PChar, GUN_ITEM_TYPE));
}
It's the reverse of the code at cases "Switch_to_Bonnie" and "Switch_to_Blaze" which checks if they're carrying weapons and if so, gives them to the player. This one checks whether you're male or female, which implies Blaze or Bonnie; checks if you're still armed; and if so, gives whatever you're carrying to your NPC counterpart. Then 'RestoreTempRemovedItems(Pchar)' which is already in "Switch_to_Beatrice" should wipe anything you picked up as Bonnie or Blaze and then give you back all Beatrice's equipment.

So PC Blaze returns carrying "blade25" and "pistol27". If the player chose to equip them, they'll be given to NPC Blaze. You could force the issue, at least for the sword, just before you go to "Switch_to_Beatrice" (which seems to be triggered from "Fake Bea_dialog.c"):
Code:
if (CheckCharacterItem(PChar, "blade25")) EquipCharacterByItem(PChar, "blade25");
If you're carrying "blade25", you automatically equip it - and then "Switch_to_Beatrice" can give your equipped blade, which is now "blade25", to NPC Blaze.
EquipCharacterByItem(NPChar, GetCharacterEquipByGroup(PChar, GUN_ITEM_TYPE));

Incidentally, "Fake Bea_dialog.c" triggers both "Cayman_finish" and "Switch_to_Beatrice". Case "Cayman_finish" restores Bonnie and Blaze as officers and gives Blaze a "blade25". I'd be inclined to take all that out of "Cayman_finish" because "Switch_to_Beatrice" is going to do it anyway.
 
Yes, I removed the existing code adding blade25 to NPC Blaze. Now he should get the new blade if you obtained and equipped it while playing as him. I also added the code regarding the governor dialog and the int n one.

I also took a trip to Aruba and entered the burial ground. You said it would be dark, but it was a lot darker than expected. ;) The screen went pitch black except for the date and time x3, time x1 etc. with no sound. System.log says it can't open the geometry file regarding cavernMedium2_lamps.gm. Perhaps it's missing in the folder you uploaded?
 

Attachments

  • system.log
    2.1 KB · Views: 74
Yes, I removed the existing code adding blade25 to NPC Blaze. Now he should get the new blade if you obtained and equipped it while playing as him. I also added the code regarding the governor dialog and the int n one.
If you don't add 'int n', the storyline will break and you'll get an error message on screen. The code to put all your officers onto the beach after the reload requires the variable 'n', and the code will crash if it's not declared somewhere first. ;)

I also took a trip to Aruba and entered the burial ground. You said it would be dark, but it was a lot darker than expected. ;) The screen went pitch black except for the date and time x3, time x1 etc. with no sound. System.log says it can't open the geometry file regarding cavernMedium2_lamps.gm. Perhaps it's missing in the folder you uploaded?
You are about to be eaten by a grue. xD

Try again - I've just uploaded the zip file again. Third time lucky - hopefully...
 
But currently, the normal NPC Blaze Devlin gets the sword assigned to him after your player character turns into Beatrice again and NPC officer Blaze re-appears.
He gets two of them. Here's why:
Code:
        case "wrapitup4":
            dialog.text = DLG_TEXT[14];
                        if (CheckQuestAttribute("ANNIE", "hired"))
                        {
            link.l1 = DLG_TEXT[15];
            link.l1.go = "wrapitup5";
                        }
                        else
                        {
            link.l1 = DLG_TEXT[15];
            link.l1.go = "exit";
                        }
            AddDialogExitQuest("Cayman_finish");
            AddDialogExitQuest("Switch_to_Beatrice");
        break;

        case "wrapitup5":
            dialog.text = DLG_TEXT[16];
            link.l1 = DLG_TEXT[17];
            link.l1.go = "wrapitup6";
        break;

        case "wrapitup6":
            dialog.text = DLG_TEXT[18];
            link.l1 = DLG_TEXT[19];
            link.l1.go = "exit";
            AddDialogExitQuest("Cayman_finish");
            AddDialogExitQuest("Switch_to_Beatrice");
        break;
That's from "Fake Bea_dialog.c". Case "wrapitup4" triggers both "Cayman_finish" and "Switch_to_Beatrice". If you hire Annie as an officer, it then continues to "wrapitup5" and "wrapitup6", which triggers "Cayman_finish" and "Switch_to_Beatrice" again. The version of "quests_reaction.c" which I have still gives the sword to NPC Blaze in "Cayman_finish", but even if you have changed it to give the sword to NPC Blaze in "Switch_to_Beatrice", it's liable to do something silly by calling "Switch_to_Beatrice" twice.

Remove the 'AddDialogExitQuest' lines from "wrapitup6". They're already set by "wrapitup4" and will activate when the dialog finishes - which will be after "wrapitup6" if you hired Annie. Or, if you want to make it clearer, put the lines inside the 'else' block in "wrapitup4", and leave them in "wrapitup6". Then they'll only be set in "wrapitup4" if you did not hire Annie. If you did, they should only be set in "wrapitup6".
 
Which is quite handy when testing the quest with a jumpstart at beginner level. ;) Else I would have died much more often while just testing the code in action. But in the end, Godefroi Bonamy can of course get a few more points, his two officers as well.
Edit "InternalSettings.h", enable cheatmode at the bottom, then press numeric keypad 0 in while playing. That's the key to make you immortal. Godefroi Bonamy could have maximum skills and abilities and you're still safe. ;) You can also press 1 and 3 to switch between your officers, then press 0 to make them immortal too. Note that pressing it again, or pressing it once on an officer who is already immortal due to quest code, will make the character mortal, so don't do it to Annie!
 
I realised only recently that the all-purpose weapon AddDialogExitQuest is not only triggered, when there's also an exit case. It gave me some problems which led to an infinite loop of "Hermit and the Frogs", this has now been solved.
 
Can you upload the files with "Hermit and the Frogs" corrected? It doesn't need to have anything beyond the current dead end as the Aruba part is not ready for testing, but this chapter should be corrected before it goes into the update.
 
When is that update planned? I still need to rework the Santo Domingo part. And a year ago, I added some slightly "hidden" locators to the Pirate fort, which in my case is the Columbus base camp, and I might use them for Mad Kays ambush on Godefroi Bonamy. As in making it more of an ambush, with the enemy pirates "hiding" and charging at the player group after you fully entered the camp. Right now they use the exact same locators and the exact same quest code as the pirate scouts a bit earlier.
 
The update is planned for when you've finished "Hermit and the Frogs". ;) Some more translation stuff will go in as well, but the translations are permanently on-going projects so there's no point waiting for them to finish.
 
Okay let's see what I can do in the next few days.

By the way "the Aruba part is not ready for testing" is a bit of an understatement. There's nothing like an Aruba part yet ;) (at least not outside of my head).
 
1: Try putting this into the quest code before you go to talk to the governor:
This worked. After you have been thrown out by the governor (well, in theory) and talk to him again, he now just throws his hissy fit with you answering "You sound like a barking dog". He won't give out letters of marque and information and international relations.

Since he threatens to call the guards, I'm going to add a little something: He'll give a second warning the next time you talk to him, but if you're brave/stupid enough to keep approaching him, he'll actually call some guards to the town hall. ;) Of course, his normal dialog will be restored after the quest.

Then, at case "Fake_Bea_removes2", try this:
This, on the other hand didn't work. Since I'm doing a reload to a locator with no adjacent officer locators while story-wise having one active officer (Annie), I could just try moving specifically her to any locator nearby. If that doesn't work somehow, I'll change the reload to a reload locator with actual officer locators, even if that means the player is in a slightly different spot after the loading screen. After all, I'm already doing the same thing several times in this quest.

Remove the 'AddDialogExitQuest' lines from "wrapitup6". They're already set by "wrapitup4" and will activate when the dialog finishes - which will be after "wrapitup6" if you hired Annie. Or, if you want to make it clearer, put the lines inside the 'else' block in "wrapitup4", and leave them in "wrapitup6". Then they'll only be set in "wrapitup4" if you did not hire Annie. If you did, they should only be set in "wrapitup6".
This worked as well. I killed the whimp Bonamy, equipped his French admirality sword and finished the quest. When switching back to Beatrice, NPC officer Blaze Devlin was equipped with his newly obtained trophy.
 
This, on the other hand didn't work. Since I'm doing a reload to a locator with no adjacent officer locators while story-wise having one active officer (Annie), I could just try moving specifically her to any locator nearby. If that doesn't work somehow, I'll change the reload to a reload locator with actual officer locators, even if that means the player is in a slightly different spot after the loading screen. After all, I'm already doing the same thing several times in this quest.
Try changing all officers to actor mode at case "Fake_Bea_removes". You may need to remove them as officers too, in which case store their ID's as attributes on "PChar". Then, at case "Fake_Bea_removes2", after they've been placed, put them back into officer mode, and reassign them as officers if you had to remove them.

Perhaps improve the pseudo French a bit? For example, sometimes they say "le Capitaine", which is correct; other times they say "le Captain". "Godefroi Bonamy_dialog.h" has "un single mot" - perhaps make that phrase entirely French, "un seul mot"? For comparison, try a FreePlay as Jean de la Croix, who also has some French phrases in mostly English dialog.
 
I decided to just teleport to the nearest reload locator, like I do in cases "Blaze_Cayman_start" and "Cayman_finish" anyway. Also the ambush by the first mate at the fort is now more of an ambush and less a copy of what happens a bit earlier with the scouts.

I could of course make the French dialog even more exaggerated and silly. Santo Domingo is also still a priority.
 
I've now tried the option where Blaze goes for the sea battle. It took me ages to find the Pastenague. One reason for this is that it wasn't the only pirate ship in the area - I spotted a fluyt of war flying a pirate flag, went after it, only to find that it was a different ship accompanied by a sloop. Also present were a couple of Spanish ships which didn't bother me because I was flying a Spanish flag and they believed it, so they attacked the sloop instead. Lorena Lopez is now the commander of an ex-pirate fluyt of war. After that I sailed round the island looking for another pirate ship, found another pirate ship which still wasn't Pastenague, captured that, and put its own captain back in charge of it now under my command. Eventually I found Pastenague on the other side of the island. Is it really meant to be that far away from Eden Rock?

Then I returned to Eden Rock for the showdown with the last of the pirates, and now I have to wonder whether you should consider renaming O'Byrne to O'Klee. Especially Annie O'Klee. :D

Beatrice Devlin said:
Now get off the high horse, and don't pretend you're Francis Drake.
This is 1576. Francis Drake has made a bit of a name for himself as a privateer but his cruise round the world doesn't start until next year. (Which, incidentally, is one reason why you'll get a different sword from a different location if you do the sidequest "Find Angelique Moulin's Father". You can't find Francis Drake's sword because Francis Drake hasn't received it himself yet. ;))
 
What a weekend. There was quite a fire in my apartment building, my flat has thankfully been spared, but it's all uninhabitable for the time being. I'm back where I moved out last year, and having all my files with me and two weeks off I have more than enough time for NH. I'm currently redoing the Guille the Kid part. He gets beaten up a bit and there will be a reference to a certain sidequest. ;)

Now I'm back to a smaller aspect ratio with black bars to the left and right, but in the meantime, I have gotten used to widescreen and Beatrice looks now too skinny for my taste. I have tried quite a few aspect ratios from the "Config" window, but the wider ones are weirdly zoomed in, so that I see my character roughly from the butt upwards at a normal camera angle from behind. Same for the ship, which touches the lower edge of the screen even when zoomed out. Other wider aspect ratios look better, but have very small icons and text. Have you got a suggestion?

Is it really meant to be that far away from Eden Rock?
Short answer: No ;) At least not neccessarily. I have chosen quite a random sea locator for it, as I still have not managed to figure out their positions easily (to be fair: You have postedinstructions for that in this thread recently, and I haven't tried them yet). For me, the ship has always been a bit up the coast (sailing from Eden Rock with the coast to your left), standing still until you get near (if she's not already enganged in battle with e.g. Spanish NPC ships). I'm open to suggestions where and how to place the ship, I just still think it shouldn't attack you immediately when you go to sea since it's been described as trying to lay anchor in another bay, the "Sunny Haven" copy I added as a pure quest location.

I have to wonder whether you should consider renaming O'Byrne to O'Klee. Especially Annie O'Klee. :D
Another reference I don't know, but why not?

This is 1576. Francis Drake has made a bit of a name for himself as a privateer but his cruise round the world doesn't start until next year.
I tried to find a suitable commander / battle hero at sea for this phrase, but couldn't find one in short time and settled for Drake, since he was alive and somewhat active. Do you know someone more suitable? If not, I'll do some more research. Whose sword do you get in Early Explorers? I have never played Angelique Moulin in that period.
 
Now I'm back to a smaller aspect ratio with black bars to the left and right, but in the meantime, I have gotten used to widescreen and Beatrice looks now too skinny for my taste. I have tried quite a few aspect ratios from the "Config" window, but the wider ones are weirdly zoomed in, so that I see my character roughly from the butt upwards at a normal camera angle from behind. Same for the ship, which touches the lower edge of the screen even when zoomed out. Other wider aspect ratios look better, but have very small icons and text. Have you got a suggestion?
Sorry to hear about the fire; glad that you, your equipment and your flat are all safe. As for aspect ratio, my own screen is 1024x768 so I've never seen wide Beatrice. What is the native resolution of your screen? What happens if you set the machine's resolution to that, and then edit "engine.ini" to match?

Short answer: No ;) At least not neccessarily. I have chosen quite a random sea locator for it, as I still have not managed to figure out their positions easily (to be fair: You have postedinstructions for that in this thread recently, and I haven't tried them yet). For me, the ship has always been a bit up the coast (sailing from Eden Rock with the coast to your left), standing still until you get near (if she's not already enganged in battle with e.g. Spanish NPC ships). I'm open to suggestions where and how to place the ship, I just still think it shouldn't attack you immediately when you go to sea since it's been described as trying to lay anchor in another bay, the "Sunny Haven" copy I added as a pure quest location.
There is already code in place at case "Cayman_sea_battle_begins3" to set Godefroi Bonamy to be stopped and not attacking; the only problem is to find - or if necessary, create - a location somewhere along the shore from Eden Rock.

Another reference I don't know, but why not?
Annie Oakley - Wikipedia

I tried to find a suitable commander / battle hero at sea for this phrase, but couldn't find one in short time and settled for Drake, since he was alive and somewhat active. Do you know someone more suitable? If not, I'll do some more research. Whose sword do you get in Early Explorers? I have never played Angelique Moulin in that period.
Francis Drake is still suitable, and probably better known to most players than other privateers of the time. Though the round-the-world voyage is still in the future, he has already had one successful expedition of his own:
Francis Drake's expedition of 1572–1573 - Wikipedia

You can't find Francis Drake's sword on Antigua because Antigua is blocked in "Early Explorers" - you can't land there. Besides, depending on the exact year, Francis Drake is either not born yet, or he's a small boy commanding a toy boat in his bathtub, or he's using the sword himself. Or, as in "Devlin Opera", he's an active privateer but has not yet received the sword. So you'll end up searching on Cuba instead, and what you'll find is the Angel Sword, a special sword designed specifically for the quest in "Early Explorers" - you won't get that sword any other way. Meanwhile, if you FreePlay as Francis Drake, you'll be awarded his special sword when you're promoted to rank 3.
 
What is the native resolution of your screen? What happens if you set the machine's resolution to that, and then edit "engine.ini" to match?
1680-1050 I believe. It is now covering the full screen but strangely it still feels compressed from the sides, compared to the other computer (which is a shitty old laptop, which I even managed to take with me, but I don't want to play on it without the external keyboard and screen. Since I'm already here, this computer is better).

the only problem is to find - or if necessary, create - a location somewhere along the shore from Eden Rock.
I guess it's exactly the same as adding a locator in a town location? I moved one of my Santo Domingo quest locators this morning and remembered how easy it is to create locators.

Annie Oakley - Wikipedia
Sold! I'm going to change the name.

Francis Drake is commanding a toy boat in his bathtub
So am I, according to my name. :sail
 
1680-1050 I believe. It is now covering the full screen but strangely it still feels compressed from the sides, compared to the other computer (which is a shitty old laptop, which I even managed to take with me, but I don't want to play on it without the external keyboard and screen. Since I'm already here, this computer is better).
1680x1050? That's an odd aspect ratio. Widescreen is normally 16:9, e.g. 1920x1080; narrow screen is 4:3, e.g.1024x768. 1680x1050 is 8:5. See if you can set it to 1680x945.

I guess it's exactly the same as adding a locator in a town location? I moved one of my Santo Domingo quest locators this morning and remembered how easy it is to create locators.
It's the same in that you'd use TOOL to do the same to an island locator file as you'd do to a town locator file. The big difference is that changing a town locator file will take effect at once - you can have a savegame in Santo Domingo, move a locator, then load the savegame (with visible locators enabled in "InternalSettings.h") and see the locator in its new place. Changing an island locator won't do anything until you start a new game.

So am I, according to my name. :sail
Wait till you have a proper ship in about 10-15 years' time, then sail around the world. :keith
 
Back
Top