Commit Graph
100 Commits
Author SHA1 Message Date
DjWarmongerandGitHub d9a2621231 Merge pull request #1939 from vcmi/fix_top_of_map_objects
Merging after positive review.
2023-04-11 10:40:18 +02:00
4bd3cc1679 Update lib/mapObjects/ObjectTemplate.h
Co-authored-by: Nordsoft91 <nordsoft@yahoo.com>
2023-04-10 20:45:41 +02:00
Tomasz Zieliński 3c87b3934d Do not place object visible tiles over the top of the map. 2023-04-10 19:26:53 +02:00
Tomasz Zieliński cf1f9c456b Removed unrelated comment 2023-04-07 21:40:47 +02:00
Tomasz Zieliński 37f1bf9d78 Merge remote-tracking branch 'origin/beta' into fix_pandora_amounts 2023-04-07 21:26:36 +02:00
Tomasz Zieliński f1c52f501d Fix Pandora Box creature amounts to match OH3 exactly. 2023-04-07 21:23:34 +02:00
DjWarmongerandGitHub 53df84459f Merge pull request #1781 from vcmi/object_distribution
Improved object distribution
2023-04-04 06:52:10 +02:00
Tomasz Zieliński 1e18887c9c Merge remote-tracking branch 'origin/beta' into object_distribution 2023-04-04 05:52:57 +02:00
Tomasz Zieliński aca227b5e4 Manually adjust the position of town - noticeable on S maps. 2023-04-01 17:07:43 +02:00
Tomasz Zieliński 308b42549b Merge remote-tracking branch 'origin/beta' into object_distribution 2023-03-31 15:44:14 +02:00
Tomasz Zieliński 46a24043e8 Add back Mines. 2023-03-29 17:06:17 +02:00
Tomasz Zieliński 401f2342c0 Place Mines after Towns and Monoliths. 2023-03-29 16:54:22 +02:00
Tomasz Zieliński 5ed3c2d518 Place towns and monoliths first - preferably at the zone border. 2023-03-29 16:25:13 +02:00
Tomasz Zieliński 045942fd68 Fixed warning-as-error 2023-03-28 18:25:56 +02:00
Tomasz Zieliński b184e80b72 Use the most suitable template for object 2023-03-28 17:53:08 +02:00
Tomasz Zieliński 49c029ea6c Minor refactor 2023-03-28 17:13:24 +02:00
Tomasz Zieliński b3a457c71a Skip objects with value too low to be placed in the zone. 2023-03-27 17:29:46 +02:00
Tomasz Zieliński 511a42f9b9 Oops missed that part. 2023-03-27 09:35:52 +02:00
Tomasz Zieliński 18a87d1ec0 Distribute limited objects evenly in zones with matching terrain 2023-03-27 09:09:58 +02:00
Tomasz Zieliński a88e1dc1f6 Add only one template per object 2023-03-27 08:44:49 +02:00
Tomasz Zieliński 00a77e3c5f Probably found the root cause of terrain problems. 2023-03-25 18:52:18 +01:00
DjWarmongerandGitHub 2c4cde060a Merge pull request #1694 from vcmi/extra_rmg_monoliths
This could be controversial solution, but since there were no objections, I'll give it a shot.
2023-03-25 18:38:06 +01:00
DjWarmongerandGitHub 114e7d196b Merge pull request #1698 from vcmi/object_placement_tweaks
No objections, works fine for me as well.
2023-03-25 18:13:15 +01:00
Tomasz Zieliński 68a2bb78a5 Fix the case of invalid native town type :? 2023-03-25 18:08:46 +01:00
Tomasz Zieliński ab57941f0a Make NKAI default AI. 2023-03-25 12:17:35 +01:00
Tomasz Zieliński 9d7d4b6a5f Fixed editor shortcut on Windows 2023-03-25 11:40:44 +01:00
Tomasz Zieliński 392061e97e Fix loading towns which in OH3 editor have defined horde buildings level 1 - 5 (inluding random town). 2023-03-25 11:17:49 +01:00
DjWarmongerandGitHub 15047a4469 Merge pull request #1718 from vcmi/fix_shipyard_border
Fix shipyard border calculation for RMG
2023-03-19 16:05:24 +01:00
Tomasz Zieliński 9e206dbbc7 Forgot this one 2023-03-19 09:51:37 +01:00
Tomasz Zieliński f52c465322 Allow zones to inherit properties recursively, in any order. 2023-03-19 09:27:05 +01:00
Tomasz Zieliński dd3803b111 Don't place shipyard or boats at very small lakes
(cherry picked from commit 1d2913bea0)
2023-03-18 22:05:25 +01:00
Tomasz Zieliński e1ced317a1 Few tweaks for boat placement to keep distance between it and other objects, especially guards. 2023-03-18 21:59:23 +01:00
Tomasz Zieliński 1dc96d6844 Fix shipyard border calculation for RMG 2023-03-18 20:12:36 +01:00
Tomasz Zieliński 23a5a32756 Add fallback for empty terrain types. Still it's a workaround and does not solve the root cause. 2023-03-18 17:00:50 +01:00
Tomasz Zieliński eabcbfc25a Fix all stacks being capped at 10 units 2023-03-17 22:32:05 +01:00
Tomasz Zieliński f57c275603 Merge remote-tracking branch 'origin/develop' into object_placement_tweaks 2023-03-17 21:47:16 +01:00
Tomasz Zieliński f2dc9cb48e - Place Subterranean Gates as far from other objects as possible
- Added minimum distance between zone guards
2023-03-16 18:42:28 +01:00
Tomasz Zieliński 62490683ce Place objects away from zone guard in both zones, not only the where it is placed. 2023-03-16 16:20:11 +01:00
Tomasz Zieliński 5b267f9cbd - Duplicate Monolith templates to ensure at least 100 are available to RMG
- Do not use Monoliths which can't be placed at any land
2023-03-16 06:58:25 +01:00
DjWarmongerandGitHub a20e6aecb7 Merge pull request #1568 from vcmi/DjWarmonger-patch-2
Update CRewardableConstructor.cpp
2023-02-11 12:14:50 +01:00
DjWarmongerandGitHub 94bc418e34 Update CRewardableConstructor.cpp
Fixed swapped identifiers in Limiter.
2023-02-11 08:28:29 +01:00
DjWarmongerandAndrii Danylchenko 908f8f5aee Update README.md 2023-02-05 10:06:35 +02:00
DjWarmongerandGitHub ca01c179b4 Merge pull request #1528 from rilian-la-te/daremyth-fix-bonus-v2
vcmi: deprecate MAXED_SPELL
2023-02-04 15:08:59 +01:00
DjWarmongerandGitHub e9c36a91a4 Merge pull request #1525 from IvanSavenko/prison_fix
Yep, Prison ID is special as Prison is `CGHeroInstance` in disguise.
2023-01-30 21:22:15 +01:00
DjWarmongerandGitHub 25ef065dbe Merge pull request #1486 from IvanSavenko/configurable_rewardables
Well, it works for my brand new objects with arbitrary bonus, so likely will work with everything else.
2023-01-26 17:01:01 +01:00
DjWarmongerandGitHub c6c2bc7ca4 Merge pull request #1504 from vcmi/dydzio0614-patch-1
Change readme year to 2023
2023-01-24 10:52:58 +01:00
DjWarmongerandNordsoft91 ccc79d4ab9 Update README.md
Keep total download counter
2022-12-24 22:07:34 +04:00
DjWarmongerandNordsoft91 e43e127339 Update README.md
Update download counter
2022-12-24 22:07:34 +04:00
Tomasz ZielińskiandAndrii Danylchenko 8c481dff46 Fix incorrect templates for mines in HoTA 2022-10-08 12:42:10 +03:00
Tomasz Zieliński 127d7ec40b Fixed asserts (only for debug build) 2022-09-29 21:10:44 +02:00
DjWarmongerandGitHub 58a3abb643 Merge pull request #963 from vcmi/terrain-rewrite
Terrain rewrite
2022-09-29 18:24:05 +02:00
Tomasz Zieliński 20c102e648 Remove T prefix from new typedefs 2022-09-29 11:44:46 +02:00
Tomasz Zieliński 475f835769 More style tweaks 2022-09-28 11:38:08 +02:00
Tomasz Zieliński d38b6297f8 missing line 2022-09-27 07:53:21 +02:00
Tomasz Zieliński f386f42166 Merge remote-tracking branch 'origin/develop' into terrain-rewrite
# Conflicts:
#	lib/Terrain.cpp
#	lib/Terrain.h
#	lib/battle/CBattleInfoEssentials.cpp
#	lib/rmg/ObstaclePlacer.cpp
#	lib/rmg/RiverPlacer.cpp
2022-09-27 07:50:17 +02:00
Tomasz Zieliński 25f66097cc Handle RoadType by value / reference 2022-09-26 10:20:39 +02:00
Tomasz Zieliński f804f8a326 Store RiverType by value, handle by reference 2022-09-26 09:51:36 +02:00
Tomasz Zieliński 11dd71515a comment 2022-09-26 09:18:01 +02:00
Tomasz Zieliński 2bd30556a3 Store TerrainType by havlue and handle by reference 2022-09-26 09:17:55 +02:00
Tomasz Zieliński cd3a1a02c2 More style tweaks 2022-09-25 21:47:44 +02:00
Tomasz Zieliński 64fd896978 Free memory at TerrainTypeHandler destruction 2022-09-25 20:52:51 +02:00
Tomasz Zieliński 4ea57ea7fc A variety of suggested style tweaks 2022-09-25 09:33:56 +02:00
Tomasz Zieliński fd63cb6109 and here 2022-09-25 08:07:22 +02:00
Tomasz Zieliński 97a94ce61e Handle Tile by reference instead of pointer 2022-09-25 08:04:15 +02:00
Tomasz Zieliński 0b56778e00 Fix for compatibility in rewrite 2022-09-23 20:01:54 +02:00
Tomasz Zieliński a5077245a8 Merge remote-tracking branch 'origin/develop' into terrain-rewrite
# Conflicts:
#	lib/Terrain.cpp
#	lib/Terrain.h
2022-09-23 20:01:13 +02:00
Tomasz Zieliński f883395710 A little refactoring 2022-09-23 19:26:38 +02:00
Tomasz Zieliński 09931b6c9d Moved roads and rivers to config files.
This also allows adding new ones via mods.
2022-09-23 18:57:16 +02:00
Tomasz Zieliński ebe45d512d Moved roads and rivers to TerrainTypeHandler, by analogy to TerrainType. 2022-09-23 16:24:01 +02:00
Tomasz Zieliński 6aaf77812b Changed logic for zone placement.
Now every zone can be surface, underground, or both. This is separate from water <-> land distinction.

