Comments (4)
Hi @idshibanov and @oleg-derevenetz , I would like to hear your opinion about a possible solution. One of them to simply add _enemyArmies.erase( tileIndex );
but I have a feeling it is not a proper solution. What do you think?
from fheroes2.
I can make a PR with the workaround I mention, or we may look for another solution (maybe update _enemyArmies
on a hero being dismissed, assuming I correctly understood what happens ?)
from fheroes2.
We root cause of this assertion is that we do not update priority targets properly for AI after the action within Normal::updatePriorityTargets()
method. More specifically, _enemyArmies is not updated. We must erase tile ID after capturing a town which we don't do. In this example the AI tries to clear a DEFEND task under if ( hero.GetIndex() != tileIndex ) {
condition. I think this comment is not valid:
// Either the castle has just been captured, or the hero meets the guest hero of a friendly castle. No task should be updated.
// If any of these assertions blow up, then this is not one of these cases.
from fheroes2.
It looks like a regression from #7379.
from fheroes2.
Related Issues (20)
- Town Population screen (with the well), "Recruit Creatures" window, display in brackets the remaining quantity of resources and gold
- Combat screen, the number displayed for lightning spells damage is incorrect when the opponent has the Lightning Helm artifact HOT 9
- Combat screen, Captured Artifact window, artifact is displayed only once when opposing hero has two copies of the same artifact HOT 3
- Magic Book, spell points bookmark right-click information window, add the maximum number of spell points
- New feature: add maps downloading script into release HOT 2
- Support more controller buttons on Switch HOT 1
- Ore (and possibly all other resources) are incorrectly shown on the map. HOT 3
- The Editor doesn't check objects while placing a castle
- [Interface] Color-Coded Interface (ala Heroes III) HOT 1
- Translate all cyrilic to latin alphabet HOT 1
- Add HD-mod to roadmap HOT 3
- Map editor, crash while creating a message with space and a new line
- Share artifacts, army, exchange castle/town HOT 1
- Random type of class - Magic or Might HOT 1
- 'Replay Opponent Turn' New Button HOT 1
- Ctrl to see enemy creature range HOT 1
- [Scenario Editor] Prohibit the positioning of the ultimate artifact near an edge of the adventure map with the 9 squares rule of the original game
- Game, harmonize the positioning order of resource sprites in the game's various windows and screens
- Android mouse map movement move mouse to edges should scroll HOT 2
- [Scenario Editor] Graphics of the hero's secondary skills should be displayed in the hero's screen
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fheroes2.