How would i to see this the Int must be this number or this number Javascript

Sorry about the name I didn’t know how to explain it in a title.

Im using JavaScript and I want to know how to make it show a picture if the integer is either 1 or 3 so I get.

if (PlayerPrefs.GetInt(“Map Area”)==1)

but how would I make

if (PlayerPrefs.GetInt(“Map Area”)==1) or (PlayerPrefs.GetInt(“Map Area”)==3)

it will show my image instead of just the Int being 1? :eyes:

Please and thankyou in advance - sorry if it doesn’t really make sense im not that good at explaining. :face_with_spiral_eyes:

Use the OR operator in JavaScript which is: ||
So your statement will look like:
if ((PlayerPrefs.GetInt(“Map Area”)==1) || (PlayerPrefs.GetInt(“Map Area”)==3))

Feel free to read up more on conditional operators at:

if((PlayerPrefs.GetInt("Map Area")==1) || (PlayerPrefs.GetInt("Map Area")==3))
{
// Insert code here
}

Thank you:)