| name | research |
| description | Decompile and analyze TaleWorlds classes before implementing or fixing |
| argument-hint | ["ClassName or DLL.ClassName"] |
TaleWorlds Research
Decompile and analyze: $ARGUMENTS
Step 1: Check Decompiled Source First
Look in External/Decompiled/ for the target class. This is faster than live decompilation.
find External/Decompiled/ -name "*$ARGUMENTS*" -type f
grep -r "$ARGUMENTS" External/Decompiled/ --include="*.cs" -l
Step 2: If Not Found, Decompile
Identify the DLL:
TaleWorlds.CampaignSystem.dll — Campaign logic, GameModels, behaviors
TaleWorlds.Core.dll — Core types
TaleWorlds.MountAndBlade.dll — Battle/mission logic
SandBox.dll — Sandbox behaviors
Decompile:
ilspycmd "E:\Steam\steamapps\common\Mount & Blade II Bannerlord\bin\Win64_Shipping_Client\<DLL>" -t "TaleWorlds.<Namespace>.<ClassName>"
For large classes, use _meta["anthropic/maxResultSizeChars"] up to 500K to prevent truncation.
Step 3: Analyze
- Method signatures (parameters, return types, access modifiers)
- Virtual vs sealed vs static methods
- Null handling patterns (TextObject.Empty vs null)
- Collection types and modification safety
- Event timing and state change ordering
- Properties (read-only vs read-write)
Step 4: Document
- Key methods and signatures
- Properties that need adapter wrapping
- Nested sealed types
- Important edge case behavior
- Recommendations for safe integration