• 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 Remove quest items

This is the relevant section of code from initItems.c:
Code:
  n = InitGun(n,"LongRifle_C", "LongRifle_C_back", "BOP2",11,0.00,99,  0, 50.0,150.0,  20, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav","pb2",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Long Rifle for All Storylines
  n = InitGun(n,"LongRifle_CT","LongRifle_CT_back","BOP2",12,0.00,99,  0,150.0,250.0,  80, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav","pb2",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Long Rifle for All Storylines, with telescope
  n = InitGun(n,"telescope",  "",      "BOP2", 9,0.00,99,  0,150.0,250.0,  80, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav", "",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Telescope
  n = InitGun(n,"LongRifle_BT","LongRifle_BT_back","BOP2",10,0.00,99,9999,150.0,250.0,  80, 1,  1, "", "OBJECTS\DUEL\pistol_medium2.wav",  "",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Custom quest musket for BOP, with telescope
  n = InitGun(n,"LongRifle_W", "LongRifle_W_back", "BOP2", 7,0.00,99,  0,150.0,250.0,  80, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav", "pb2",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Custom quest musket for WR
  n = InitGun(n,"LongRifle_WT","LongRifle_WT_back","BOP2", 8,0.00,99,  0,150.0,250.0,  80, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav", "pb2",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Custom quest musket for WR, with telescope
I have already made some slight changes there. Minlevel 99 is to prevent these items from showing up at random.
If I recall, any items with price=0 are treated pretty much as quest items. Solution would be to put real numbers in there instead.
In the above example, I changed the "LongRifle_BT" to have a price of 9999 which is quite a lot because it is a very special pistol.

Not sure if the "LongRifle_C" variations and the "telescope" should be sell-able though. Once you sell them, you'll never find any other in the game.
We should be able to give them a price of "1" though and set skipsell to true for them. That might be an idea.
I have also set skipequip to true for the "telescope" to avoid the auto-equip functionality from using it, which is rather pointless.

At the moment the two Merchant Letters are quest items you can't get rid of:
Code:
  n = InitQuestItem(n,"EITC_Passport",   "EITC_Passport",     "",       4,   13,     0,0,   "","",   "","",     "","",""   ); // PB: For player types
  n = InitQuestItem(n,"WIC_Passport",   "WIC_Passport",       "",       4,   13,     0,0,   "","",   "","",     "","",""   ); // PB: For player types
Of course you DO need to carry them to have the intended effect, so I'm not sure why you would WANT to get rid of them.
But if desired, they can be changed to OBJECT_ITEM_TYPE and given a price so you can sell them again if you wish.
Is that worth it?
 
I'm making some changes to the code for these items:

Special exception added for the "Telescope" item so that it will NOT be found by FindCharacterItemByGroup and therefore won't be auto-equipped.

For item trade, it used to be that items with price = 0 could not be sold. That also prevented them from being placed in a ship's chest.
I have now changed this so that now items with price = 1 also cannot be sold. However, those CAN then be placed in a chest.

So at the moment I have these items working like this in my game:
- Common Long Rifle: Found in Maltese Knight Abbey, cannot be sold, but can be placed in a chest
- Common Long Rifle with Telescope: Combined with Telescope, cannot be sold, but can be placed in a chest
- Telescope: Can only be equipped if you have a Long Rifle, will NOT be auto-equipped. Can be placed in a chest, but not sold
- Bartolomeu Quest Long Rifle: Does not require ammo, can be sold for a LOT of gold (for if realistically inclined players don't want to keep this overpowered weapon)
- Woodes Rogers Quest Long Rifle: Remains unchanged, so this does use ammo and cannot be sold nor placed in a chest
- None of these items can be Tossed

Here's the initItems.c code I have for this now:
Code:
  n = InitGun(n,"pistolbow", "bow",  "BOP",  1, 0.00,  1,  20, 30.0, 40.0,  80, 1, 1.5,"", "OBJECTS\DUEL\bow.wav",  "ar",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // Bow (BOP)
  n = InitGun(n,"LongRifle_C", "LongRifle_C_back", "BOP2",11,0.00,99,  1, 50.0,150.0,  20, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav","pb2",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Long Rifle for All Storylines
  n = InitGun(n,"LongRifle_CT","LongRifle_CT_back","BOP2",12,0.00,99,  1,150.0,250.0,  80, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav","pb2",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Long Rifle for All Storylines, with telescope
  n = InitGun(n,"telescope",  "",      "BOP2", 9,0.00,99,  1,150.0,250.0,  80, 1, 30, "", "",  "",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Telescope
  n = InitGun(n,"LongRifle_BT","LongRifle_BT_back","BOP2",10,0.00,99,9999,150.0,250.0,  80, 1,  1, "", "OBJECTS\DUEL\pistol_medium2.wav",  "",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Custom quest musket for BOP, with telescope
  n = InitGun(n,"LongRifle_W", "LongRifle_W_back", "BOP2", 7,0.00,99,  0,150.0,250.0,  80, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav", "pb2",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Custom quest musket for WR
  n = InitGun(n,"LongRifle_WT","LongRifle_WT_back","BOP2", 8,0.00,99,  0,150.0,250.0,  80, 1, 30, "", "OBJECTS\DUEL\pistol_medium2.wav", "pb2",  1,  PERIOD_EARLY_EXPLORERS,  PERIOD_NAPOLEONIC);  // JRH: Custom quest musket for WR, with telescope
Any thoughts or comments on this? Especially @Bartolomeu o Portugues, @Grey Roger and @salonikasurf .
 
Last edited:
If anything, I'd have the rifles the other way round - you should be able to sell the one from the Maltese abbey but perhaps not the ones from the quests. But it ought to be possible to put all of them into the ship's chest. (Personally, I'll most likely put the rifle from "Bartolomeu" into the chest, along with other quest souvenirs, regardless of whether it can be sold. There's no way to get another one, and I'm a hoarder. xD)

Why are you not allowing the Woodes Rogers rifle to be put in a chest?
 
If anything, I'd have the rifles the other way round - you should be able to sell the one from the Maltese abbey but perhaps not the ones from the quests. But it ought to be possible to put all of them into the ship's chest. (Personally, I'll most likely put the rifle from "Bartolomeu" into the chest, along with other quest souvenirs, regardless of whether it can be sold. There's no way to get another one, and I'm a hoarder. xD)
Since you cannot get a new one and they're quite special, I'd prefer if you need to keep at least one.
The Bartolomeu one is technically ridiculously overpowered, but the Maltese Knight Abbey one is not.
So I can understand why some people would not want the silly (but fun!) one.
I'll just set them ALL to be not sell-able but do allow them to be placed in a chest. With the exception off....

Why are you not allowing the Woodes Rogers rifle to be put in a chest?
I'm pretty sure that item is already how @Jack Rackham wants it. It's his gun in his storyline. He probably wouldn't appreciate me changing that.... :rolleyes:
 
Why are you not allowing the Woodes Rogers rifle to be put in a chest?
That rifle may be used in WoodesRogers 2. I have the town and situations for it. If it's a quest item it can't
be put in a chest or given to anyone.
 
Very true. So if that's indeed what you want for it, that is what you have. :yes
 
To keep questitems doesn't look good. In many games you find for ex. a hammer and when you use it it suddenly disappears.
Very strange. I'm sure I have done that some times too. :oops:

Keys though can be treated that way. When you unlock a door the key can be "left in the lock". (disappear) :shrug

The most elegant solution is if you can get the removal of those items to fit in with the story. :boom:
A natural explanition of how they are removed. Even if it's as simple as "Hey, that's my tools..."

Just some thoughts from an :pirate07:
 
If it is worth too much, the player suddenly gets a huge advantage though.
 
Currently the most expensive gun is 9999 though. Should this one indeed be worth 50% more?
 
Frankly a player who reached the last quest of this storyline has already a lot of money (Otherwise, he really needs to learn to play video games xD). So, earning 9999 or 15 000 doesn't change much his situation. In my opinion, this gun is the best one, so it can be the most expensive. Let's say 12 000.
 
If you want to maintain some sort of balancing, then yes you do! :cheeky
How about adding a character early in the quest who "steals" some stuff from you prior to the quest (including that one)?
This can be stored somewhere so you can get it back later.
 
If you want to maintain some sort of balancing, then yes you do! :cheeky
How about adding a character early in the quest who "steals" some stuff from you prior to the quest (including that one)?
This can be stored somewhere so you can get it back later.
Yes, this could be a solution :yes. Something sure, I don't want this gun used in the Mayan island :rolleyes: (maybe the most important part of the quest)
 
How do you determine that the rifle does not need ammunition? One way to disable it is to change it so that it does need ammunition, preferably a type of ammunition which can only be obtained at an appropriate time if you need the rifle again in a later quest... Otherwise, if you are certain that the rifle will never be needed again, change the end of "The Cartagena Firework" so that you give it back to Augusto Queiroz.
 
Back
Top