1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-15 20:49:56 +00:00
Commit graph

818 commits

Author SHA1 Message Date
scrawl
ec4e2f0064
Merge pull request #1684 2018-04-22 15:27:31 +00:00
Capostrophic
37dc3200d1 Inherit the calling object scale in PlaceAt (fixes #4308) 2018-04-20 00:15:26 +03:00
tri4ng1e
d4d1703bcf
Some PVS-Studio and cppcheck fixes
cppcheck:
[apps/esmtool/record.cpp:697]: (performance) Prefer prefix ++/-- operators for non-primitive types.
[apps/esmtool/record.cpp:1126]: (performance) Prefer prefix ++/-- operators for non-primitive types.
[apps/esmtool/record.cpp:1138]: (performance) Prefer prefix ++/-- operators for non-primitive types.
[apps/niftest/niftest.cpp:36]: (performance) Function parameter 'filename' should be passed by reference.
[apps/niftest/niftest.cpp:41]: (performance) Function parameter 'filename' should be passed by reference.
[apps/opencs/model/prefs/boolsetting.cpp:25]: (warning) Possible leak in public function. The pointer 'mWidget' is not deallocated before it is allocated.
[apps/opencs/model/prefs/shortcuteventhandler.cpp:52]: (warning) Return value of std::remove() ignored. Elements remain in container.
[apps/openmw/mwstate/quicksavemanager.cpp:5]: (performance) Variable 'mSaveName' is assigned in constructor body. Consider performing initialization in initialization list.

PVS-Studio:
apps/opencs/model/filter/parser.cpp  582  warn  V560 A part of conditional expression is always true: allowPredefined.
apps/opencs/view/world/referencecreator.cpp  67  warn  V547 Expression '!errors.empty()' is always false.
apps/opencs/view/world/referencecreator.cpp  74  warn  V547 Expression '!errors.empty()' is always false.
apps/opencs/view/doc/loader.cpp  170  warn  V560 A part of conditional expression is always true: !completed.
apps/opencs/view/doc/loader.cpp  170  warn  V560 A part of conditional expression is always true: !error.empty().
apps/opencs/model/tools/pathgridcheck.cpp  32  err  V517 The use of 'if (A) {...} else if (A) {...}' pattern was detected. There is a probability of logical error presence. Check lines: 32, 34.
apps/opencs/model/world/refidadapterimp.cpp  1376  err  V547 Expression 'subColIndex < 3' is always true.

apps/openmw/mwgui/widgets.hpp  318  warn  V703 It is odd that the 'mEnableRepeat' field in derived class 'MWScrollBar' overwrites field in base class 'ScrollBar'. Check lines: widgets.hpp:318, MyGUI_ScrollBar.h:179.
apps/openmw/mwgui/widgets.hpp  319  warn  V703 It is odd that the 'mRepeatTriggerTime' field in derived class 'MWScrollBar' overwrites field in base class 'ScrollBar'. Check lines: widgets.hpp:319, MyGUI_ScrollBar.h:180.
apps/openmw/mwgui/widgets.hpp  320  warn  V703 It is odd that the 'mRepeatStepTime' field in derived class 'MWScrollBar' overwrites field in base class 'ScrollBar'. Check lines: widgets.hpp:320, MyGUI_ScrollBar.h:181
apps/openmw/mwmechanics/actors.cpp  1425  warn  V547 Expression '!detected' is always true.
apps/openmw/mwmechanics/character.cpp  2155  err  V547 Expression 'mode == 0' is always true.
apps/openmw/mwmechanics/character.cpp  1192  warn  V592 The expression was enclosed by parentheses twice: ((expression)). One pair of parentheses is unnecessary or misprint is present.
apps/openmw/mwmechanics/character.cpp  521  warn  V560 A part of conditional expression is always true: (idle == mIdleState).
apps/openmw/mwmechanics/pathfinding.cpp  317  err  V547 Expression 'mPath.size() >= 2' is always true.
apps/openmw/mwscript/interpretercontext.cpp  409  warn  V560 A part of conditional expression is always false: rank > 9.
apps/openmw/mwgui/windowbase.cpp  28  warn  V560 A part of conditional expression is always true: !visible.
apps/openmw/mwgui/journalwindow.cpp  561  warn  V547 Expression '!mAllQuests' is always false.
apps/openmw/mwgui/referenceinterface.cpp  18  warn  V571 Recurring check. The '!mPtr.isEmpty()' condition was already verified in line 16.
apps/openmw/mwworld/scene.cpp  463  warn  V547 Expression 'adjustPlayerPos' is always true.
apps/openmw/mwworld/worldimp.cpp  409  err  V766 An item with the same key '"sCompanionShare"' has already been added.
apps/openmw/mwworld/cellstore.cpp  691  warn  V519 The 'state.mWaterLevel' variable is assigned values twice successively. Perhaps this is a mistake. Check lines: 689, 691.
apps/openmw/mwworld/weather.cpp  1125  warn  V519 The 'mResult.mParticleEffect' variable is assigned values twice successively. Perhaps this is a mistake. Check lines: 1123, 1125.
apps/openmw/mwworld/weather.cpp  1137  warn  V519 The 'mResult.mParticleEffect' variable is assigned values twice successively. Perhaps this is a mistake. Check lines: 1135, 1137.

apps/wizard/unshield/unshieldworker.cpp  475  warn  V728 An excessive check can be simplified. The '(A && B) || (!A && !B)' expression is equivalent to the 'bool(A) == bool(B)' expression.
apps/wizard/installationpage.cpp  163  warn  V735 Possibly an incorrect HTML. The "</p" closing tag was encountered, while the "</span" tag was expected.

components/fontloader/fontloader.cpp  427  err  V547 Expression 'i == 1' is always true.
components/nifosg/nifloader.cpp  282  warn  V519 The 'created' variable is assigned values twice successively. Perhaps this is a mistake. Check lines: 278, 282.
components/esm/loadregn.cpp  119  err  V586 The 'clear' function is called twice for deallocation of the same resource. Check lines: 112, 119.
components/esm/cellref.cpp  178  warn  V581 The conditional expressions of the 'if' statements situated alongside each other are identical. Check lines: 175, 178.
components/esmterrain/storage.cpp  235  warn  V560 A part of conditional expression is always true: colStart == 0.
components/esmterrain/storage.cpp  237  warn  V560 A part of conditional expression is always true: rowStart == 0.
2018-04-18 12:36:10 +00:00
Andrei Kortunov
62c04c6758 Unstack soulgem, added via AddSoulGem console command (bug #4351) 2018-03-09 21:49:27 +04:00
scrawl
1522bda60b
Fix crash in getDistance when invoked before the game starts 2018-01-11 01:48:05 +00:00
Andrei Kortunov
ba46473038 Do not skip weather transitions from SetPos script command (bug #3603) 2017-12-13 10:53:23 +04:00
Andrei Kortunov
c908ad2fba Do not allow to place actors underground via SetPos (bug #3783) 2017-12-10 14:38:02 +04:00
scrawl
0c6ef17fb5 Add explicit variant of 'OnActivate' 2017-10-23 23:33:06 +00:00
scrawl
64e27c032b Merge pull request #1481 from scrawl/keyfocus
WindowManager overhaul & improved keyboard support
2017-09-28 22:34:05 +00:00
scrawl
2ce79e07a4 Refactor dialogue GUI to talk to the dialogue manager, not the other way around and not both ways.
- Fix memory leaks in DialogueWindow
- Fix Link objects being deleted from their own event handler
2017-09-25 23:38:28 +02:00
scrawl
32f9c8058a Remove redundant RestBed gui mode 2017-09-24 19:08:14 +02:00
scrawl
ad4b91131f toggleGui renamed to toggleHud, remove unused variable 2017-09-24 19:08:14 +02:00
scrawl
0e648222b8 Merge pull request #1446 from akortunov/takeallfix
Do not allow to equip a replacement, when take all items from a dead corpse
2017-09-22 09:14:21 +00:00
Andrei Kortunov
4580024d76 Unequip all items from dead corpse when take all items (bug #4095) 2017-09-22 12:32:47 +04:00
Andrei Kortunov
65d8e2ff5d Allow to use GetDetected without a reference (bug #3110) 2017-09-18 21:46:57 +04:00
Chris Robinson
780e82480d Make the PlayMode and PlayType enums scoped
Also shorten them by putting them in the MWSound namespace
2017-09-15 02:36:59 -07:00
Andrei Kortunov
c6fd75bf42 Take in account elemental shields for GetResist and SetResist script commands (bug #4093) 2017-09-10 22:05:58 +04:00
Andrei Kortunov
bc7353f100 Check animation state for GetPCRunning and GetPCSneaking 2017-08-16 20:30:47 +04:00
Andrei Kortunov
3b163ce6ce Disable sound distortion for PlaySound script command 2017-07-15 10:58:19 +04:00
Allofich
42402976e3 Fixes for building in MSVC 2017-06-13 19:38:12 +09:00
Bret Curtis
c781d1f8ed purge unnecessary imports
add fstream back

add fstream back

add fstream back

add fstream back

add fstream back

add fstream back

add fstream back
2017-06-09 19:08:53 +02:00
Bret Curtis
d785344fad purge all instances of <boost/shared_ptr.hpp>, clean up unused headers 2017-06-09 19:08:53 +02:00
Allofich
143ee387cc Add enabled check to animation script commands
(Fixes #3793)
2017-04-21 23:27:24 +09:00
Allofich
ff3e307059 Pass parameters by const reference 2017-04-20 23:47:03 +09:00
Allofich
6e405aed8c Adjustments to RemoveItem behavior
(Fixes #3796)
2017-04-13 22:33:13 +09:00
Allofich
57aeec59d5 Change bounds behavior of stat script commands
Fixes (#3776)
2017-03-22 15:17:44 +09:00
MiroslavR
af1fe64408 GetSoundPlaying called on an equipped item now also looks for sounds played by the equipping actor (Fixes #3781) 2017-03-07 19:00:09 +01:00
scrawl
29556a1802 More consistent wording of errors/warnings
A Warning indicates a potential problem in the content file(s) that the user told OpenMW to load. E.g. this might cause an object to not display at all or as intended, however the rest of the game will run fine.

An Error, however, is more likely to be a bug with the engine itself - it means that basic assumptions have been violated and the engine might not run correctly anymore.

The above mostly applies to errors/warnings during game-play; startup issues are handled differently: when a file is completely invalid/corrupted to the point that the engine can not start, that might cause messages that are worded as Error due to the severity of the issue but are not necessarily the engine's fault.

Hopefully, being a little more consistent here will alleviate confusion among users as to when a log message should be reported and to whom.
2017-03-04 21:48:31 +01:00
scrawl
1692b7f38e Merge pull request #1209 from dhustkoder/master
Added ConstContainerStoreIterator (Task #3092)
2017-03-02 18:36:21 +01:00
Rafael Moura
6c2ce2b2a1 Porting more ContainerStoreIterator usage to const version #4
removed const_cast revision
2017-02-28 19:11:00 +00:00
scrawl
3f27c8cc97 Always print context for script warnings to remove the need for verbose option
(Fixes #2813)
2017-02-21 04:32:59 +01:00
scrawl
05ad0dca34 Use ActionTeleport in COE/COC commands 2017-02-20 20:26:45 +01:00
Rafael Moura
9963601484 Porting code to ConstContainerStoreIterator #1 2017-02-19 15:18:35 +00:00
scrawl
249fe9077b Handle 'tcb' command as an alias for 'tcg' 2017-02-08 18:51:07 +01:00
scrawl
34deb6e7b1 Add 'showSceneGraph' command to export the scene or a particular object to .osgt for debugging purposes 2017-02-01 06:00:14 +01:00
MiroslavR
d97e9cfe7e Fix InterpreterContext::updatePtr updating mLocals to the implicit ref's locals when interpreting a targeted global script (Fixes #3738)
The interpreter context of a targeted global script would point to the target's locals instead of the global script instance's locals when the target changed cell during script execution. Credit to scrawl for the solution.
2017-01-29 13:29:53 +01:00
scrawl
45fb4f04b1 Update reference of the interpreter context when an Activate results in a take action (Fixes #3727) 2017-01-18 21:57:50 +01:00
scrawl
70c5f64caa Fix mLocals not being updated in InterpreterContext::updatePtr 2017-01-18 21:55:58 +01:00
Leon Krieg
739cd5ba45 Fixed more spelling mistakes 2016-12-15 13:09:40 +01:00
scrawl
e0f613661e Fix char -> int, fix shadowing warning 2016-10-30 20:10:33 +01:00
Allofich
125e94ef0e Fix shadowing warnings 2016-10-31 00:39:31 +09:00
Marc Zinnschlag
03a35c38df add missing item when executing the Equip instruction 2016-09-06 16:33:26 +02:00
Allofich
a381a15b19 Make loopgroup loop correct number of times 2016-08-14 21:57:06 +09:00
MiroslavR
b65f379b7f Save scripted animation state (Fixes #1931, #2150, #3393) 2016-08-03 03:52:35 +02:00
MiroslavR
dc0bc5b68c Implement Face instruction (Feature #1424) 2016-07-09 02:16:47 +02:00
scrawl
ab2089bbf3 Throw an exception if placeAt is passed an invalid direction parameter 2016-06-02 21:19:02 +02:00
scrawl
ba3f4f122a Account for the stack count in HasSoulGem (Bug #3340) 2016-04-12 21:39:05 +02:00
scrawl
5bd8ef247d Do not adjust the player position when loading a savegame (Fixes #2089) 2016-03-24 17:18:08 +01:00
scrawl
d7c7bb850b ToggleAI cleanup 2016-03-12 20:32:42 +01:00
scrawl
6df71f6250 Factor out safePlaceObject function 2016-02-29 17:19:22 +01:00