LotSys Init

Events


Map initialization

Conditions

Actions


Custom script: set udg_LotSys_LineBreak = "\n"


-------- Random Range --------


Set LotSys_RandomRange[0] = 0


Set LotSys_RandomRange[1] = 2


-------- Maximum bet --------


Set LotSys_MaxBet = 2000


-------- Draw Count --------


Set LotSys_DrawCount = 5


-------- Prize --------


Set LotSys_PrizeMultiplier = 2


-------- Seperator ex. 2/500 or 2-500 (2 is your number 500 is your bet) --------


Set LotSys_Seperator = /


-------- Messages --------


Set LotSys_Messages[0] = Invalid Input


Set LotSys_Messages[1] = Your number is


Set LotSys_Messages[2] = Your bet is


Set LotSys_Messages[3] = Drawing...


Set LotSys_Messages[4] = You Won


Set LotSys_Messages[5] = You Loose


Set LotSys_Messages[6] = Has won
LotSys Dialog

Events


Player - Player 1 (Red) skips a cinematic sequence


Player - Player 2 (Blue) skips a cinematic sequence


Player - Player 3 (Teal) skips a cinematic sequence

Conditions

Actions


Dialog - Clear LotSys_Dialog


Dialog - Change the title of LotSys_Dialog to (Gold: + (String(((Triggering player) Current gold))))


Dialog - Create a dialog button for LotSys_Dialog labelled Type Bet ex. 1-200...


Set LotSys_DialogButtons[(Player number of (Triggering player))] = (Last created dialog Button)


Dialog - Show LotSys_Dialog for (Triggering player)
LotSys Dialog Buttons

Events


Dialog - A dialog button is clicked for LotSys_Dialog

Conditions

Actions


If (All Conditions are True) then do (Then Actions) else do (Else Actions)



If - Conditions




(Clicked dialog button) Equal to LotSys_DialogButtons[(Player number of (Triggering player))]



Then - Actions




Set LotSys_Typing[(Player number of (Triggering player))] = True




Game - Display to (Player group((Triggering player))) the text: (Please type + ((# + LotSys_Seperator) + Bet to draw.))



Else - Actions
LotSys Set and Draw

Events


Player - Player 1 (Red) types a chat message containing <Empty String> as A substring


Player - Player 2 (Blue) types a chat message containing <Empty String> as A substring


Player - Player 3 (Teal) types a chat message containing <Empty String> as A substring

Conditions


LotSys_Typing[(Player number of (Triggering player))] Equal to True

Actions


If (All Conditions are True) then do (Then Actions) else do (Else Actions)



If - Conditions




And - All (Conditions) are true





Conditions






((Triggering player) Current gold) Greater than or equal to (Integer((Substring((Entered chat string), 3, (3 + (Length of (String(LotSys_MaxBet))))))))






(Integer((Substring((Entered chat string), 1, 1)))) Greater than or equal to 0






(Substring((Entered chat string), 2, 2)) Equal to LotSys_Seperator






(Integer((Substring((Entered chat string), 3, (3 + (Length of (String(LotSys_MaxBet)))))))) Less than or equal to LotSys_MaxBet






LotSys_Typing[(Player number of (Triggering player))] Equal to True



Then - Actions




Set LotSys_Typing[(Player number of (Triggering player))] = False




Set LotSys_Number[(Player number of (Triggering player))] = (Integer((Substring((Entered chat string), 1, 1))))




Set LotSys_Bet[(Player number of (Triggering player))] = (Integer((Substring((Entered chat string), 3, (3 + (Length of (String(LotSys_MaxBet))))))))




Game - Display to (Player group((Triggering player))) the text: ((LotSys_Messages[1] + (String(LotSys_Number[(Player number of (Triggering player))]))) + (LotSys_LineBreak + (LotSys_Messages[2] + (String(LotSys_Bet[(Player number of (Triggering player))])))))




Game - Display to (Player group((Triggering player))) the text: LotSys_Messages[3]




For each (Integer A) from 0 to LotSys_DrawCount, do (Actions)





Loop - Actions






Set LotSys_Result[(Player number of (Triggering player))] = (Random integer number between LotSys_RandomRange[0] and LotSys_RandomRange[1])






Game - Display to (Player group((Triggering player))) the text: (String(LotSys_Result[(Player number of (Triggering player))]))




Game - Display to (Player group((Triggering player))) the text: (Final Result + (String(LotSys_Result[(Player number of (Triggering player))])))




If (All Conditions are True) then do (Then Actions) else do (Else Actions)





If - Conditions






LotSys_Number[(Player number of (Triggering player))] Equal to LotSys_Result[(Player number of (Triggering player))]





Then - Actions






Player - Add (LotSys_Bet[(Player number of (Triggering player))] x LotSys_PrizeMultiplier) to (Triggering player) Current gold






Game - Display to (Player group((Triggering player))) the text: (LotSys_Messages[4] + (String((LotSys_Bet[(Player number of (Triggering player))] x LotSys_PrizeMultiplier))))






Game - Display to (All players) the text: ((Name of (Triggering player)) + (LotSys_Messages[6] + (String((LotSys_Bet[(Player number of (Triggering player))] x LotSys_PrizeMultiplier)))))





Else - Actions






Player - Set (Triggering player) Current gold to (((Triggering player) Current gold) - (Integer((Substring((Entered chat string), 3, (3 + (Length of (String(LotSys_MaxBet)))))))))






Game - Display to (Player group((Triggering player))) the text: LotSys_Messages[5]



Else - Actions




Game - Display to (Player group((Triggering player))) the text: (LotSys_Messages[0] + ( + ((Entered chat string) + (LotSys_LineBreak + Press ESC again.))))
Update Reloaded v1.0Major Update v1.0 Changes.
-Major All Changed