Didn't work in play mode

Hi, Everyone.
I’m new in Unity but almost 2 months I’m working on it. I’m developing a racing game and a couple days ago I open my project and click to run it and the play screen become frozen. I tried many thing but it didn’t work( I changed unity version, also I completely remove and install it). Also I tried some assets (vehicle physics pro) its not worked. I have tried same assets in my friend computer, it’s worked.
Where do you think the problem might be?

Welcome to the forums. Unfortunately we’re going to need a lot more information than what you’ve given us in order to be able to help.

  • Are there any error messages in the console?
  • What are your PC specs?
  • What changed in your project from when you could open it to when you couldn’t?
  • Do you have a backup of your project you can try restoring from? (If not, this is a great time to learn how to do that using Git)
  • Could you record a video or grab some screenshots of the issue happening so we can see what’s going on?

My answer your questions in order,

  1. The answer to this question is a bit complicated, I had more than one project but all of them was working despite minor error message. There is an sample errors picture below.
    Note 1: I tried the same asset(Vehicle Physics Pro) as seen in the first picture on another pc. Same error appeared there but the game worked. This is what made me doubt. 1 week ago this asset was working on my computer.
    Note 2: I installed standard assets and I fixed gui error. I click to play button, game started.(This asset does not give any error while running.) So Something came to my mind,Is there a setting that won’t run the project even if it’s the simplest error?

  2. Nvidia gtx1650 , intel i5.

  3. I didn’t remember :frowning:

  4. No I haven’t. I wish I knew.

  5. There is a picture. If you want video, I can record it.

Okay, so it seems to me that the issue isn’t that your screen is frozen, it’s that you’re getting errors in your console and your game doesn’t respond to input or anything, right? If that’s all that’s happening, you need to look at the errors and check the code that it’s pointing to (Mudguard.cs line 24 and BrakeLight.cs line 22) and see why they’re throwing NREs. my bet would be there are values that need to be assigned in the Inspector.

Yes not responding. The game also has AI, they don’t move.
You are right I have to fix errors, but same scene working on other computer with same minor error. Why my computer not allowing working with minor error. If the same scene is running on another computer, shouldn’t it work for me too?

Is the exact same code running on both machines? Without being able to see it running, I can’t really tell you anything more about what’s happening. From those screenshots I can tell you there are NullReferenceErrors happening at those two points, but whether they’re preventing execution from happening later in the loop isn’t clear from this alone.

A freeze in play mode almost always indicates your code has entered an infinite loop. Why it would behave differently on different hardware depends on the code. Null reference errors will cause the remaining code in the same method to be skipped, which can cause unintended behavior when the skipped code is important to the rest of the game.

sorry for the late reply, I’ve had the flu for a few days so I couldn’t write. In the video which I shared below, same asset were downloaded to two different computers from unity asset store and tested. Computer gaved same error but friends(ozkan pc) worked mine didn’t worked.

I do not object to the consequences of the errors you have stated. But don’t you think there is something strange about this? working on one computer and not working on another?

Review on Asset Store:
7597009--942463--upload_2021-10-23_21-0-20.png

Ozkan’s PC:

7597009--942457--upload_2021-10-23_20-58-41.png

Your PC:

7597009--942460--upload_2021-10-23_20-58-56.png

1 Like

I can’t explain how relieved. Thank you it worked :slight_smile:

1 Like

I kinda had the same problem but the problem was that I had an Infinite loop

You’re a genius man, i had a movieto make real quick for a client… you saved my night !!! HIGH FIVE :smile:

Looks like your PC’s crashed! If you have a recent backup of your game, restart and it might all work.

Thanks! Thanks you so much! You saved my 6 month of hardwork. I am sooo relieved I don’t need to recreate it again.

1 Like