1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-16 10:19:47 +02:00
Commit Graph

207 Commits

Author SHA1 Message Date
Ivan Savenko
3dd4fa2528 Reduce usage of pointers to VLC entities
Final goal (of multiple PR's) is to remove all remaining pointers from
serializeable game state, and replace them with either identifiers or
with shared/unique pointers.

CGTownInstance::town and CGHeroInstance::type members have been removed.
Now this data is computed dynamically using subID member.

VLC entity of a town can now be accessed via following methods:
- getFactionID() returns ID of a faction
- getFaction() returns pointer to a faction
- getTown() returns pointer to a town

VLC entity of a hero can now be accessed via following methods:
- getHeroTypeID() returns ID of a hero
- getHeroClassID() returns ID of a hero class
- getHeroType() returns pointer to a hero
- getHeroClass() returns pointer to a hero class
2024-10-10 12:28:08 +00:00
Ivan Savenko
a8f8c3f4b1 Replaced most of accesses to CGObjectInstance::pos with anchorPoint() 2024-10-09 15:43:46 +00:00
Tomasz Zieliński
54ba4d50d6 Allow to ban spell scrolls 2024-09-23 17:09:46 +02:00
Tomasz Zieliński
ec603f46ae - Handle new configurable banks
- Handle "all" object banned option
2024-09-21 13:36:28 +02:00
Tomasz Zieliński
2fe54504ab Merge remote-tracking branch 'origin/develop' into custom_objects_per_zone
# Conflicts:
#	lib/rmg/CRmgTemplate.cpp
2024-09-14 10:19:22 +02:00
Tomasz Zieliński
4d4538a48d Use CompoundMapObjectID in ObjectInfo 2024-09-14 09:23:28 +02:00
Tomasz Zieliński
9591ce1ab4 Move CompoundMapObjectID to separate file 2024-09-14 08:55:28 +02:00
Tomasz Zieliński
4b263b6d41 Add specific objects and configure their frequency / value 2024-09-12 21:04:27 +02:00
Tomasz Zieliński
bfe75a6a02 It is now possible to copy object settings between zones 2024-08-24 20:18:36 +02:00
Tomasz Zieliński
64fc2e5ed0 Move ObjectConfig to ObjectInfo.cpp. Preliminary version of banning object categories. 2024-08-24 15:12:22 +02:00
Tomasz Zieliński
85ee859b6e First version that works - banning objects is possible 2024-08-21 20:16:41 +02:00
SoundSSGood
39bb6d5f39 IMarket now able to store artifacts 2024-08-20 18:49:47 +03:00
Tomasz Zieliński
4413f03276 Cleanup 2024-07-30 08:50:33 +02:00
Tomasz Zieliński
d10711928f Allow connecting zone to itself (always through the portal) 2024-07-29 21:56:07 +02:00
Tomasz Zieliński
f4f416eb16 Add RMG option "forcePortal" 2024-07-29 20:36:23 +02:00
Ivan Savenko
4aa73b40c9 Split CTownHandler into smaller chunks 2024-07-21 18:21:48 +00:00
Ivan Savenko
63bcf7d83c Replaced most of usages of CRandomGenerator with vstd::RNG in library 2024-07-16 13:13:07 +00:00
Ivan Savenko
60a51e98de Remove usage of std::function from CRandomGenerator 2024-07-16 13:13:07 +00:00
Ivan Savenko
6b8f94e6e7 Merge remote-tracking branch 'vcmi/master' into develop 2024-07-11 17:43:44 +00:00
Tomasz Zieliński
5b99974d31 Route roads even further away from zone boundary 2024-07-04 14:22:22 +02:00
Tomasz Zieliński
d7a4ea9f32 Draw random artifact as an atomic operation 2024-06-24 20:06:50 +02:00
Alexander Wilms
02e429e973 Fix typos using https://github.com/crate-ci/typos
Changes were reviewed manually
2024-06-24 03:47:19 +02:00
Ivan Savenko
3bea383b59 Merge branch 'vcmi/beta' into 'vcmi/develop' 2024-06-21 12:58:36 +00:00
Ivan Savenko
0ca41127a6
Merge pull request #4152 from IvanSavenko/rmg_fix
[1.5.3] Fix rmg generation if player list is not continuous
2024-06-18 12:06:40 +03:00
Tomasz Zieliński
6d9f83a376 Protect lakes accessed from both zones with lock 2024-06-17 19:00:37 +02:00
Ivan Savenko
2d0bd94135 Fix rmg generation if player list is not continuous 2024-06-17 13:35:58 +00:00
Ivan Savenko
5d6470e527
Merge pull request #4025 from IvanSavenko/shared_ptr_lib
[1.6] Use shared_ptr for library entities
2024-05-30 19:14:06 +03:00
Ivan Savenko
7461df161c lib now uses shared_ptr for entities. Removed manual memory management. 2024-05-17 15:04:05 +00:00
Ivan Savenko
721b15d9de Merge branch 'vcmi/master' into 'vcmi/develop' 2024-05-17 08:26:37 +00:00
Tomasz Zieliński
5a979e42e2 Satisfy SonarCloud 2024-05-10 21:14:15 +02:00
Tomasz Zieliński
ee27a79aa1 Sonarcloud issues 2024-05-10 17:07:09 +02:00
Tomasz Zieliński
21bb61fc4d Unused variable 2024-05-10 15:56:49 +02:00
Tomasz Zieliński
7cb17afe7a Fix diagonal paths if we need to use them 2024-05-10 15:53:54 +02:00
Ivan Savenko
2521557f68 Fixed some newly reported issues from SonarCloud 2024-05-10 13:40:24 +00:00
Tomasz Zieliński
a6fa6855dc Route roads away from zone borders 2024-05-10 15:35:33 +02:00
Tomasz Zieliński
dd55188b77 Option to define surface or underground level for obstacle set 2024-05-07 07:15:00 +02:00
Tomasz Zieliński
20176521eb Actually revert this change, it's not better. 2024-05-01 15:27:19 +02:00
Tomasz Zieliński
4d13c3b94f Final fixes and tweaks 2024-05-01 13:58:24 +02:00
Tomasz Zieliński
186b6629c7 Do not hide roads behind objects 2024-05-01 12:15:07 +02:00
Tomasz Zieliński
5315beec8c Fixes for guard condition 2024-05-01 11:34:34 +02:00
Tomasz Zieliński
acab1d38cf Build fix 2024-05-01 10:45:01 +02:00
Tomasz Zieliński
7f3cf607a7 Allow guards not stronger than 1/3 max value next to roads 2024-05-01 10:24:21 +02:00
Tomasz Zieliński
67447acd0e First implementation that works 2024-05-01 09:16:10 +02:00
Tomasz Zieliński
4d948e8c6d Also, this 2024-05-01 07:58:47 +02:00
Tomasz Zieliński
9301bb9af5 Do not place guardes treasure on roads. Do not place guards next to roads. 2024-05-01 07:58:17 +02:00
Tomasz Zieliński
4fa7f0e93d Also allow filtering biomes by faction(s) 2024-04-12 10:25:13 +02:00
Tomasz Zieliński
a356fdaf2a Allow filtering obstacles by faction aligmnment 2024-04-11 18:10:14 +02:00
Tomasz Zieliński
b1a5693612 Proof of concept with OH3 obstacles 2024-04-04 21:39:01 +02:00
Tomasz Zieliński
a94286c23d Code cleanup 2024-03-27 08:03:19 +01:00
Tomasz Zieliński
19633a0f62 Build fixes 2024-03-27 06:48:22 +01:00