View Issue Details

IDProjectCategoryView StatusLast Update
0002816The Dark ModAIpublic22.05.2012 23:42
Reportertels Assigned Tograyman  
PrioritynormalSeveritynormalReproducibilityalways
Status resolvedResolutionfixed 
Product VersionTDM 1.06 
Target VersionTDM 1.08Fixed in VersionTDM 1.08 
Summary0002816: AI are not alerted if you throw things at them
DescriptionIf you throw something at an AI, they blissfully ignore it when they are friendly. Even hostile AI probably ignore the flying object, they just react to the sound of the object when it bounces on the floor.

So if you throw a vase at an archer at a parapet, they will only react if the vase falls down on the (stone) parapet, but not if it falls sufficiently deep onto the street, or back onto to some straw.
TagsNo tags attached.

Activities

grayman

grayman

19.11.2011 05:14

viewer   ~0004159

The problem for an AI is to determine whether the object hit them or they hit the object. It's the same collision code in both cases. We don't want them getting alerted when they kick a box out of the way.

If the velocity of the incoming object is still available after the collision, then we could differentiate between the two cases.
tels

tels

19.11.2011 21:31

reporter   ~0004165

But aren't thrown objects tagged with "set in motion by: player" versus "set in motion by: entity myself"?

The same goes for the case where the player still has the object in the grabber - if it bumbs into an AI they should be able to tell the difference and react.
grayman

grayman

17.04.2012 22:43

viewer   ~0004474

1 – AI are now alerted, and possibly hurt, if you throw something at them. They will stop and look at the item thrown, then turn back toward where it came from.

2 – AI can be knocked out if you drop something heavier than 20kg on their head.

3 – Throwing or dropping things at/on AI will never kill them.

4 – When an AI kills an enemy, he will pause before emitting his victory bark. It was being emitted at the same time as the enemy’s death bark, making it difficult to make out either. Plus, it’s more dramatic.

5 – An AI remembers who he last killed, so that contact with the victim on his way down doesn’t cause a tactile alert to the victor.

6 – When an AI drops his weapon upon dying, that weapon won’t hurt or alert others who come in contact with it.

7 – An AI who kills an enemy won’t emit a rampdown bark. It sounded silly when they’d just killed someone, and then said something like, “I guess it was just rats” or “You win this round.”

8 – An AI is no longer alerted by the death bark of someone he just killed.

9 – Increased the tactile alert search volume from (40,40,40) to (100,100,100) because AI were just standing still and not searching.

10 – Prevent knocked-out AI from yelping with pain when something is dropped on them.

rev. 5394:

CombatState.cpp
ObservantState.cpp
State.cpp
AI.cpp
AI.h
AI_events.cpp
Memory.h
Physics_RigidBody.cpp
Actor.cpp
Actor.h
Moveable.cpp
AFEntity.cpp
Mind.cpp
Entity.cpp
MeleeWeapon.cpp

rev. 12768:

tdm_damage.def
moveable.def
tdm_movable_containers.def
grayman

grayman

19.04.2012 20:46

viewer   ~0004487

Last edited: 19.04.2012 20:53

Next round:

1 – moveable weapons in the map at map start won’t hurt AI that collide with them

2 – objects dropped on the inventor with his goggles up can cause KO

Rev. 5396:

Actor.cpp
Moveable.cpp

grayman

grayman

23.04.2012 23:54

viewer   ~0004494

Third round:

1 - Adjust velocity limits to eliminate the likelihood of damage from stepping or jumping on objects. Then I don't need to worry about what struck what. CrashLand() will take care of damage from crashing into walls or crates or whatever when riding movers or being flung from movers.

2 - If an object hits an AI when he's not searching, he should stop, look at the object for a moment, and turn to look in the direction the object came from. If he spots an enemy, he'll do his normal "Aha!" and enter combat mode. If he spots a friend, he'll go back to what he was doing. If he spots no one, and a friend/neutral threw the object, he'll go back to what he was doing. If he spots no one, and an enemy threw the object, he'll treat it as a suspicious event and start searching. If the object is heavy enough and fast enough to knock him out, it will.

