Jump to content

Castillo

Retired Staff
  • Posts

    21,935
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Castillo

  1. Castillo

    unbindkey help

    Because that doesn't make any sense, you don't want to unbind, you want to hide the window when it's open. bindKey ( 'F4', 'down', function ( ) local state = ( not guiGetVisible ( GUIEditor_Window[1] ) ) guiSetVisible ( GUIEditor_Window[1], state ) showCursor ( state ) end )
  2. You replaced that and you have the other script which uses that event?
  3. Check the meta.xml, you surely have the script set as server side, but it's a client side script.
  4. Are you sure that the positions are the correct ones? does the debugscript say anything related to this script?
  5. You are creating the font over and over again, create it outside the onClientRender function.
  6. Castillo

    Disconnect

    1: Do you even read what they said? you can't execute hard coded commands. 2: 'playerSource' and 'commandName' is nil on your code, you must use 'source'.
  7. 3NAD, read this quote: He's obviously using DD/DM and not race with checkpoints, so that event won't work. @Mossy: Go to "race/modes/destructionderby.lua" and replace the function: "handleFinishActivePlayer" with this one: function DestructionDerby:handleFinishActivePlayer(player) -- Update ranking board for player being removed if not self.rankingBoard then self.rankingBoard = RankingBoard:create() self.rankingBoard:setDirection( 'up', getActivePlayerCount() ) end local timePassed = self:getTimePassed() self.rankingBoard:add(player, timePassed) -- Do remove local rank = self:getPlayerRank(player) finishActivePlayer(player) if rank and rank > 1 then triggerEvent( "onPlayerFinishDD",player,tonumber( rank ) ) end -- Update ranking board if one player left local activePlayers = getActivePlayers() if #activePlayers == 1 then self.rankingBoard:add(activePlayers[1], timePassed) showMessage(getPlayerName(activePlayers[1]) .. ' is the final survivor!', 0, 255, 0) triggerEvent( "onPlayerWinDD",activePlayers[1] ) end end
  8. if source == HitmanEvent then That doesn't make any sense, you are comparing a table with an element, maybe you wanted to do this: if ( source == HitmanEvent.element ) then
  9. That doesn't really make much sense, the timer is used to execute the same function executed by the command, and you have getRandomPlayer, which is not required, also, you are looping all vehicles, no idea what for. What you must do is: get the vehicle from the player that used the command, then check if he actually has one, if so, set the timer to repair it.
  10. Castillo

    register

    https://wiki.multitheftauto.com/wiki/ACL
  11. I'm not saying that you shouldn't use the timer to create it, I'm saying that you can use the same timer that creates it to set the parent.
  12. That whole script doesn't make any sense as I sai before. You are trying to show random messages every 10 seconds?
  13. You did it wrong, you must add it after the other end, not after the event handler.
  14. You must to add another end to close the 'if' statement.
  15. That's because your script doesn't make any sense, you can't use an "else" if you don't have an "if". Also, your event handler is wrong.
  16. Found your problem, here: if isTimer(timers[hitElement]) then killTimer(timers[hitElement]) end You are using "hitElement", but your argument is "leaveElement".
  17. I don't really understand the problem, but I can't seem to understand why do you want to kill the player after 5 seconds when they enter on a green zone?
  18. What's the point of that timer? you had one to create the blip, just add the setElementParent after you create it inside the same function.
  19. Si, le dara "infinite running script".
  20. Castillo

    GUI help

    That should be on an script file ( that's how it is when you download it ).
  21. Castillo

    GUI help

    "vehicles" table should be defined on another script.
×
×
  • Create New...