slapztea

Members
  • Content Count

    189
  • Joined

  • Last visited

Community Reputation

3 Neutral

About slapztea

  • Rank
    Mark

Details

  • Gang
    pangea
  • Location
    pangea
  • Occupation
    pangea
  • Interests
    create own server

Recent Profile Visitors

314 profile views
  1. function givemins (player) local mins = getElementData(player,"mins") local res = getElementData(player,"respects") if mins == 60 then setElementData(player,"mins", -1) setElementData(player,"respects", (getElementData(player, "respects") or 0) +1) end setTimer( function() setElementData(player,"mins", (getElementData(player, "mins") or 0) +1) givemins() end, 1000, 1, root, source) end addCommandHandler ( "gg", givemins ) addEvent("givemins",true) addEventHandler("givemins",root,givemins) What am I doing wrong? and how to fix it? Need restart timer when the timer is over. The timer works, but after restart an error occurs.(that is, it works once without restart) 290 - local mins = getElementData(player,"mins") 291 - local res = getElementData(player,"respects") 298 - setElementData(player,"mins", (getElementData(player, "mins") or 0) +1)
  2. Hello! Is it possible to limit shooting on an airplane hydra/hunter ? Without limitation, you can hold down the left mouse button and it will shoot endlessly. How to limit the number of shots?
  3. One more question local test1 = 1 local test2 = 2 local test3 = 3 local ot = outputChatBox ( ""..ot.."" ) How to use random with this code? How do I make randomly choose one of the variables(test1 or test2 or test3) for "ot" ?
  4. not working correctly, always output letter "G" but i need random from "bb" Example you type /ss and random output "B" next time maybe "C" and etc With your example, only the last letter is obtained "G"
  5. How to use random for letters? function asd() bb = {"A", "B", "C", "F", "G"} for _, i in ipairs( bb ) do z = end outputChatBox ( ""..z.."" ) end addCommandHandler ( "ss", asd ) How to write correctly "z" for random from "bb"
  6. slapztea

    email script

    Can you give me a working example for "email api" ?
  7. slapztea

    email script

    I don’t understand how it works, can anyone help with this? So that the script code has a username and password from the email and this email will be send mail on other email.
  8. slapztea

    email script

    Help! How to implement a script for sending emails? Something like: use in script login and password from e-mail and this email will be send mail on other email.
  9. slapztea

    getrealtime

    I have script for get real time: local minuteDelay = get ("realtime.minuteDelay") setMinuteDuration (minuteDelay) local hour = get ("realtime.initialHour") local minute = get ("realtime.initialMinute") function servetime () servertime = getRealTime () hours = (servertime.hour) minutes = string.format("%02d", servertime.minute) second = string.format("%02d", servertime.second) end setTimer (servetime, 1000, 0) local function onJoin() spawn(source) setTime (hours,minutes) end setting for this in meta: <settings> <setting name="*initialHour" value="0" friendlyname="Initial Hour" accept="0-23" desc="The hour that the game inits with when starting this resource." /> <setting name="*initialMinute" value="0" friendlyname="Initial Minute" accept="0-60" desc="The minute that the game inits with when starting this resource." /> <setting name="*minuteDelay" value="60000" friendlyname="Minute Delay" accept="0-9999000" desc="How much time does minutes delay its advance in miliseconds." /> </settings> I got what I wanted, but there is a problem with the seconds. Example: you start server in 11:33:55 and when in real time there will be 11:34:00 , will be on the server 11:33:05 It is necessary that the server would be the same (11:33:55 not 11:33:00) How to fix it?
  10. @IIYAMA Can you give me example in code? I can’t understand how to use it correctly. I could only get this but how can i use it in my goal ? local time = getRealTime() local hours = time.hour local minutes = time.minute local seconds = time.second local duration = 10 local endtime = seconds + duration local curtime = hours..":"..minutes..":"..seconds local remaintime = endtime - curtime
  11. For example, an account has a value: setAccountData (acc, "time", "10" ) How to make a timer on the server, by which in a minute this value will be "9" and after another 9 minutes it will become "0" Account must be offline
  12. local health1 = getElementHealth(getPlayerFromName(player)) guiSetText(label1, "HP: "..health1.. " %") How to change digit display format? Now display like this but how to make that there would be a maximum of 2 digits after the decimal point 26.39 %
  13. if current user try to login in account which was registered from another serial I get this error in the console How can I remove this error and allow authorization ?