Forum rules - please read before posting.

SpriteDirections compile error: Attribute 'SerializeField' is not valid

edited November 30 in Technical Q&A

I upgraded to Unity 6000.3.29f1 and get this compile error:

Assets\AdventureCreator\Scripts\Animation\SpriteDirectionData.cs(25,4): error CS0592: Attribute 'SerializeField' is not valid on this declaration type. It is only valid on 'field' declarations.

Any ideas what it's about? I am on AC 1.86.7

Comments

  • Could you copy/paste the mentioned line, line 25 of SpriteDirectionData? I'm not seeing mention of any SerializeField attribute on me end with v1.86.7.

  • Solved. I must have had the SpriteDirectionData.cs file open and it didn't import it. I reimported everything and the SerializeField line is now removed. Thanks.

    Line 25: private enum Directions { None, Four, Eight, Custom };

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.