Scripts / [SOLVED] Problem with custom key press

Author
Message
Vpze
4
Years of Service
User Offline
Joined: 17th Feb 2020
Location:
Posted: 13th Aug 2020 17:08
Hi everyone,
I'm currently working on a script for the player to press to show the level objectives on the screen like a HUD. Here I have chosen M is the key that the player has to press to show the objectives, and this is my script:



The problem is that with this script, the player has to HOLD M to show the objectives, but I want to press to show it then press it again to close it. I have made a script like this:


But it didn't work!
I want to press to show it then press it again to close it. Any ideas? Thanks in advance!

The author of this post has marked a post as an answer.

Go to answer
PM
GubbyBlips
5
Years of Service
User Offline
Joined: 14th Jan 2019
Location:
Posted: 13th Aug 2020 17:45 Edited at: 13th Aug 2020 18:02
This post has been marked by the post author as the answer.
You need to use an empty key toggle, and then a flag +/-
Don't use openObj in this regard
You will need;

PM
Vpze
4
Years of Service
User Offline
Joined: 17th Feb 2020
Location:
Posted: 14th Aug 2020 11:16
Wow, it works!
Thanks, GubbyBlips! I appreciate your help!
PM

Login to post a reply

Server time is: 2024-03-29 01:27:06
Your offset time is: 2024-03-29 01:27:06