Jump to content

Hex codes


krYshuT

Recommended Posts

Well, there is this line in delay indicator resource:

delayDisplayBehind:text("+"..msToTimeStr(delayTime).." "..cps..getPlayerName(source))

I have no experience in coding, so I don't know how to make it work fine. I tried to edit it like:

delayDisplayBehind:text("+"..msToTimeStr(delayTime).." "..cps..string.gsub(playerName, '#%x%x%x%x%x%x', ''))

But it didn't work.

How it's correct?

Else in the killmessages resource I have no idea where to paste it to make it work. Can you help me with this?

Link to comment

Ingame it looks like this:

beznzvuck.png

Lua file:

local messagesList = { 
    "19.11.: ESE #00ff0013:3 TPT", 
    "ingame cycling text shows here", 
    "ingame cycling text shows here", 
    "ingame cycling text shows here", 
    "ingame cycling text shows here", 
    "ingame cycling text shows here", 
  
} 
local currentMessage = 0 
  
addEventHandler("onClientPreRender", getRootElement(), 
    function() 
        local screenWidth, screenHeight = guiGetScreenSize() 
  
        -- Draw the news sticker. 
        dxDrawRectangle(screenWidth - 249, 4, 0, 20, tocolor(0, 0, 0, 192), false) 
         
        -- Draw all strings. 
        dxDrawText(messagesList[currentMessage + 1], screenWidth - 246, 6, screenWidth - 6, 16, tocolor(255, 255, 255, 255), 1, "default-bold", "center", "top", false, false, false) 
    end 
) 
  
function updateMessage() 
    if (currentMessage == 5) then 
        currentMessage = 0 
    else 
        currentMessage = currentMessage + 1 
    end 
end 
setTimer(updateMessage, 5000, 0) 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...