Module ExpGamingCore.Gui
Adds a objective version to custom guis.
Info:
- License: https://github.com/explosivegaming/scenario/blob/master/LICENSE
- Author: Cooldude2606
data |
Used to set and get data about different guis |
_comment () |
This file will be loaded when ExpGamingCore.Command is present |
__comment () |
Adds a server thread that allows the camera follows to be toggled off and on |
-
bar (frame[, width=10])
-
Add a white bar to any gui frame
Parameters:
- frame
the frame to draw the line to
- width
the width of the bar
(default 10)
Returns:
the line that was made type is progressbar
Usage:
Gui.bar(frame,100)
-
set_dropdown_index (dropdown, _item)
-
Used to set the index of a drop down to a certian item
Parameters:
- dropdown
the dropdown that is to be effected
- _item
this is the item to look for
Returns:
returns the dropdown if it was successful
Usage:
Gui.set_dropdown_index(dropdown,player.name)
-
cam_link (data)
-
Adds a camera that updates every tick (or less depeading on how many are opening) it will move to follow an entity
Parameters:
- data
table
contains all other params given below
Returns:
the camera that the function used be it made or given as a param
Usage:
Gui.cam_link{entity=game.player.character,frame=frame,width=50,hight=50,zoom=1}
Gui.cam_link{entity=game.player.character,cam=frame.camera,surface=game.surfaces['testing']}
-
events
-
Stores all the on_player_joined_game event handlers for the guis
-
ParametersForCamLink
-
Prams for Gui.cam_link
Fields:
- entity
this is the entity that the camera will follow
- cam
a camera that you already have in the gui
- frame
the frame to add the camera to, no effect if cam param is given
- zoom
the zoom to give the new camera
- width
the width to give the new camera
- height
the height to give the new camera
- surface
this will over ride the surface that the camera follows on, allowing for a 'ghost surface' while keeping same position
- respawn_open
if set to true then the camera will auto re link to the player after a respawn
-
data
-
Used to set and get data about different guis
- location
string
the location to get/set the data, center left etc...
- key
string
the name of the gui to set the value of
(optional)
- value
the data that will be set can be any value but table advised
(optional)
Usage:
-
_comment ()
-
This file will be loaded when ExpGamingCore.Command is present
-
__comment ()
-
Adds a server thread that allows the camera follows to be toggled off and on