public ZertzRingRenderer RemoveRing(HexLocation loc)
        {
            ZertzRingRenderer zrr = rings[loc.X, loc.Y];

            ringlocs.Remove(zrr);
            rings[loc.X, loc.Y] = null;
            return(zrr);
        }
Exemple #2
0
        public static ZertzRingRenderer[] GenerateRings(RenderContainer rc, ZertzBoardRenderer board, ZertzGame game, ZertzCupRenderer cup, HexLocation[] hls, int offsetid)
        {
            int n  = hls.Length;
            int id = offsetid;
            ZertzRingRenderer zrr;

            ZertzRingRenderer[] list = new ZertzRingRenderer[n];
            ZertzTileRenderer   ztr;
            float time = n * TIME_FACTOR + TIME_OFFSET;

            for (int i = 0x00; i < n; i++)
            {
                ztr = cup.MinimalTile;
                zrr = new ZertzRingRenderer(game, hls[i], ztr.NextVector, ztr.TileEscapeLocation, time);
                board.PutRing(zrr, hls[i]);
                ztr.Add(zrr);
                list[i] = zrr;
                rc.Add(id++, zrr);
                time -= TIME_FACTOR;
            }
            cup.ClearTiles();
            return(list);
        }
 public void PutRing(ZertzRingRenderer ring, HexLocation loc)
 {
     ringlocs.Add(ring,loc);
     rings[loc.X,loc.Y] = ring;
 }
Exemple #4
0
 public static ZertzRingRenderer[] GenerateRings(RenderContainer rc, ZertzBoardRenderer board, ZertzGame game, ZertzCupRenderer cup, HexLocation[] hls, int offsetid)
 {
     int n = hls.Length;
     int id = offsetid;
     ZertzRingRenderer zrr;
     ZertzRingRenderer[] list = new ZertzRingRenderer[n];
     ZertzTileRenderer ztr;
     float time = n*TIME_FACTOR+TIME_OFFSET;
     for(int i = 0x00; i < n; i++) {
         ztr = cup.MinimalTile;
         zrr = new ZertzRingRenderer(game,hls[i],ztr.NextVector,ztr.TileEscapeLocation,time);
         board.PutRing(zrr,hls[i]);
         ztr.Add(zrr);
         list[i] = zrr;
         rc.Add(id++,zrr);
         time -= TIME_FACTOR;
     }
     cup.ClearTiles();
     return list;
 }
 public void PutRing(ZertzRingRenderer ring, HexLocation loc)
 {
     ringlocs.Add(ring, loc);
     rings[loc.X, loc.Y] = ring;
 }
Exemple #6
0
 public void Remove(ZertzRingRenderer ring)
 {
     this.rings.Remove(ring);
 }
Exemple #7
0
 public void Add(ZertzRingRenderer ring)
 {
     this.rings.Add(ring);
     this.offset.Y += 4.0f*ZertzRingRenderer.THICKNESS;
 }
Exemple #8
0
 public void Remove(ZertzRingRenderer ring)
 {
     this.rings.Remove(ring);
 }
Exemple #9
0
 public void Add(ZertzRingRenderer ring)
 {
     this.rings.Add(ring);
     this.offset.Y += 4.0f * ZertzRingRenderer.THICKNESS;
 }