@tlua/gmod 1.0.4 → 1.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/types/achievementicon.d.tlua +0 -1
- package/types/achievements.d.tlua +0 -31
- package/types/ai.d.tlua +0 -11
- package/types/ai_schedule.d.tlua +0 -1
- package/types/ai_task.d.tlua +0 -1
- package/types/angle.d.tlua +0 -37
- package/types/avatarimage.d.tlua +0 -1
- package/types/awesomium.d.tlua +0 -1
- package/types/baseclass.d.tlua +0 -4
- package/types/bf_read.d.tlua +0 -23
- package/types/bit.d.tlua +0 -23
- package/types/button.d.tlua +0 -1
- package/types/cam.d.tlua +0 -33
- package/types/ceffectdata.d.tlua +0 -65
- package/types/chat.d.tlua +0 -11
- package/types/checkbutton.d.tlua +0 -1
- package/types/cleanup.d.tlua +0 -15
- package/types/cluaemitter.d.tlua +0 -25
- package/types/clualocomotion.d.tlua +0 -81
- package/types/cluaparticle.d.tlua +0 -89
- package/types/cmovedata.d.tlua +0 -95
- package/types/cnavarea.d.tlua +0 -155
- package/types/cnavladder.d.tlua +0 -45
- package/types/cnewparticleeffect.d.tlua +0 -53
- package/types/color.d.tlua +0 -57
- package/types/concommand.d.tlua +0 -9
- package/types/constraint.d.tlua +0 -57
- package/types/construct.d.tlua +0 -3
- package/types/contentheader.d.tlua +1 -6
- package/types/contenticon.d.tlua +1 -18
- package/types/contentsidebar.d.tlua +1 -8
- package/types/contentsidebartoolbox.d.tlua +0 -1
- package/types/contextbase.d.tlua +1 -8
- package/types/controlpanel.d.tlua +6 -31
- package/types/controlpresets.d.tlua +1 -26
- package/types/convar.d.tlua +0 -33
- package/types/cookie.d.tlua +0 -7
- package/types/coroutine.d.tlua +0 -15
- package/types/crecipientfilter.d.tlua +0 -33
- package/types/csent.d.tlua +0 -1
- package/types/csoundpatch.d.tlua +0 -29
- package/types/ctakedamageinfo.d.tlua +0 -67
- package/types/ctrllistbox.d.tlua +0 -1
- package/types/ctrlnumpad.d.tlua +0 -13
- package/types/cusercmd.d.tlua +0 -55
- package/types/custom_entity_fields.d.tlua +0 -1
- package/types/cvars.d.tlua +0 -13
- package/types/dadjustablemodelpanel.d.tlua +1 -14
- package/types/dalphabar.d.tlua +1 -6
- package/types/dbinder.d.tlua +1 -8
- package/types/dbubblecontainer.d.tlua +1 -4
- package/types/dbutton.d.tlua +1 -16
- package/types/dcategoryheader.d.tlua +0 -1
- package/types/dcategorylist.d.tlua +0 -1
- package/types/dcheckbox.d.tlua +1 -10
- package/types/dcheckboxlabel.d.tlua +0 -19
- package/types/dcollapsiblecategory.d.tlua +1 -46
- package/types/dcolorbutton.d.tlua +1 -14
- package/types/dcolorcombo.d.tlua +1 -10
- package/types/dcolorcube.d.tlua +1 -26
- package/types/dcolormixer.d.tlua +1 -54
- package/types/dcolorpalette.d.tlua +1 -46
- package/types/dcolumnsheet.d.tlua +1 -10
- package/types/dcombobox.d.tlua +1 -34
- package/types/ddragbase.d.tlua +1 -26
- package/types/ddrawer.d.tlua +1 -16
- package/types/debug.d.tlua +25 -60
- package/types/debugoverlay.d.tlua +0 -23
- package/types/dentityproperties.d.tlua +1 -10
- package/types/derma.d.tlua +0 -21
- package/types/dexpandbutton.d.tlua +1 -6
- package/types/dfilebrowser.d.tlua +0 -41
- package/types/dform.d.tlua +1 -36
- package/types/dframe.d.tlua +0 -49
- package/types/dgrid.d.tlua +1 -22
- package/types/dhorizontaldivider.d.tlua +1 -40
- package/types/dhorizontalscroller.d.tlua +1 -22
- package/types/dhscrollbar.d.tlua +1 -22
- package/types/dhtml.d.tlua +1 -16
- package/types/dhtmlcontrols.d.tlua +0 -11
- package/types/diconbrowser.d.tlua +1 -22
- package/types/diconlayout.d.tlua +1 -36
- package/types/dimage.d.tlua +1 -39
- package/types/dimagebutton.d.tlua +0 -19
- package/types/dkillicon.d.tlua +0 -1
- package/types/dlabel.d.tlua +1 -66
- package/types/dlabeleditable.d.tlua +1 -10
- package/types/dlabelurl.d.tlua +1 -20
- package/types/dlistbox.d.tlua +1 -16
- package/types/dlistboxitem.d.tlua +1 -8
- package/types/dlistlayout.d.tlua +0 -1
- package/types/dlistview.d.tlua +1 -68
- package/types/dlistview_column.d.tlua +1 -28
- package/types/dlistview_columnplain.d.tlua +0 -1
- package/types/dlistview_draggerbar.d.tlua +0 -1
- package/types/dlistview_line.d.tlua +1 -26
- package/types/dlistviewheaderlabel.d.tlua +0 -1
- package/types/dlistviewlabel.d.tlua +0 -1
- package/types/dlistviewline.d.tlua +0 -1
- package/types/dmenu.d.tlua +1 -53
- package/types/dmenubar.d.tlua +1 -11
- package/types/dmenuoption.d.tlua +1 -26
- package/types/dmenuoptioncvar.d.tlua +1 -12
- package/types/dmodelpanel.d.tlua +1 -44
- package/types/dmodelselect.d.tlua +1 -4
- package/types/dmodelselectmulti.d.tlua +1 -4
- package/types/dnotify.d.tlua +1 -20
- package/types/dnumberscratch.d.tlua +1 -52
- package/types/dnumberwang.d.tlua +1 -32
- package/types/dnumpad.d.tlua +0 -1
- package/types/dnumslider.d.tlua +0 -35
- package/types/dpanel.d.tlua +1 -28
- package/types/dpanellist.d.tlua +0 -23
- package/types/dpaneloverlay.d.tlua +1 -14
- package/types/dpanelselect.d.tlua +0 -1
- package/types/dpanpanel.d.tlua +1 -12
- package/types/dprogress.d.tlua +1 -6
- package/types/dproperties.d.tlua +1 -8
- package/types/dproperty_boolean.d.tlua +0 -1
- package/types/dproperty_combo.d.tlua +1 -6
- package/types/dproperty_entity.d.tlua +0 -1
- package/types/dproperty_float.d.tlua +0 -1
- package/types/dproperty_generic.d.tlua +1 -10
- package/types/dproperty_int.d.tlua +0 -1
- package/types/dproperty_vectorcolor.d.tlua +0 -1
- package/types/dpropertysheet.d.tlua +9 -41
- package/types/dragndrop.d.tlua +0 -21
- package/types/draw.d.tlua +0 -22
- package/types/drgbpicker.d.tlua +1 -8
- package/types/drive.d.tlua +6 -31
- package/types/dscrollbargrip.d.tlua +0 -1
- package/types/dscrollpanel.d.tlua +0 -21
- package/types/dshape.d.tlua +1 -14
- package/types/dsizetocontents.d.tlua +1 -10
- package/types/dslider.d.tlua +1 -56
- package/types/dsprite.d.tlua +1 -18
- package/types/dtab.d.tlua +1 -16
- package/types/dtextentry.d.tlua +1 -86
- package/types/dtilelayout.d.tlua +1 -42
- package/types/dtooltip.d.tlua +1 -12
- package/types/dtree.d.tlua +1 -32
- package/types/dtree_node.d.tlua +1 -136
- package/types/dtree_node_button.d.tlua +0 -1
- package/types/duplicator.d.tlua +0 -60
- package/types/dverticaldivider.d.tlua +1 -46
- package/types/dvscrollbar.d.tlua +1 -22
- package/types/editablepanel.d.tlua +0 -1
- package/types/effect.d.tlua +1 -8
- package/types/effects.d.tlua +0 -13
- package/types/engine.d.tlua +0 -43
- package/types/entity.d.tlua +2 -1319
- package/types/ents.d.tlua +0 -44
- package/types/enums.d.tlua +0 -1
- package/types/file.d.tlua +0 -79
- package/types/file_class.d.tlua +0 -1
- package/types/fingerposer.d.tlua +0 -1
- package/types/fingervar.d.tlua +0 -1
- package/types/frame.d.tlua +0 -1
- package/types/frame_blend.d.tlua +0 -15
- package/types/game.d.tlua +0 -79
- package/types/gameevent.d.tlua +4 -9
- package/types/gamemode.d.tlua +0 -6
- package/types/global.d.tlua +0 -18
- package/types/gm.d.tlua +0 -535
- package/types/gmod.d.tlua +0 -1
- package/types/gmsave.d.tlua +0 -9
- package/types/gui.d.tlua +0 -43
- package/types/gwen.d.tlua +0 -7
- package/types/halo.d.tlua +0 -5
- package/types/hammer.d.tlua +0 -1
- package/types/hook.d.tlua +0 -9
- package/types/html.d.tlua +0 -1
- package/types/http.d.tlua +0 -3
- package/types/iconeditor.d.tlua +1 -22
- package/types/igmodaudiochannel.d.tlua +0 -83
- package/types/imagecheckbox.d.tlua +1 -8
- package/types/imaterial.d.tlua +0 -53
- package/types/imesh.d.tlua +0 -11
- package/types/input.d.tlua +0 -47
- package/types/invalidateinternalentitycache.d.tlua +0 -1
- package/types/irestore.d.tlua +0 -19
- package/types/isave.d.tlua +0 -19
- package/types/itexture.d.tlua +0 -21
- package/types/ivideowriter.d.tlua +0 -11
- package/types/jit.d.tlua +9 -42
- package/types/killicon.d.tlua +0 -15
- package/types/label.d.tlua +0 -1
- package/types/language.d.tlua +0 -3
- package/types/list.d.tlua +0 -17
- package/types/makeballoon.d.tlua +0 -1
- package/types/markup.d.tlua +0 -5
- package/types/markupobject.d.tlua +0 -11
- package/types/material.d.tlua +0 -1
- package/types/math.d.tlua +200 -371
- package/types/matproxy.d.tlua +0 -7
- package/types/matselect.d.tlua +1 -22
- package/types/menu.d.tlua +0 -1
- package/types/menubar.d.tlua +0 -5
- package/types/mesh.d.tlua +0 -39
- package/types/modelimage.d.tlua +0 -1
- package/types/motionsensor.d.tlua +0 -21
- package/types/navmesh.d.tlua +0 -53
- package/types/net.d.tlua +0 -104
- package/types/nextbot.d.tlua +10 -83
- package/types/notification.d.tlua +0 -5
- package/types/npc.d.tlua +1 -364
- package/types/numpad.d.tlua +0 -15
- package/types/os.d.tlua +0 -8
- package/types/package.d.tlua +0 -1
- package/types/panel.d.tlua +2 -662
- package/types/panellist.d.tlua +0 -1
- package/types/pathfollower.d.tlua +0 -63
- package/types/permissions.d.tlua +0 -13
- package/types/physcollide.d.tlua +0 -7
- package/types/physenv.d.tlua +0 -23
- package/types/physobj.d.tlua +0 -157
- package/types/pixelvis_handle_t.d.tlua +0 -1
- package/types/player.d.tlua +11 -594
- package/types/player_manager.d.tlua +0 -27
- package/types/preseteditor.d.tlua +0 -1
- package/types/presets.d.tlua +0 -13
- package/types/projectedtexture.d.tlua +0 -97
- package/types/properties.d.tlua +0 -11
- package/types/propselect.d.tlua +1 -10
- package/types/radiobutton.d.tlua +0 -1
- package/types/render.d.tlua +0 -285
- package/types/resource.d.tlua +0 -5
- package/types/richtext.d.tlua +0 -1
- package/types/sandbox.d.tlua +1 -108
- package/types/saverestore.d.tlua +0 -25
- package/types/schedule.d.tlua +0 -13
- package/types/scripted_ents.d.tlua +0 -21
- package/types/search.d.tlua +0 -3
- package/types/serverlist.d.tlua +0 -15
- package/types/slidebar.d.tlua +0 -1
- package/types/slider.d.tlua +0 -1
- package/types/sound.d.tlua +0 -21
- package/types/spawnicon.d.tlua +1 -16
- package/types/spawnmenu.d.tlua +0 -48
- package/types/spawnmenucontentpanel.d.tlua +1 -10
- package/types/sql.d.tlua +0 -19
- package/types/stack.d.tlua +0 -11
- package/types/steamworks.d.tlua +0 -37
- package/types/string.d.tlua +0 -96
- package/types/structures.d.tlua +0 -7
- package/types/surface.d.tlua +0 -69
- package/types/surfaceinfo.d.tlua +0 -11
- package/types/system.d.tlua +0 -21
- package/types/table.d.tlua +0 -93
- package/types/task.d.tlua +0 -19
- package/types/team.d.tlua +0 -39
- package/types/textentry.d.tlua +0 -1
- package/types/tgaimage.d.tlua +0 -1
- package/types/timer.d.tlua +0 -29
- package/types/tool.d.tlua +1 -90
- package/types/ugcpublishwindow.d.tlua +1 -18
- package/types/umsg.d.tlua +0 -25
- package/types/undo.d.tlua +0 -21
- package/types/urllabel.d.tlua +0 -1
- package/types/usermessage.d.tlua +0 -5
- package/types/utf8.d.tlua +0 -15
- package/types/util.d.tlua +0 -185
- package/types/vector.d.tlua +0 -73
- package/types/vehicle.d.tlua +2 -102
- package/types/vgui.d.tlua +0 -33
- package/types/video.d.tlua +0 -1
- package/types/vmatrix.d.tlua +0 -71
- package/types/weapon.d.tlua +2 -168
- package/types/weapons.d.tlua +0 -12
- package/types/widgets.d.tlua +0 -3
- package/types/workshopfilebase.d.tlua +0 -11
package/types/string.d.tlua
CHANGED
|
@@ -49,27 +49,21 @@ interface StringLib {
|
|
|
49
49
|
* @source https://wiki.facepunch.com/gmod/string.CardinalToOrdinal
|
|
50
50
|
*/
|
|
51
51
|
CardinalToOrdinal(input: number): string;
|
|
52
|
-
}
|
|
53
52
|
|
|
54
|
-
interface StringLib {
|
|
55
53
|
/**
|
|
56
54
|
* Inserts commas for every third digit of a given number.
|
|
57
55
|
* @realm shared and menu
|
|
58
56
|
* @source https://wiki.facepunch.com/gmod/string.Comma
|
|
59
57
|
*/
|
|
60
58
|
Comma(value: number, separator?: string): string;
|
|
61
|
-
}
|
|
62
59
|
|
|
63
|
-
interface StringLib {
|
|
64
60
|
/**
|
|
65
61
|
* Returns whether or not the second passed string matches the end of the first.
|
|
66
62
|
* @realm shared and menu
|
|
67
63
|
* @source https://wiki.facepunch.com/gmod/string.EndsWith
|
|
68
64
|
*/
|
|
69
65
|
EndsWith(str: string, _end: string): boolean;
|
|
70
|
-
}
|
|
71
66
|
|
|
72
|
-
interface StringLib {
|
|
73
67
|
/**
|
|
74
68
|
* Splits a string up wherever it finds the given separator. string.Split is an
|
|
75
69
|
* alias of this, except that it doesn't support patterns.
|
|
@@ -81,28 +75,21 @@ interface StringLib {
|
|
|
81
75
|
* @source https://wiki.facepunch.com/gmod/string.Explode
|
|
82
76
|
*/
|
|
83
77
|
Explode<Sep extends string, Str extends string>(separator: ConstTpl<Sep>, str: ConstTpl<Str>, withpattern?: boolean): Split<Sep, Str>;
|
|
84
|
-
}
|
|
85
|
-
|
|
86
78
|
|
|
87
|
-
interface StringLib {
|
|
88
79
|
/**
|
|
89
80
|
* Returns the time as a formatted string or as a table if no format is given.
|
|
90
81
|
* @realm shared and menu
|
|
91
82
|
* @source https://wiki.facepunch.com/gmod/string.FormattedTime
|
|
92
83
|
*/
|
|
93
84
|
FormattedTime(float: number, format?: string): string | FormattedTime;
|
|
94
|
-
}
|
|
95
85
|
|
|
96
|
-
interface StringLib {
|
|
97
86
|
/**
|
|
98
87
|
* Creates a string from a Color variable.
|
|
99
88
|
* @realm shared and menu
|
|
100
89
|
* @source https://wiki.facepunch.com/gmod/string.FromColor
|
|
101
90
|
*/
|
|
102
91
|
FromColor(color: Color): string;
|
|
103
|
-
}
|
|
104
92
|
|
|
105
|
-
interface StringLib {
|
|
106
93
|
/**
|
|
107
94
|
* Returns char value from the specified index in the supplied string.
|
|
108
95
|
* @realm shared and menu
|
|
@@ -110,9 +97,7 @@ interface StringLib {
|
|
|
110
97
|
* @deprecated Use either string.sub(str, index, index) or str[index].
|
|
111
98
|
*/
|
|
112
99
|
GetChar(str: string, index: number): string;
|
|
113
|
-
}
|
|
114
100
|
|
|
115
|
-
interface StringLib {
|
|
116
101
|
/**
|
|
117
102
|
* Returns extension of the file.
|
|
118
103
|
*
|
|
@@ -126,9 +111,7 @@ interface StringLib {
|
|
|
126
111
|
* @source https://wiki.facepunch.com/gmod/string.GetExtensionFromFilename
|
|
127
112
|
*/
|
|
128
113
|
GetExtensionFromFilename(path: string): string;
|
|
129
|
-
}
|
|
130
114
|
|
|
131
|
-
interface StringLib {
|
|
132
115
|
/**
|
|
133
116
|
* Returns file name and extension.
|
|
134
117
|
*
|
|
@@ -139,9 +122,7 @@ interface StringLib {
|
|
|
139
122
|
* @source https://wiki.facepunch.com/gmod/string.GetFileFromFilename
|
|
140
123
|
*/
|
|
141
124
|
GetFileFromFilename(path: string): string;
|
|
142
|
-
}
|
|
143
125
|
|
|
144
|
-
interface StringLib {
|
|
145
126
|
/**
|
|
146
127
|
* Returns the path part of a full file path.
|
|
147
128
|
*
|
|
@@ -153,9 +134,7 @@ interface StringLib {
|
|
|
153
134
|
* @source https://wiki.facepunch.com/gmod/string.GetPathFromFilename
|
|
154
135
|
*/
|
|
155
136
|
GetPathFromFilename(path: string): string;
|
|
156
|
-
}
|
|
157
137
|
|
|
158
|
-
interface StringLib {
|
|
159
138
|
/**
|
|
160
139
|
* Joins the values of a table together to form a string.
|
|
161
140
|
*
|
|
@@ -166,36 +145,28 @@ interface StringLib {
|
|
|
166
145
|
* @deprecated You really should just use table.concat.
|
|
167
146
|
*/
|
|
168
147
|
Implode(separator?: string, pieces?: table): string;
|
|
169
|
-
}
|
|
170
148
|
|
|
171
|
-
interface StringLib {
|
|
172
149
|
/**
|
|
173
150
|
* Interpolates a given string with the given table. This is useful for formatting localized strings.
|
|
174
151
|
* @realm shared and menu
|
|
175
152
|
* @source https://wiki.facepunch.com/gmod/string.Interpolate
|
|
176
153
|
*/
|
|
177
154
|
Interpolate(str: string, lookuptable: table): string;
|
|
178
|
-
}
|
|
179
155
|
|
|
180
|
-
interface StringLib {
|
|
181
156
|
/**
|
|
182
157
|
* Escapes special characters for JavaScript in a string, making the string safe for inclusion in to JavaScript strings.
|
|
183
158
|
* @realm shared and menu
|
|
184
159
|
* @source https://wiki.facepunch.com/gmod/string.JavascriptSafe
|
|
185
160
|
*/
|
|
186
161
|
JavascriptSafe(str: string): string;
|
|
187
|
-
}
|
|
188
162
|
|
|
189
|
-
interface StringLib {
|
|
190
163
|
/**
|
|
191
164
|
* Returns everything left of supplied place of that string.
|
|
192
165
|
* @realm shared and menu
|
|
193
166
|
* @source https://wiki.facepunch.com/gmod/string.Left
|
|
194
167
|
*/
|
|
195
168
|
Left(str: string, num: number): string;
|
|
196
|
-
}
|
|
197
169
|
|
|
198
|
-
interface StringLib {
|
|
199
170
|
/**
|
|
200
171
|
* Converts a `"string_likeThis"` to a more human-friendly `"String like This"`.
|
|
201
172
|
*
|
|
@@ -205,63 +176,49 @@ interface StringLib {
|
|
|
205
176
|
* @source https://wiki.facepunch.com/gmod/string.NiceName
|
|
206
177
|
*/
|
|
207
178
|
NiceName(text: string): string;
|
|
208
|
-
}
|
|
209
179
|
|
|
210
|
-
interface StringLib {
|
|
211
180
|
/**
|
|
212
181
|
* Converts a digital filesize to human-readable text.
|
|
213
182
|
* @realm shared and menu
|
|
214
183
|
* @source https://wiki.facepunch.com/gmod/string.NiceSize
|
|
215
184
|
*/
|
|
216
185
|
NiceSize(bytes: number): string;
|
|
217
|
-
}
|
|
218
186
|
|
|
219
|
-
interface StringLib {
|
|
220
187
|
/**
|
|
221
188
|
* Formats the supplied number (in seconds) to the highest possible time unit.
|
|
222
189
|
* @realm shared and menu
|
|
223
190
|
* @source https://wiki.facepunch.com/gmod/string.NiceTime
|
|
224
191
|
*/
|
|
225
192
|
NiceTime(num: number): string;
|
|
226
|
-
}
|
|
227
193
|
|
|
228
|
-
interface StringLib {
|
|
229
194
|
/**
|
|
230
195
|
* Escapes all special characters within a string, making the string safe for inclusion in a Lua pattern.
|
|
231
196
|
* @realm shared and menu
|
|
232
197
|
* @source https://wiki.facepunch.com/gmod/string.PatternSafe
|
|
233
198
|
*/
|
|
234
199
|
PatternSafe(str: string): string;
|
|
235
|
-
}
|
|
236
200
|
|
|
237
|
-
interface StringLib {
|
|
238
201
|
/**
|
|
239
202
|
* Replaces all occurrences of the supplied second string.
|
|
240
203
|
* @realm shared and menu
|
|
241
204
|
* @source https://wiki.facepunch.com/gmod/string.Replace
|
|
242
205
|
*/
|
|
243
206
|
Replace(str: string, find: string, replace: string): string;
|
|
244
|
-
}
|
|
245
207
|
|
|
246
|
-
interface StringLib {
|
|
247
208
|
/**
|
|
248
209
|
* Returns the last n-th characters of the string.
|
|
249
210
|
* @realm shared and menu
|
|
250
211
|
* @source https://wiki.facepunch.com/gmod/string.Right
|
|
251
212
|
*/
|
|
252
213
|
Right(str: string, num: number): string;
|
|
253
|
-
}
|
|
254
214
|
|
|
255
|
-
interface StringLib {
|
|
256
215
|
/**
|
|
257
216
|
* Sets the character at the specific index of the string.
|
|
258
217
|
* @realm shared and menu
|
|
259
218
|
* @source https://wiki.facepunch.com/gmod/string.SetChar
|
|
260
219
|
*/
|
|
261
220
|
SetChar(InputString: string, Index: number, ReplacementChar: string): string;
|
|
262
|
-
}
|
|
263
221
|
|
|
264
|
-
interface StringLib {
|
|
265
222
|
/**
|
|
266
223
|
* Splits the string into a table of strings, separated by the second argument.
|
|
267
224
|
* An alias of string.Explode, but with flipped arguments.
|
|
@@ -273,10 +230,7 @@ interface StringLib {
|
|
|
273
230
|
* @source https://wiki.facepunch.com/gmod/string.Split
|
|
274
231
|
*/
|
|
275
232
|
Split<Sep extends string, Str extends string>(Inputstring: ConstTpl<Str>, Separator: ConstTpl<Sep>): Split<Sep, Str>;
|
|
276
|
-
}
|
|
277
|
-
|
|
278
233
|
|
|
279
|
-
interface StringLib {
|
|
280
234
|
/**
|
|
281
235
|
* Returns whether or not the first string starts with the second. This is a alias of [string.StartsWith](https://wiki.facepunch.com/gmod/string.StartsWith).
|
|
282
236
|
* @realm shared and menu
|
|
@@ -284,18 +238,14 @@ interface StringLib {
|
|
|
284
238
|
* @deprecated Use string.StartsWith.
|
|
285
239
|
*/
|
|
286
240
|
StartWith(inputStr: string, start: string): boolean;
|
|
287
|
-
}
|
|
288
241
|
|
|
289
|
-
interface StringLib {
|
|
290
242
|
/**
|
|
291
243
|
* Returns whether or not the first string starts with the second.
|
|
292
244
|
* @realm shared and menu
|
|
293
245
|
* @source https://wiki.facepunch.com/gmod/string.StartsWith
|
|
294
246
|
*/
|
|
295
247
|
StartsWith(inputStr: string, start: string): boolean;
|
|
296
|
-
}
|
|
297
248
|
|
|
298
|
-
interface StringLib {
|
|
299
249
|
/**
|
|
300
250
|
* Removes the extension of a path.
|
|
301
251
|
*
|
|
@@ -305,9 +255,7 @@ interface StringLib {
|
|
|
305
255
|
* @source https://wiki.facepunch.com/gmod/string.StripExtension
|
|
306
256
|
*/
|
|
307
257
|
StripExtension(path: string): string;
|
|
308
|
-
}
|
|
309
258
|
|
|
310
|
-
interface StringLib {
|
|
311
259
|
/**
|
|
312
260
|
* Attempts to create a Color from a string.
|
|
313
261
|
*
|
|
@@ -315,27 +263,21 @@ interface StringLib {
|
|
|
315
263
|
* @source https://wiki.facepunch.com/gmod/string.ToColor
|
|
316
264
|
*/
|
|
317
265
|
ToColor(colorString: string): Color;
|
|
318
|
-
}
|
|
319
266
|
|
|
320
|
-
interface StringLib {
|
|
321
267
|
/**
|
|
322
268
|
* Returns given time in "MM:SS" format.
|
|
323
269
|
* @realm shared and menu
|
|
324
270
|
* @source https://wiki.facepunch.com/gmod/string.ToMinutesSeconds
|
|
325
271
|
*/
|
|
326
272
|
ToMinutesSeconds(time: number): string;
|
|
327
|
-
}
|
|
328
273
|
|
|
329
|
-
interface StringLib {
|
|
330
274
|
/**
|
|
331
275
|
* Returns given time in "MM:SS:MS" format.
|
|
332
276
|
* @realm shared and menu
|
|
333
277
|
* @source https://wiki.facepunch.com/gmod/string.ToMinutesSecondsMilliseconds
|
|
334
278
|
*/
|
|
335
279
|
ToMinutesSecondsMilliseconds(time: number): string;
|
|
336
|
-
}
|
|
337
280
|
|
|
338
|
-
interface StringLib {
|
|
339
281
|
/**
|
|
340
282
|
* Splits the string into characters and creates a sequential table of characters.
|
|
341
283
|
*
|
|
@@ -346,36 +288,28 @@ interface StringLib {
|
|
|
346
288
|
* @source https://wiki.facepunch.com/gmod/string.ToTable
|
|
347
289
|
*/
|
|
348
290
|
ToTable(str: string): table;
|
|
349
|
-
}
|
|
350
291
|
|
|
351
|
-
interface StringLib {
|
|
352
292
|
/**
|
|
353
293
|
* Removes leading and trailing matches of a string.
|
|
354
294
|
* @realm shared and menu
|
|
355
295
|
* @source https://wiki.facepunch.com/gmod/string.Trim
|
|
356
296
|
*/
|
|
357
297
|
Trim(Inputstring: string, Char?: string): string;
|
|
358
|
-
}
|
|
359
298
|
|
|
360
|
-
interface StringLib {
|
|
361
299
|
/**
|
|
362
300
|
* Removes leading spaces/characters from a string.
|
|
363
301
|
* @realm shared and menu
|
|
364
302
|
* @source https://wiki.facepunch.com/gmod/string.TrimLeft
|
|
365
303
|
*/
|
|
366
304
|
TrimLeft(str: string, char?: string): string;
|
|
367
|
-
}
|
|
368
305
|
|
|
369
|
-
interface StringLib {
|
|
370
306
|
/**
|
|
371
307
|
* Removes trailing spaces/passed character from a string.
|
|
372
308
|
* @realm shared and menu
|
|
373
309
|
* @source https://wiki.facepunch.com/gmod/string.TrimRight
|
|
374
310
|
*/
|
|
375
311
|
TrimRight(str: string, char?: string): string;
|
|
376
|
-
}
|
|
377
312
|
|
|
378
|
-
interface StringLib {
|
|
379
313
|
/**
|
|
380
314
|
* Returns the given string's characters in their numeric ASCII representation.
|
|
381
315
|
* **WARNING**: This function will throw an error if the slice length is greater than 8000 characters.
|
|
@@ -385,18 +319,14 @@ interface StringLib {
|
|
|
385
319
|
* @source https://wiki.facepunch.com/gmod/string.byte
|
|
386
320
|
*/
|
|
387
321
|
byte(string: string, startPos?: number, endPos?: number): (...any);
|
|
388
|
-
}
|
|
389
322
|
|
|
390
|
-
interface StringLib {
|
|
391
323
|
/**
|
|
392
324
|
* Takes the given numerical bytes and converts them to a string.
|
|
393
325
|
* @realm shared and menu
|
|
394
326
|
* @source https://wiki.facepunch.com/gmod/string.char
|
|
395
327
|
*/
|
|
396
328
|
char(...: any): string;
|
|
397
|
-
}
|
|
398
329
|
|
|
399
|
-
interface StringLib {
|
|
400
330
|
/**
|
|
401
331
|
* Returns the binary bytecode of the given function.
|
|
402
332
|
*
|
|
@@ -407,9 +337,7 @@ interface StringLib {
|
|
|
407
337
|
* @source https://wiki.facepunch.com/gmod/string.dump
|
|
408
338
|
*/
|
|
409
339
|
dump(func: function, stripDebugInfo?: boolean): string;
|
|
410
|
-
}
|
|
411
340
|
|
|
412
|
-
interface StringLib {
|
|
413
341
|
/**
|
|
414
342
|
* Attempts to find the specified substring in a string.
|
|
415
343
|
*
|
|
@@ -420,18 +348,14 @@ interface StringLib {
|
|
|
420
348
|
* @source https://wiki.facepunch.com/gmod/string.find
|
|
421
349
|
*/
|
|
422
350
|
find(haystack: string, needle: string, startPos?: number, noPatterns?: boolean): (number, number, string);
|
|
423
|
-
}
|
|
424
351
|
|
|
425
|
-
interface StringLib {
|
|
426
352
|
/**
|
|
427
353
|
* Formats the specified values into the string given.
|
|
428
354
|
* @realm shared and menu
|
|
429
355
|
* @source https://wiki.facepunch.com/gmod/string.format
|
|
430
356
|
*/
|
|
431
357
|
format(format: string, ...: any): string;
|
|
432
|
-
}
|
|
433
358
|
|
|
434
|
-
interface StringLib {
|
|
435
359
|
/**
|
|
436
360
|
* Returns an iterator function that is called for every complete match of the pattern, all sub matches will be passed as to the loop.
|
|
437
361
|
* @realm shared and menu
|
|
@@ -439,18 +363,14 @@ interface StringLib {
|
|
|
439
363
|
* @deprecated This function is removed in Lua versions later than what GMod is currently using. Use string.gmatch instead.
|
|
440
364
|
*/
|
|
441
365
|
gfind(data: string, pattern: string): function;
|
|
442
|
-
}
|
|
443
366
|
|
|
444
|
-
interface StringLib {
|
|
445
367
|
/**
|
|
446
368
|
* Using [Patterns](https://wiki.facepunch.com/gmod/Patterns), returns an iterator which will return either one value if no capture groups are defined, or any capture group matches.
|
|
447
369
|
* @realm shared and menu
|
|
448
370
|
* @source https://wiki.facepunch.com/gmod/string.gmatch
|
|
449
371
|
*/
|
|
450
372
|
gmatch(data: string, pattern: string): function;
|
|
451
|
-
}
|
|
452
373
|
|
|
453
|
-
interface StringLib {
|
|
454
374
|
/**
|
|
455
375
|
* Replaces certain character sequences in a string using Patterns.
|
|
456
376
|
*
|
|
@@ -461,19 +381,14 @@ interface StringLib {
|
|
|
461
381
|
* @source https://wiki.facepunch.com/gmod/string.gsub
|
|
462
382
|
*/
|
|
463
383
|
gsub(string: string, pattern: string, replacement: string | table | ((...: string) => string), maxReplaces?: number): (string, number);
|
|
464
|
-
}
|
|
465
384
|
|
|
466
|
-
|
|
467
|
-
interface StringLib {
|
|
468
385
|
/**
|
|
469
386
|
* Counts the number of characters in the string (length). This is equivalent to using the length operator (#).
|
|
470
387
|
* @realm shared and menu
|
|
471
388
|
* @source https://wiki.facepunch.com/gmod/string.len
|
|
472
389
|
*/
|
|
473
390
|
len(str: string): number;
|
|
474
|
-
}
|
|
475
391
|
|
|
476
|
-
interface StringLib {
|
|
477
392
|
/**
|
|
478
393
|
* Changes any upper-case letters in a string to lower-case letters.
|
|
479
394
|
* **NOTE**: This function doesn't work on special non-English UTF-8 characters.
|
|
@@ -483,45 +398,35 @@ interface StringLib {
|
|
|
483
398
|
* @source https://wiki.facepunch.com/gmod/string.lower
|
|
484
399
|
*/
|
|
485
400
|
lower(str: string): string;
|
|
486
|
-
}
|
|
487
401
|
|
|
488
|
-
interface StringLib {
|
|
489
402
|
/**
|
|
490
403
|
* Finds a [Pattern](https://wiki.facepunch.com/gmod/Patterns) in a string.
|
|
491
404
|
* @realm shared and menu
|
|
492
405
|
* @source https://wiki.facepunch.com/gmod/string.match
|
|
493
406
|
*/
|
|
494
407
|
match(string: string, pattern: string, startPosition?: number): (...any);
|
|
495
|
-
}
|
|
496
408
|
|
|
497
|
-
interface StringLib {
|
|
498
409
|
/**
|
|
499
410
|
* Repeats a string by the provided number, with an optional separator.
|
|
500
411
|
* @realm shared and menu
|
|
501
412
|
* @source https://wiki.facepunch.com/gmod/string.rep
|
|
502
413
|
*/
|
|
503
414
|
rep(str: string, repetitions: number, separator?: string): string;
|
|
504
|
-
}
|
|
505
415
|
|
|
506
|
-
interface StringLib {
|
|
507
416
|
/**
|
|
508
417
|
* Reverses a string.
|
|
509
418
|
* @realm shared and menu
|
|
510
419
|
* @source https://wiki.facepunch.com/gmod/string.reverse
|
|
511
420
|
*/
|
|
512
421
|
reverse(str: string): string;
|
|
513
|
-
}
|
|
514
422
|
|
|
515
|
-
interface StringLib {
|
|
516
423
|
/**
|
|
517
424
|
* Returns a sub-string, starting from the character at position `StartPos` of the string (inclusive), and optionally ending at the character at position `EndPos` of the string (also inclusive). If EndPos is not given, the rest of the string is returned.
|
|
518
425
|
* @realm shared and menu
|
|
519
426
|
* @source https://wiki.facepunch.com/gmod/string.sub
|
|
520
427
|
*/
|
|
521
428
|
sub(string: string, StartPos: number, EndPos?: number): string;
|
|
522
|
-
}
|
|
523
429
|
|
|
524
|
-
interface StringLib {
|
|
525
430
|
/**
|
|
526
431
|
* Changes any lower-case letters in a string to upper-case letters.
|
|
527
432
|
* **NOTE**: This function doesn't work on special non-English UTF-8 characters.
|
|
@@ -532,4 +437,3 @@ interface StringLib {
|
|
|
532
437
|
*/
|
|
533
438
|
upper(str: string): string;
|
|
534
439
|
}
|
|
535
|
-
|
package/types/structures.d.tlua
CHANGED
|
@@ -1128,7 +1128,6 @@ interface EntityCopyData {
|
|
|
1128
1128
|
WorkshopID?: number;
|
|
1129
1129
|
}
|
|
1130
1130
|
|
|
1131
|
-
|
|
1132
1131
|
/**
|
|
1133
1132
|
* The table structure used for bullets that have already been fired.
|
|
1134
1133
|
*
|
|
@@ -1409,7 +1408,6 @@ interface HTTPRequestWithoutParameters extends HTTPRequest {
|
|
|
1409
1408
|
parameters: nil;
|
|
1410
1409
|
}
|
|
1411
1410
|
|
|
1412
|
-
|
|
1413
1411
|
/**
|
|
1414
1412
|
* Table used by util.TraceHull.
|
|
1415
1413
|
* @realm shared
|
|
@@ -1444,7 +1442,6 @@ interface HullTrace {
|
|
|
1444
1442
|
hitclientonly?: boolean;
|
|
1445
1443
|
}
|
|
1446
1444
|
|
|
1447
|
-
|
|
1448
1445
|
/**
|
|
1449
1446
|
* Table structure used for [render.SetLocalModelLights](https://wiki.facepunch.com/gmod/render.SetLocalModelLights).
|
|
1450
1447
|
* @realm client
|
|
@@ -3148,7 +3145,6 @@ interface SoundData {
|
|
|
3148
3145
|
pitchend?: number;
|
|
3149
3146
|
}
|
|
3150
3147
|
|
|
3151
|
-
|
|
3152
3148
|
/**
|
|
3153
3149
|
* Table describing a sound hint, used by [NPC:GetBestSoundHint](https://wiki.facepunch.com/gmod/NPC:GetBestSoundHint) and [sound.GetLoudestSoundHint](https://wiki.facepunch.com/gmod/sound.GetLoudestSoundHint).
|
|
3154
3150
|
* @realm server
|
|
@@ -3380,7 +3376,6 @@ interface Tool {
|
|
|
3380
3376
|
RightClickAutomatic?: boolean;
|
|
3381
3377
|
}
|
|
3382
3378
|
|
|
3383
|
-
|
|
3384
3379
|
/**
|
|
3385
3380
|
* Table is one element from [team.GetAllTeams](https://wiki.facepunch.com/gmod/team.GetAllTeams).
|
|
3386
3381
|
* @realm shared
|
|
@@ -3523,7 +3518,6 @@ interface Trace {
|
|
|
3523
3518
|
hitclientonly?: boolean;
|
|
3524
3519
|
}
|
|
3525
3520
|
|
|
3526
|
-
|
|
3527
3521
|
/**
|
|
3528
3522
|
* Table structure used as trace result. Default values are when the trace hits nothing.
|
|
3529
3523
|
*
|
|
@@ -4439,4 +4433,3 @@ interface ViewSetup {
|
|
|
4439
4433
|
*/
|
|
4440
4434
|
offcenter: table;
|
|
4441
4435
|
}
|
|
4442
|
-
|