mCasino
mCasino API
Functions
setRootPanel
This item only works when running on the client. ClientmCasino.setRootPanel(panelName: string) → ()Sets the given panel name as a root panel
getRootPanel
This item only works when running on the client. ClientmCasino.getRootPanel(panel: DPanel) → DPanelTraverses the panel's parents until a registered root panel is found
getRootPlayer
This item only works when running on the client. ClientTraverses the panel's parents until a registered root panel is found and returns the player based on its entity or local
getRootEntity
This item only works when running on the client. ClientmCasino.getRootEntity(panel: DPanel) → Entity?Traverses the panel's parents until a registered root panel is found and returns the entity if found
setPanel
This item only works when running on the client. ClientmCasino.setPanel(panel: DPanel,gameId?: string) → ()Registers the panel to receive updates through the SendUpdate() method. This should be set when the panel is created, and deregistered (set gameId to nil) when the panel is removed
setPanelOverride
This item only works when running on the client. ClientmCasino.setPanelOverride(panel: string,--
Panel to override e.g. mCasino_crash
newPanel: string--
Panel to use instead e.g. mCasino_devKit_crash
) → ()Overrides the default panels used in mCasino with your own
alert
This item only works when running on the client. ClientmCasino.alert(title: string,message: string) → ()Shows an alert popup to the user
notify
This item only works when running on the server. ServermCasino.notify(type: number,--
1 = popup, 2 = animated popup
duration: number,title: string,message: string) → ()Shows an alert popup to the user
getLang
mCasino.getLang(translationId: string) → ()Returns the translation for a given ID based on the selected language