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

Solved Nation rank dev-console cheat. + a question or two.

Jonesie85

Boarding Master
Storm Modder
Hello all, if you have looked at the forum you will have noticed that i haev flooded it with questions about national rank. I found a possible lead.

'Age of Pirates 2/Program/DIALOGS/russian/Governor/eng_Governor.c', I found that the file contained quest-line codes.

eg:

Code:
case "Step_4_3":
            dialog.text = DLG_TEXT_GUB[168];
            link.l1 = DLG_TEXT_GUB[169];
            link.l1.go = "exit";
            AddQuestRecord("Eng_Line_4_Intelligence_Curacao", "10");      <--- THE SPECIFIC QUEST
            CloseQuestHeader("Eng_Line_4_Intelligence_Curacao");
            pchar.questTemp.State = "empty";
            pchar.questTemp.CurQuestNumber = "5";
            SaveCurrentQuestDateParam("questTemp");
            pchar.questTemp.Waiting_time = "2";
            AddMoneyToCharacter(pchar, 110000);                          //    <--- QUEST REWARD
            AddCharacterExpToSkill(pchar, "Sailing", 250);
            AddCharacterExpToSkill(pchar, "Sneak", 170);
            AddCharacterExpToSkill(pchar, "Grappling", 400);
            AddTitleNextRate(sti(NPChar.nation), 2);                        //<--- THE LINE OF CODE THAT INTERESTS ME
            TakeItemFromCharacter(pchar, "letter_open");
            BackItemDescribe("letter_open");
            TakeNationLicence(HOLLAND);
            ChangeCharacterNationReputation(pchar, sti(NPChar.nation), 1);
            //ñëóõè
            AddSimpleRumour(DLG_TEXT_GUB[170],ENGLAND, 5, 1);
        break;

I ashumed that the number represents a cumulative value. from 0 to (i think 13 or 14). With various quests giving from 0.5 to 4 it would add up.

I wrote this code into the dev-console. Basically i copied and pasted the line of code into the Debuger.c file and removed the 'N'.

Code:
string descF22 = "Jonesies' National Title Cheat";
void CalculateInfoDataF22()
{
    totalInfo = descF22;
    // -->
    AddTitleNextRate(sti(pchar.nation), 5);                            //<--- No 'n' and altered value.
    // <--
    totalInfo = totalInfo + NewStr() + NewStr() +
    "National Rank cumulative number increased by 5, good luck";
    SetFormatedText("INFO_TEXT",totalInfo);
}

I tested it by loading up my current game, I am a leitenant (sorry about the spelling). I had originally left the value at 2. I went into the dev-console and pressed the f22 button 4 times. I then went to the english governor-general and asked for a new mission for england. i was given the dialog informing me of my promotion to commander. I pressed the f22 button another 4/6 times and was informed of my promotion to captain. Another 4/6 times, another promotion.

I am unsure of the side effects but the worst that could happen is the world ending. Or, it breaks the a quest line. Myabe the promotion isnt valid.

I hope this helps somebody. especially if the messed up a mission and can no longer achieve max national rank.
 
That's some good work Jonesie!

People are always messing this up when they accidentally attack the wrong ship. It recently happened to me when I attacked a pirate I was after outside of a French port flying a French flag. When I fired upon him, I lost my credentials.

You should modify the appropriate files and save them. Write a "read me" file on how/what to replace/where to put the new files and then RAR it into a downloadable file and hang it on GameFront or whatever your preferred sharing site might be and then share the link for it here in a new thread announcing it as a Mod Release - "Nation Rank Quick Promotion Mod" or something like that.

Then we get you Modder status.

MK
 
Back
Top