Commit graph

1557 commits

Author SHA1 Message Date
scrawl
559ddbb480 Quick fix for Ai fast-forward crash in exteriors (Fixes #2241) 2015-01-01 18:18:46 +01:00
Internecine
a7a3ab0c78 Fixed instant negative dynamic stat changes being applied as positive 2015-01-01 21:26:09 +13:00
scrawl
dc1c52bda7 Add some todo comments 2015-01-01 03:38:54 +01:00
scrawl
e0d083f702 Add hand-to-hand combat mechanics for bipedal creatures
You can now have a fistfight with vivec, if you so desire.
2015-01-01 03:38:54 +01:00
scrawl
70d3bfc6ed Fix idle animation not restarting immediately for creatures 2015-01-01 03:38:54 +01:00
scrawl
01652bbcc5 Store original actor position in AiWander package (Fixes #2200) 2015-01-01 03:38:49 +01:00
scrawl
99ae0f901b Implement AiTravel fast-forward (Fixes #1125) 2014-12-31 20:42:29 +01:00
scrawl
a8ae0dec52 Implement AiWander fast-forward (Feature #1125) 2014-12-31 18:41:57 +01:00
scrawl
d26d5f6c26 Fix outdated bone locations when camera view is changed while paralyzed 2014-12-31 17:25:06 +01:00
scrawl
d1a29300f0 Handle bipedal creatures not using weapons (Fixes #2238) 2014-12-31 16:59:21 +01:00
scrawl
363d1f9207 Merge remote-tracking branch 'upstream/master' 2014-12-30 23:01:45 +01:00
scrawl
6c9875969a Stop idle animations for non-biped creatures when attacking/moving
The idle animation wouldn't be visible anyway, since these creatures don't have animation layers. However sounds tagged in the animation would still play.
2014-12-28 15:34:47 +01:00
scrawl
a58bc9f2f7 Remove sneaking effect on combat AI (Fixes #2237) 2014-12-28 14:45:20 +01:00
scrawl
1bd3ab8a2d Fix torch animation playing when torch is hidden (Fixes #2236) 2014-12-28 14:17:53 +01:00
scrawl
de9d347018 Fix on touch area effect spells (Fixes #2233) 2014-12-28 01:51:12 +01:00
scrawl
a62fe38a1b Fix unsafe use of BaseNode 2014-12-27 15:02:05 +01:00
Internecine
5f9540318a Fixed incorrect indexes 2014-12-27 19:49:14 +13:00
Internecine
a87fe71ddf Added a helper function to handle dynamic stat changes 2014-12-27 19:46:54 +13:00
scrawl
768c4a5757 Update crime response to pickpocket attempts (thanks Hrnchamd) 2014-12-24 15:45:14 +01:00
scrawl
7f0d71f8f4 Swap use of iDispAttackMod/fDispAttacking (thanks Hrnchamd) 2014-12-24 15:45:14 +01:00
scrawl
019cd96719 Stop AiPursue when target has invisibility or chameleon>=75 2014-12-24 15:45:14 +01:00
scrawl
edc128572d Add MWMechanics::Actor class for temporary actor state, move AiState there 2014-12-24 15:45:14 +01:00
scrawl
8bc7eb5530 PlayGroup: Don't loop animations with no loop keys (Fixes #2223) 2014-12-24 15:45:13 +01:00
scrawl
9e5dfb6e98 Update crime system according to research wiki for more accurate attack responses 2014-12-24 15:45:13 +01:00
scrawl
2410d79410 Fix iFightAttack and iFightAttacking being swapped
Looks like the research wiki page was incorrect, the higher value (iFightAttack) being for the victim makes more sense, is consistent with iDispAttackMod/fDispAttacking, and seems to be how the original game behaves as well.
2014-12-24 15:45:13 +01:00
scrawl
0081a68376 Use fMagicStartIconBlink for spell effect indicator fading 2014-12-24 15:45:13 +01:00
scrawl
f3738e9a98 Say an "intruder" voice dialogue for trespassing crimes (Fixes #1082)
Seems to be broken in the original engine, but according to the TES-CS help this is how the intruder voices should be used. There are legitimate entries for "intruder" in the game's files, so we might as well use them.
2014-12-24 15:45:13 +01:00
scrawl
866fdfe8bd Crime system improvements
- If someone saw the crime, they will notify everyone else in range, even if the Alarm rating of the witness is 0.
- Pickpocket and selling stolen items now works properly, i.e. honors the victim's Alarm rating instead of always being reported.
2014-12-24 15:45:12 +01:00
scrawl
1910327469 Implement disposition changes due to crimes 2014-12-24 15:45:12 +01:00
scrawl
cc9af9562b Function_CreatureTargetted should return '2' for werewolfs
This makes NPCs say the correct attack voice files when fighting a werewolf.
2014-12-24 15:45:12 +01:00
scrawl
efa9ff3a76 Fix incorrect implementation of iWerewolfBounty 2014-12-24 15:45:12 +01:00
scrawl
35d2bfabca Adjust NPC response to pickpocket attempts (Fixes #2219) 2014-12-24 15:45:12 +01:00
scrawl
105f0f8716 Head tracking: don't look at dead actors 2014-12-24 15:45:12 +01:00
scrawl
8a210c49e9 Improve AI prioritising health potions 2014-12-24 15:45:12 +01:00
scrawl
f931ba2efc Fix some static analysis issues (coverity) 2014-12-24 15:45:12 +01:00
scrawl
1b9209df4a Allow blocking of hand-to-hand attacks 2014-12-24 15:45:11 +01:00
Alexander "Ace" Olofsson
462b41a3a8 Missing files, aka; Why you shouldn't stresscommit 2014-12-19 11:26:54 +01:00
Alexander "Ace" Olofsson
0af5c7b379 Starting to clean up some heavy includes 2014-12-19 09:23:16 +01:00
scrawl
d962f0918d Implement NPC head tracking (Fixes #1720) 2014-12-16 20:47:45 +01:00
scrawl
4d5adfb5dd Fix being able to use enchantments of items that failed to equip (Fixes #2215) 2014-12-15 13:47:34 +01:00
scrawl
2b78e9795d Implement Calm effect removing combat packages (Fixes #1985) 2014-12-14 19:35:34 +01:00
scrawl
4f3995a4d8 Fix werewolf AI being able to use items 2014-12-14 19:15:43 +01:00
scrawl
88a2e4c043 Graceful error handling for missing spells/factions (Fixes #1825, Bug #2176, Bug #2203) 2014-12-14 02:38:27 +01:00
scrawl
60aa209144 Implement drowning when knocked out underwater (Fixes #1228) 2014-12-12 17:42:56 +01:00
scrawl
d034a079e6 Allow equipping twohanded weapon and shield at the same time (Fixes #1785)
The shield can be equipped, meaning armor rating and item enchantments apply, but can not be blocked with.
2014-12-12 16:49:22 +01:00
scrawl
bc85bb32c2 Fix vampirism magic effect not applying immediately (Fixes #1984) 2014-12-12 02:39:59 +01:00
scrawl
2601b26217 Merge branch 'master' of https://github.com/OpenMW/openmw 2014-12-11 22:44:58 +01:00
scrawl
886903d70e Implement HitAttemptOnMe function (Bug #2078) 2014-12-11 22:25:41 +01:00
scrawl
5f00a3d5c3 Reset lastHitObject when it is retrieved rather than every frame
This seems to be how vanilla MW does it.
2014-12-11 22:00:31 +01:00
Marc Zinnschlag
19bd07648b Merge remote-tracking branch 'scrawl/pathgrid' 2014-12-11 20:32:32 +01:00
scrawl
3270f0e932 Change pathgrid workaround to check for interior cell name 2014-12-11 15:19:48 +01:00
scrawl
623783cd6a Enchanting: fix cast cost for "on use" enchantments being set incorrectly 2014-12-10 18:05:11 +01:00
scrawl
ead6bf1601 Enchanting: cast the enchant points for the item to int (Fixes #2202) 2014-12-10 17:34:05 +01:00
scrawl
3c747195ae Add fall damage for creatures (Fixes #2201) 2014-12-10 17:21:34 +01:00
scrawl
e0c6f84546 AiFollow: target has to be seen in order to start following (Fixes #1637) 2014-12-09 22:25:28 +01:00
scrawl
109a3f78a1 Adjust AiFollow distance for groups of multiple followers (Fixes #1637) 2014-12-09 16:06:04 +01:00
scrawl
0fe7500f74 Work around pathgrid record limitation (Fixes #2195) 2014-12-09 00:13:56 +01:00
scrawl
416d549568 Fix animation glitch caused by knockdown
If the player was knocked down while having no weapon, spell nor fists ready, the animation state would incorrectly shift to "weapon equipped" even though no weapon is equipped.
2014-12-05 22:02:18 +01:00
scrawl
83dcf9ce4b Overwrite existing records in IndexedStore (Fixes #2182) 2014-12-05 15:58:05 +01:00
Marc Zinnschlag
eb6e1576be Merge remote-tracking branch 'scrawl/master' 2014-12-03 20:17:34 +01:00
scrawl
14ae6d28b0 Fix being able to jump when overencumbered 2014-12-03 18:28:35 +01:00
scrawl
7faa849cef Fix fatigue recalculation using older value (oops) 2014-12-03 18:28:34 +01:00
Paulo Viadanna
bfa048e687 Fix #1734: AI will stop combat if target disappear 2014-12-02 17:38:25 -02:00
scrawl
46d93f1b08 Crime update: NPCs can report crimes if they didn't see the crime, but were alerted by someone who saw it and did not report it themselves. 2014-12-01 23:09:46 +01:00
scrawl
507cbcfae3 Remove incorrect implementation of the iAlarm* GMSTs, not used by vanilla MW (Fixes #2064)
According to Hrnchamd, these are unused. The real mechanics are not fully documented, but from a quick test only NPCs with an alarm value of 100 will report crimes.
2014-12-01 23:09:46 +01:00
scrawl
a1226501fa AiWander: move idle animation handling to non-delayed section (Fixes #2073) 2014-12-01 23:09:46 +01:00
scrawl
c684c99a95 Combat AI: Don't attempt to cast spells when impossible to succeed (Fixes #2059) 2014-12-01 23:09:46 +01:00
scrawl
61d1aa78ce Move AiWander path finder to temporary storage (Fixes #2082) 2014-12-01 23:09:46 +01:00
Marc Zinnschlag
003675318d Merge remote-tracking branch 'scrawl/master' 2014-11-29 20:54:04 +01:00
scrawl
5f5fcc2fef Make PlayGroup use an indefinite number of loops (Fixes #2156) 2014-11-28 17:15:31 +01:00
scrawl
0a466ad643 Make recalculation of magicka less aggressive (Fixes #2155) 2014-11-28 14:45:35 +01:00
MiroslavR
cb74c1c36e Set health to 0 if it drops below 1 (Fixes #2163) 2014-11-27 20:44:41 +01:00
MiroslavR
238325455d Erase effects that have expired (Fixes #2134) 2014-11-25 10:33:03 +01:00
MiroslavR
b8d5a9486a Make Restore/Damage Attribute/Skill effects continuous 2014-11-08 00:57:03 +01:00
Internecine
edc51ab768 Removed debug output 2014-11-05 15:26:13 +13:00
Internecine
6741fbe7a9 Fixes bug #2031 2014-11-05 15:22:44 +13:00
MiroslavR
140013820b Fix invalidated iterator 2014-11-02 15:40:08 +01:00
scrawl
45f14f0704 Fix stolen faction-owned items not being confiscated 2014-10-31 00:25:37 +01:00
scrawl
8b3755a770 Compile fix 2014-10-20 17:45:24 +02:00
scrawl
192069a181 Add automatic potion naming 2014-10-20 17:45:11 +02:00
scrawl
fd7c181e06 Fix alchemy producing potion IDs from content files 2014-10-20 17:45:06 +02:00
scrawl
f117a75747 Force walk animation when flying (Fixes #2015) 2014-10-17 19:11:06 +02:00
Alexander "Ace" Olofsson
dc788512e2 Fix LNK2019 link error on Visual Studio 2010 builds
For some reason VS2010 (Haven't tested 2013) is REALLY pedantic about class/struct being two different things when it comes to function signatures
2014-10-14 16:10:19 +02:00
Marc Zinnschlag
6beee95151 Merge remote-tracking branch 'terrorfisch/aistate' 2014-10-13 19:14:15 +02:00
Marc Zinnschlag
eb45793eab Merge remote-tracking branch 'thoronador/fix-numeric-limits-usage' 2014-10-13 11:03:03 +02:00
Thoronador
4d62541b62 fix usage of numeric_limits static functions min() and max()
Functions min() and max() of std::numeric_limits<T> are static
and can therefore be accessed via class name and :: operator.
2014-10-12 23:28:16 +02:00
scrawl
d51daf5875 Fix AI not using F_Always spells, for example "vampire touch" 2014-10-12 17:18:27 +02:00
scrawl
8cb09e89ed Make spells cast by scripts always succeed (Fixes #1993) 2014-10-12 17:18:27 +02:00
MiroslavR
ad253059b1 Hit indicator for absorb/damage health effect 2014-10-12 01:15:40 +02:00
MiroslavR
0ae604990e Implement continuous damage indication (Fixes #1970) 2014-10-11 22:21:48 +02:00
terrorfisch
c4badcea6e removed warning 2014-10-10 23:51:29 +02:00
terrorfisch
c28dfc2fa4 Travis CI fix? 2014-10-10 23:34:58 +02:00
terrorfisch
4eb1668467 references now initialized when they are needed 2014-10-10 23:32:15 +02:00
terrorfisch
bbca942601 -improved trigonometric precision
-cleanup
2014-10-10 23:31:01 +02:00
terrorfisch
5248917a6c - changed namespace 2014-10-10 23:28:49 +02:00
terrorfisch
db1b93498d Added comment. 2014-10-10 00:17:50 +02:00
terrorfisch
730abf6841 Moved all variables in temporary storage for AiCombat and some more for AiWander.
+Buxfix for previous AiWander changes
2014-10-10 00:16:17 +02:00
terrorfisch
cae948df96 removed unecessary PathFinders 2014-10-08 23:09:50 +02:00
terrorfisch
4c36c67fb8 Updated AiCombat:
-moved everything except target to temporary storage
-removed the Pathfinder since present in baseclass
-cleaned some trigonometric mess
2014-10-08 23:00:36 +02:00
terrorfisch
4391c1fd00 Addded the parts of AiWander that I fully understand to the temporary storage.
The rest should be done by someone who has a clearer overview over the class.
2014-10-08 22:11:45 +02:00
terrorfisch
0871d45790 Draft how to move temporary package state to CharacterController.
Example for a few values shown in AiWander.
2014-10-08 10:58:52 +02:00
Marc Zinnschlag
744c56943a Merge remote-tracking branch 'jordan-ayers/topic/misc-cleanup' 2014-10-07 18:03:25 +02:00
Jordan Ayers
56db525a93 Document the return value of getEffectMultiplier. 2014-10-06 21:56:41 -05:00
scrawl
c4fa671381 Don't allow raising faction rank if the next rank has no name (Fixes #1975) 2014-10-05 16:47:55 +02:00
scrawl
5c3bc6563b Fix divisions by zero in normalizedEncumbrance 2014-10-05 15:50:01 +02:00
scrawl
8dd410fe96 Teleport indirect followers as well when using a door (Fixes #1974) 2014-10-05 15:18:32 +02:00
Jordan Ayers
663647bee8 Simplify getEffectMultiplier.
Both return cases were same, except for some overflow conditions.
2014-10-04 15:28:58 -05:00
scrawl
6fc53e73ad Don't run AI for knocked-out actors (Fixes #1854) 2014-10-03 15:58:14 +02:00
Marc Zinnschlag
a166034e12 Merge remote-tracking branch 'jordan-ayers/topic/disease-cleanup' 2014-10-02 17:19:32 +02:00
scrawl
861cc26aa6 Don't sell racial spells (Fixes #1961) 2014-10-02 16:50:05 +02:00
scrawl
afbd2de511 Fix broken alchemy magnitude/duration 2014-10-02 13:55:42 +02:00
scrawl
7e10818bdf Fix uninitialized flags for custom-made spells 2014-10-02 13:55:42 +02:00
Jordan Ayers
3bc91c66e6 Disease Check: Shorten the resistance calculations. 2014-10-01 19:29:03 -05:00
Jordan Ayers
a9a0930b85 Disease check: Reuse corprus check from spells.hpp. 2014-10-01 19:26:25 -05:00
scrawl
1c51694aa9 Don't update physics and animation for actors outside the AI processing distance 2014-10-02 00:27:04 +02:00
scrawl
ee8b85aa2c Fix priority bug in AiSequence::stack (Fixes #1959) 2014-09-30 22:57:38 +02:00
Jordan Ayers
da9d858201 Add 'const' to a spell helper function. 2014-09-29 20:59:10 -05:00
scrawl
7f18f85a1d Forgot const 2014-09-29 12:04:19 +02:00
scrawl
e9ed0211c9 Attempt to fix Clang warnings 2014-09-28 12:44:47 +02:00
scrawl
02dec787fd Cache GMSTs in getDerivedDisposition 2014-09-27 22:44:20 +02:00
scrawl
ea956b537c Don't search for fFatigueReturnBase and fFatigueReturnMult every frame 2014-09-27 22:37:53 +02:00
scrawl
e868a48a63 Don't trigger OnPcHitMe for friendly hits (Fixes #1950)
Don't consider actors as followers if they are also in combat with the follow target
2014-09-26 22:08:07 +02:00
scrawl
7252cb63a6 Fix cppcheck issues 2014-09-26 17:48:14 +02:00
scrawl
f56711f443 Fix crash caused by teleportation spells (Fixes #1904) 2014-09-25 18:14:04 +02:00
scrawl
8ad2b95208 Revert "AiFollow: return from execute() if target is not player"
This reverts commit 061c7813f6.

Fixes #1898.
2014-09-25 17:57:10 +02:00
scrawl
40ce5add59 Don't report crime for attacking an NPC that is already in combat with another NPC (Fixes #1908, Fixes #1821) 2014-09-25 17:33:26 +02:00
scrawl
40587f984d Implement price-based mercantile skill progress (Fixes #1947), thanks Hrnchamd
Correct barter formula (removed erroneous clamping)
2014-09-25 13:02:42 +02:00
Marc Zinnschlag
175d4f3d44 Merge remote-tracking branch 'ragora/playdeathlevelupmusic' 2014-09-23 13:30:50 +02:00
Ragora
06e683d378 Added code to play music on level up and on death 2014-09-23 04:58:19 -04:00
scrawl
3ac04060c1 Fix NPCs being able to practice Block skill 2014-09-20 16:17:09 +02:00
scrawl
023d7072f9 Don't play battle music for enemies out of AI processing range 2014-09-20 13:55:57 +02:00
Marc Zinnschlag
65ddf7acfe Merge remote-tracking branch 'scrawl/master' 2014-09-19 15:59:59 +02:00
Marc Zinnschlag
2a48c377a8 Merge remote-tracking branch 'miroslavr/master' 2014-09-19 15:55:24 +02:00
scrawl
b145d183ae Fix incorrect alchemy failure handling when an effect has a zero magnitude/duration (Fixes #1922) 2014-09-19 09:11:21 +02:00
scrawl
8a3a3baed4 Tweak AiEscort maximum distances 2014-09-19 05:47:45 +02:00
scrawl
b39fe85a51 Implement fPCbaseMagickaMult and fNPCbaseMagickaMult 2014-09-18 14:56:43 +02:00
scrawl
c19f89976e Add missing Hit voice dialogue for friendly hits 2014-09-18 05:13:17 +02:00
scrawl
be7839873a Don't trigger dynamic stats recalculation when setting up actor initial stats (Fixes #1927)
This caused the magicka value set in the CS to be ignored completely, so flame atronachs were spawning with 50 magicka instead of 105.
2014-09-18 03:47:45 +02:00
scrawl
447e93bdb4 Use SpellCast animation for creatures that have it (flame atronach) 2014-09-18 03:24:47 +02:00
scrawl
07cd647e75 Fix broken AI for creatures with OnTarget spells (Bug #1927) 2014-09-18 03:19:13 +02:00
scrawl
2eaceb71ba Reject AiTravel destinations further than 7168 units away, as in vanilla MW (Fixes #1911) 2014-09-17 12:39:10 +02:00
scrawl
3ce3f31452 Adjust turning animation speed multiplier based on turning speed 2014-09-17 07:02:19 +02:00
scrawl
6debd21ec6 Make sure the Jump control is always handled by the PhysicsSystem even if game runs faster than the minimum physics timestep 2014-09-17 07:02:19 +02:00
scrawl
269c200c8f Fix jump velocity mechanics (Fixes #1708) 2014-09-17 07:02:19 +02:00
scrawl
b6a89c7845 Fix idlestorm animation conflict with torch animation 2014-09-17 07:02:19 +02:00
scrawl
4c285151a3 Fix incorrect movement animation for some creatures (Fixes #1924) 2014-09-17 07:02:10 +02:00
scrawl
0c75c6bf1b Improve spellcasting AI for Drain/Damage effects 2014-09-15 10:42:51 +02:00
scrawl
157c53bed4 Handle spellcasting for creatures with no casting animation (Fixes #1856) 2014-09-15 10:42:44 +02:00
scrawl
233e221de2 Terminate AI packages when target is disabled or deleted (Fixes #1910) 2014-09-14 10:49:33 +02:00
scrawl
a42e60970b Revert "delete death events on adding an actor to the scene"
If we go to a different cell in the exact frame of an actor's death, the death event would be lost permanently.

This reverts commit fd2c07a6f4.

Conflicts:
	apps/openmw/mwmechanics/actors.cpp
2014-09-13 20:57:25 +02:00