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

Fixed Assassin Storyline: Item "pistoldart" not implemented

Levis

Find(Rum) = false;
Staff member
Administrator
Creative Support
Programmer
Storm Modder
Code:
WARNING!!! Item id = pistoldart not implemented

Get this error when starting a new game in the assasins storyline
 
Code:
WARNING!!! Item id = pistoldart not implemented

Get this error when starting a new game in the assasins storyline
Problem is that item isn't ALWAYS initialized, only for SOME storylines (which does actually include Assassin).

And the character init takes place BEFORE the item init does, so when the item is given to the Indian Chief character, it doesn't yet exist.
If I recall, there is a line in the StartStoryline.c to give him the item correctly afterwards.
Which means perhaps the character init version of that line can be removed.
 
"pistoldart" is a non-poisoned throwing knife which is defined in "PROGRAM\Items\initItems.c". The condition under which it is initialised is:
Code:
if(sti(GetStorylineVar(FindCurrentStoryline(), "WR_PUZZLES")) > 0 || sti(GetStorylineVar(FindCurrentStoryline(), "BUG_PUZZLES")) > 0
|| sti(GetStorylineVar(FindCurrentStoryline(), "BART_PUZZLES")) > 0)

I see references to "pistoldart" in an older version of the game, it's used to equip Indians in various places such as the ones on Petit Tabac in the "Silver Train" side quest. The version in the 18th January installer no longer equips those Indians with "pistoldart", probably because they're now supposed to use bows instead. Perhaps the references to "pistoldart" in "StartStoryline.c" and "characters\init\Story.c" for "Assassin" should also be removed or replaced with something to give "Indian Chief" a bow?

Otherwise perhaps "ASSN_PUZZLES", which is set in "Assassin.c" the same way "BART_PUZZLES" is set in "Bartolomeu.c", could be added to that condition in "initItems.c" so that the "Assassin" story also gets "pistoldart".

I suspect that "Indian Chief" never got his knife, but he's not a combat character so nobody probably noticed before. His job is to take some money from you in return for sending some warriors to help at Oranjestad. (The old version of "quests_reaction.c" tried to give "pistoldart" to those warriors, but the lines doing so have been removed in the current version, probably because they're now "isIndian" instead of "Native" and presumably get default Indian weapons, tomahawk and bow).
 
Good points, @Grey Roger.

Indeed time to equip him like this instead:
Code:
  TakeNItems(ch, "bladearrows", 3);
  ch.equip.blade = "bladearrows";
  GiveItem2Character(ch, "pistolbow");
  ch.equip.gun = "pistolbow";
  GiveItem2Character(ch, "tomahawk");
@Jack Rackham, could you confirm that is the correct way to manually equip an Indian character?
 
The tomahawk doesn't have to be there as it's given to him the moment he
tries to hit with the bladearrows.

And maybe
TakeNItems(ch, "bladearrows", 1 + rand(2));

He should not have the "IsIndian" attribute as that would give him 1 + rand(2) more arrows and another Bow.
 
The tomahawk doesn't have to be there as it's given to him the moment he
tries to hit with the bladearrows.

And maybe
TakeNItems(ch, "bladearrows", 1 + rand(2));

He should not have the "IsIndian" attribute as that would give him 1 + rand(2) more arrows and another Bow.
Done. This is a character from the character init entries, so "isIndian" doesn't apply.
 
He's equipped now and no more annoying log entry:
upload_2016-1-22_18-58-42.png
 
Back
Top