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

Medium Priority Making Better use of Indian Weapons

Changed the indian treasure in the apothecary quest to contain some curare now and removed the bow and arrows, it only holds a quiver now. The bow and arrows you probably got already from the indians annoying you everywhere in that quest :p.
Also added the possebility to gain some tar in the quest.
I like how it works :), altough I expected you'd use flame particle effects, but the smoke is nice too :).
Included in here:
Mod Release - Build 14 Beta 4 Internal WIP For Testing | PiratesAhoy!
 
Using the previous version (18th January installer plus 24th January zip update), I went to Hispaniola to look at the temple. There are Indians guarding the temple who attack you. Two problems became apparent:
1: At close quarters they usually tried to stab me with arrows. Only a couple used tomahawks.
2: If I kill an Indian, as with any other dead enemy I auto-loot his weapons. As arrows are being treated as melee weapons rather than ammo, I auto-looted those as well. Which meant by the time the fight was over, I had rather more than the 2 arrows you're supposed to be able to carry without a quiver.

I've yet to try the newest (6th February) installer so if these problems have already been fixed, ignore this post.
 
At close quarters they usually tried to stab me with arrows. Only a couple used tomahawks.
If I saw correctly, they switch to using Tomahawks at the moment that they first hit you.
So they start the hit with an arrow and finish it with a tomahawk.
@Jack Rackham should be able to confirm this though.

If I kill an Indian, as with any other dead enemy I auto-loot his weapons. As arrows are being treated as melee weapons rather than ammo, I auto-looted those as well. Which meant by the time the fight was over, I had rather more than the 2 arrows you're supposed to be able to carry without a quiver.
That does match up with my earlier observation that if you're having an arrow-vs-arrow fight, you can do a LONG time before you run out of ammo.
I think that hasn't changed, so indeed something still to be looked at.

Good find! :onya
 
Yes one hit with an arrows should change it to tomahawk use.
And one fired bow should change the tomahawk back to an arrow.

Even if I changed it to 3 arrows without a quiver to match someting else somewhere
maybe you can get to many arrows by looting. Will look at it when I find time.
 
Yes one hit with an arrows should change it to tomahawk use.
And one fired bow should change the tomahawk back to an arrow.
Thanks for confirming. :doff

Even if I changed it to 3 arrows without a quiver to match someting else somewhere
maybe you can get to many arrows by looting. Will look at it when I find time.
Indeed if I understand correctly the issue is with the looting.
If you could have a look into it, that would be much appreciated! :cheers
 
I made a quick check and
1) Some of the arrows enemies fire at you adds to your arrows. But this never exceed 3 (without a quiver)
2) I made no changes in InternalSettings.h. No autolooting occured so not too many arrows because of that.
But I wonder is autoloot a choice somewhere or is something changed?
 
