Evil Eye
3967509cdd
Use meaningful names instead of pretending we don't know what snow is
2022-07-17 19:54:59 +02:00
jvoisin
498a835b77
Merge branch 'coverity' into 'master'
...
Fix some Coverity issues
See merge request OpenMW/openmw!2082
2022-07-03 16:29:05 +00:00
Andrei Kortunov
fe785ea788
Don't cast away const when we can avoid it
2022-07-03 16:36:41 +04:00
Andrei Kortunov
aa349f2ed9
Initialize some missing variables
2022-07-03 15:44:50 +04:00
psi29a
9c1970dce4
Merge branch 'lua_esm' into 'master'
...
Advanced Lua scripts configuration in omwaddon
See merge request OpenMW/openmw!1947
2022-06-11 18:48:23 +00:00
Evil Eye
10e4eb8e8e
Append orphaned dialogue instead of always appending it
2022-06-06 10:12:36 +02:00
Petr Mikheev
a70d5831c5
Lua scripts configuration in omwaddon
2022-06-05 01:36:39 +02:00
psi29a
58fd560ce9
Merge branch 'esm_readers_cache' into 'master'
...
Limit the number of simultaneously open not actively used content files (#6756 )
Closes #6756
See merge request OpenMW/openmw!1966
2022-06-04 19:11:27 +00:00
jvoisin
df0cd86cf4
Use the proper types
2022-06-04 16:34:23 +02:00
jvoisin
6c71071083
Make the sRedcordId constexpr
2022-06-04 16:07:59 +02:00
elsid
3affe9913f
Limit the number of simultaneously open not actively used content files
...
Use LRU cache for ESMReaders. When cache capacity is reached close least
recently used ESMReader. Remember the file name if a reader was open. Once the
reader requested again open the file if there is stored name for it. Put
released ESMReader to the back of the free items list. Close ESMReader's from
the front of the free items list.
Cached item can be used only by one client at the same time. If the same item is
requested twice exception is thrown. This should never happen in practice. If
this happens need to fix the client logic.
It's allowed to go over the capacity limit when requesting different readers.
Ideally this should never happen but there will be system error anyway
signalizing about too many open files. Need to fix client logic in this case.
All places that were using a vector of ESMReaders now using the cache. Cache is
local for each use case and there is no need for a thread safety.
2022-06-03 01:29:03 +02:00
Evil Eye
bb495bffeb
0 initialize mRecordFlags
2022-05-29 22:12:30 +02:00
jvoisin
6feb92a9bf
Remove boost::filesystem from a couple of files
2022-05-24 21:18:21 +00:00
psi29a
f17d7fc00b
Merge branch 'string_view' into 'master'
...
Make getStringLiteral return a string_view
See merge request OpenMW/openmw!1896
2022-05-22 20:50:04 +00:00
jvoisin
fb732d74a2
Remove boost::filesystem from bsatool
2022-05-22 18:53:10 +02:00
Evil Eye
ac78b537d2
Address feedback
2022-05-22 09:29:03 +02:00
jvoisin
23eccebe9e
Convert esmtool from const std::string&
to std::string_view
2022-05-21 21:39:26 +02:00
Evil Eye
134dc2b21b
Address feedback on !1857
2022-05-16 17:37:55 +02:00
Evil Eye
c0cc5feecd
Initialize DialInfo::DATAstruct with the proper blank values
2022-05-15 14:52:44 +02:00
jvoisin
331363d469
Merge branch 'fix_uninit' into 'master'
...
Fix uninitialized coverity warnings
See merge request OpenMW/openmw!1819
2022-05-05 17:35:16 +00:00
Evil Eye
a64979e25d
Replace empty std::string assignments
2022-05-04 22:33:39 +02:00
elsid
b67a0a8f2b
Fix uninitialized coverity warnings
2022-05-01 18:36:16 +02:00
elsid
92538dde89
End SNAM record as SNAM record
2022-05-01 15:45:22 +02:00
Evil Eye
9a96d64611
Use subrecord size instead of version to load WEAT
2022-04-30 10:11:49 +02:00
elsid
b09570692e
Use ifstream for ESMReader
...
ESMReader reads the whole file, there is no need in the ConstrainedFileStream.
2022-04-15 02:58:57 +02:00
elsid
4447ab0ed7
Remove ESM:: namespace qualifier in components/esm3/ and tests
2022-04-12 02:04:24 +02:00
psi29a
03806eb75e
Merge branch 'esm_rm_redundant_include' into 'master'
...
Remove redundant include from esm3/esmreader.hpp
See merge request OpenMW/openmw!1761
2022-04-11 07:47:48 +00:00
psi29a
cf1764f255
Merge branch 'constrained_file_stream' into 'master'
...
Avoid redundant conversion to const char* and use make_shared
See merge request OpenMW/openmw!1763
2022-04-11 07:26:53 +00:00
elsid
6481324eb1
Read when need to skip few bytes
2022-04-11 01:55:05 +02:00
elsid
5eb8c4aebe
Avoid redundant conversion to const char* and use make_shared
2022-04-10 22:33:08 +02:00
elsid
db44f91fd5
Remove redundant include from esm3/esmreader.hpp
2022-04-10 22:16:32 +02:00
elsid
c3a924de23
Fix skip DATA in cell ref loading
2022-04-10 19:16:30 +02:00
elsid
6b464a9330
Check ESMReader value size in compile time
2022-04-10 19:16:11 +02:00
elsid
bbfdb347bd
Skip load cell ref when there is no need
...
Primarily to avoid temporary allocations by ESMReader::getHString.
2022-04-08 19:16:38 +02:00
psi29a
6d55317d57
Merge branch 'refactor/prng-2' into 'master'
...
Save random state and refactor usage of generators
See merge request OpenMW/openmw!1715
2022-03-23 09:50:54 +00:00
ζeh Matt
b502dc12f0
Add prng to World instance and serialize state in Save
2022-03-21 17:49:42 +02:00
Evil Eye
484a7c7b7e
Base dialogue order solely on mPrev
2022-03-16 18:09:21 +01:00
duncanspumpkin
3a117cac22
Switch to a constexpr for FourCC constant
...
Add static asssert on wrong size
2022-03-08 14:48:37 +00:00
Matt
54e114d83e
Avoid string copies for ESM::Variant::getString
2022-03-06 17:38:58 +00:00
elsid
3c66a927d8
Fix coverity issue about uninitialized members of LevelledListBase
...
* Remove explicit constructor.
* Use static constexpr where possible.
* Use CRTP to get RecName.
2022-02-23 20:39:05 +01:00
elsid
595c2e0a8e
Use unique_ptr to manage AiPackage lifetime
2022-02-23 00:39:30 +01:00
psi29a
776b286286
Merge branch 'esm_name' into 'master'
...
Use ESM::NAME instead of const char* and std::string as argument type
See merge request OpenMW/openmw!1659
2022-02-15 08:11:12 +00:00
elsid
3305b400dc
Use ESM::NAME instead of const char* and std::string as argument type
2022-02-14 23:40:40 +01:00
Evil Eye
649c2f8286
Fix stats not working right for saves started before version 17
2022-02-14 18:38:37 +01:00
elsid
c75e938c46
Return string_view from Utf8Encoder functions
...
To avoid redundant std::string constructions.
2022-02-12 17:11:54 +01:00
elsid
c9c7fb7e49
Remove redundant functions from Utf8Encoder interface
2022-02-12 13:47:46 +01:00
jvoisin
4cd6d2dacf
Merge branch 'rework_fixed_string' into 'master'
...
Rework fixed string
See merge request OpenMW/openmw!1596
2022-01-30 18:47:06 +00:00
elsid
b17c9a22ff
Disallow to call ESMWriter::writeT with pointer type
...
This will make ESMWriter to use a pointer to this pointer to access the data
that is unlikely an intent. For example:
68ef96410c
.
2022-01-30 14:13:02 +01:00
Petr Mikheev
4554a075e7
Merge branch 'fix_save_corruption' into 'master'
...
Fix save corruption introduced by https://gitlab.com/OpenMW/openmw/-/merge_requests/1600
See merge request OpenMW/openmw!1607
2022-01-30 11:59:30 +00:00
uramer
de2383ec98
Fix save corruption introduced by https://gitlab.com/OpenMW/openmw/-/merge_requests/1600
2022-01-30 11:59:30 +00:00