Jump to content

[HELP] Why not working getElementData?


Tokio

Recommended Posts

Posted
					local iras = getElementData(player, "typing") and " [ÍR...]" or ""
					dxDrawText ( playerName.." "..iras, sx+1, sy - offset, sx+1, sy - offset+1, tocolor(0,0,0,255), textscale*NAMETAG_TEXTSIZE, srfont, "center", "bottom", false, false, false, true, true )

What wrong? :/ 

My servers:

Fun:

n-560x95_FFFFFF_FFFFFF_000000_000000.png

Derby(DD):

n-560x95_FFFFFF_FFFFFF_000000_000000.png

  • Moderators
Posted

There is nothing wrong with it, you just have to set it first.

Do you want to improve your Lua programming skills and make less mistakes?   Start with Lua Language Server!   🙀

 

  Useful functions  3x 

  Tutorials  4x 

 

Posted
1 minute ago, IIYAMA said:

There is nothing wrong with it, you just have to set it first.

I don't understand this :S What do you mean? :| 

  • Haha 1

My servers:

Fun:

n-560x95_FFFFFF_FFFFFF_000000_000000.png

Derby(DD):

n-560x95_FFFFFF_FFFFFF_000000_000000.png

  • Moderators
Posted

Elementdata is custom data you can attach to an element. With getElementData you get the data and with setElementData you attach the data. But if the data isn't attached then you can't get it.

 

Understood?

Do you want to improve your Lua programming skills and make less mistakes?   Start with Lua Language Server!   🙀

 

  Useful functions  3x 

  Tutorials  4x 

 

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...