View Issue Details

IDProjectCategoryView StatusLast Update
0003166The Dark ModCodingpublic21.03.2013 17:55
ReporterSpringheel Assigned Tograyman  
PrioritynormalSeveritynormalReproducibilityhave not tried
Status resolvedResolutionfixed 
Product VersionTDM 1.08 
Target VersionTDM 2.00Fixed in VersionTDM 2.00 
Summary0003166: After putting away sword AI still uses weapon_idle
DescriptionCheck to see what's up with that...should only be used when sword is attached to the right hand. At least twice in Rightful Property I've seen AI ramp down from a search, put their sword away, and stay using the weapon_idle with one hand in a fist.
TagsNo tags attached.

Activities

Springheel

Springheel

04.07.2012 23:28

administrator   ~0004690

The weapon has the correct replace spawnarg:

    "replace_anim_idle RightHand" "idle_weapon"

Yet even when the weapon was no longer attached to the RightHand, "idle_weapon" was still replacing "idle".
Springheel

Springheel

24.07.2012 20:54

administrator   ~0004728

Just saw this in test/walkcycle.map.

Shoot a noise arrow into the corner. Wait for AI to return to their patrols. They put their weapons away, but they use the "alert walk" animation with their right hand in a fist.
Springheel

Springheel

14.08.2012 00:52

administrator   ~0004752

This is a non-critical thing that can wait until after 1.08.
grayman

grayman

20.03.2013 04:36

viewer   ~0005222

Found that unbinding a weapon doesn't account for the joint name when removing replacement anims, so none of the replacement anims were found in the replacement list, and so weren't being removed.

After correcting this, AI that don't carry torches return to the correct idle animations.

I'm currently testing with an armed wench carrying a torch and an armed builder carrying a torch. The wench correctly returns to the torch-carrying walking and idle anims (torch held up), but the builder doesn't (torch held down).

Will need to see what the difference is between them.
grayman

grayman

20.03.2013 18:05

viewer   ~0005223

The replacement anim system does a good job when an actor only wields one item.

When an actor wields two items (weapon & torch), the system doesn't work. It can't support the combinations of idle/alert, armed/unarmed, torch/no torch, and fails when a torch-carrying actor sheathes his weapon, because the replacement anim removals aren't aware that the torch is still wielded. Essentially, the actor behaves as if he isn't carrying a torch.

Rather than replacing the system, implement a workaround when an actor is carrying a torch. After a weapon is sheathed, the replacement anims from the torch are reloaded, making the system once again aware that a torch is present.
grayman

grayman

20.03.2013 20:53

viewer   ~0005224

Unbinding weapons didn’t cause the replacement anims to be removed.

Sheathing a weapon when carrying a torch requires reloading the torch’s replacement anims.

Dropping a torch when carrying a weapon requires reloading the weapon’s replacement anims.

rev. 5719:

AI_events.cpp
Actor.cpp
Actor.h

rev. 13367:

tdm_ai_base.script
tdm_moveable_weapons.def
AluminumHaste

AluminumHaste

21.03.2013 16:38

developer   ~0005227

This breaks Darkmod, get crash at start:

--------- Game Map Shutdown ----------
--------- Game Map Shutdown done -----
ERROR:Error: file script\tdm_ai_base.script, line 2528: Unknown value "reloadTorchReplacementAnims"
grayman

grayman

21.03.2013 16:49

viewer   ~0005228

In script/tdm_events.script, instead of "#if 0", do you have "#if 1" in the following section?

// ===== THIS FILE ONLY SERVES FOR DOCUMENTATION PURPOSES, IT'S NOT ACTUALLY READ BY THE GAME =======
// ===== If you want to force this file to be loaded, change the line below to #if 1 ================
#if 0
grayman

grayman

21.03.2013 17:02

viewer   ~0005229

Assuming that was the problem, and you want to continue running with "#if 1", though it isn't necessary, you can update your darkmod folder and you'll receive a newly generated tdm_events.script file. You'll need to replace "#if 0" with "#if 1" if that's how you want to run.
grayman

grayman

21.03.2013 17:05

viewer   ~0005230

Or perhaps you didn't delete darkmod/gamex86.dll before running the new update, and you're picking up an old Windows DLL?
AluminumHaste

AluminumHaste

21.03.2013 17:29

developer   ~0005231

I checked that file and it was set to #if 0, so I changed it to 1 but it still crashes with the same error. I did a SVN update just before running Darkmod, everything is showing as up to date. I'll try deleting gamex86.dll and checking out again.
AluminumHaste

AluminumHaste

21.03.2013 17:30

developer   ~0005232

Yeah it was the old dll, working now. I thought Darkmod was supposed to overwrite the gamex86.dll file in the main folder, if the one in the pk4 was newer?
grayman

grayman

21.03.2013 17:55

viewer   ~0005233

taaaki knows about this problem, but hasn't submitted a change for it.

Issue History

Date Modified Username Field Change
04.07.2012 01:32 Springheel New Issue
04.07.2012 23:28 Springheel Note Added: 0004690
24.07.2012 20:54 Springheel Note Added: 0004728
14.08.2012 00:52 Springheel Note Added: 0004752
20.03.2013 04:26 grayman Assigned To => grayman
20.03.2013 04:26 grayman Status new => assigned
20.03.2013 04:36 grayman Note Added: 0005222
20.03.2013 18:05 grayman Note Added: 0005223
20.03.2013 20:53 grayman Note Added: 0005224
20.03.2013 20:53 grayman Status assigned => resolved
20.03.2013 20:53 grayman Resolution open => fixed
20.03.2013 20:53 grayman Fixed in Version => TDM 2.00
20.03.2013 20:53 grayman Target Version => TDM 2.00
21.03.2013 16:38 AluminumHaste Note Added: 0005227
21.03.2013 16:49 grayman Note Added: 0005228
21.03.2013 17:02 grayman Note Added: 0005229
21.03.2013 17:05 grayman Note Added: 0005230
21.03.2013 17:29 AluminumHaste Note Added: 0005231
21.03.2013 17:30 AluminumHaste Note Added: 0005232
21.03.2013 17:55 grayman Note Added: 0005233