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

1149 commits

Author SHA1 Message Date
elsid
6c8ed4d19c
Move Files::IStreamPtr alias to a separate header
To avoid transitive include of Windows.h all over the engine.
2022-07-17 11:35:39 +02:00
elsid
bef15edf0b
Remove redundant ostream, istream, iostream and sstream includes
* Replace by std::to_string and operator+ where possible.
* Move the code requiring to include <sstream> from .hpp to .cpp files.
2022-07-05 01:41:28 +02:00
Petr Mikheev
a70d5831c5 Lua scripts configuration in omwaddon 2022-06-05 01:36:39 +02:00
elsid
d2510284ec
Support TES4 in esmtool dump 2022-04-25 17:35:26 +02:00
elsid
13c970b37a
Add const modifier to encoder type 2022-04-25 17:35:25 +02:00
psi29a
f99f818c0c Merge branch 'esm4_cleanup' into 'master'
ESM4 cleanup

See merge request OpenMW/openmw!1792
2022-04-23 15:27:28 +00:00
elsid
761a04ce00
Remove duplicated enum definition 2022-04-23 00:32:52 +02:00
elsid
94c1d0cced
Use unique_ptr to store istream 2022-04-22 18:27:17 +02:00
Evil Eye
61ea678a96 Implement ignored records 2022-04-16 16:28:39 +02:00
elsid
5eb8c4aebe
Avoid redundant conversion to const char* and use make_shared 2022-04-10 22:33:08 +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
Petr Mikheev
d251c4e2a1 [Lua] Change behavior of obj.type 2022-03-15 23:35:36 +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
Bret Curtis
0f43455dc3 merge in master 2022-02-16 16:57:59 +01:00
elsid
139ae9325a Fix compile errors by using StatelessUtf8Encoder 2022-02-16 16:41:23 +01:00
elsid
3305b400dc
Use ESM::NAME instead of const char* and std::string as argument type 2022-02-14 23:40:40 +01:00
cc9cii
ba3ae448d4 Initial import of esm4 by cc9cii 2022-01-31 08:58:45 +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
Petr Mikheev
68ef96410c Make ESM::Position not packed (should fix #6566) 2022-01-29 02:32:58 +01:00
elsid
45db56b382
Rework fixed string
* Avoid inheritance.
* Define equality operators out of the class definition.
* Replace toString with toStringView where it doesn't make sense to create a string.
2022-01-28 18:39:09 +01:00
Bret Curtis
d1fb854521 move most of the files from esm to esm3, keep common code in esm; this is make space for a future with esm4
esm typo

esm typo
2022-01-23 17:04:48 +01:00
Petr Mikheev
2d1b100239 Change terminology of gameSecond/gameHour to simulationTime/gameTime 2022-01-10 21:03:35 +01:00
psi29a
bafde5c9c4 Merge branch 'cleanup' into 'master'
Remove constant conditions

See merge request OpenMW/openmw!1527
2022-01-05 10:48:13 +00:00
jvoisin
421e6629ad Fix unnecessary-copy-initialization
> warning: the variable 'key' is copy-constructed from a const reference but is
only used as const reference; consider making it a const reference
[performance-unnecessary-copy-initialization]

Found by clang-tidy.
2022-01-04 20:42:09 +01:00
Evil Eye
5a7a3a0d2d Silence a signed/unsigned mismatch warning 2022-01-04 17:11:55 +01:00
Evil Eye
bdfad27e05 Remove constant conditions 2022-01-04 16:50:04 +01:00
psi29a
0766e1310b Merge branch 'lunacy' into 'master'
Don't touch base stats when turning into a werewolf

Closes #6333

See merge request OpenMW/openmw!1511
2022-01-04 10:27:48 +00:00
Evil Eye
6f870a464b Replace magic numbers with enums 2021-12-29 12:34:12 +00:00
Evil Eye
debdcf2953 Don't touch base stats when turning into a werewolf 2021-12-27 00:47:33 +01:00
Evil Eye
c1f59b1221 Automatically drop workaround when the format is next updated 2021-12-24 23:17:50 +01:00
elsid
5a6b39f8e0
Store mesh source data in recast mesh 2021-12-10 23:55:02 +01:00
psi29a
53e14eb238 Merge branch 'reset' into 'master'
AI reset argument

Closes #6177 and #1465

See merge request OpenMW/openmw!1405
2021-11-21 09:39:55 +00:00
Evil Eye
3c57ffd81f Save repeat and duration 2021-11-20 11:03:07 +01:00
Evil Eye
231da19aa4 Load repeat flag and use reset argument 2021-11-20 11:02:58 +01:00
Petr Mikheev
ded8997362 Avoid problems if builtin.omwscripts is above Morrowind.esm in content list. 2021-11-19 20:37:21 +01:00
Bo Svensson
a62b22cd31
isolates groundcover content files (#3208)
Specifications developed in PR #3206 require that groundcover content files must not be allowed to corrupt normal content files. With this PR we simply isolate our existing loading logic by instantiating a separate `ESMStore` for `Groundcover`. In addition, we remove some outdated workarounds.
2021-11-13 23:37:53 +01:00
Evil Eye
5f406158b5 Zero initialize context index 2021-11-13 12:46:10 +01:00
Alexei Dobrohotov
7a0c13fcf8 Make better use of std::clamp 2021-11-06 08:47:32 +03:00
Bo Svensson
6cf74f7041
refactors ESM::Land (#3213)
With this PR we reduce coupling, simplify code, encapsulate a variable and separate actual `ESM` data from its context.
2021-11-04 16:55:32 +01:00
Bo Svensson
4657c655b1 refactors parentFileIndices (#3211)
This PR aims to start addressing `ESM` design issues that have silenced errors we incorporated into groundcover `ESM` loading approaches.

- We move the resolution of `parentFileIndices` from `ESMStore` to `ESMReader` as suggested in a `TODO` comment.
- We improve a highly misleading comment which downplayed the significance of `parentFileIndices`.
- We document important preconditions.
- We move a user facing error message to the highest level and improve its context.
- We remove an inappropriate `setGlobalReaderList` method. We now pass this reader list into the method that requires it.
- We remove a thoroughly pointless optimisation of `Store<ESM::LandTexture>`'s construction that has unnecessarily depended on `getGlobalReaderList`.

There should be no functional changes for `master`, but this PR should remove an issue blocking PR #3208.
2021-11-03 11:07:28 +01:00
psi29a
4c81518abb Merge branch 'puddle' into 'master'
Give each reflect and spell absorption effect a chance to apply

Closes #6255 and #6253

See merge request OpenMW/openmw!1279
2021-10-30 19:26:32 +00:00
Petr Mikheev
47c89567fb Load LuaScriptsCfg from both *.omwscripts and *.omwaddon files. 2021-10-26 21:52:42 +02:00
Petr Mikheev
6aab246879 Add ESM records that are needed to store Lua scripts configuration;
Use ptr.getType() (i.e. esm record names) instead of typeid(ptr.getClass()) in apps/openmw/mwlua.
2021-10-26 21:32:02 +02:00
Evil Eye
4ec927829f Give each reflect and spell absorption effect a chance to apply 2021-10-26 16:50:40 +02:00
Andrei Kortunov
0f3c0cb0a0 Fix argument types mismatch 2021-10-24 18:45:46 +04:00
elsid
18d3102148
Do not use union to access FIXED_STRING<4> as int
https://en.cppreference.com/w/cpp/language/union:
> It's undefined behavior to read from the member of the union that wasn't most recently written.
2021-10-17 17:16:21 +02:00
Petr Mikheev
a8acc19988 Avoid copying std::string in MWWorld::Ptr::getTypeDescription() 2021-10-12 00:18:23 +02:00
Evil Eye
dc1fe62dde Overhaul magic effects to work with onApply and onEnd events 2021-09-29 19:25:10 +02:00
cc9cii
7227a83e60 Preserve "blocked" record flags when saving with OpenCS. This will help outputs of OpenCS to be used with vanilla Morrowind.
Sample use case: users are using the Morrowind Code Patch feature that allows modders to enable this flag to differentiate editor-made potions from player crafted potions for tooltips.
2021-08-28 09:42:54 +10:00
Bret Curtis
c99bddc8dc Revert "Move reference to the right cell according to its geographical position"
This reverts commit d0677c3f07.
2021-08-09 22:11:00 +02:00
psi29a
9b7e14ec00 Merge branch 'OpenCS-moved-reference' into 'master'
OpenCS - Fix moved reference - Issues #3514 and #4752

See merge request OpenMW/openmw!1051

(cherry picked from commit 2bee171c7990522da33c2667f7d079fa35f4ede0)

36c30f7f Fix for Issue #3514 where moving a reference to another cell is not handled properly.
40327681 Update the changelog.
2021-08-03 23:29:05 +00:00
Cédric Mocquillon
d0677c3f07 Move reference to the right cell according to its geographical position 2021-07-30 18:28:29 +02:00
Evil Eye
5f84494046 Fail on invalid water levels 2021-07-21 16:00:25 +00:00
jvoisin
7b32458aec Improve a bit two esmreader logging call 2021-07-21 15:38:41 +02:00
elsid
aec4e02417
Ignore only CellRefs with preceding MVRF subrecord
MVRF subrecord means that only single following FRMR subrecord is moved not the
rest of subrecords.
2021-07-12 18:56:45 +02:00
elsid
cfdbd0d471
Indicate moved cell refs explicitly
This is less error prone approach than use of MovedCellRef fields.

Also make separate functions for skipping and reading moved cell refs to avoid
passing special flags  logic and null pointers for unused arguments.
2021-07-12 18:56:42 +02:00
jvoisin
5aaac8e47e Reduce a bit the size of getHT
Factoring common code parts outside of a template
is apparently a good practise to reduce code duplication
(and the size of openmw by around 0.5%),
and should improve a bit the performances,
since the whole `std::to_string` * 2 + string concatenation
dance results in quite a lot of code, preventing inlining on my machine.
2021-07-11 21:43:40 +02:00
Petr Mikheev
702eb19271 Fixes and refactoring 2021-07-09 20:48:54 +02:00
Petr Mikheev
8c6d303730 Saving/loading for Lua scripts (saves format is changed) 2021-07-09 20:24:56 +02:00
Petr Mikheev
6db2450c90 Initial support of generated RefNums with negative mContentFile. 2021-07-09 20:03:27 +02:00
Petr Mikheev
479856f812 Add components/lua/scriptscontainer and components/esm/luascripts 2021-07-09 20:03:27 +02:00
psi29a
c372c239a6 Merge branch 'master' into 'OpenCS_Bug6017'
# Conflicts:
#   CHANGELOG.md
2021-07-06 07:52:49 +00:00
cc9cii
a47ebf5c9e For consistency with TES CS, force DELE record writes to be 4 bytes (currently writes 1 byte). 2021-07-06 14:57:58 +10:00
cc9cii
fea1ac2c0f Remove dead code from commit 024ad3276b. 2021-07-06 14:21:17 +10:00
cc9cii
f68c81e631 Merge branch 'master' into 'OpenCS_Bug6017' 2021-07-06 03:10:46 +00:00
cc9cii
4b3de46bfa Use enums in place of magic numbers. Ensure Creature and NPC cell references are always saved as persistent. 2021-07-06 12:37:02 +10:00
elsid
91cece5cc4
Define ESM::Land static constants as constexpr
To avoid linking issues.
2021-07-04 22:17:44 +02:00
cc9cii
f2a301653c Remove redundant mPersistent member from ESM::NPC and ESM::Creature, replaced by mRecordFlags. Fixed the editing of the persistence flag value. 2021-06-30 08:20:29 +10:00
jvoisin
8561245fda Minor refactor making use of std::clamp 2021-06-29 18:43:47 +02:00
cc9cii
2a76634f5f Moved persistence flag from references to the header flags of referenceables (e.g. Static, Weapon, etc). Editing widget is not fully working. 2021-06-29 23:25:26 +10:00
cc9cii
024ad3276b Partial fix for #6017. The persistence flag of the references are saved but it is not yet possible to modify it via OpenCS. 2021-06-29 19:20:01 +10:00
jvoisin
2c8f328ac2 Use make_unique instead of unique_ptr+new 2021-06-25 20:55:38 +02:00
Evil Eye
080106e802 Merge branch 'inline' into 'master'
Inline a couple of methods in esmreader.cpp

See merge request OpenMW/openmw!945
2021-06-24 19:56:18 +00:00
Evil Eye
0998929608 Merge branch 'noreturn' into 'master'
Sprinkle some [[noreturn]] where possible

See merge request OpenMW/openmw!793
2021-06-24 19:21:29 +00:00
Evil Eye
1a421c3b2e Merge branch 'multicast' into 'master'
Fix two excessive type casting instances

See merge request OpenMW/openmw!953
2021-06-24 17:32:25 +00:00
Evil Eye
7e9785941c Merge branch 'default' into 'master'
Use `default` instead of empty constructors/destructors

See merge request OpenMW/openmw!957
2021-06-24 17:19:02 +00:00
jvoisin
5840279f16 Use default instead of empty constructors/destructors
See https://pvs-studio.com/en/docs/warnings/v832/ for details
2021-06-24 00:26:15 +02:00
jvoisin
b2c170efa0 Use initialization lists where possible 2021-06-23 23:36:43 +02:00
jvoisin
33e035cc95 Fix two excessive type casting instances
No need to to a string -> char* -> string dance.
2021-06-23 22:19:08 +02:00
jvoisin
aec3c74fa5 Sprinkle some [[noreturn]] where possible 2021-06-22 12:51:08 +02:00
jvoisin
17e0c75d30 Some more constexpr in esm/variant.cpp 2021-06-22 12:49:09 +02:00
jvoisin
6140c9c3fd Don't catch exceptions in EsmReader::getExact 2021-06-21 20:06:45 +00:00
jvoisin
cff11fbca9 Inline a couple of methods in esmreader.cpp 2021-06-21 14:22:26 +02:00
psi29a
afda721d4b Merge branch 'race_floats' into 'master'
Display Race record height/weight as a float

See merge request OpenMW/openmw!880
2021-06-19 00:29:21 +00:00
psi29a
a6b695e15b Merge branch 'esmcleanup' into 'master'
More ESM cleanup

See merge request OpenMW/openmw!903
2021-06-19 00:23:52 +00:00
jvoisin
22153cca7b Reduce a bit the code bloat in hot paths/small functions
There is no need to bloat hot/small functions with
a ton of function calls and involving locales
for simple error messages.
2021-06-15 17:57:14 +02:00
Dobrohotov Alexei
e68a454fd8 More ESM cleanup 2021-05-23 16:02:05 +03:00
Benjamin Winger
21f04f0d0f
Fixed data subrecord name for Armour record used in error 2021-05-17 18:36:59 -04:00
Benjamin Winger
41cfcfdc0f
Display Race record height/weight as a float 2021-05-17 18:33:02 -04:00
Bret Curtis
66a527c3de
Merge pull request #3075 from akortunov/warnfix
Fix MSVC's C4244 and C4267 warnings
2021-05-14 21:28:56 +02:00
Petr Mikheev
4a7147e222 Merge branch 'constexpr_esm' into 'master'
Use a constexpr for esm cc

See merge request OpenMW/openmw!849
2021-05-13 13:30:01 +00:00
jvoisin
bcd8190516 Fix a crash in aipackage.cpp 2021-05-13 14:19:12 +02:00
jvoisin
89f721fad3 Use a constexpr for esm cc 2021-05-12 22:35:00 +02:00
Andrei Kortunov
963e1b8b3f Fix MSVC's C4244 warnings 2021-05-12 10:34:40 +04:00
Andrei Kortunov
f9d42ed396 Fix MSVC's C4267 warnings 2021-05-12 10:34:39 +04:00
elsid
b806445a36
Use existing min implementation 2021-05-09 13:58:05 +02:00
psi29a
08e1a8e0fb Merge branch 'esm_opti' into 'master'
Teensy optimisation for esmtool

See merge request OpenMW/openmw!826
2021-05-07 14:21:37 +00:00
jvoisin
8a56ba6aaa Fix compilation 2021-05-07 13:58:30 +02:00
elsid
fbeccc2908 Apply 1 suggestion(s) to 1 file(s) 2021-05-07 09:28:47 +00:00
jvoisin
e97e4d07dd Teensy optimisation for esmtool
- Use an unordered_set instead of a list to
  keep track of skipped records.
- Reduce the number of conditions when parsing 4-letters
  records by using a switch-case instead of cascading conditions.
- Add a const
2021-05-06 22:41:20 +02:00
Dobrohotov Alexei
57c372a50e ESM code cleanup 2021-05-05 22:23:06 +03:00
psi29a
e94181b2b2 Merge branch 'constexpr' into 'master'
Sprinkle a couple of constexpr found by VS

See merge request OpenMW/openmw!800

(cherry picked from commit 5e8ea624bc85acebf457592dd10b790124ecf6ef)

5704b2ac Sprinkle a couple of constexpr found by VS
2021-05-04 21:09:20 +00:00
jvoisin
5f65583a3a Fix a heap overflow in loadpgrd.cpp 2021-04-30 12:04:41 +00:00
Evil Eye
abb120b439 Don't log a warning for reading to the end of the subrecord 2021-04-27 14:57:07 +02:00
Alexei Dobrohotov
add04a4ea0 Merge branch 'fix_esm' into 'master'
Fix a read head-buffer-overflow in esm

See merge request OpenMW/openmw!751
2021-04-25 21:56:52 +00:00
jvoisin
032ba1e9a0 Fix the compilation 2021-04-18 13:26:26 +02:00
jvoisin
c0f7e0d585 Use isnan 2021-04-17 20:58:37 +02:00
jvoisin
38316cdaf8 Fix various warnings found by clang
- unused alias
- inefficient use of push_back
- exceptions not inheriting from std::exception
- weird use of a comma
- value compared against itself
2021-04-17 19:06:33 +02:00
jvoisin
a35eae3dd1 Fix a read head-buffer-overflow in esm
The check forgot to account for the terminal zero.
2021-04-17 15:36:38 +02:00
Evil Eye
80266d435c Merge branch 'fix_crash' into 'master'
Fix an off-by-one in loadscpt

See merge request OpenMW/openmw!728
2021-04-16 18:02:47 +00:00
Andrei Kortunov
016a1d45df Remove outdated field - remnant from earlier implementation 2021-04-14 10:58:44 +04:00
jvoisin
54adb9cbed Fix an off-by-one in loadscpt 2021-04-12 12:03:20 +02:00
psi29a
301411c5c5 Merge branch 'esm_variant' into 'master'
Use std::variant for ESM::Variant implementation

See merge request OpenMW/openmw!719
2021-04-10 12:53:11 +00:00
Andrei Kortunov
124a33d8a3 Fix uninitialized variables 2021-04-10 10:58:00 +04:00
elsid
8e1c92d9af
Use std::variant for ESM::Variant implementation 2021-04-08 19:39:31 +02:00
elsid
03fc3ec803
Do not allow write variant of string as local variable
To be consitent with read where it's not allowed.
2021-04-04 23:09:27 +02:00
Gleb Mazovetskiy
b9c2f6ea1a Minor cleanup: Remove using namespace std
I came across these while trying to figure why MSVC build triggers
https://developercommunity.visualstudio.com/t/error-c2872-byte-ambiguous-symbol/93889

In the end, the issue was not in openmw but in OSG, but it's good to
clean up here anyway.
2021-03-16 19:58:02 +00:00
Andrei Kortunov
4d48c81998 Add move assignment operator and move constructor for the ESM::Variant 2021-03-13 22:28:13 +04:00
Andrei Kortunov
f40e227686 Remove redundant formatting changes 2021-01-26 22:29:41 +04:00
Andrei Kortunov
d12a0fdcb3 Mark only instances from groundcover files as groundcover objects 2021-01-26 22:29:41 +04:00
Andrei Kortunov
14cf0ce1dc Implement instanced groundcover 2021-01-26 22:29:41 +04:00
Andrei Kortunov
89f3f860ed Allow to get a rotation vector from ESM::Position 2021-01-13 14:25:25 +04:00
elsid
7b54415c40
Fix reference binding to null
/usr/include/c++/10.2.0/bits/stl_vector.h:1046:34: runtime error: reference binding to null pointer of type 'value_type'
    #0 0x55e37f50008a in std::vector<char, std::allocator<char> >::operator[](unsigned long) /usr/include/c++/10.2.0/bits/stl_vector.h:1046
    #1 0x55e37f50008a in ESM::SavedGame::load(ESM::ESMReader&) /home/elsid/dev/openmw/components/esm/savedgame.cpp:28
    #2 0x55e37e726139 in MWState::Character::addSlot(boost::filesystem::path const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) /home/elsid/dev/openmw/apps/openmw/mwstate/character.cpp:31
    #3 0x55e37e742b39 in MWState::Character::Character(boost::filesystem::path const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) /home/elsid/dev/openmw/apps/openmw/mwstate/character.cpp:88
    #4 0x55e37e7006e1 in MWState::CharacterManager::CharacterManager(boost::filesystem::path const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) /home/elsid/dev/openmw/apps/openmw/mwstate/charactermanager.cpp:25
    #5 0x55e37e6d4140 in MWState::StateManager::StateManager(boost::filesystem::path const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) /home/elsid/dev/openmw/apps/openmw/mwstate/statemanagerimp.cpp:90
    #6 0x55e37e82595a in OMW::Engine::prepareEngine(Settings::Manager&) /home/elsid/dev/openmw/apps/openmw/engine.cpp:641
    #7 0x55e37e8439fd in OMW::Engine::go() /home/elsid/dev/openmw/apps/openmw/engine.cpp:867
    #8 0x55e37e782760 in runApplication(int, char**) /home/elsid/dev/openmw/apps/openmw/main.cpp:289
    #9 0x55e37f6483c3 in wrapApplication(int (*)(int, char**), int, char**, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) /home/elsid/dev/openmw/components/debug/debugging.cpp:200
    #10 0x55e37ba8e3fe in main /home/elsid/dev/openmw/apps/openmw/main.cpp:301
    #11 0x7f013e845151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)
    #12 0x55e37baa0e3d in _start (/home/elsid/dev/openmw/build/gcc/ubsan/openmw+0x6c11e3d)
2021-01-09 22:59:24 +01:00
Andrei Kortunov
8084a336b5 Replace zeroes and nulls by nullptrs 2020-11-29 11:14:07 +04:00
Alexei Dobrohotov
53f91a3aa5
Merge pull request #3018 from akortunov/emplace
Use emplace_back instead of push_back
2020-11-01 01:58:56 +03:00
Andrei Kortunov
64ba81ecf2 Fix some issues, found by CoverityScan 2020-10-28 18:02:31 +04:00
Bret Curtis
5a824d0333 components/compiler cleanup; also cleaned up related cascading warnings; fixed up final/override issues 2020-10-22 23:57:53 +02:00
Andrei Kortunov
065ed5138e Use emplace_back instead of push_back 2020-10-18 10:27:35 +04:00
Andrei Kortunov
8ca3c3b123 Mark overrided methods by override keyword 2020-10-16 22:18:54 +04:00
Assumeru
72549651e0
Rework container resolution (#3006)
* Rework container resolution

* add optional argument to getCount

* remove now-redundant changes

* undo worldimp changes

* move save-fixing code to InventoryState

* replace Rng instances with Seeds
2020-10-13 17:46:32 +02:00
Andrei Kortunov
822764d0fa Rework fixed strings handling 2020-10-05 21:52:22 +04:00
Andrei Kortunov
9f1fbd56a3 Fix SummonKey comparison function 2020-09-04 13:45:38 +04:00
Andrei Kortunov
67eace1028 Use struct instead of tuple 2020-08-29 11:24:08 +04:00
Andrei Kortunov
924f634bda Support for multiple summons with same ID in the single spell 2020-08-28 21:14:54 +04:00
Evil Eye
6ad20ec9c7 Mutate base records when adding/removing spells 2020-07-28 08:33:28 +02:00
Andrei Kortunov
d0fe15b095 Use meaningful names instead of mSkill1 and mSkill2 2020-06-26 11:47:59 +04:00
bzzt lost a hitlab login
26ab176389 profiling
Signed-off-by: Bret Curtis <psi29a@gmail.com>
2020-06-13 00:22:28 +02:00
Andrei Kortunov
d997842f8d Use FourCC to declare all ESM record names 2020-06-09 10:07:37 +04:00
Bret Curtis
cd97d0c61c
Merge branch 'master' into automove 2020-06-08 11:42:05 +02:00
Roman Siromakha
27a113167c
Merge pull request #2890 from akortunov/position
Do not store object position, if it is the same as in CellRef
2020-06-08 01:12:47 +02:00
Andrei Kortunov
75e7a3e8b1 Do not store object position, if it is the same as in CellRef 2020-06-07 09:25:46 +04:00
elsid
5209f5ff6d
Mark all derived classes from ESM::ObjectsState and overriden functions as final 2020-06-06 23:00:53 +02:00
Capostrophic
1873da4c91 Don't save to or read automove state from saved games (#5452) 2020-06-06 15:58:21 +03:00
Bret Curtis
204d2acf25
Merge pull request #2092 from akortunov/float_stats
Store attributes and skills values as floats
2020-06-05 22:38:12 +02:00
Andrei Kortunov
81805b7263 Introduce a separate class to control world date and time 2020-06-05 12:07:32 +04:00
Andrei Kortunov
5468fcb29f Store attributes and skills values as floats (bug #4021) 2020-06-03 17:34:15 +04:00
Andrei Kortunov
3dce225f28 Implement vanilla-style corprus handling (bug #3714, bug #4623) 2020-06-03 12:58:17 +04:00
Andrei Kortunov
b5833f3c59 Use real time to update spell effects instead of game timestamps (bug #5165) 2020-05-16 11:00:28 +04:00
Andrei Kortunov
e6ca95174a Optimize characters data in savegame 2020-05-14 21:07:31 +04:00
Andrei Kortunov
d5806fd0ed Fix merge conflicts 2020-05-12 14:33:00 +04:00
Bret Curtis
42cba092b7
Merge pull request #2716 from akortunov/png
Store fog of war as a PNG image instead of TGA
2020-05-12 11:52:23 +02:00
Bret Curtis
4b30bf5699
Merge pull request #2829 from Capostrophic/logging
Log some more things
2020-05-12 11:44:05 +02:00
unknown
3b4782959e Allow targeting non-unique actors with StartScript (bug #2311) 2020-05-10 14:57:06 +02:00
Capostrophic
aa5161f99e Log some more things 2020-05-09 20:27:12 +03:00
Bret Curtis
e7795f2bf7
Merge pull request #2775 from Capostrophic/dooractivation
Only disarm traps with keys when the door/container is locked (bug #5370)
2020-04-24 08:46:24 +02:00
Bret Curtis
8c2f3ff007 clean up code; purge const_cast 2020-04-19 16:31:54 +02:00
Capostrophic
bbed9a70c5 Ignore traps of initially unlocked refs with assigned keys 2020-04-14 17:49:03 +03:00
Capostrophic
ad333e88fe Handle enchantment autocalc flag as a flag (bug #5363) 2020-04-11 00:03:14 +03:00
Andrei Kortunov
028760e108
Merge pull request #2758 from akortunov/warnfix
Fix some issues, found by CoverityScan
2020-04-04 21:34:26 +04:00
Capostrophic
5732b8e026 Use std::fill instead of loops to reset some arrays to defaults 2020-04-04 17:53:36 +03:00
Capostrophic
27d4fe9ee1 Fix ESM::Land oversights 2020-04-04 16:48:38 +03:00
Andrei Kortunov
a68d9aed4c Fix issues, found by CoverityScan 2020-04-04 17:45:26 +04:00
elsid
ef4a7089e4
Use template specialization for writeHNT to write raw arrays
To avoid passing explicit size argument where it's possible.
2020-04-04 01:12:49 +02:00
Andrei Kortunov
e20d156904 Do not write empty trade time 2020-03-18 13:31:26 +04:00
Bret Curtis
79517f3f42
Merge pull request #2724 from akortunov/factions
Cleanup ownership for items in containers
2020-03-18 10:00:36 +01:00
Andrei Kortunov
ea30e27370 Cleanup ownership for items in containers 2020-03-17 17:22:39 +04:00
Andrei Kortunov
dea2018d9f Do not use dynamic casts when using ObjectState 2020-03-17 15:18:40 +04:00
Andrei Kortunov
94df2114c1 Store fog of war as a PNG image instead of TGA (bug #5108) 2020-03-07 11:05:32 +04:00
Capostrophic
216a5d27c6 Avoid working with AMBI subrecord in tools unnecessarily (bug #5269) 2020-02-04 20:57:04 +03:00
capostrophic
89055f1c6c Generate WNAM upon saving terrain 2020-01-11 02:42:04 +03:00
capostrophic
0467e8ee15 Avoid heap corruption while reading SCVR (bug #4680) 2020-01-04 01:34:41 +03:00
Alexei Dobrohotov
2693598d82
Merge pull request #2642 from akortunov/warnfix2
Add safety checks for door state
2019-12-23 21:22:56 +03:00
Andrei Kortunov
24044b08e0 Do not store gold-specific value for everything 2019-12-23 19:34:57 +04:00
Andrei Kortunov
88a695f251 Add safety checks for door state 2019-12-23 19:29:12 +04:00
Assumeru
737aa1e4e8 Remove FactionID editing from OpenCS (#2636)
* Remove FactionID editing

* remove useless comments

* rename FactionID to Unknown
2019-12-18 20:42:54 +03:00
Assumeru
dfbe0021a5 Change rescaling to be more inline with vanilla (fixes #5214) (#2635)
* move rescaling to loadData

* clamp on save
2019-12-18 19:37:45 +03:00
Capostrophic
4b38bab0d9 Make sure empty cell name subrecords are saved (bug #5222) 2019-12-03 18:47:02 +03:00
Andrei Kortunov
6eb8e0cf4d Display magic effects according to research page 2019-11-07 11:05:18 +04:00
Bret Curtis
0ec4e51922
Revert "Store raw data about fog of war instead of RGBA images" 2019-10-30 14:48:44 +01:00
Bret Curtis
36614dba2a
Merge pull request #2453 from akortunov/fog_compression
Store raw data about fog of war instead of RGBA images
2019-10-30 13:45:55 +01:00
Andrei Kortunov
b2e12f0a73 Attempt to fix a regression - crash on ARM 2019-10-28 18:58:16 +04:00
Andrei Kortunov
2fc819cdae Encode ID's in all places to UTF-8 (bug #3977) 2019-10-10 20:52:32 +04:00
Nelsson Huotari
2fdaacf23c remove for array, just std::swap 2019-10-06 23:50:16 +03:00
Nelsson Huotari
e35ed960ee for -> std::copy 2019-10-06 21:57:10 +03:00
Nelsson Huotari
7f030fc3ee copy mWnam record in copy constructor and custom assignment operator 2019-10-06 21:50:40 +03:00
Andrei Kortunov
b360deaec3 Store raw data about fog of war instead of RGBA images (bug #5108) 2019-09-22 19:59:12 +04:00
Andrei Kortunov
f0cef772fa Refactor weapon types behaviour
1. Move weapon types behaviour from switches to the table (should allow
us to de-hardcode weapon types later)
2. Gereralize bones injection to actors skeletons (instead of using the
hardcoded xbase_anim_sh.nif)
2019-08-09 19:40:27 +04:00
Andrei Kortunov
b9a1e4d796
Merge pull request #2425 from Capostrophic/esm
Signedness fixes
2019-06-21 10:01:10 +04:00
Capostrophic
3aa65273c5 Signedness fixes 2019-06-18 14:47:10 +03:00
Evil Eye
698c90b3ee fix builds against MyGUI master 2019-06-16 14:41:34 +02:00
Alexei Dobrohotov
2c956398c1
Actually fix bug 4938 2019-05-15 21:41:49 +03:00
Capostrophic
7814bd1b76 Support eight possible blood types (feature #4958) 2019-04-14 18:48:31 +03:00
Capostrophic
4b6fc5f720 Make sure the record hasn't ended in getHString hack (bug #4938) 2019-03-30 20:11:22 +03:00
elsid
c91deaf7af
Use std::vector::data method to avoid reference binding to null pointer 2019-03-16 00:46:00 +03:00
Andrei Kortunov
943279abbb Consider land texture with given ID and index as override for base texture with the same ID and index (bug #4736) 2019-03-11 20:19:19 +04:00
Bret Curtis
56d5fc788c
Merge pull request #2163 from Capostrophic/hello
AI data handling minor revisions
2019-02-24 20:14:08 +01:00
Bret Curtis
d4564a9be7
Merge pull request #2180 from akortunov/includes
Remove redundant includes
2019-02-24 01:14:16 +01:00
Bret Curtis
44920352ce
Merge pull request #2181 from Capostrophic/boost
Get rid of Boost.Array
2019-02-23 23:54:30 +01:00
Capostrophic
594ea39f5d Revise AI data handling
Make Hello 16-bit unsigned as it's intended to be
Get rid of redundant mHasAI boolean
Always save AI data subrecord
Adjust creature and NPC default rating values to Morrowind defaults
2019-02-23 21:00:47 +03:00