• 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

The Spanish cup-hilt rapier is available from "Spanish Main" onwards. Mind you, so are the basic rapier and duelling rapier, which I'm inclined to make available to "Early Explorers" because at least some rapiers did exist in the 16th century. But the Spanish cup-hilt rapier is rather powerful for a starting weapon. Ardent only gets it after surviving a difficult boarding and then duelling the captain, who got the cup-hilt rapier to make him a bit tougher! "Blade47", the light tizona, might be more suitable as a starting weapon.

Having said that, "Assassin" gives Johan Elting his special sword right at the start, while "Hoist the Colours" gives Jack Sparrow his special cutlass almost at the start. So, if Beatrice Devlin gets a powerful sword right away, she's in good company! As the cup-hilt rapier would be unique in "Devlin Opera" due to not normally being available in this period, you could have Emmanuel say something about it being special.
 
Let's see. Basically the sword doesn't affect story progress too much, so it could easily be a good one.

How can I see which weapons appear in which time periods? Would be useful also for NPC's, so I don't hand out too many futuristic weapons.
 
Look at "PROGRAM\ITEMS\initItems.c". There's a section defining the regular swords, e.g. the duelling rapier:
Code:
n = InitBlade(n, "blade13", "blade13",                 3,   6,  0.10,   5,  285, 16.0, 19.0, 35, 15,  "",        1,     0,    PERIOD_THE_SPANISH_MAIN,     PERIOD_NAPOLEONIC); // Dueling Rapier//BB
And another for regular guns, e.g.:
Code:
n = InitGun(n,"pistol5", "pistol5a",            6,  5, 0.10,  16,   2653, 50.0,150.0,   70, 1, 14, "", "OBJECTS\DUEL\pistol_big.wav",    "pb",     0,    PERIOD_GOLDEN_AGE_OF_PIRACY, PERIOD_NAPOLEONIC);  // Horse Pistol (was Scrapper Pistol)
I'll be changing both "blade2" (rapier) and "blade13" (duelling rapier) to start in "PERIOD_EARLY_EXPLORERS", so feel free to use those - you can make the changes to your own version of "initItems.c" so that they'll show up when you test the game.

Some swords also have nations associated with them, e.g. "blade3" (badelaire) is French.
 
Uncle Manny's gift now includes a spyglass 3 instead of spyglass 4 and - both more period-appropriate and not too overpowered - a light tizona and a miquelet pistol. He now simply says: Anyway, here is the map, some money and a few other items that you may find of use. A spyglass and a compass to find your way at sea, and some decent weapons to defend yourself on land, should it be necessary.

The same has been applied to both jumpstarts.
 
Last edited:
I ran into a couple of minor problems when starting the new "Devlin Opera". The first one, I literally ran into - after Mystery Messenger ran away, I ran to the harbourmaster's office, and because I got there before Mystery Messenger had completed his long run to the jumpstart house, Emmanuel Devlin had not been placed. Possibly move all the 'Pchar.quest.meet_habourmaster.win_condition' lines up to case "ReceivedLetter"? If the player is in that much of a hurry to meet Emmanuel and isn't watching where Mystery Messenger goes, he won't get the jumpstarts, and probably doesn't care because he's going straight for the full story.

Trying again, I followed Mystery Messenger, picked the jumpstart to Santiago, didn't go much further - I was just checking that neither type of start showed any error messages. Strangely, the jumpstart did put a message in "error.log" but the normal start didn't, and the reason it's strange is that the message was about "PROGRAM\Characters\officer.c", function "GetOfficerSkillFactor", which was complaining that someone didn't have an "officerType" attribute. Putting a 'trace' in there showed that the offending character is Bonnie Devlin. I've no idea why the same error didn't show up in the normal start, when I let Mystery Messenger complete his run, then went to see Emmanuel Devlin, then left the office to meet Bonnie - both the standard quest and the jumpstart use the same commands to set Bonnie as an officer. But it does explain why Bonnie shows up in your characters as "Civilian". Neither she nor Blaze have 'ch.quest.officertype' lines in their definitions. You can set what type of officer they should be by using this line - you can find a list of valid officer types at the top of "PROGRAM\Characters\officer.c". Just to put something there, I added 'ch.quest.officertype = OFFIC_TYPE_ABORDAGE;' to both of them, tried the jumpstart again, and there was no error message. "OFFIC_TYPE_ABORDAGE" is Master at Arms, and both Bonnie and Blaze were indeed now Master at Arms. If you want them to be Civilian until the player actively assigns them, you can use "OFFIC_TYPE_CIVILIAN".
 
