Jump to content

Control arrows


HairyMeets

Recommended Posts

Posted

If you talk about doing this with GUI and interact with it, I don't see how. If you talk about dxDraw events, it is indeed possible, though you would need some knowledge.

Create a table and make arrow keys responsible of highlighting certain options, by looping through the table and setting different data per option. It's the only way I can think of something similar.

  • Like 1

tJ5zeFm.gif

Proud owner and developer of ZNEXT: Aftermath.

Enter a post-apocalyptic San Andreas and fight over 30 types of enemies and bosses with varying difficulties and skills, improve and customize your character by leveling up, completing challenges and a solid lootbox system with no Pay-to-Win mechanics that will break your experience.

Meet new characters, creatures and weapon metas, experience an innovative combo-based melee system, or join our solid PvP modes to show other survivors who’s boss. 

Español, Pусский, Türk, عربى, Polski, Português

IP: mtasa://104.36.110.227:22003 - Discord: https://discord.gg/CxMxjvC5pB

Posted
1 hour ago, MadnessReloaded said:

If you talk about doing this with GUI and interact with it, I don't see how. If you talk about dxDraw events, it is indeed possible, though you would need some knowledge.

Create a table and make arrow keys responsible of highlighting certain options, by looping through the table and setting different data per option. It's the only way I can think of something similar.

I have not worked with tables and loops yet, but I think there will be no problems, considering that I am learning very fast, thank you

Posted

Can you help me I'm using this for marker purpose 

i want a script which is count players travel time from marker to marker. start time and end time. the time is stored somewhere and the best time (the shortest) is callable  and taken element data in server side so that all can see who got the best time to reach end marker 

Posted
1 hour ago, alonemta said:

Can you help me I'm using this for marker purpose 

i want a script which is count players travel time from marker to marker. start time and end time. the time is stored somewhere and the best time (the shortest) is callable  and taken element data in server side so that all can see who got the best time to reach end marker 

Create another topic and describe your problem there

  • Moderators
Posted (edited)

@HairyMeets

function keyDetection (key, keyState)
	iprint("key:", key, ", keystate:", keyState)
end

bindKey ( "arrow_u", "down", keyDetection )
bindKey ( "arrow_d", "down", keyDetection )

 

Untested, but should activate a single function with the keys arrow UP and DOWN. (clientside)

 

Edited by IIYAMA

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

 

  Useful functions  3x 

  Tutorials  4x 

 

Posted
10 hours ago, IIYAMA said:

@HairyMeets


function keyDetection (key, keyState)
	iprint("key:", key, ", keystate:", keyState)
end

bindKey ( "arrow_u", "down", keyDetection )
bindKey ( "arrow_d", "down", keyDetection )

 

Untested, but should activate a single function with the keys arrow UP and DOWN. (clientside)

 

I'll try this later, thanks

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