public override cCritter copy() { cCritter3DBoss c = new cCritter3DBoss(); c.copy(this); return(c); }
public override void copy(cCritter pcritter) { base.copy(pcritter); if (!pcritter.IsKindOf("cCritter3DBoss")) { return; } cCritter3DBoss pcritterplayer = (cCritter3DBoss)(pcritter); }
public void setRoom2() { Biota.purgeCritters("cCritterWall"); Biota.purgeCritters("cCritter3Dcharacter"); Biota.purgeCritters("cCritter3DCharacterEnemy"); setBorder(BORDER_XZ, BORDER_Y, BORDER_XZ); cRealBox3 skeleton = new cRealBox3(); skeleton.copy(_border); setSkyBox(skeleton); SkyBox.setAllSidesTexture(BitmapRes.BossRoom, 0); SkyBox.setSideTexture(cRealBox3.LOX, BitmapRes.BossRoom_90r); SkyBox.setSideTexture(cRealBox3.HIX, BitmapRes.BossRoom_90r); SkyBox.setSideTexture(cRealBox3.LOY, BitmapRes.Concrete); SkyBox.setSideSolidColor(cRealBox3.HIY, Color.Blue); _seedcount = 0; Player.setMoveBox(new cRealBox3(BORDER_XZ, BORDER_Y, BORDER_XZ)); Player.MaxSpeed = 30; //reduce player max speed to account for smaller room Player.moveTo(new cVector3(_border.Midx, _border.Midy, _border.Hiz)); float zpos = 0.0f; /* Point on the z axis where we set down the wall. 0 would be center, * halfway down the hall, but we can offset it if we like. */ float height = 0.1f * _border.YSize; float ycenter = -_border.YRadius + height / 2.0f; float wallthickness = cGame3D.WALLTHICKNESS; cCritterWall pwall = new cCritterWall( new cVector3(_border.Lox, ycenter, zpos), new cVector3(_border.Hix, ycenter, zpos), _border.YSize - 4, //thickness param for wall's dy which goes perpendicular to the //baseline established by the frist two args, up the screen wallthickness, //height argument for this wall's dz goes into the screen this); cSpriteTextureBox pspritebox = new cSpriteTextureBox(pwall.Skeleton, BitmapRes.Wall3, 16); //Sets all sides /* We'll tile our sprites three times along the long sides, and on the * short ends, we'll only tile them once, so we reset these two. */ pwall.Sprite = pspritebox; wentThrough = true; startNewRoom = Age; movingWall = new cCritterMovingWall( new cVector3(_border.Midx - 2, _border.Midy, _border.Loz + 10.0f), new cVector3(_border.Midx - 2, _border.Midy, _border.Loz + 2.0f), 10.0f, 1, this); cSpriteTextureBox pspritedoor = new cSpriteTextureBox(movingWall.Skeleton, BitmapRes.Door); movingWall.Sprite = pspritedoor; shouldMoveWall = true; //spawn two bosses in final room cCritter3DBoss boss1 = new cCritter3DBoss(this); boss1.moveTo(new cVector3(_border.Hiz - 3.0f, _border.Loy, _border.Hix - 3.0f)); cCritter3DBoss boss2 = new cCritter3DBoss(this); boss2.moveTo(new cVector3(_border.Loz + 3.0f, _border.Loy, _border.Lox + 3.0f)); cCritterDragonball dball6 = new cCritterDragonball(this); dball6.moveTo(new cVector3(_border.Lox, Border.Loy, _border.Hiz - 3.0f)); cCritterDragonball dball7 = new cCritterDragonball(this); dball7.moveTo(new cVector3(_border.Hix - 2, Border.Loy, _border.Loz + 2)); }