I made no changes in InternalSettings.h. No autolooting occured so not too many arrows because of that.
But I wonder is autoloot a choice somewhere or is something changed?
Auto Looting is on by default. The relevant code is in PROGRAM\Loc_ai\LAi_fightparams.c:
Code:
    if(AutoLoot)
     {
       int q;
       aref tempitem;
       bool log = false;
       string b = "";
       string g = "";
       string m = "";
       string comp = "";
       string tempitm = ""; // PB: prevent double looting
       bool btemp = !IsOfficer(attack) && !IsOfficer(enemy);
       // SCREWFACE : to loot enemy weapons if one of your crewmember kill an enemy
       if(attack.name==XI_ConvertString("Crewmember") || enemy.name==XI_ConvertString("Crewmember")){btemp=false;}
       // END
       if(!btemp) // that is, do this if either attack || enemy is officer. Done as a ! and && because there were originally three ors to do and some nesting which POTC doesn't support.
       {
         int ethingidx;
         if(CheckAttribute(enemy, "equip.blade") && enemy.lastname != VC_MONKEY_LNAME) // ccc
         {
           //tmp += enemy.equip.blade;
           ethingidx = GetItemIndex(enemy.equip.blade);
           if(ENABLE_WEAPONSMOD && CheckAttribute(Items[ethingidx], "bladequality") && sti(Items[ethingidx].bladequality) < MIN_QUALITY_TO_KEEP+2) // NK 04-11-03 add min qual check
           {
             //do nothing
           }
           else
           {
             tempitm = GetCharacterEquipByGroup(enemy,BLADE_ITEM_TYPE);
             if(tempitm != "bladeX4")
             // PB: Don't loot fists
             {
               GiveItem2Character(GetMainCharacter(), tempitm);
               TakeItemFromCharacter(enemy, tempitm); // PB: To prevent double looting
               makearef(tempitem, Items[ethingidx]); // NK 04-09-08 now use native getindex
               log = true;
               b = " " + XI_ConvertString("a") + " " + TranslateString("",tempitem.name);
             }
           }
         }
 
Yes one hit with an arrows should change it to tomahawk use.
And one fired bow should change the tomahawk back to an arrow.
The problem there is that if you block, the Indian is likely not to hit you. Then you hit him. If you can keep that up (and I did, several times, despite only having Melee 2 and the first two melee perks) then you kill him without him ever getting to use the tomahawk.

Indian corpses don't seem to be lootable. So if one of my officers, who is less adept at blocking than I am, manages to kill an Indian who did switch to tomahawk, I can't take it from the body.
 
Thanks for that Pieter. Guess I can do an exception in that code like for fists.
Strange though that autoloot didn't happen when I started a new fresh game of the latest version. I also killed a guard (with a musket) just to be sure and his weapons were not autolooted either. :confused:
 
It's more logicical if indians do switch to tomahawks if they only hit your block too.
I'll see what I can do about it.

Indian corpses don't seem to be lootable.
That's strange - I have no problem looting them.
 
Indian corpses don't seem to be lootable. So if one of my officers, who is less adept at blocking than I am, manages to kill an Indian who did switch to tomahawk, I can't take it from the body.
That IS odd. What happens when you try? Even if there is "nothing to loot", there should be an onscreen message saying "There is nothing to take".
But that shouldn't happen for Indians anyway, because they get PLENTY items.
Depends though on how those Indians were generated. I did my tests with the ones just outside the Hispaniola temple, which are randomly generated.

It wasn't too long ago that I did some tests with Indians myself and while I observed the same general behaviour that you report, I had no problem with manual looting at the time.
If that is indeed a problem now, it must be VERY recently introduced. If you can replicate it, please make a Bug Tracker entry so we'll remember to check it.

Thanks for that Pieter. Guess I can do an exception in that code like for fists.
Thanks in advance! :woot

Strange though that autoloot didn't happen when I started a new fresh game of the latest version. I also killed a guard (with a musket) just to be sure and his weapons were not autolooted either. :confused:
Remove the file named "options" in your main game folder.
Maybe you had disabled the Auto Loot setting in the Game Preferences?

It's more logicical if indians do switch to tomahawks if they only hit your block too.
I'll see what I can do about it.
Sounds good. :onya
 
In that case, please make a "problems with looting" bug tracker entry to remind me to give both your issues a test as well.
 
I have made these changes:

1) Autoloot excludes bladearrows to prevent from getting more arrows than you could carry.
2) Now also Pchar and officers switch to tomahawks (if they got one!) when trying to hit with an bladearrow.
3) Pchar, officers and NPC:s do this also when hitting at an blocking enemy. Earlier only when hitting the body.

Tested and works.
 

Attachments

  • JRH bow & arrow fixes 16-02-10.7z
    27.9 KB · Views: 169
Thanks a lot, Jack! ;cat

Autoloot excludes bladearrows to prevent from getting more arrows than you could carry.
Since arrows double as ammo rather than blades and the REAL blade should be a Tomahawk, that does make sense to me.
I hadn't actually thought of it like that though; I just figured "enforcing the ammo limit upon looting".
Your solution is much simpler, effective and therefore much better. Good thinking! :onya

EDIT: Ah, but I think line:
Code:
if(tempitm != "bladeX4" || tempitm != "bladearrows")
Should be:
Code:
if(tempitm != "bladeX4" && tempitm != "bladearrows")
Otherwise it would always return true, wouldn't it?
 
Not sure about that synatx. I have made a lot of looting and it seems to work both ways.
If you're sure about the syntax please change it to &&.
 
Not sure about that synatx. I have made a lot of looting and it seems to work both ways.
If you're sure about the syntax please change it to &&.
Imagine if you killed a character who was wielding his fists, so tempitm = "bladeX4";
That means:
Code:
if("bladeX4" is not equal to "bladeX4" (false, because they ARE equal) || "bladeX4" is not equal to "bladearrows" (true, because they indeed are different) )
Which means:
Code:
if(false OR true)
And that returns 'true'.
 
Back
Top