Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Game Development Cameras in Unity Camera Basics Scene Overview

Tojo Alex
PLUS
Tojo Alex
Courses Plus Student 13,331 Points

I have a error which I don't understand

The console shows this error :

Assets/Standard Assets/ParticleSystems/Scripts/WaterHoseParticles.cs(41,48): error CS0619: UnityEngine.ParticleCollisionEvent.collider' is obsolete:collider property is deprecated. Use colliderComponent instead, which supports Collider and Collider2D components (UnityUpgradable) -> colliderComponent'

I don't know what the problem is please help.

5 Answers

Steven Parker
Steven Parker
231,275 Points

Without seeing the code, but based solely on the error message, I'd look on line 41 of "WaterHoseParticles.cs" and try changing the term "collider" to "colliderComponent".

Tojo Alex
PLUS
Tojo Alex
Courses Plus Student 13,331 Points

I didn't even open the script and there is an error I'm confused

Tojo Alex
PLUS
Tojo Alex
Courses Plus Student 13,331 Points

I fixed the error though I got a new one: Assets/Scripts/Screenshot.cs(10,25): error CS0619: UnityEngine.Application.CaptureScreenshot(string, int)' is obsolete:Application.CaptureScreenshot is obsolete. Use ScreenCapture.CaptureScreenshot instead (UnityUpgradable) -> [UnityEngine] UnityEngine.ScreenCapture.CaptureScreenshot(*)'

Steven Parker
Steven Parker
231,275 Points

I'd try handling this one the same way: on line 10 of "Screenshot.cs", change "Application.CaptureScreenshot" to "ScreenCapture.CaptureScreenshot".

Tojo Alex
PLUS
Tojo Alex
Courses Plus Student 13,331 Points

after changing that, five more errors came with the same issue I'm confused why they keep on coming

Steven Parker
Steven Parker
231,275 Points

It sounds like you're using s different (and non-back-compatible) version of the Unity engine from the one the code was developed on. You might see if you can still get a copy of the exact same version and install that one. Also check the Unity website in case they have some available migration packages.

Otherwise, expect to spend some time doing conversions.

Steven Parker
Steven Parker
231,275 Points

It's only important if it is not back-compatible with the version the code you are building was created with.