Iand type is now a combination of flags and can take multiple values: "type": ["LAND", "WATER", "SURFACE", "SUB", "ROCK"]. In nothing is specified, terrains get LAND | SURFACE flags by default.

Non-surface zones will default to DIRT, and non-underground zones will default to SUBTERRA.
2022-09-22 18:23:31 +02:00
Tomasz Zieliński e53613caa7 Fixed crash in pathfinder 2022-09-21 21:44:39 +02:00
Tomasz Zieliński fa31309eed Fixed minimap colors 2022-09-21 14:42:22 +02:00
Tomasz Zieliński 97c17c6294 - Terrain config
- Fix for underground terrains
2022-09-21 14:11:32 +02:00
Tomasz Zieliński c9c4603f75 Firts working version that launches original maps 2022-09-21 13:43:57 +02:00
Tomasz Zieliński 11e1bb44a2 Load sounds for new terrains later 2022-09-21 13:43:00 +02:00
Tomasz Zieliński 494b0f0226 First version that compiles 2022-09-21 11:34:23 +02:00
Tomasz Zieliński b20f649521 stash 2022-09-19 16:13:58 +02:00
DjWarmongerandGitHub 7ba271edf1 Rotation rebase2 (#912)
* Instead of [x][y][z] coordinates, map will be stored as [z][x][y].
* Nullkiller AI can get it too.
* Use boost::multi_array instead of nested vectors
* In MapHandler too
* Rotate foreach algorithms, too
* VCAI gets rotated, too
2022-09-18 17:39:10 +03:00
DjWarmongerandGitHub d34dd8676e Merge pull request #898 from vcmi/cache-pathfinding
Cache pathfinding
2022-09-14 20:32:54 +02:00
5e2d87abd7 Update AI/Nullkiller/Goals/ExecuteHeroChain.cpp
Co-authored-by: Andrey Filipenkov <decapitator@ukr.net>
2022-09-14 16:23:13 +02:00
Tomasz Zieliński 931f4af2df typo 2022-09-14 15:24:39 +02:00
Tomasz Zieliński 77e43cb36f Cache Pathfinding skill 2022-09-14 15:24:24 +02:00
DjWarmongerandGitHub 627b63ca56 Merge pull request #894 from vcmi/optimization_rebase
Bonus and string optimization
2022-09-14 13:03:30 +02:00
Tomasz Zieliński 55b142a8c9 Suggested tweaks 2022-09-14 11:37:12 +02:00
Tomasz Zieliński d0f857c3c4 - Generate caching string with sprintf
- Reserve BonusList space to avoid costly vector reallocation
- Tweaks in int3 and UNDEAD bonus
2022-09-14 11:00:40 +02:00
DjWarmongerandAndrii Danylchenko 3d2dc2335b Switch ObjectTemplate to shared_ptr<const> (#870) 2022-09-11 16:13:53 +03:00
Tomasz ZielińskiandAndrii Danylchenko 40585a66c0 Style, commend - requested 2022-09-11 11:31:28 +03:00
Tomasz ZielińskiandAndrii Danylchenko 22b4795f86 Well, we should have some sensible exception handling in VCMI 2022-09-11 11:31:28 +03:00
Tomasz ZielińskiandAndrii Danylchenko 1649cf2bb9 misc comments 2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko 6ae3b77d80 AI will not wait to conwuer fort if possible 2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko f0bb97b0d2 AI will actually attack all heroes when possible - and win the game eventually :) 2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko 6fb7301e8e Fixed issue with taking creatures from a Bank, Pandora or joiners 2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko b52faad4c7 + Stack speed is valuable
+ Hero movement is also very valuable
2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko efb6580958 Fix for mislaced hero rescued from Prison - https://bugs.vcmi.eu/view.php?id=3227 2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko a83753a7d2 AI will now pick Prisons if possible 2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko cbf2a1b7cc AI will consider Pandora Box as a valuable object - good for every occasion! 2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko faa6ca401e Fixed duplicated value 2022-09-11 11:31:27 +03:00
Tomasz ZielińskiandAndrii Danylchenko f4de5453c6 + AI will consider free slot (or lack of it) for creature reward from a bank
+ AI might use banks for resources other than gold
2022-09-11 11:31:27 +03:00
DjWarmongerandAndrii Danylchenko f81d869b4a Mine roads (#808)
* Create dirt roads to mines if there are no roads in a zone.
2022-09-11 11:31:27 +03:00
Tomasz Zielinski 816d4b3081 Merge remote-tracking branch 'origin/cpp-map-editor' into gui-ux-improvements
# Conflicts:
#	mapeditor/mainwindow.h
#	mapeditor/mainwindow.ui
#	mapeditor/windownewmap.cpp
2022-09-11 08:10:16 +02:00