Jump to content

[HELP] Dx Edit Box


K4stic

Recommended Posts

Don't use onClientKey, use onClientCharacter

That is also an option. Pretty much depends on the usage and needs - but he will need onClientKey eventually since if he wants to be able to delete characters.

You can also use getKeyState in a onClientRender

Link to comment
  
text = {} 
function getCharacter(character) 
for i,ebox in ipairs(youreditbox) do 
      table.insert(text[i], character) 
    end 
end 
addEventHandler("onClientCharacter", getRootElement(), getCharacter) 
addEventHandler("onClientRender",root,function() 
dxDrawText(table.concat(text[i],""),.......) 
end) 
--and to remove it just use 
bindKey("backspace", "down", function () 
  table.remove(....) 
end) 
  

Like that?

It's just an example.

  • Like 1
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...