- Home /
Script Compiller errors. need help fixing
I need help! When i try to press "play" it tells me something similar to this, "You need to fix all compiller errors to play" So the error i saw and it was the only one is this
Assets/Standard Assets/Image Effects (Pro Only)/ColorCorrectionEffect.cs(6,14): error CS0101: The namespace global::' already contains a definition for
ColorCorrectionEffect'
Any idea how i can fix it? thanks in advance.
you need to post the script where the error is in. -> ColorCorrectionEffect file
Can you possibly be more specific?:L I'm new to this stuff.
we do not know what you are doing in your script that causes the error, so copy the code from your editor in here so we can have a look and probabply tell you what's wrong :)
Ohh. okay :) this is the script.
using UnityEngine; using System.Collections;
[ExecuteInEdit$$anonymous$$ode] [AddComponent$$anonymous$$enu("Image Effects/Color Correction (Ramp)")] public class ColorCorrectionEffect : ImageEffectBase { public Texture textureRamp;
// Called by camera to apply image effect
void OnRenderImage (RenderTexture source, RenderTexture destination) {
material.SetTexture ("_RampTex", textureRamp);
Graphics.Blit (source, destination, material);
}
}
Dead$$anonymous$$ask, it tells you where the script is: Assets/Standard Assets/Image Effects (Pro Only)/ColorCorrectionEffect.cs , post it and I'm sure someone will help! Edit: you posted it right when I posted this
Answer by fafase · Jul 11, 2013 at 11:57 PM
Use the project search bar and type in ColorCorrectionEffect. if it returns two of the same, remove one.
The error tells you have it twice so you probably have it twice.