static BlockTypes() { blockTypes = new BlockType[256]; nameMap = new Dictionary<string, BlockType>(); //!!!!!!!!!!!!!!!!!!!!!!! //!!Reihenfolge WICHTIG!! //!!!!!!!!!!!!!!!!!!!!!!! addCube(Color.Black, CubeType.Empty, false, BlockingType.Hard, 0, "Nothing", "Not yet loaded"); addCube(Color.Transparent, CubeType.Empty, true, BlockingType.Free, 0, "Air", "Nothing but air"); addCube(Color.Gray, CubeType.Solid, true, BlockingType.Hard, 1, "Stone", "Gray 'n' cold stone"); addCube(Color.Brown, CubeType.Solid, true, BlockingType.Hard, 2, "Dirt", "Brown crap"); addCube(Color.Transparent, CubeType.SemiTransparent, true, BlockingType.Hard, 49, "Glass", "You can see through glass"); addCustom(Color.White, BlockingType.Hard, 136, GetCyl(18), "Column", "Roundy round thingy"); addCube(Color.White, CubeType.Solid, true, BlockingType.Hard, 135, "Marble", "Big time"); addCustom(Color.Green, BlockingType.Free, 15, GetFold(3, 1.6f, -0.5f, 1f, Vector2.Zero), "Bush", "Green hope"); addCube(Color.LimeGreen, CubeType.Solid, true, BlockingType.Hard, 0, "Grass", "Awesome", GetFold(3, 1.6f, 0.5f, 1.5f, Vector2.UnitY)); addCustom(Color.Red, BlockingType.Free, 12, GetFold(3, 1.6f, -0.5f, 1f, Vector2.Zero), "Flower", "Red roses are gay"); addCustom(Color.Brown, BlockingType.Hard, 116, GetCyl(18), "Tree1", "Kind A"); addCustom(Color.Brown, BlockingType.Hard, 117, GetCyl(18), "Tree2", "Kind B"); addCustom(Color.Transparent, BlockingType.Free, 132, GetWild(3, 5f), "Leaf1", "Kind A"); addCustom(Color.Transparent, BlockingType.Free, 133, GetWild(3, 5f), "Leaf2", "Kind B"); addCube(Color.Brown, CubeType.Solid, true, BlockingType.Hard, 4, "Wood", "Get outa heee"); addCube(Color.Black, CubeType.Solid, true, BlockingType.Hard, 151, "BMarble", "Big time as well"); addCube(Color.CornflowerBlue, CubeType.SemiTransparent, true, BlockingType.Liquid, 49, "Water", "Wet stuff"); addCube(Color.Brown, CubeType.Solid, true, BlockingType.Hard, 7, "Brick", "Badaboom"); }
public void PlaceableTest() { BlockType target = new BlockType(); // TODO: Passenden Wert initialisieren bool actual; actual = target.Placeable; Assert.Inconclusive("Überprüfen Sie die Richtigkeit dieser Testmethode."); }
bool IsVisibleTo(BlockType block, uint x, uint y, uint z) { if (parentVolume == null) return true; var id = parentVolume.ReadValue(x + this.X, y + this.Y, z + this.Z); if (id == block.ID) return false; return !BlockTypes.FromID(id).IsSolid; }
static void add(BlockType bt) { nameMap[bt.Name] = bt; blockTypes[bt.ID = count] = bt; count++; }
public void BlockTypeConstructorTest() { BlockType target = new BlockType(); Assert.Inconclusive("TODO: Code zum Überprüfen des Ziels implementieren"); }