public cLightSystem(uint width, uint height, Color clear_color, AssetContext assets)
        {
            this.assets                = assets;
            staticLights               = new List <cLight>();
            dynamicLights              = new List <cLight>();
            m_ClearColor               = clear_color;
            lightMapDarkShape          = new RectangleShape();
            lightMapDarkShape.Position = new Vector2f(0.0f, 0.0f);
            this.Create(width, height);

            loadShader();
        }
        public cLightSystem(Color clear_color, AssetContext assets)
        {
            this.assets                = assets;
            lightMapDarkShape          = new RectangleShape();
            lightMapDarkShape.Position = new Vector2f(0.0f, 0.0f);

            staticLights  = new List <cLight>();
            dynamicLights = new List <cLight>();
            m_ClearColor  = clear_color;

            lightTexture        = new Texture(assets.GetTexture("light1"));
            lightTexture.Smooth = true;
            lightSprite         = new Sprite(this.lightTexture);
            lightSprite.Origin  = new Vector2f(lightTexture.Size.X / 2.0f, lightTexture.Size.Y / 2.0f);
            //lightSprite.Scale = new Vector2f(0.45f, 0.45f);
            loadShader();
        }
Exemple #3
0
 public void Mix(AssetContext other_context)
 {
 }