To some extent, yes. Except that the fort saw me pirate the SP_CastelF. Anyway, I added your modifications from post 78 and the problem is solved. At least, it is now. After adding those modifications I tested it by reloading my Playa de Sierra Maestra savegame, capturing the payroll ship, then going away and pirating something else. When I returned to Santiago I wasn't attacked and "compile.log" correctly reported that Santiago fort remembered me being in a SP_CastelF which I no longer had. Then I reloaded the savegame, captured the payroll ship, went away and did not get a new ship, and returned to Santiago. The fort still didn't attack me and "compile.log" still reported that the fort remembered me being in a SP_CastelF which I no longer had. Huh? This is why: Code: compidx = GetCompanionIndex(GetMainCharacter(), n); if (compidx > 0) That made "HasThisShip" fail. You are companion index 0! So that condition didn't allow your own ship to be checked. Changing it to 'if (compidx >= 0)' solved the problem. I ran the test both ways again and it worked perfectly - the fort forgot me and did not attack if I returned with a different ship, but it remembered me and did attack if I returned with the SP_CastelF. It's probably the only time when I've been glad to see a fort shooting at me. I merely put the forget code in the same place as the remember code. If it can remember your ship then it can forget because you don't have it any more. When you next come within visible range, if you give them reason to remember your new ship then that's when they'll remember it. If you don't come within visible range then it doesn't really matter. It wasn't a player mistake - he's not to know that some time in the future Portugal and France will go to war, so at the time it was fine. Another possible scenario is if you're on good terms with Portugal and Holland, they're on good terms with each other, you've just come from Kralendijk so you're flying a Dutch flag, and you're planning on going back soon so there's no reason to change to Portuguese. If Sao Jorge remembers you as Dutch and Portugal later goes to war with Holland, you're in trouble next time you visit Sao Jorge even though you've personally done nothing against Portugal. But if Sao Jorge doesn't care about you when it sees you as a friend then, provided you don't do anything to provoke them, it still won't care if you return as a friend. Maybe increase visibility ranges again? Anyway, I suspect that's rather optimistic because even in WW2 with better optics, it wasn't that easy to identify a ship properly until it got rather closer. That's from reading books written by the ships' officers about real events, not fiction. If they did that, they'd end up with so much paper that they'd never have been able to find the record of the ships which were actually important, i.e. the ones they knew to be suspicious. On the other hand, thinking about it a bit more, I'm inclined to agree with you on making the memory depend on model rather than type, provided a default model is indeed assigned where none is specified in the ship's own entry in "Ships_init.c". My analogy with a crook repainting a car to avoid detection would be valid if repainting the ship was as much of an effort as repainting a car to a good enough standard to be convincing, which it isn't; and anyway, detecting model rather than type doesn't get in the way of doing what I want to do, which is go away, pirate something else, then return and the fort doesn't remember me as I'm not in the ship it saw me steal. So, pending a test of whether "GetCharacterShipModel" works as intended, try this version. Friendly ships still aren't remembered but ships which are worth remembering should now be remembered by model rather than type.