Skip to content

Commit 28218d0

Browse files
authored
Update l4d_consistent_escaperoute (#924)
* Update l4d_consistent_escaperoute * Fix missing include
1 parent 6fd83ec commit 28218d0

2 files changed

Lines changed: 256 additions & 271 deletions

File tree

addons/sourcemod/gamedata/l4d_consistent_escaperoute.txt

Lines changed: 111 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,70 @@
11
"Games"
22
{
3+
"#default"
4+
{
5+
"Functions"
6+
{
7+
"l4d_consistent_escaperoute::TerrorNavMesh::ComputeFlowDistances"
8+
{
9+
"signature" "TerrorNavMesh::ComputeFlowDistances"
10+
"callconv" "thiscall"
11+
"return" "int"
12+
"this" "ignore"
13+
}
14+
15+
// GetPlayerSpawnPosition(SurvivorCharacterType,Vector *,QAngle *,TerrorNavArea **)
16+
"l4d_consistent_escaperoute::GetPlayerSpawnPosition"
17+
{
18+
"signature" "GetPlayerSpawnPosition"
19+
"callconv" "cdecl"
20+
"return" "bool"
21+
"arguments"
22+
{
23+
"SurvivorCharacterType"
24+
{
25+
"type" "int"
26+
}
27+
"Vector *"
28+
{
29+
"type" "vectorptr"
30+
}
31+
"QAngle *"
32+
{
33+
"type" "vectorptr"
34+
}
35+
"TerrorNavArea **"
36+
{
37+
"type" "int"
38+
}
39+
}
40+
}
41+
}
42+
}
43+
344
"left4dead"
445
{
46+
"MemPatches"
47+
{
48+
"skip_spawn_position_idx"
49+
{
50+
"signature" "GetPlayerSpawnPosition"
51+
"linux"
52+
{
53+
"offset" "356h"
54+
"verify" "\x8B\x8B\x2A\x2A\x2A\x2A\x8D\x51\x01\x39\xC2\x0F\x8D\x2A\x2A\x2A\x2A\x89\x93\x2A\x2A\x2A\x2A\x01\xD2\x01\xD2"
55+
"patch" "\x31\xD2\xEB\x17" // xor edx, edx
56+
// jmp next
57+
}
58+
"windows"
59+
{
60+
"offset" "1E5h"
61+
"verify" "\xA1\x2A\x2A\x2A\x2A\x83\xC0\x01\x3B\xC5\xA3\x2A\x2A\x2A\x2A\x7C\x07\x33\xC0\xA3\x2A\x2A\x2A\x2A"
62+
"patch" "\x31\xC0\xEB\x14" // xor eax, eax
63+
// jmp next
64+
}
65+
}
66+
}
67+
568
"Offsets"
669
{
770
"CEscapeRoute::m_nMainPathAreaCount"
@@ -10,99 +73,88 @@
1073
"windows" "7016"
1174
}
1275

13-
"TerrorNavArea::m_flowToGoal"
14-
{
15-
"linux" "348"
16-
"windows" "340"
17-
}
18-
19-
"TerrorNavMesh::m_flMapMaxFlowDistance"
76+
"CNavArea::m_id"
2077
{
21-
"windows" "1444"
22-
"linux" "1444"
78+
"linux" "136"
79+
"windows" "136"
2380
}
2481
}
2582

2683
"Signatures"
2784
{
28-
// Search string "ERROR: BuildEscapeRoute failed. The start or end area was NULL\n"
29-
// "CEscapeRoute::ResetPath", "CEscapeRoute::AddArea" and "CEscapeRoute::FinishPath" can be found there.
30-
"CEscapeRoute::ResetPath"
31-
{
32-
"library" "server"
33-
"linux" "@_ZN12CEscapeRoute9ResetPathEv"
34-
"windows" "\xD9\xEE\x33\xC0\xD9\x99"
35-
/* D9 EE 33 C0 D9 99 */
36-
}
37-
38-
"CEscapeRoute::AddArea"
85+
"TerrorNavMesh::ComputeFlowDistances"
3986
{
4087
"library" "server"
41-
"linux" "@_ZN12CEscapeRoute7AddAreaEP13TerrorNavArea"
42-
"windows" "\x55\x8B\xEC\x83\xE4\xF0\x83\xEC\x28\x56\x8B\xF1\x8B\x86\x2A\x2A\x2A\x2A\x3D"
43-
/* 55 8B EC 83 E4 F0 83 EC 28 56 8B F1 8B 86 ? ? ? ? 3D */
88+
"linux" "@_ZN13TerrorNavMesh20ComputeFlowDistancesEv"
89+
"windows" "\x83\xEC\x3C\x53\x55\x56\x57\x6A\x04\x33\xFF"
90+
/* 83 EC 3C 53 55 56 57 6A 04 33 FF */
4491
}
45-
46-
"CEscapeRoute::FinishPath"
92+
93+
"GetPlayerSpawnPosition"
4794
{
4895
"library" "server"
49-
"linux" "@_ZN12CEscapeRoute10FinishPathEv"
50-
"windows" "\x8B\x81\x2A\x2A\x2A\x2A\x3D\x00\x02\x00\x00\x7C\x2A\x68"
51-
/* 8B 81 ? ? ? ? 3D 00 02 00 00 7C ? 68 */
96+
"linux" "@_Z22GetPlayerSpawnPosition21SurvivorCharacterTypeP6VectorP6QAnglePP13TerrorNavArea"
97+
"windows" "\x83\xEC\x34\x8B\x0D\x2A\x2A\x2A\x2A\x53"
98+
/* 83 EC 34 8B 0D ? ? ? ? 53 */
5299
}
53100
}
54101
}
55102

56103
"left4dead2"
57104
{
105+
"MemPatches"
106+
{
107+
"skip_spawn_position_idx"
108+
{
109+
"signature" "GetPlayerSpawnPosition"
110+
"linux"
111+
{
112+
"offset" "41Ch"
113+
"verify" "\x8B\x0D\x2A\x2A\x2A\x2A\x8D\x51\x01\x39\xC2\x0F\x8D\x2A\x2A\x2A\x2A\x89\x15\x2A\x2A\x2A\x2A\xC1\xE2\x02"
114+
"patch" "\x31\xD2\xEB\x16" // xor edx, edx
115+
// jmp next
116+
}
117+
"windows"
118+
{
119+
"offset" "2A8h"
120+
"verify" "\xA1\x2A\x2A\x2A\x2A\x40\xA3\x2A\x2A\x2A\x2A\x3B\xC3\x7C\x07\x33\xC0\xA3\x2A\x2A\x2A\x2A"
121+
"patch" "\x31\xC0\xEB\x12" // xor eax, eax
122+
// jmp next
123+
}
124+
}
125+
}
126+
58127
"Offsets"
59128
{
60129
"CEscapeRoute::m_nMainPathAreaCount"
61130
{
62131
"linux" "7232"
63132
"windows" "7212"
64133
}
65-
66-
"TerrorNavArea::m_flowToGoal"
134+
135+
"CNavArea::m_id"
67136
{
68-
"linux" "340"
69-
"windows" "332"
70-
}
71-
72-
"TerrorNavMesh::m_flMapMaxFlowDistance"
73-
{
74-
"windows" "1528"
75-
"linux" "1524"
76-
// Compared against inside of the current_flow_distance ccommand.
137+
"linux" "140"
138+
"windows" "140"
77139
}
78140
}
79-
141+
80142
"Signatures"
81143
{
82-
// Search string "ERROR: BuildEscapeRoute failed. No path from start to end. zeroFlowArea = #%d, endArea = #%d.\n"
83-
// "CEscapeRoute::ResetPath", "CEscapeRoute::AddArea" and "CEscapeRoute::FinishPath" can be found there.
84-
"CEscapeRoute::ResetPath"
85-
{
86-
"library" "server"
87-
"linux" "@_ZN12CEscapeRoute9ResetPathEv"
88-
"windows" "\x0F\x57\xC0\x33\xC0\x89\x81\x2A\x2A\x2A\x2A\x89\x81\x2A\x2A\x2A\x2A\xF3\x0F"
89-
/* 0F 57 C0 33 C0 89 81 ? ? ? ? 89 81 ? ? ? ? F3 0F */
90-
}
91-
92-
"CEscapeRoute::AddArea"
144+
"TerrorNavMesh::ComputeFlowDistances"
93145
{
94146
"library" "server"
95-
"linux" "@_ZN12CEscapeRoute7AddAreaEP13TerrorNavArea"
96-
"windows" "\x53\x8B\xDC\x83\xEC\x08\x83\xE4\xF0\x83\xC4\x04\x55\x8B\x6B\x04\x89\x6C\x24\x04\x8B\xEC\x83\xEC\x28\x56\x8B\xF1\x8B\x86\x2A\x2A\x2A\x2A\x57\x3D\x00\x02\x00\x00\x7C"
97-
/* 53 8B DC 83 EC 08 83 E4 F0 83 C4 04 55 8B 6B 04 89 6C 24 04 8B EC 83 EC 28 56 8B F1 8B 86 ? ? ? ? 57 3D 00 02 00 00 7C */
147+
"linux" "@_ZN13TerrorNavMesh20ComputeFlowDistancesEv"
148+
"windows" "\x55\x8B\xEC\x81\xEC\x88\x00\x00\x00\xA1\x2A\x2A\x2A\x2A\x53"
149+
/* 55 8B EC 81 EC 88 00 00 00 A1 ? ? ? ? 53 */
98150
}
99-
100-
"CEscapeRoute::FinishPath"
151+
152+
"GetPlayerSpawnPosition"
101153
{
102154
"library" "server"
103-
"linux" "@_ZN12CEscapeRoute10FinishPathEv"
104-
"windows" "\x8B\x81\x2A\x2A\x2A\x2A\x3D\x00\x02\x00\x00\x7C\x2A\x68"
105-
/* 8B 81 ? ? ? ? 3D 00 02 00 00 7C ? 68 */
155+
"linux" "@_Z22GetPlayerSpawnPosition21SurvivorCharacterTypeP6VectorP6QAnglePP13TerrorNavArea"
156+
"windows" "\x55\x8B\xEC\x83\xEC\x4C\x53\x33\xDB"
157+
/* 55 8B EC 83 EC 4C 53 33 DB */
106158
}
107159
}
108160
}

0 commit comments

Comments
 (0)