Jump to content

AdiBoy

Members
  • Posts

    9
  • Joined

  • Last visited

Details

  • Gang
    SKC

AdiBoy's Achievements

Newbie

Newbie (4/54)

0

Reputation

  1. or you could use the simple, faster way: addEventHandler("onPlayerReachCheckpoint", getRootElement(), function(cp_number) blah blah blah, your code here, cp_number is the cp the player hit end )
  2. here: https://wiki.multitheftauto.com/wiki/Get ... ceRotation
  3. have you tried the SKC Race Server? pure racing in there with some fun/boomage maps its true that not a lot of ppl can win against SKC guys and i think SKC being a 4-year old Racing Clan has something to do with it but its still fun lots of car mods, lots of scripts, great maps; fast connection for those who fear the big downloads server ip: teamskc.co.uk port: 22003 website: http://www.teamskc.co.uk
  4. move "local gui = {}" above "function build_Form( commandName, typ )" like this: local gui = {} function build_Form( commandName, typ ) if (typ == "stworz") then showCursor ( true, true ) gui._placeHolders = {} local screenWidth, screenHeight = guiGetScreenSize() local windowWidth, windowHeight = 451, 238 local left = screenWidth/2 - windowWidth/2 local top = screenHeight/2 - windowHeight/2 gui["_root"] = guiCreateWindow(left, top, windowWidth, windowHeight, "Tworzenie nowego biznesu cz. 1", false) guiWindowSetSizable(gui["_root"], false) gui["pushButton"] = guiCreateButton(80, 205, 75, 23, "Ok", false, gui["_root"]) gui["pushButton_2"] = guiCreateButton(290, 205, 75, 23, "Anuluj", false, gui["_root"]) gui["lineEdit"] = guiCreateEdit(10, 45, 431, 20, "", false, gui["_root"]) guiEditSetMaxLength(gui["lineEdit"], 32767) gui["label"] = guiCreateLabel(20, 25, 46, 13, "Nazwa", false, gui["_root"]) guiLabelSetHorizontalAlign(gui["label"], "left", false) guiLabelSetVerticalAlign(gui["label"], "center") gui["radioButton"] = guiCreateRadioButton(40, 105, 41, 17, "Bar", false, gui["_root"]) gui["radioButton_2"] = guiCreateRadioButton(40, 125, 51, 17, "Hotel", false, gui["_root"]) gui["radioButton_3"] = guiCreateRadioButton(40, 145, 51, 17, "Sklep", false, gui["_root"]) gui["label_2"] = guiCreateLabel(20, 85, 46, 13, "Typ", false, gui["_root"]) guiLabelSetHorizontalAlign(gui["label_2"], "left", false) guiLabelSetVerticalAlign(gui["label_2"], "center") gui["radioButton_4"] = guiCreateRadioButton(130, 105, 82, 17, "Bank", false, gui["_root"]) gui["radioButton_5"] = guiCreateRadioButton(130, 125, 82, 17, "Komisariat", false, gui["_root"]) gui["radioButton_6"] = guiCreateRadioButton(130, 145, 82, 17, "Klub", false, gui["_root"]) addEventHandler ( "onClientGUIClick", gui["pushButton_2"], guiAnulujClick, false) return gui, windowWidth, windowHeight end end addCommandHandler ( "biznes", build_Form ) function guiAnulujClick ( ) guiSetVisible ( gui["_root"], false ) showCursor (false) end
  5. that happends bcoz your "gui" variable is set locally in your build_form function and so the other function, guiAnulujClick doesnt know about it, you have to declare it at the top of the script, outside of any functions
  6. AdiBoy

    SQL Question

    oh, but alter table works, i've used it before, im still using it when updating my scripts get the admin panel up, resources tab and execute this command: executeSQLQuery( "ALTER TABLE ADD COLUMN (size) DEFAULT " ) the DEFAULT option is not mandatory, you can skip it but you might also find it useful
  7. the generated meta.xml should also contain: type="map" in the info tag and im not sure if this is a mistake or it works like this too but instead of gamemode="race" it should be gamemodes="race" also in the tag it adds dimension="0", this makes the map not run on my servers, so in case this is not a personal bug you should remove that in the lua script i think there was a typo: engineLoadCol instead of engineLoadCOL, same typo for engineReplaceCOL also in the .map file instead of generating it sets it to "deathmatch" hope this helps
  8. try something like this: local result = executeSQLQuery( "SELECT score FROM table WHERE nick=players_nick" ) local rank = #executeSQLQuery( "SELECT score FROM table WHERE score>=" .. result[1]["score"] ) the variable 'rank' will give you his rank... this is how i use it on the skc servers and it works just fine
  9. hey, the gui works fine for me too.. i made the PM window for the SKC DD/DM server and its not a final release so it might still have bugs it worked fine for me, couldnt see the bug happening so cant really tell you why u had the pm window bugs..
×
×
  • Create New...