1. I know about that, but have never adjusted it. There's some other stuff in the very early parts of the quest I sort of never returned to, to make them better. For example on Salvador Island Bonnie doesn't follow you from pier to town hall and the crewmember approaches you from a distance. The Mystery Messenger/Emmanuel problem of course is solved if you step outside of the harbour master's office, wait a little bit and go back in because I think Emmanuel is placed when the Mystery Messenger disappears at Nicholas Sharp's door. Obviously, just moving a line to an earlier quest case is the best and easiest solution, I'll do that tonight.

2. I noticed I always had PROGRAM\Characters\officer.c in my error.log, but had no idea what the cause was and thus it didn't bother me. Line 39, right? I'll correct that too. Probably civilian, this seems to be the most story-appropriate way. And I'm also thinking about a few specific hireable officers later in the quest. But frankly I have no idea what the different role assignements for officers do.

If you want to wait a bit, in the next few days (also depending on my weekend plans) the whole Santiago chapter will be finished (next will be Santo Domingo, since you once said there aren't too many quests going on there while Santiago de Cuba is almost a bit overused). Then I will upload the complete version for testing and adjustements. If you already want to do stuff, then the Beatrice path in Santiago (the basic structure of the chapter is the same as in Martinica) should be playable in my last upload and hasn't changed since. So it can already be tested regarding topics like nighttime/daytime, the strange issues @Sebrian experienced with the open gate and other issues.
 
Uncle Manny's gift now includes a spyglass 3 instead of spyglass 4 and - both more period-appropriate and not too overpowered - a light tizona and a miquelet pistol. He now simply says: Anyway, here is the map, some money and a few other items that you may find of use. A spyglass and a compass to find your way at sea, and some decent weapons to defend yourself on land, should it be necessary.

The same has been applied to both jumpstarts.
I places Emmanuel in the port head house earlier and assigned an officer type to Blaze and Bonnie, but I've also found out that you already have a comass right at the start of the quest. This means, either by talking to Emmanuel or using a jumpstart, you get a second one. But I haven't found any compass in StartStoryline. Before I remove the second compass (then I could basically also remove the spyglass) - does anybody know how to remove the first?
 
"PROGRAM\Characters\characters_init.c" gives you some starting equipment depending on your player type. Beatrice is set to be an explorer in "DevlinOpera.c", so "characters_init.c" will give her a "compass3". To remove it, put this into "StartStoryline.c":
Code:
TakeItemFromCharacter(Pchar, "compass3");
 
I'm almost finished, but does anybody know why this here doesn't work? It's supposed to transport me to a quest cabin from the end of the pier, but neither using "boat" nor "reload2" do anything.

Code:
        case "Meet_after_Santiago":
            Locations[FindLocation("Santiago_port")].reload.l2.disable = false;
            Locations[FindLocation("Santiago_port")].reload.l3.disable = false;
            logit(TranslateString("","Let's get back to the ship!"));
            GiveItem2Character(PChar, "second_part_map");
            DeleteQuestHeader("El Navegante");

            Pchar.quest.Santiago_Debriefing.win_condition.l1 = "locator";
            Pchar.quest.Santiago_Debriefing.win_condition.l1.location = "Santiago_port";
            Pchar.quest.Santiago_Debriefing.win_condition.l1.locator_group = "reload";
            Pchar.quest.Santiago_Debriefing.win_condition.l1.locator = "boat";
            Pchar.quest.Santiago_Debriefing.win_condition = "Santiago_Debriefing";
        break;

        case "Santiago_Debriefing":
            RemoveOfficersIndex(pchar, GetCharacterIndex("Bonnie Devlin"));
            RemoveOfficersIndex(pchar, GetCharacterIndex("Blaze Devlin"));
            ChangeCharacterAddressGroup(characterfromID("Blaze Devlin"),"Cabin2SJG", "rld", "aloc0");
            ChangeCharacterAddressGroup(characterfromID("Bonnie Devlin"),"Cabin2SJG", "rld", "aloc3");
            DoQuestReloadToLocation("Cabin2SJG", "rld", "aloc4", "Santiago_Debriefing2");
//            DoReloadFromSeaToLocation("Cabin2SJG", "rld", "aloc4");
        break;
 
I'm almost finished, but does anybody know why this here doesn't work? It's supposed to transport me to a quest cabin from the end of the pier, but neither using "boat" nor "reload2" do anything.

Try using something like this ?


C:
Locations[FindLocation("Santiago_port")].locators_radius.goto.goto1 = 2.5;
    Pchar.quest.Santiago_Debriefing.win_condition.l1 = "locator";
    Pchar.quest.Santiago_Debriefing.win_condition.l1.location = "Santiago_port";
    Pchar.quest.Santiago_Debriefing.win_condition.l1.locator_group = "goto";
    Pchar.quest.Santiago_Debriefing.win_condition.l1.locator = "goto1";
    Pchar.quest.Santiago_Debriefing.win_condition = "Santiago_Debriefing";

I couldn't make "reload2_back" work either, maybe becuase there is alraedy a reaload on it, but there is no reason to use it anyways, any locator can do just fine. :fiddle

This is just an example, i'd advise to create a new locator for this.
 
"reload2_back" should work, that's how I trigger Lucia or Edmundo to ask your intentions immediately before boarding ship in "Ardent", case "kidnap_escape2":
Code:
            Pchar.quest.kidnap_what_next.win_condition.l1 = "locator";
            Pchar.quest.kidnap_what_next.win_condition.l1.location = "Santiago_port";
            Pchar.quest.kidnap_what_next.win_condition.l1.locator_group = "reload";
            Pchar.quest.kidnap_what_next.win_condition.l1.locator = "reload2_back";
            Pchar.quest.kidnap_what_next.win_condition = "kidnap_what_next";
            Locations[FindLocation("Santiago_port")].reload.l2.disable = 1;
That 'reload.l2.disable' makes sure you can't get onto your ship. It's cancelled later:
Code:
Locations[FindLocation("Santiago_port")].reload.l2.disable = 0;
 
"reload2_back" should work, that's how I trigger Lucia or Edmundo to ask your intentions immediately before boarding ship in "Ardent", case "kidnap_escape2":
Code:
            Pchar.quest.kidnap_what_next.win_condition.l1 = "locator";
            Pchar.quest.kidnap_what_next.win_condition.l1.location = "Santiago_port";
            Pchar.quest.kidnap_what_next.win_condition.l1.locator_group = "reload";
            Pchar.quest.kidnap_what_next.win_condition.l1.locator = "reload2_back";
            Pchar.quest.kidnap_what_next.win_condition = "kidnap_what_next";
            Locations[FindLocation("Santiago_port")].reload.l2.disable = 1;
That 'reload.l2.disable' makes sure you can't get onto your ship. It's cancelled later:
Code:
Locations[FindLocation("Santiago_port")].reload.l2.disable = 0;

For some reason this exact code did not work when i tested it :confused: The only difference being in that i did not disable the reload...
 
Something similar works earlier in Martinique, when you are transported back to either the jetty or the beach and start the cabin scene by going to the sea locator. I took the same structure but shortened it a bit this time, by not specifically assigning Blaze and Bonnie back as officers, only for them to be turned into quest characters again in the cabin. Perhaps I'll simply transport the player directly to the cabin after the Santiago story - no matter which of the three paths was chosen - is finished. But making it similar to the Mrtinica scene would be the nicer way.
 
Taking a break from "Hoist the Colours", I've been doing a bit of testing on "Devlin Opera". After following Mystery Messenger to the house, I took the jumpstart to Santiago. I haven't got as far as rounding up all five of Balboa's missing crew but I did finally manage to find the right stall to collect the bucket, then went to the pier to get the water, which is coded thus:
Code:
            pchar.quest.Juan_filled_bucket.win_condition.l1 = "locator";
            pchar.quest.Juan_filled_bucket.win_condition.l1.location = "Santiago_port";
            pchar.quest.Juan_filled_bucket.win_condition.l1.locator_group = "reload";
            pchar.quest.Juan_filled_bucket.win_condition.l1.locator = "reload2_back";
            pchar.quest.Juan_filled_bucket.win_condition = "Juan_filled_bucket";
That certainly worked. So using "reload2_back" should work for the teleport to the cabin in "Meet_after_Santiago".

I'd advise putting 'Locations[FindLocation("Santiago_port")].reload.l2.disable = 1;' into quest case "Santiago_start" or soon afterwards, to prevent the player from going back to the ship right away. You have to wait a long time for "Crewmember Devlin" to reach you and a player who doesn't know that he's on his way might try doing other things. If the exit back to the ship is blocked, the only way the player can move is along the pier, towards "Crewmember Devlin".

There are three ways into Santiago, and a player who has become hostile to Spain will probably use one of the other two - land at Bahia de Moa and walk into town through the same gate where you're supposed to help Ricardo, or land at Playa de Sierra Maestra, walk into town through the gate near the store, and then go from town to port - if the player even thinks of doing that. If you're going to force the player to sail into port then you might want to put 'iForceDetectionFalseFlag = -1;' either at "Greenford2Santiago", at "Cuban_history_over" or somewhere in between. Then put 'iForceDetectionFalseFlag = 0;' into a later quest case yet to be written, after the player has left Santiago and for preference after he's left Cuba entirely. The idea is to prevent the fort from seeing through the false flag which a player who is hostile to Spain will need to use to get into Santiago port. Otherwise Beatrice might be able to sail into Santiago port but might not be able to sail away...
 
Keep in mind that's the state from when I drifted off course last year. I finished the section of the story yesterday and will upload it tonight.

Last year I already mentioned that finding the missing sailor is a task that is supposed to take place at night / late in the evening, but might take until daylight. Maybe now you have a better picture of what I mean. It just doesn't work the same in daylight and involves some searching and running with very long walking distances. The quickest and most efficient way I could figure out to round up all five roughly takes until 1-2 am already. So far, I haven't done anything about this "problem" yet.

"reload2_back" works for the teleport.

The pier is already disabled as well: To @Sebrian I already explained: "The crewman deliberately takes an eternity to run up to you after you've spoken to Bonnie-Blaze-Bonnie. If I remember correctly, first it was simply because the locator I chose for him was further away than I thought. Then I kept it as a gag about how oversized the town is." But he can still be moved to a closer locator if that would be better.

I'll put iForceDetectionFalseFlag today, thanks for the tip! :onya
 
The pier is not disabled when the crewmember runs up to you, at least in the version of "quests_reaction.c" which I have - admittedly out of date! I figured that something was supposed to happen, so I ignored the icon to go back to the ship and waited, then I noticed someone running and guessed that this was something happening. If you've already disabled the reload back to ship then the crewmember's long run and the subsequent gag are fine. An impatient player can always speed up time. (Which I routinely do anyway when I'm in Santiago, or for that many any of the new, large towns.)

Searching for the missing sailors works well at night. Now I need to see what Bonnie and Blaze get up to...
 
An impatient player can always speed up time. (Which I routinely do anyway when I'm in Santiago, or for that many any of the new, large towns.)

Or fast travel out of there, like i did :D
 
Speed up time yes, fast travel not anymore. You'll have to wait for your out-of-breath crewman now. ;)

Searching for the missing sailors works well at night.
My concern is that players can either deliberately (you could even take a room at the tavern) or accidentally (not finding the sailors, forgetting stuff) reach daytime and then things like the shopkeeper working late in the evening and finally closing up to go home or the town gate being closed for the night etc. don't make that much sense anymore.

Now I need to see what Bonnie and Blaze get up to...
More trouble for sure...
 
My concern is that players can either deliberately (you could even take a room at the tavern) or accidentally (not finding the sailors, forgetting stuff) reach daytime and then things like the shopkeeper working late in the evening and finally closing up to go home or the town gate being closed for the night etc. don't make that much sense anymore.

I have tested this with the code that i posted somewhere above, and even after spending the night time will still reset to what you put it to while the loop is doing it's thing...
 
My concern is that players can either deliberately (you could even take a room at the tavern) or accidentally (not finding the sailors, forgetting stuff) reach daytime and then things like the shopkeeper working late in the evening and finally closing up to go home or the town gate being closed for the night etc. don't make that much sense anymore.
Step 1: WinMerge shows that the only difference between story-specific "Pedro Fructoso_dialog.c" and general "Pedro Fructoso_dialog.c" is the added stuff for Jorge's bible. There's a little more difference between the two versions of "Pedro Fructoso_dialog.h", the storyline version still has old versions of the lines for the "Family Story" sidequest referring to Lady Suarez instead of Lady Carranza, which won't affect the storyline as that sidequest is only for FreePlay and then only for a specific character. If I correct that, both files can go into the general "PROGRAM\DIALOGS" folder.

Step 2: if your storyline is at this point, Pedro Fructoso can be made to explain that the room is occupied right now, and a soldier has just told him to stop letting people sit for hours swigging rum because the last man who did that could barely stagger out of the door and has probably passed out on the street somewhere. That would prevent the player from advancing to daytime there. (And no prizes for guessing who "the last man" is. ;))

And if "reload2_back" is still disabled then you're not getting back on your ship to ask a crewmember for the time. That neatly covers the other way to advance time.

Moving from place to place does advance time a little, but if the fun starts at 22:00 then the player is going to have to do a lot of walking to use up 8 hours and advance to 6:00 the next morning!
 
Back
Top