1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-20 12:53:52 +00:00
Commit graph

31128 commits

Author SHA1 Message Date
Petr Mikheev
1b669db017 Load ESM4::Tree and ESM4::Furniture 2023-05-29 18:47:27 +02:00
jvoisin
599265eea7 Merge branch 'cell_store' into 'master'
Use CellStore::mStore instead of MWBase::Environment::get()

See merge request OpenMW/openmw!3079
2023-05-29 15:36:01 +00:00
elsid
731ff90c37
Remove unused include 2023-05-29 15:53:19 +02:00
elsid
947e8f0e94
Use CellStore::mStore instead of MWBase::Environment::get() 2023-05-29 15:53:19 +02:00
psi29a
df57f8004b Merge branch 'default' into 'master'
Replace some empty constructors and destructors with default

See merge request OpenMW/openmw!3078
2023-05-29 13:06:19 +00:00
psi29a
27babefee6 Merge branch 'esm4-terrain' into 'master'
Initial support for ESM4 terrain

See merge request OpenMW/openmw!3032
2023-05-29 12:08:49 +00:00
Evil Eye
9214ffb50b Replace some empty constructors and destructors with default 2023-05-29 13:37:19 +02:00
florent.teppe
9f9a6c06e0 Fix get vertex Height for esm4 2023-05-29 12:10:42 +02:00
florent.teppe
ff9e04062d Applies changes from previous commit
from commit bb1d040ac8
Was lost during rebase.
2023-05-29 12:10:42 +02:00
florent.teppe
5dfa06acf8 removes unused variable
it was already mostly unused, it was usefull only in the constructor, even though it was a paramater of the constructor, so it could have been removed.
2023-05-29 12:10:42 +02:00
florent.teppe
12304d36aa std::cout => Log(Debug::Verbose) 2023-05-29 12:10:42 +02:00
florent.teppe
ad8cfde4e0 ESM::LandData no longer a virtual interface
instead it is constructed from ESM::Land or ESM4::Land
2023-05-29 12:10:42 +02:00
florent.teppe
4c4ed77bd7 Fixes Quad tree terrain missing in some places
the function that queried if data existed or not didn't take the worlspace into account.
2023-05-29 12:10:42 +02:00
florent.teppe
b29be74491 ground cover manager and object paging exists per worldspace.
They don't work though. But at least it doesn't crash. You get a morrowind world on top of the skyrim world.
But it fixes the crashes.
2023-05-29 12:10:42 +02:00
fteppe
22dc383f63 fixes errors and warnings
Applies review comments

getWorldspaceTerrain => returns a reference because never null
crashfix in navigator
updateLandPositions fixes naming of it
const ESM4::Land* MWWorld::Store<ESM4::Land>::search(ESM::ExteriorCellLocation cellLocation) const removes useless else
ExteriorCellLocation uses default initializers
get terrain height returns -MAX_FLOAT when there is no esm4 terrain.

applied review comments

use default initlializer when possible
factorise code
uses pattern matching in for loop.
2023-05-29 12:10:42 +02:00
florent.teppe
f600730459 fixes functions that were virtual but not tagged as override. 2023-05-29 12:10:41 +02:00
florent.teppe
7d88a240d3 no default terrain for esm4 exterior. 2023-05-29 12:10:41 +02:00
florent.teppe
2bb17279df linux build
clang format 14.0

Arm64 build
2023-05-29 12:10:41 +02:00
florent.teppe
a9e0489867 fixes stutters => bugs in the way cells were updated. 2023-05-29 11:32:14 +02:00
florent.teppe
0e4d21a40c takes the right terrain bounds. 2023-05-29 11:32:14 +02:00
florent.teppe
7bc4fc6bf9 Fix issues on terrain change
terrain Preloader now preloads the right terrain
2023-05-29 11:32:14 +02:00
florent.teppe
427b6ea39a fix bug in "fixColour" and "fixNormal"
fix issue in vtx texture selection
2023-05-29 11:32:13 +02:00
florent.teppe
c2e652b8a0 getLand taken out of loop where it's value would always be the same. 2023-05-29 11:32:13 +02:00
florent.teppe
feb60f5ad8 One landsize variable instead of two.
fixes issues in constant values.
2023-05-29 11:32:13 +02:00
florent.teppe
d0211acf9e Fixes bug in terrain loading + collision heightmap works
although terrain rendering is 100% broken right now
2023-05-29 11:32:13 +02:00
florent.teppe
c35c7b3640 ESM4::Land loaded, added to store and to land objects
it does not work yet. Some things are displayed, but it looks all wrong.
2023-05-29 11:31:37 +02:00
florent.teppe
fffcf52316 land manager cache's key is an ExteriorCellLocation
ESM4::Land is now a ESM::LandData
2023-05-29 11:31:37 +02:00
florent.teppe
e0fa15b727 Abstracted Land data that can be used by esm3 and esm4. 2023-05-29 11:31:37 +02:00
florent.teppe
e09cf6ac61 enable terrain takes a worldspace as input
enable terrain anslo switches the worldspace.
2023-05-29 11:31:37 +02:00
florent.teppe
1b718f09c5 adding worldspace info to terrain data structures
Rendering manager can have multiple terrain, one for each queried worldspace
Terrain::World has a worldspace member
storage functions require a worldspace parameter.
2023-05-29 11:31:37 +02:00
florent.teppe
93e7b0d946 Terrain has a mandatory worldspace in constructor
getTerrainHeightAt takes a worldspace.

