While loop running even though the statement is false

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve? Keep it simple and clear!
    I want to achieve a similar training system like Roller Race Simulator
  2. What is the issue? Include screenshots / videos if possible!
    when I train and then leave quickly the loop keeps running for few seconds and then stops
  3. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    I have tried looking for solutions across the devfourm but there was nothing similar to my issue

because youre checking if plr.Name is inside the table, not if if equals something

while Train[plr.Name] and Train[plr.Name] == true do

thx for the replay and the script you provided helped but still when I spam the prompt the while loop runs after I left the seat for a second then stops and when I spam the prompt I still get parachute value like this: