Quantcast
Channel: Unity Forum
Viewing all articles
Browse latest Browse all 1466670

C# properties not getting serialized properly?

$
0
0
Hello everyone,

I just started to get into interfaces and inheritance. I have a Interface called IItem with a property which looks like this:
Code (CSharp):
  1. string name {get; set;}
and a class called BaseItem. BaseItem extends MonoBehaviour and implements IItem, the implementation of the property looks like this:
Code (CSharp):
  1. public virtual new string name {
  2.             get {
  3.                 return name.Equals("") ? gameObject.name : name;
  4.             }
  5.             set {...
C# properties not getting serialized properly?

Viewing all articles
Browse latest Browse all 1466670

Trending Articles



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