3 - If an object hits an AI when he's searching, he should turn to look in the direction the object came from (assuming the search code doesn't override this somehow). If he spots an enemy, he'll enter combat mode. If he spots a friend or no one, he'll go back to what he was doing (searching). If the object is heavy enough and fast enough to knock him out, it will.

TODO: Use appropriate barks for this event.

rev 5397:

AI.h
PlayerView.cpp
HitByMoveableState.cpp
DeadState.cpp
Moveable.cpp
Player.cpp
HitByMoveableState.h
BlindedState.cpp
HandleElevatorTask.cpp
FailedKnockoutState.cpp
SearchingState.cpp
Memory.cpp
CombatState.cpp
MovementSubsystem.cpp
KnockedOutState.cpp
StayInCoverState.cpp
SuspiciousState.cpp
Memory.h
AI_events.cpp
ConversationState.cpp
Actor.cpp
FleeState.cpp
game.vcxproj
State.cpp
Actor.h
UnreachableTargetState.cpp
TakeCoverState.cpp
HandleDoorTask.cpp
game.vcxproj.filters
State.h
AI.cpp
grayman

grayman

29.04.2012 22:29

viewer   ~0004501

Fourth round:

1 – Put back immediate AI tactile alert when you bump them or they bump you.

2 – Allow small AI to be killed by a dropped moveable.

3 – Further corrections to KOs by dropped moveables

4 – Define new sounds for getting hit and admonishing friends when appropriate.

rev 5400:

Actor.cpp
Actor.h
AFEntity.cpp
AI.cpp
CombatState.cpp
HitByMoveableState.cpp
HitByMoveableState.h
State.cpp
Moveable.cpp

rev 12787:

tdm_ai_animal_horse2.def
tdm_ai_animal_rat.def
tdm_ai_base.def
tdm_ai_ghostwoman.def
tdm_ai_humanoid.def
tdm_ai_humanoid_undead.def
tdm_ai_monster_spider.def
tdm_ai_steambot_base.def
tdm_ai_vocal_set_monster.def
tdm_ai_vocal_set_revenant01.def
grayman

grayman

01.05.2012 17:00

viewer   ~0004509

Another round:

snd_notice_generic needed to be added for all 5 horse types; I had only added it to the first type.

The code line that emitted snd_notice_generic hadn’t made it into the committed version.

rev 5415:

HitByMoveableState.cpp
State.cpp

rev 12795:

tdm_ai_animal_horse2.def
grayman

grayman

03.05.2012 23:38

viewer   ~0004527

Another round:

Change mass threshold beneath which a falling object that would have KO’ed an AI kills them instead. Changed from 5 to 50 to kill a normal-sized spider.

rev 5420:

Actor.h
grayman

grayman

22.05.2012 23:42

viewer   ~0004612

Another round:

Only set the 1s timer for when damage can next be applied if damage was taken.

rev 5458:

AI.cpp
Moveable.cpp

Issue History

Date Modified Username Field Change
17.07.2011 15:20 tels New Issue
19.11.2011 05:14 grayman Note Added: 0004159
19.11.2011 21:31 tels Note Added: 0004165
10.04.2012 19:20 grayman Assigned To => grayman
10.04.2012 19:20 grayman Status new => assigned
17.04.2012 22:43 grayman Note Added: 0004474
17.04.2012 22:43 grayman Status assigned => resolved
17.04.2012 22:43 grayman Resolution open => fixed
17.04.2012 22:43 grayman Fixed in Version => TDM 1.08
17.04.2012 22:43 grayman Target Version => TDM 1.08
19.04.2012 20:46 grayman Note Added: 0004487
19.04.2012 20:53 grayman Note Edited: 0004487
23.04.2012 23:54 grayman Note Added: 0004494
29.04.2012 22:29 grayman Note Added: 0004501
01.05.2012 17:00 grayman Note Added: 0004509
03.05.2012 23:38 grayman Note Added: 0004527
22.05.2012 23:42 grayman Note Added: 0004612