Quantcast
Channel: Questions in topic: "error"
Viewing all articles
Browse latest Browse all 7934

Respawn fix

$
0
0
So I'm really new to unity and I've been making a Platformer, and I want the Player to die when he touches the Blue Jelly named "Death". I've looked around forums, videos, and tried to fix it myself for atleast 4 hours.. But I cant find a fix! - Here is my code: void OnCollisionEnter(Collision col) { if(col.gameObject.name == "Jelly") { Destroy(col.gameObject); I cant find any code for it to respawn without there being errors. From this code I get quite a few error messages: error CS8025: Parsing error error CS1519: Unexpected symbol `' in class, struct, or interface member declaration error CS1520: Class, struct, or interface method must have a return type error CS1041: Identifier expected Unexpected symbol `==' in class, struct, or interface member declaration Unexpected symbol `if' in class, struct, or interface member declaration Could anyone help me to get this code fixed and make it so my player can respawn?

Viewing all articles
Browse latest Browse all 7934

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>