/
sh_interface.lua
207 lines (196 loc) · 4.89 KB
/
sh_interface.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
DarkRP.PLAYER.isWanted = DarkRP.stub{
name = "isWanted",
description = "Whether this player is wanted",
parameters = {
},
returns = {
{
name = "answer",
description = "Whether this player is wanted",
type = "boolean"
}
},
metatable = DarkRP.PLAYER
}
DarkRP.PLAYER.getWantedReason = DarkRP.stub{
name = "getWantedReason",
description = "Get the reason why someone is wanted",
parameters = {
},
returns = {
{
name = "answer",
description = "The reason",
type = "string"
}
},
metatable = DarkRP.PLAYER
}
DarkRP.PLAYER.isArrested = DarkRP.stub{
name = "isArrested",
description = "Whether this player is arrested",
parameters = {
},
returns = {
{
name = "answer",
description = "Whether this player is arrested",
type = "boolean"
}
},
metatable = DarkRP.PLAYER
}
DarkRP.PLAYER.isCP = DarkRP.stub{
name = "isCP",
description = "Whether this player is part of the police force (mayor, cp, chief).",
parameters = {
},
returns = {
{
name = "answer",
description = "Whether this player is part of the police force.",
type = "boolean"
}
},
metatable = DarkRP.PLAYER
}
DarkRP.PLAYER.isMayor = DarkRP.stub{
name = "isMayor",
description = "Whether this player is a mayor.",
parameters = {
},
returns = {
{
name = "answer",
description = "Whether this player is a mayor.",
type = "boolean"
}
},
metatable = DarkRP.PLAYER
}
DarkRP.PLAYER.isChief = DarkRP.stub{
name = "isChief",
description = "Whether this player is a Chief.",
parameters = {
},
returns = {
{
name = "answer",
description = "Whether this player is a Chief.",
type = "boolean"
}
},
metatable = DarkRP.PLAYER
}
DarkRP.hookStub{
name = "canRequestWarrant",
description = "Whether someone can request a search warrant.",
parameters = {
{
name = "target",
description = "The player to get the search warrant for",
type = "Player"
},
{
name = "actor",
description = "The player requesting the warrant",
type = "Player"
},
{
name = "reason",
description = "The reason for the search warrant",
type = "Player"
}
},
returns = {
{
name = "canRequest",
description = "A yes or no as to whether the search warrant can be requested",
type = "boolean"
},
{
name = "message",
description = "The message that is shown when it can't",
type = "string"
}
}
}
DarkRP.hookStub{
name = "canWanted",
description = "Whether someone can make a player wanted",
parameters = {
{
name = "target",
description = "The player to make wanted by the police",
type = "Player"
},
{
name = "actor",
description = "The player requesting the wanted status",
type = "Player"
},
{
name = "reason",
description = "The reason",
type = "Player"
}
},
returns = {
{
name = "canRequest",
description = "A yes or no as to whether the wanted can be requested",
type = "boolean"
},
{
name = "message",
description = "The message that is shown when it can't",
type = "string"
}
}
}
DarkRP.hookStub{
name = "canUnwant",
description = "Whether someone can remove the wanted status from a player",
parameters = {
{
name = "target",
description = "The player to make wanted by the police",
type = "Player"
},
{
name = "actor",
description = "The player requesting the wanted status",
type = "Player"
}
},
returns = {
{
name = "canUnwant",
description = "A yes or no answer",
type = "boolean"
},
{
name = "message",
description = "The message that is shown when the answer is no",
type = "string"
}
}
}
DarkRP.hookStub{
name = "lockdownStarted",
description = "When a lockdown has started.",
parameters = {},
returns = {
{
name = "actor",
description = "The player who started the lockdown",
type = "Player"
}
}
}
DarkRP.hookStub{
name = "lockdownEnded",
description = "When a lockdown has ended.",
parameters = {},
returns = {}
}