Skip to content
View in the app

A better way to browse. Learn more.

LCPDFR.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Y key isnt working?

Featured Replies

Spoiler

        public override void Process()
        {
            base.Process();

            if (Game.LocalPlayer.Character.DistanceTo(Suspect) <= 20f)
            {
                Game.DisplayHelp("Press Y to talk to the Suspect!", false);
                GameFiber.Sleep(2000);

                if (Game.IsKeyDown(System.Windows.Forms.Keys.Y))
                {
                    counter++;

                    if (counter == 2)
                    {
                        Game.DisplaySubtitle("Officer: Hello" + maleFemale + "are you drunk?");
                    }
                    if (counter == 3)
                    {
                        Game.DisplaySubtitle("Suspect: Nwo Ofwicer mee nwo drunk");
                    }
                    if (counter == 4)
                    {
                        Game.DisplaySubtitle("Officer:" + maleFemale + "Do you mind taking a breathaliyzer for me?");
                    }
                    if (counter == 5)
                    {
                        Game.DisplaySubtitle("Suspect: NO i wil nwot twake the breathalwizer!");
                    }
                    if (counter == 6)
                    {
                        Game.DisplaySubtitle("Officer:" + maleFemale + "stop Walking away!");
                        Suspect.Tasks.Wander();
                        Suspect.Tasks.ReactAndFlee(Suspect);
                        Game.DisplaySubtitle("No more Text to display");
                    }
                }
            }
            if (Suspect.IsCuffed || Suspect.IsDead || Game.LocalPlayer.Character.IsDead || !Suspect.Exists())
            {
                End();
                Game.DisplayNotification("Officer: Show me Code 4");
            }
        }

when i click Y it dosent bring the text off any reason why?
Code is above

Edited by TheLastKnight2310

LFennell

  • Management Team

Because, unless you have ninja reflexes, you will not hit the exact point in time where your script has waited 2 seconds to press the key that very frame. You need to check for the key without a sleep in the loop.

Please do not PM me unless really necessary (knowing you helps). If you think you need my attention in a topic, tag me.

  • Author
5 hours ago, LMS said:

Because, unless you have ninja reflexes, you will not hit the exact point in time where your script has waited 2 seconds to press the key that very frame. You need to check for the key without a sleep in the loop.

even without the wait it dosent work

LFennell

  • Author
5 hours ago, LMS said:

Because, unless you have ninja reflexes, you will not hit the exact point in time where your script has waited 2 seconds to press the key that very frame. You need to check for the key without a sleep in the loop.

i got it to work ty

LFennell

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.