Jump to content

Castillo

Retired Staff
  • Posts

    21,935
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Castillo

  1. I guess there is no requesting section you got the chance to learn all by yourself and when got in problems ask here for help https://wiki.multitheftauto.com/wiki/Main_Page
  2. This isn't a requesting forum, here we help you to fix your scripts/detect errors.
  3. it outputs at debugscript this, got values: 866 and 0 sending values: 866 and 0
  4. ... i think you don't get what i want to mean, i will explain again, i have a whole menu where you can see your kills deaths rank level etc well there it shows the zombiekills value.
  5. Castillo

    Car Team

    no, i was thinking also why he said that...
  6. well, i can get the data then trigger it to client and set a label with that data but then when using it with ratio it fails saying its a nil value
  7. sorry, i forgot to post that its genting the data for other individual labels thats why its strange.. the data is there i can get it via many ways but this still not working
  8. hey, i've got a strange problem updating a gui label with a data i get from server side O_o, here is my code and the error i'm genting. client: function upClientStats(zombiekills,deaths) if deaths == 0 then guiSetText(ratioLabel, "Ratio: N/A") else ratio = (tonumber(zombiekills)/tonumber(deaths))*10 guiSetText(ratioLabel, "Ratio: "..tostring(ratio).." %") end end addEvent("updateClientStatsGui", true) addEventHandler("updateClientStatsGui", getRootElement(), upClientStats) server: function info2(cliente) local account = getPlayerAccount (cliente); if not isGuestAccount(account) then local zombiekills = getAccountData(account,"zombieKills") local deaths = getAccountData(account,"deaths") triggerClientEvent (cliente,"updateClientStatsGui",cliente,zombiekills,deaths) end end addEvent("getInfoFromClient", true) addEventHandler("getInfoFromClient", getRootElement(), info2) Error: attempt to perfrom arithmetic on a nil value its at zombiekills if i'm right. Thanks in advance
  9. do you have the MySQL module and a MySQL server running?
  10. function makeVisible() get = guiGetVisible(YOURWINDOW) if get == true then guiSetVisible(YOURWINDOW,false) else guiSetVisible(YOURWINDOW,true) end end bindKey("F7","down",makeVisible) Should work
  11. This way you won't get any reply, have pacience.
  12. find at race_server.lua this function addRaceScoreboardColumns() exports.scoreboard:addScoreboardColumn('race rank') exports.scoreboard:addScoreboardColumn('checkpoint') exports.scoreboard:addScoreboardColumn('state') end then change it by function addRaceScoreboardColumns() exports.scoreboard:addScoreboardColumn('race rank') exports.scoreboard:addScoreboardColumn('state') end
  13. Please give more information, what you mean with "Remplace resource"?
  14. Depends on how this Roleplay must be i could help you
  15. Ok, when i will try when i get someone else.
  16. that was my old idea but dunno why it won't work O_o code was: addEventHandler("onResourceStart", getResourceRootElement(getThisResource()), function () local allTeams = getElementsByType ( "team" ) for index, theTeam in ipairs(allTeams) do if ( getTeamFriendlyFire ( theTeam ) == true ) then setTeamFriendlyFire ( theTeam, false ) end end end)
  17. hey, i want to make when a player is on same team and he tryes to kill his teamate the health won't go down, i've done something but it won't work. function playerDamage ( attacker, weapon, bodypart, loss ) if attacker then if getElementType ( attacker ) == "vehicle" then cancelEvent() else local team = getPlayerTeam(source) local teamname = getTeamName(team) local team2 = getPlayerTeam(attacker) local teamname2 = getTeamName(team2) if teamname == teamname2 then --triggerClientEvent(source,"enableGodMode",source) cancelEvent() end end end end addEventHandler ( "onPlayerDamage", getRootElement(), playerDamage) thanks in advance. addEvent("enableGodMode", true) addEventHandler ("enableGodMode", getRootElement(), function() addEventHandler ("onClientPlayerDamage", getRootElement(), cancelEventEvent) end)
  18. maybe find next the "checkpoint" like i ever do.
  19. i guess you must edit "race" resource to remove that.
  20. please translate to ENGLISH what it does it.
  21. download xampp or something like that and create the database import the file which comes with the resource and will work (i made it working)
  22. first you got to press like W and S at same time (forwards,backwards) and then when the bar gets full drop them
  23. no exist such function: getPlayerCountry
  24. this is group Admin i Copy it from my server acl <group name="Admin"> <acl name="Moderator" /> <acl name="SuperModerator" /> <acl name="Admin" /> <acl name="RPC" /> <acl name="Default" /> <object name="resource.admin" /> <object name="resource.webadmin" /> <object name="user.basel" /> <object name="resource.BaseMode" /> </group> The problem is not from acl it is from the Script maybe you should read XX3 last post
×
×
  • Create New...