Example #1
0
            public override List <LEVoxel> CreateVoxels(VoxAtlas atlas)
            {
                voxels = new List <LEVoxel>(GameState.MAX_NONENV_PLAYERS * 2);
                LEVoxel lev;
                VGPCube vgp;

                for (int i = 0; i < GameState.MAX_NONENV_PLAYERS; i++)
                {
                    // Create HQ Voxel
                    lev = new LEVoxel("Team " + (i + 1) + " HQ", atlas);
                    lev.VData.FaceType.SetAllTypes(0x00000001u);
                    lev.VData.FaceType.SetAllMasks(0xfffffffeu);
                    vgp                   = new VGPCube();
                    vgp.Color             = TEAM_COLORS[i];
                    vgp.UVRect            = new Vector4(DUV * 0, DUV * 1, DUV, DUV);
                    lev.VData.GeoProvider = vgp;
                    voxels.Add(lev);

                    // Create Barracks Voxel
                    lev = new LEVoxel("Team " + (i + 1) + " Barracks", atlas);
                    lev.VData.FaceType.SetAllTypes(0x00000001u);
                    lev.VData.FaceType.SetAllMasks(0xfffffffeu);
                    vgp                   = new VGPCube();
                    vgp.Color             = TEAM_COLORS[i];
                    vgp.UVRect            = new Vector4(DUV * 1, DUV * 1, DUV, DUV);
                    lev.VData.GeoProvider = vgp;
                    voxels.Add(lev);
                }
                minID = voxels[0].VData.ID;
                maxID = voxels[voxels.Count - 1].VData.ID;
                return(voxels);
            }
Example #2
0
        public override List <LEVoxel> CreateVoxels(VoxAtlas atlas)
        {
            float duv = 1f / 8f;

            voxels = new List <LEVoxel>(2);
            LEVoxel lev;
            VGPCube vgp;

            // Create Flora Voxel
            lev = new LEVoxel("Flora", atlas);
            lev.VData.FaceType.SetAllTypes(0x00000001u);
            lev.VData.FaceType.SetAllMasks(0xfffffffeu);
            vgp                   = new VGPCube();
            vgp.Color             = Color.Khaki;
            vgp.UVRect            = new Vector4(duv * 0, duv * 1, duv, duv);
            lev.VData.GeoProvider = vgp;
            voxels.Add(lev);

            // Create Ore Voxel
            lev = new LEVoxel("Ore", atlas);
            lev.VData.FaceType.SetAllTypes(0x00000001u);
            lev.VData.FaceType.SetAllMasks(0xfffffffeu);
            vgp                   = new VGPCube();
            vgp.Color             = Color.Purple;
            vgp.UVRect            = new Vector4(duv * 1, duv * 1, duv, duv);
            lev.VData.GeoProvider = vgp;
            voxels.Add(lev);

            minID = voxels[0].VData.ID;
            maxID = voxels[voxels.Count - 1].VData.ID;
            return(voxels);
        }
        public override List <LEVoxel> CreateVoxels(VoxAtlas atlas)
        {
            float duv = 1f / 8f;

            voxels = new List <LEVoxel>(1);

            // Create Camera Voxel
            LEVoxel lev = new LEVoxel("Camera Position", atlas);

            lev.VData.FaceType.SetAllTypes(0x00000001u);
            lev.VData.FaceType.SetAllMasks(0xfffffffeu);
            VGPCube vgp = new VGPCube();

            vgp.Color             = Color.White;
            vgp.UVRect            = new Vector4(duv * 0, duv * 1, duv, duv);
            lev.VData.GeoProvider = vgp;
            voxels.Add(lev);

            camID = voxels[0].VData.ID;
            return(voxels);
        }
        public override List<LEVoxel> CreateVoxels(VoxAtlas atlas)
        {
            float duv = 1f / 8f;
            voxels = new List<LEVoxel>(2);
            LEVoxel lev;
            VGPCube vgp;

            // Create Flora Voxel
            lev = new LEVoxel("Flora", atlas);
            lev.VData.FaceType.SetAllTypes(0x00000001u);
            lev.VData.FaceType.SetAllMasks(0xfffffffeu);
            vgp = new VGPCube();
            vgp.Color = Color.Khaki;
            vgp.UVRect = new Vector4(duv * 0, duv * 1, duv, duv);
            lev.VData.GeoProvider = vgp;
            voxels.Add(lev);

            // Create Ore Voxel
            lev = new LEVoxel("Ore", atlas);
            lev.VData.FaceType.SetAllTypes(0x00000001u);
            lev.VData.FaceType.SetAllMasks(0xfffffffeu);
            vgp = new VGPCube();
            vgp.Color = Color.Purple;
            vgp.UVRect = new Vector4(duv * 1, duv * 1, duv, duv);
            lev.VData.GeoProvider = vgp;
            voxels.Add(lev);

            minID = voxels[0].VData.ID;
            maxID = voxels[voxels.Count - 1].VData.ID;
            return voxels;
        }
Example #5
0
            public override List<LEVoxel> CreateVoxels(VoxAtlas atlas)
            {
                voxels = new List<LEVoxel>(GameState.MAX_NONENV_PLAYERS * 2);
                LEVoxel lev;
                VGPCube vgp;
                for(int i = 0; i < GameState.MAX_NONENV_PLAYERS; i++) {
                    // Create HQ Voxel
                    lev = new LEVoxel("Team " + (i + 1) + " HQ", atlas);
                    lev.VData.FaceType.SetAllTypes(0x00000001u);
                    lev.VData.FaceType.SetAllMasks(0xfffffffeu);
                    vgp = new VGPCube();
                    vgp.Color = TEAM_COLORS[i];
                    vgp.UVRect = new Vector4(DUV * 0, DUV * 1, DUV, DUV);
                    lev.VData.GeoProvider = vgp;
                    voxels.Add(lev);

                    // Create Barracks Voxel
                    lev = new LEVoxel("Team " + (i + 1) + " Barracks", atlas);
                    lev.VData.FaceType.SetAllTypes(0x00000001u);
                    lev.VData.FaceType.SetAllMasks(0xfffffffeu);
                    vgp = new VGPCube();
                    vgp.Color = TEAM_COLORS[i];
                    vgp.UVRect = new Vector4(DUV * 1, DUV * 1, DUV, DUV);
                    lev.VData.GeoProvider = vgp;
                    voxels.Add(lev);
                }
                minID = voxels[0].VData.ID;
                maxID = voxels[voxels.Count - 1].VData.ID;
                return voxels;
            }
        public override List<LEVoxel> CreateVoxels(VoxAtlas atlas)
        {
            float duv = 1f / 8f;
            voxels = new List<LEVoxel>(1);

            // Create Camera Voxel
            LEVoxel lev = new LEVoxel("Camera Position", atlas);
            lev.VData.FaceType.SetAllTypes(0x00000001u);
            lev.VData.FaceType.SetAllMasks(0xfffffffeu);
            VGPCube vgp = new VGPCube();
            vgp.Color = Color.White;
            vgp.UVRect = new Vector4(duv * 0, duv * 1, duv, duv);
            lev.VData.GeoProvider = vgp;
            voxels.Add(lev);

            camID = voxels[0].VData.ID;
            return voxels;
        }