Jump to content

blinkerchris

Members
  • Posts

    23
  • Joined

  • Last visited

Everything posted by blinkerchris

  1. I'm using this one now, but it's not working 100% The problem is now that when I /chaton everything should work as normal, both chats should work. when /chatoff then ONLY mainchat should be disabled, teamchat should work. and mainchat doesn't work weither its on or not. Thanks chris
  2. There is no errors in the debugscript or console.
  3. Tested it. Now the chat works no matter what. When I /chatoff both chats still works =/ only teamchat should work when /chatoff, normal chat shouldn't. when /chaton both chats should work. Thanks chris.
  4. I tested it now, and the admin part works fine. but when I do /chatoff I can't use teamsay. that's my clue that I want to work =/ but the mainchat should still be disabled when /chatoff, only teamsay should work then. Thanks
  5. I have no idea how to do that. Could you help? Thanks
  6. Hello, I'm making a local mute script and I need some help. This is what I have so far. local chat = true function chatDis(thePlayer) outputChatBox("#E3E8B7The chat has been disabled by "..getPlayerName(thePlayer)..".",root,255, 255, 255, true) chat = false end addCommandHandler("chatoff", chatDis) function chatEn(thePlayer) outputChatBox("#E3E8B7The chat has been enabled by "..getPlayerName(thePlayer)..".",root,255, 255, 255, true) chat = true end addCommandHandler("chaton",chatEn) function onChat() if (chat == false) then cancelEvent() end end addEventHandler("onPlayerChat", root, onChat) Everything works fine with the lua above. But the thing I want is the teamchat should work all the time, when /chatoff then only local chat should be disabled. Not teamsay. and when /chaton, everything should work as normal. Only admins should be able to /chaton /chatoff Regards, chris. Thanks
  7. Thanks that works perfectly. Do you know how to make teamchat allowed? but the main chat disabled Also, only admins can /chaton /chatoff, not everyone. thanks again
  8. Yea, I know =/ do you know how to make it, if I write /chaton it will say 'The chat has been enabled by (the name im using) do you know how to make it like that?
  9. Hey, I started on a new chatmute script and it seems to have errors, I know there are errors in the script because of the debugscript which says: ERROR: Loading script failed: localmute\client.lua:5: '' expected near 'end' I can't get it to work (I know that there are alot of mistakes) function chatdis(command) cancelEvent() outputChatBox("#E3E8B7The chat has been disabled by (localPlayerName)",source,255,0,0) addEventHandler("onPlayerChat",getRootElement(),chatdis) end end end ) function chaten(command) outputChatBox("#E3E8B7The chat has been enabled by (localPlayerName)",getRootElement(),255,0,0) removeEventHandler("onPlayerChat",getRootElement(),chatdis) end ) ) addCommandHandler("myname", function() local localPlayerName = getPlayerName(getLocalPlayer()) end ) addCommandHandler("chatoff",chatdis) addCommandHandler("chaton",chaten) Can you correct me? Thanks
  10. Hey, I'm wondering if this is totally wrong , I made a try to edit a scoreping & fps because I didn't like the display. The problem is that the PING is not showing on the screen, only the letters 'PING'. The FPS is working 100%, the ping is the problem. I want it to work the same way. Could you edit a bit on this? if thats what it needs? (I doubt that.) Thanks. Client local ping = getPlayerPing(getLocalPlayer()) local x, y = guiGetScreenSize ( ) r,g,b=0,0,0 alpha=150 local root = getRootElement() local player = getLocalPlayer() local counter = 0 local starttick local currenttick addEventHandler("onClientRender",root, function() if not starttick then starttick = getTickCount() end counter = counter + 1 currenttick = getTickCount() if currenttick - starttick >= 1000 then setElementData(player,"FPS",counter) counter = 0 starttick = false end end ) local root = getRootElement() local player = getLocalPlayer() local counter = 0 local starttick local currenttick addEventHandler("onClientRender",root, function() if not starttick then starttick = getTickCount() end counter = counter + 1 currenttick = getTickCount() if currenttick - starttick >= 1000 then setElementData(player,"PING",counter) counter = 0 starttick = false end end ) function drawStates () addEventHandler ( "onClientRender", root, pingState ) addEventHandler ( "onClientRender", root, fpsState ) end addEventHandler ( "onClientResourceStart", resourceRoot, drawStates ) function pingState() posx= x-30 posy= 20 dxDrawText ( getElementData(getLocalPlayer(),"PING"), posx2-12, posy2-6, x, y, tocolor ( 255, 255, 255, 255 ), 1.4, "default-bold" ) dxDrawText ( "FPS", posx2-13, posy2+10, x, y, tocolor ( 255, 255, 255, 255 ), 1.0, "default-bold" ) dxDrawText ( "PING", posx2+23, posy2+10, x, y, tocolor ( 255, 255, 255, 255 ), 1.0, "default-bold" ) end function fpsState() posx2= x-55 posy2= 13 dxDrawText ( getElementData(getLocalPlayer(),"FPS"), posx2-12, posy2-6, x, y, tocolor ( 255, 255, 255, 255 ), 1.4, "default-bold" ) dxDrawText ( "FPS", posx2-13, posy2+10, x, y, tocolor ( 255, 255, 255, 255 ), 1.0, "default-bold" ) dxDrawText ( "PING", posx2+23, posy2+10, x, y, tocolor ( 255, 255, 255, 255 ), 1.0, "default-bold" ) end Server addEventHandler("onResourceStart",getResourceRootElement(getThisResource()), function() call(getResourceFromName("scoreboard"),"addScoreboardColumn","FPS") call(getResourceFromName("scoreboard"),"addScoreboardColumn","PING") end )
  11. Thanks NeO! That worked 100% ) cheers!
  12. function daspawnzon() if not spx then outputChatBox("#E3E8B7The command will be available once the map is restarted!", 0, 0, 0, true) else local car = getPedOccupiedVehicle(localPlayer) if not car then return end setElementFrozen(car, false) setElementModel(car, model) setTimer(setElementFrozen, 2500, 1000, car, false) setElementHealth(car, 1000) setElementPosition(car, spx, spy, spz) setElementRotation(car, sprx, spry, sprz) triggerServerEvent('syncModel', resourceRoot, car, spm) bool setElementFrozen ( element theElement, bool freezeStatus ) end So that would be wrong?
  13. Yes I get that you have to edit the setElementFrozen part, but to what numbers? I tried 0, 0, Thanks
  14. Hey, I have a problem with a training script, the problem is that when I write /RES, (I will go to my spawn zone with /RES). And then my car freezes for like 2 secounds, and then I can drive. How to make it with 0 delays/make it drive at the time I write /RES? It's quite annoying. I'll paste the command(s) below. function daspawnzon() if not spx then outputChatBox("#E3E8B7The command will be available once the map is restarted!", 0, 0, 0, true) else local car = getPedOccupiedVehicle(localPlayer) if not car then return end setElementFrozen(car, true) setElementModel(car, model) setTimer(setElementFrozen, 2500, 1000, car, false) setElementHealth(car, 1000) setElementPosition(car, spx, spy, spz) setElementRotation(car, sprx, spry, sprz) triggerServerEvent('syncModel', resourceRoot, car, spm) end end addCommandHandler("RES", daspawnzon) I hope you get my point. Thanks!
  15. Okay, I tried that. I have to wait for people to test it now. Do you know any way to make the script save the teamname and points? ForExample: If EG// had 8 points and a yellow team color, and if I do /reconnect when the team has those points. Then when I'm joining, it's 0 points and the team color is back to normal. How to make them save the current points & team color? Thanks
  16. That went very well! A new bug discovered: I have the resolution 1366x768x32. And the display is not showing on other players screen (they have resolution 1024 and something more. How can I make it show for everyone? no matter what resolution? is there a way to do that? would be great. I have already done the local screenWidth, screenHeight = guiGetScreenSize ( ) command, but it doesn't help. Thanks
  17. dxDrawText ( hexColorHome..homeName..":"..displayHome, (screenWidth/2)+600, screenHeight-390, screenWidth, screenHeight, tocolor ( 255, 102, 1, 255 ), 1.1, "default-bold" , nil, nil, nil, nil, nil, true) dxDrawText ( hexColorVisit..visitName..":"..displayVisit, (screenWidth/2)+600, screenHeight-370, screenWidth, screenHeight, tocolor ( 255, 0, 0, 255 ), 1.1, "default-bold", nil, nil, nil, nil, nil, true ) This is what I found, what should I edit here to get a clear text to read? Thanks, I appreciate your help!
  18. And thats to edit the letters very right on the photo? sorry for many re-uploads. the photo was very bad.
  19. Hey, I'm doing a clanwar script, and it has bad letters (thick ones), I'd like normal letters at the cwboard. Look at the picture below. http://tinypic.com/r/2wpupmp/8 How can I make more thin and more readable letters? those unlcear to read. What command should I use? The letters are very right on the picture where it says 'awdawd' and 'Others' Thanks!
  20. Well, how would you write the 2nd info sentence about the server? Example: GUIEditor.memo[1] = guiCreateMemo(1, 1, 711, 334, "Hey chris", false, GUIEditor.tab[1]) GUIEditor.memo[1] = guiCreateMemo(1, 1, 711, 334, "Hey chris/hey blinker", false, GUIEditor.tab[1]) Please explain it like that. Thanks (super noob)
  21. Hello, I downloaded https://community.multitheftauto.com/in ... ls&id=8828 some days ago and I have some problems with making it work. The problem is that I can only write one line about the server (info). GUIEditor.memo[1] = guiCreateMemo(1, 1, 711, 334, "Add your server information here", false, GUIEditor.tab[1]) The line above is the command to write something about the server. But I would like to write more than one sentence about the server. If I copy paste that sentence, and put it below this one --> GUIEditor.memo[1] = guiCreateMemo(1, 1, 711, 334, "Add your server information here", false, GUIEditor.tab[1]) And try to write the 2nd sentence, nothing happends. How can I write more than one line in the server info? Hope you understand, sorry for a bad explanation. Thanks.
×
×
  • Create New...