Doesn't change anything for now => Therrain is created with the default ESM3 worldspace, and is never changed.
2023-05-29 11:31:36 +02:00
psi29a
4399748889 Merge branch 'clickbait' into 'master'
Move more arrays to the ESM::Attribute struct

See merge request OpenMW/openmw!3074
2023-05-29 09:00:22 +00:00
Petr Mikheev
1563c5c84e Merge branch 'simple_world_model_get_all' into 'master'
Simplify WorldModel::getAll

See merge request OpenMW/openmw!3077
2023-05-29 08:36:37 +00:00
elsid
02adb91859
Simplify WorldModel::getAll
There is no need to have generic forEach template function.
2023-05-29 00:01:46 +02:00
psi29a
c368c188f2 Merge branch 'fix_position_cell_crash' into 'master'
Use sDefaultWorldspaceId as fallback worldspace for PositionCell command

See merge request OpenMW/openmw!3073
2023-05-28 17:42:16 +00:00
Evil Eye
90a3a7b62f Add mWerewolfGMST 2023-05-28 15:28:34 +02:00
Evil Eye
a5e1c87fb8 Remove sGmstAttributeIds, sGmstAttributeDescIds, sAttributeIcons 2023-05-28 15:10:53 +02:00
psi29a
692396a608 Merge branch 'ptr_registry' into 'master'
Move Ptr registry into a separate type and fix potential issues

See merge request OpenMW/openmw!3072
2023-05-28 12:49:17 +00:00
elsid
06af4cb56a
Use sDefaultWorldspaceId as fallback worldspace for PositionCell command
store is nullptr at this point because there was no cell found.
2023-05-28 14:25:53 +02:00
elsid
86db640c8b
Increment revision on clearing PtrRegistry
Setting it to 0 may not lead to the change detected by clients. Potentially
mRevision may already have value 0. For example on overflow.
2023-05-28 13:04:20 +02:00
elsid
a581e394b4
Check for revision inequality
It's not possible to have SafePtr with mLastUpdate from the future. But
theoretically it's possible to get PtrRegistry::mRevision overflow so operator
less would return false when there is a change.
2023-05-28 13:04:20 +02:00
elsid
ce91784085
Move Ptr registry into a separate type
There is no dependency on the rest of the WorldModel state.
2023-05-28 13:04:17 +02:00
psi29a
16a580eb21 Merge branch 'clickbait' into 'master'
Remove sAttributeIds and sSkillIds

See merge request OpenMW/openmw!3071
2023-05-28 09:14:47 +00:00
psi29a
052972033c Merge branch 'get_rid_of_asserts_in_esm' into 'master'
Replace all asserts in components/esm[34] with throw

See merge request OpenMW/openmw!3069
2023-05-28 09:14:08 +00:00
unknown
14600de185 Remove sAttributeIds and sSkillIds 2023-05-27 21:54:13 +02:00
psi29a
36aea64eb8 Merge branch 'refactor_world_model' into 'master'
Cleanup and refactor WorldModel

See merge request OpenMW/openmw!3068
2023-05-27 15:38:17 +00:00
jvoisin
c98c532213 Replace all asserts in components/esm[34] with throw 2023-05-27 16:10:53 +02:00
elsid
d98852fdbe
Use std::count_if to implement WorldModel::countSavedGameRecords 2023-05-27 15:49:36 +02:00
elsid
3a66854c3c
Avoid confusion for generated cell flags 2023-05-27 15:49:36 +02:00
elsid
60139c6bd5
Use WorldModel::mStore instead of MWBase::Environment::get().getESMStore() 2023-05-27 15:49:36 +02:00