Commit Graph

19685 Commits (65cdd489fb3dbc388ca5a9ba5d606fc2553463f7)

Author SHA1 Message Date
florent.teppe 65cdd489fb create a specific esm reader function for RefID to avoid allocation for string and then again for RefId
Fixed some types

removed useless header

applied clang format

fixed compile tests

fixed clang tidy, and closer to logic before this MR

Removed hardcoded refids

unless there is a returned value we don't use static RefIds
can use == between RefId and hardcoded string

Fix clang format

Fixed a few instances where std::string was used, when only const std::string& was needed

removed unused variable
2 years ago
florent.teppe 874ff88288 In the interpretter, the id is no longer passed by vallue, but as a const reference instead.
In getMembersLocal(, a reference to a reference wrapper is used, because the id can change, bu all we need to do is change a pointer.No need to change the value
2 years ago
fteppe 09d461a8cd fixed Topic selected event
Fix rebase
2 years ago
fteppe c283ea0ae8 string_view& => string_view
fixed ref to temp variable
2 years ago
fteppe 7da38113be Changed more hardcoded RefId to be static to avoid multiple runtime creations
adresses multiple review comments
2 years ago
fteppe b57dd6d083 Fixed search random, it is a prefix so not a refId
Fixed situation where we return a const reference to a static variable that may change if the same function is called multiple times
2 years ago
fteppe 62d8fe3fc2 changed a few hardcoded refIds used in mutliple places to be defined only once in a variable 2 years ago
fteppe 20da0892ef openMW_test_suite compiles and runs
Slowly moving through the open-cs errors

Good progress in openCS

Very good progress on openCS

Getting closer with openCS

OpenCS compiles and runs! Didn't have time to test it all though

ix openMW

everything compiles on windows??

Fix gcc

Fix Clang
2 years ago
fteppe 2f2e401559 is Hidden marker now takes a const RefId& instead of a string_view 2 years ago
fteppe c8bb733360 removed clear() function, the only way to change the Id from the outside is from the assignment operator
replaced ciEqual with == operator
2 years ago
fteppe ee941f9b09 RefId's mId can't be get as mutable from the outside
also removed useless operator= defintion
2 years ago
fteppe 69d70d64f6 Fixed GUI that used RefId when it should have used strings 2 years ago
fteppe 125b21de20 Initial commit: In ESM structures, replace the string members that are RefIds to other records, to a new strong type
The strong type is actually just a string underneath, but this will help in the future to have a distinction so it's easier to search and replace when we use an integer ID

Slowly going through all the changes to make, still hundreds of errors

a lot of functions/structures use std::string or stringview to designate an ID. So it takes time

Continues slowly replacing ids. There are technically more and more compilation errors

I have good hope that there is a point where the amount of errors will dramatically go down as all the main functions use the ESM::RefId type

Continue moving forward, changes to the stores

slowly moving along

Starting to see the fruit of those changes.

still many many error, but more and more Irun into a situation where a function is sandwiched between two functions that use the RefId type.

More replacements. Things are starting to get easier

I can see more and more often the issue is that the function is awaiting a RefId, but is given a string
there is less need to go down functions and to fix a long list of them.

Still moving forward, and for the first time error count is going down!

Good pace, not sure about topics though, mId and mName are actually the same thing and are used interchangeably

Cells are back to using string for the name, haven't fixed everything yet. Many other changes

Under the bar of 400 compilation errors.

more good progress <100 compile errors!

More progress

Game settings store can use string for find, it was a bit absurd how every use of it required to create refId from string

some more progress on other fronts

Mostly game settings clean

one error opened a lot of other errors. Down to 18, but more will prbably appear

only link errors left??

Fixed link errors

OpenMW compiles, and launches, with some issues, but still!
2 years ago
psi29a 8b0eba8906 Merge branch 'blockofcoal' into 'master'
Play blocked hit sound on the victim, not the attacker

See merge request OpenMW/openmw!2551
2 years ago
Alexei Kotov cdd6a8c007 Merge branch 'models_for_the_model_god' into 'master'
Implement TestModels/T3D

Closes #7058

See merge request OpenMW/openmw!2506
2 years ago
Alexei Kotov 83d563e2ff Merge branch 'classless' into 'master'
Don't call getClass on an empty Ptr

See merge request OpenMW/openmw!2552
2 years ago
Alexei Kotov f11d4b76d1 Merge branch 'stay_mad' into 'master'
Update a reference's base record pointer on resurrection

Closes #7084

See merge request OpenMW/openmw!2527
2 years ago
Evil Eye 1cf0befd07 Don't call getClass on an empty Ptr 2 years ago
Alexei Kotov 74225991ca Play blocked hit sound on the victim, not the attacker 2 years ago
Cédric Mocquillon 76d77bf3c3 Connect zoom in/out only when the option is allowed 2 years ago
elsid 0b399a9d1a
Fix detournavigator tests
d40c09c18c changed the logic in parallel with
15e8f0b53c making this check invalid.
2 years ago
elsid 15e8f0b53c
Check input and report errors via RecastContext
Recast functions have preconditions for arguments they don't validate. This may
produce garbage data which may lead to crash. Check arguments and log when they
are invalid.

Do not throw exceptions when these function calls fail, capture Recast reported
errors via RecastContext inherited from rcContext and log them.
2 years ago
Petr Mikheev de57a95c9d Rename mCells -> mWorldModel 2 years ago
Petr Mikheev ac6303a83a Rename MWWorld::Cells -> WorldModel 2 years ago
AnyOldName3 66b8d4fb29 Add a setting to control coverage adjustment
With it on, which was always the case before this setting was added,
vanilla content and poorly-made mods will look acceptable, but well-made
mods will have alpha-tested meshes appear to grow and potentially gain a
weird outline as they get further away.

With it off, which replicates the 0.46 behaviour, well-made mods will
look really good, but vanilla content and poorly-made mods will have
alpha-tested meshes shrink as they get further away.

It's been bugging me that this was forced on since 0.47 released, and
I'd hoped to figure out a solution for automatic detection at some point
before 0.48 branched off, but I didn't, so now this is what we're
getting to have Tamriel Rebuilt look right.
2 years ago
psi29a 1d55be8214 Merge branch 'lua_profiler' into 'master'
Lua profiler

See merge request OpenMW/openmw!2523
2 years ago
psi29a eabb230de2 Merge branch 'keep_calm_and_get_hit' into 'master'
Add option to restore non-MCP Calm spell behaviour

Closes #7063

See merge request OpenMW/openmw!2522
2 years ago
Evil Eye 69fe4594fc Reset mCharGen along with the other MyGUI-holding members 2 years ago
psi29a 06a626452c Merge branch 'ptr2' into 'master'
Refactoring; slightly reduce amount of code in worldimp.cpp

See merge request OpenMW/openmw!2498
2 years ago
Petr Mikheev 7c36a7eb49 Run Lua GC in every frame 2 years ago
Petr Mikheev 55db95d4cf Update Lua profiler; add ability to run OpenMW with old LuaJit that doesn't allow custom allocator (Lua profiler will be disabled in this case) 2 years ago
Evil Eye 209a102061 Update a reference's base record pointer on resurrection 2 years ago
Petr Mikheev 02a9069a0e Lua Profiler 2 years ago
Petr Mikheev 6fa65e4729 Track memory and CPU usage per script in LuaUtil::LuaState 2 years ago
Evil Eye a648e4cc11 Add option to restore non-MCP Calm spell behaviour 2 years ago
Cédric Mocquillon dde8ee0611 Delay the deletion of esm versions after the deletion of the scene as it is used in one of its workers (the objectpaging one) 2 years ago
Petr Mikheev aa230698a8 Apply clang-format 2 years ago
Petr Mikheev 313df72be0 Remove raycasting functions from MWWorld::World 2 years ago
Petr Mikheev 7a354d8c78 Remove from MWWorld::World a few functions that already exist in MWWorld::Cells and MWWorld::Scene 2 years ago
Petr Mikheev 2df993004c Make MWWorld:Cells and MWWorld::Scene to be accessible via Environment 2 years ago
AnyOldName3 08361a6682 Merge branch 'LOD-support-to-Object-Paging' into 'master'
Add LOD support to Object Paging

See merge request OpenMW/openmw!2459
2 years ago
Cédric Mocquillon 7142bb4ce7 Select only one level of LOD outside the active grid
Do not create group when not needed
2 years ago
psi29a 518bd03547 Merge branch 'post_ui' into 'master'
Improve postprocess HUD layout

See merge request OpenMW/openmw!2505
2 years ago
Evil Eye b94818b24a Tweak message and temporarily set model ttl to 0 2 years ago
Andrei Kortunov da5b442fcf Improve postprocess HUD layout 2 years ago
Alexei Kotov 1d31c5eb6f Remove the correct bound item when the effect expires 2 years ago
psi29a d29d68f1ba Merge branch 'allycache' into 'master'
Always consider an actor their own ally (bug #6313)

Closes #4229 and #6313

See merge request OpenMW/openmw!2504
2 years ago
Cédric Mocquillon 4140e4ea05 Remove LOD which could never be displayed in a chunk 2 years ago
psi29a 577c9ad5fb Merge branch 'deprecated' into 'master'
Replace gmtime with safer equivalents

See merge request OpenMW/openmw!2503
2 years ago
Evil Eye 0ae5755abb Implement TestModels/T3D 2 years ago