Single equal sign is assignment, which won’t work here.
Double equal sign is comparison.
Otherwise, rather than an incomplete random snippet, try this format for asking technical questions:
This is the bare minimum of information to report:
what you want
what you tried
what you expected to happen
what actually happened, log output, variable values, and especially any errors you see
links to actual Unity3D documentation you used to cross-check your work (CRITICAL!!!)
The purpose of YOU providing links is to make our job easier, while simultaneously showing us that you actually put effort into the process. If you haven’t put effort into finding the documentation, why should we bother putting effort into replying?
hey, i saw an error so just typing by, in the if function you need to use two == equal signs, thats how the code checks your variable, single equal sign is used for assigning