Ulysses
Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Home
Help
Search
Login
Register
Ulysses
»
Ulysses Stuff
»
General Chat & Help and Support
»
help ulx, lua
« previous
next »
Print
Pages: [
1
]
Go Down
Author
Topic: help ulx, lua (Read 614 times)
0 Members and 1 Guest are viewing this topic.
$VDFOREVER
Newbie
Posts: 9
Karma: 0
help ulx, lua
«
on:
July 27, 2020, 08:24:14 AM »
Help in lua, I'm a complete zero, I need to move there when I execute (sorry google translate)
Code: Lua
local
CATEGORY_NAME
=
"admin"
function
ulx
.
adminzone
(
ply
)
local
str
=
"#A tp admin zone"
ulx
.
fancyLogAdmin
(
ply
,
str
)
end
local
adminzone
=
ulx
.
command
(
CATEGORY_NAME
,
"ulx az"
,
ulx
.
adminzone
,
"!az"
)
adminzone
:
defaultAccess
(
ULib
.
ACCESS_ADMIN
)
adminzone
:
help
(
"tp admin zone"
)
function
adminzone
(
ply
)
ply
:
SetPos
(
Vector
(
-
1244.353638
,
1044.383301
,
80.597824
)
)
-- admin zone position
end
Logged
MrPresident
Ulysses Team Member
Hero Member
Posts: 2734
Karma: 427
Re: help ulx, lua
«
Reply #1 on:
July 29, 2020, 05:51:21 PM »
Code: Lua
local
CATEGORY_NAME
=
"admin"
function
ulx
.
adminzone
(
ply
)
local
str
=
"#A tp admin zone"
ulx
.
fancyLogAdmin
(
ply
,
str
)
adminzone
(
ply
)
end
local
adminzone
=
ulx
.
command
(
CATEGORY_NAME
,
"ulx az"
,
ulx
.
adminzone
,
"!az"
)
adminzone
:
defaultAccess
(
ULib
.
ACCESS_ADMIN
)
adminzone
:
help
(
"tp admin zone"
)
function
adminzone
(
ply
)
ply
:
SetPos
(
Vector
(
-
1244.353638
,
1044.383301
,
80.597824
)
)
-- admin zone position
end
Logged
MrPresident
Ulysses Team Member
Hero Member
Posts: 2734
Karma: 427
Re: help ulx, lua
«
Reply #2 on:
July 29, 2020, 05:52:07 PM »
You were close. You just needed to call that function you created to teleport the player.
Logged
Print
Pages: [
1
]
Go Up
« previous
next »
Ulysses
»
Ulysses Stuff
»
General Chat & Help and Support
»
help ulx, lua