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

_ field names, CamelCase Properties???

$
0
0
So following what is shown in the actual MSDN docs I've been doing this:

public string[] TagArray { get { returntagArray; } set { tagArray = value; } }
private string[] tagArray;

As of late I notice some people, particularly prime31 use this:
public float delay { get; private set; }
private float _delay;

Whats going on here and why? Does anyone have any reasoning for this? What is really the ideal way to do this? I figured following MSDN docs was ideal.

Viewing all articles
Browse latest Browse all 1466670

Trending Articles



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