Set default values of generic
<p>Quick question, I have a Generic class that I'm instantiating, but I'm having problem with primitives that are setted by default in the class.</p>

<pre><code>public class HeroLaunchData
{
    public int player;
    public int team;
    //....
    public bool withAnimation = true;
    //....
</code></pre>

<p>When I do the new of the generic this is not asigned, any idea why this may be?</p>

<p>Btw, I'm doing the new like </p>

<pre><code>public static T WoRDeserializer&lt;T&gt;(string serializedObj, char separator = ';') where T : class, new()
{
    //...
    T obj = new T();
    //...
</code></pre>

<p>Thanks! </p>