• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

How to get player target Id? / Triggering something by key press

Dbzl

New Member
Joined
Jan 22, 2017
Messages
34
Reaction score
1
I'm trying to get what the player is targetting so I can return its name (and it's actual health). But I can't find any way of doing so...
I was able to return every monster in battle, though. But it isn't enough yet :<

Does anyone know anything about it? @_@

Also, is there an easy way to recognize keyboard press?
 
Also, is there an easy way to recognize keyboard press?
There's easy way.
In init function you can bind keys, for example:
Lua:
g_keyboard.bindKeyDown('Ctrl+S', toggle)
So toggle change the function you need.
 
There's easy way.
In init function you can bind keys, for example:
Lua:
g_keyboard.bindKeyDown('Ctrl+S', toggle)
So toggle change the function you need.
Sadly I can't study and test it now. But as soon as I test Imma answer here. Thanks!

I ended up discovering with the function you gave how it's done. Thanks a lot!
And sorry for the delay tho.
 
Last edited:
Back
Top