コード例 #1
0
 public DungeonMoodResources()
 {
     foreach (UnityEngine.Object obj2 in ResourceUtil.LoadResourcesAtPath("DungeonMoods"))
     {
         if (obj2 is TextAsset)
         {
             DungeonMood mood = JsonUtils.Deserialize <DungeonMood>(((TextAsset)obj2).text, true);
             mood.Id = obj2.name;
             mood.postDeserializeInitialization();
             this.m_dungeonMoods.Add(mood.Id, mood);
         }
     }
 }
コード例 #2
0
 public void copyFrom(DungeonMood another)
 {
     this.Id = another.Id;
     this.AmbientLightColor           = another.AmbientLightColor;
     this.DirectionalLightColor       = another.DirectionalLightColor;
     this.DirectionalLightIntensity   = another.DirectionalLightIntensity;
     this.DirectionalLightOrientation = another.DirectionalLightOrientation;
     this.FogColor                     = another.FogColor;
     this.BackgroundColor              = another.BackgroundColor;
     this.HeroLightColor               = another.HeroLightColor;
     this.HeroLightIntensity           = another.HeroLightIntensity;
     this.HeroLightRange               = another.HeroLightRange;
     this.HorizontalFogStartTerm       = another.HorizontalFogStartTerm;
     this.HorizontalFogEndTerm         = another.HorizontalFogEndTerm;
     this.FloorAndDecoMoodContribution = another.FloorAndDecoMoodContribution;
     this.DungeonLightColors           = new List <Color>(another.DungeonLightColors);
     this.DungeonLightIntensity        = another.DungeonLightIntensity;
     this.Weather   = another.Weather;
     this.PropColor = another.PropColor;
 }
コード例 #3
0
        public DungeonMood(DungeonMood prototype)
        {
            this.Id = string.Empty;
            this.AmbientLightColor           = Color.black;
            this.DirectionalLightColor       = Color.white;
            this.DirectionalLightOrientation = new Vector2(45f, -30f);
            this.FogColor                     = new Color(0.1098039f, 0.6745098f, 0.6078432f, 1f);
            this.BackgroundColor              = new Color(0.1176471f, 0.345098f, 0.3372549f, 1f);
            this.HeroLightColor               = new Color(0.9411765f, 0.5019608f, 0.5019608f, 1f);
            this.HeroLightIntensity           = 2.5f;
            this.HeroLightRange               = 13f;
            this.HorizontalFogStartTerm       = 12f;
            this.HorizontalFogEndTerm         = 28f;
            this.FloorAndDecoMoodContribution = 1f;
            List <Color> list = new List <Color>();

            list.Add(new Color(1f, 0.5647059f, 0f, 1f));
            list.Add(new Color(1f, 0.5647059f, 0f, 1f));
            list.Add(new Color(1f, 0.5647059f, 0f, 1f));
            this.DungeonLightColors    = list;
            this.DungeonLightIntensity = 1f;
            this.PropColor             = new Color(1f, 1f, 1f, 1f);
            this.copyFrom(prototype);
        }