Jump to content

Izanagi

Members
  • Posts

    19
  • Joined

  • Last visited

Izanagi's Achievements

Square

Square (6/54)

0

Reputation

  1. I try to do that, and ye i fixed them i'm glad that forums are alive it's been a while since i scripted, hehe off to bed and then gonna make blackjack script got guy and images done already, what is left is the way it works. goodnight
  2. here you have an example of a lazy man who doesn't check his scripts thoroughly. don't be like him (me)
  3. kk /me has fixed that somehow for some reason the fixing of diceChosen to dieChosen fixed this. still getting warnings or killtimer function, tho... the one when 'resetTimer' has a nil value and killTimer is called with a nil value, not sure why my if doesn't work tho doesn't matter tho, still works nicely
  4. reply nope, that's just the function's name 'testPlay' it's 'requestPlay' clientside as well as in addEvent
  5. line 39 fixed, uploaded old code. i'll check the first issue you mentioned again.
  6. what is wrong is that the gui dice images won't change and the gamble_hotResultLabel won't change it's name the givemoney server-side works, but I think the trigger server-side which calls the result client-side doesn't trigger the clientside events, which would result in the problem i am at. I am not sure what should I do to fix it thom as i don't see anything that may be wrong, but i am 100% sure that i am wrong. i have done a similair 'kitsune bakuchi' script with 3 dices, and it works just nicely, but this, on the other hand, does not.
  7. scripts: cs http://pastebin.com/m7759f8a9 ss http://pastebin.com/m771a024
  8. solution found to everything - quit scripting MTA sadly, but too small time is left for me to actually have scripting done as I have studies and they're hard
  9. okay, no more warnings but could anyone help me to make the scripts work? I mean server-side. I would like to know what should I do to get the desired result like login/register i'll think of a way for recovery later
  10. okay, first I didn't say that tehy don't mean anything. and those are warnings. let me qoute it.. WARNING: c.base.lua: bad argument @ 'addEventHandler' - Line:112 same for lines 113 and 114. the handlers I add onguiclick... wonder what's wrong. it's the lines 86,87,88 in the script provided by me in the first post, it has diffrent line numbers as i've changed something in the create function and it works just fine now. I am new to lua+mta so i need help handling things. please guide me what did I do wrong EDIT: oh yeah, and i've added the three handlers for the addEventHandler functions
  11. yeah okay. That solved it but now with /debugscript 3 it displays that there are errors in the cient script where I add event handlers. and about the values, i'll see into it that they use less memory which I will do (if is possible) so make me shut up because I don't know what I am telling, but the thing is now that the addEventHandler is giving errors in the debugscript 3.. what do I do now?
  12. Alright, I got a problem with gui. it won't create properly. I am using tab panel with 3 tabs and stuff in there, but it only creates the tab panel + first tab and then it won't do anything after those lines. I am posting my client script. It is all in one file at the moment as I have started scripting about 53 minutes ago. ANyways, here it is: client: local root = getRootElement() local loc = getLocalPlayer() function createAuthWindow() tpAuth = {} GUIEditor_Edit = {} tpAuth[1] = guiCreateTabPanel(583,317,187,159,false) authTab[1] = guiCreateTab("Register",tpAuth[1]) regLabel[1] = guiCreateLabel(0.05,0.1,0.4,0.1,"Username* :",true,authTab[1]) guiLabelSetColor(regLabel[1],255,255,255) guiLabelSetVerticalAlign(regLabel[1],"center") guiLabelSetHorizontalAlign(regLabel[1],"right",false) regLabel[2] = guiCreateLabel(0.05,0.3,0.4,0.1,"Password* :",true,authTab[1]) guiLabelSetColor(regLabel[2],255,255,255) guiLabelSetVerticalAlign(regLabel[2],"center") guiLabelSetHorizontalAlign(regLabel[2],"right",false) regLabel[3] = guiCreateLabel(0.05,0.5,0.4,0.1,"Repeat* :",true,authTab[1]) guiLabelSetColor(regLabel[3],255,255,255) guiLabelSetVerticalAlign(regLabel[3],"center") guiLabelSetHorizontalAlign(regLabel[3],"right",false) regEdit[1] = guiCreateEdit(0.5,0.1,0.4,0.15,"",true,authTab[1]) guiEditSetMaxLength(regEdit[1],24) regEdit[2] = guiCreateEdit(0.5,0.3,0.4,0.15,"",true,authTab[1]) guiEditSetMasked(regEdit[2],true) guiEditSetMaxLength(regEdit[2],16) regEdit[3] = guiCreateEdit(0.5,0.5,0.4,0.15,"",true,authTab[1]) guiEditSetMasked(regEdit[3],true) guiEditSetMaxLength(regEdit[3],16) regButton[1] = guiCreateButton(0.3,0.75,0.4,0.2,"Register",true,authTab[1]) authTab[2] = guiCreateTab("Login",tpAuth[1]) logLabel[1] = guiCreateLabel(0.05,0.1,0.4,0.1,"Username :",true,authTab[2]) guiLabelSetColor(logLabel[1],255,255,255) guiLabelSetVerticalAlign(logLabel[1],"center") guiLabelSetHorizontalAlign(logLabel[1],"right",false) logLabel[2] = guiCreateLabel(0.05,0.3,0.4,0.1,"Password :",true,authTab[2]) guiLabelSetColor(logLabel[2],255,255,255) guiLabelSetVerticalAlign(logLabel[2],"center") guiLabelSetHorizontalAlign(logLabel[2],"right",false) logEdit[1] = guiCreateEdit(0.5,0.1,0.4,0.15,"",true,authTab[2]) guiEditSetMaxLength(logEdit[1],24) logEdit[2] = guiCreateEdit(0.5,0.3,0.4,0.15,"",true,authTab[2]) guiEditSetMasked(logEdit[2],true) guiEditSetMaxLength(logEdit[2],16) logCheckbox[1] = guiCreateCheckBox(0.1,0.55,0.8,0.1,"Remember me",false,true,authTab[2]) logCheckbox[2] = guiCreateCheckBox(0.1,0.65,0.8,0.1,"Auto login",false,true,authTab[2]) logButton[1] = guiCreateButton(0.3,0.85,0.4,0.1,"Login",true,authTab[2]) authTab[3] = guiCreateTab("Recovery",tpAuth[1]) --GUIEditor_Edit[1] = guiCreateEdit(0.4545,1.1136,0,0,"",true,authTab[3]) recLabel[1] = guiCreateLabel(0.1,0.1,0.8,0.1,"Unique User ID",true,authTab[3]) guiLabelSetColor(recLabel[1],255,255,255) guiLabelSetVerticalAlign(recLabel[1],"center") guiLabelSetHorizontalAlign(recLabel[1],"center",false) recLabel[2] = guiCreateLabel(0.1,0.4,0.8,0.1,"New Password",true,authTab[3]) guiLabelSetColor(recLabel[2],255,255,255) guiLabelSetVerticalAlign(recLabel[2],"center") guiLabelSetHorizontalAlign(recLabel[2],"center",false) recEdit[1] = guiCreateEdit(0.2,0.25,0.6,0.15,"",true,authTab[3]) recEdit[2] = guiCreateEdit(0.2,0.55,0.6,0.15,"",true,authTab[3]) guiEditSetMaxLength(recEdit[2],16) recButton[1] = guiCreateButton(0.2,0.8,0.6,0.15,"Set Password",true,authTab[3]) end addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), function () createAuthWindow() guiSetVisible(tpAuth, true) outputChatBox("test after show") showCursor(true) guiSetInputEnabled(true) end ) function clientSubmitLogin(button) if button == "left" then triggerServerEvent("SubmitLogin", root, guiGetText(logEdit[1]), guiGetText(logEdit[2])) guiSetInputEnabled(false) guiSetVisible(tpAuth[1], false) showCursor(false) end end addEventHandler("onClientGUIClick", regButton[1], clientSubmitRegister, false) addEventHandler("onClientGUIClick", logButton[1], clientSubmitLogin, false) addEventHandler("onClientGUIClick", recButton[1], clientSubmitRecovery, false) what is wrong with the code, tell me! I used the Gui Edit to generate gui code..
  13. how do you guys export it? I can't seem to make it work, I get '--- ---- ---' etc etc in the output file ;/
  14. Atleast the connection was similair for everyone so each understood another. that's great
×
×
  • Create New...