Ejemplo n.º 1
0
/// OBJの落下
///---------------------------------------------------------------------------

        public bool frameGravityObj()
        {
            GameCtrlManager ctrlResMgr = GameCtrlManager.GetInstance();

            Vector3 movePos = trgObjPos;

            movePos.Y = 0.0f;

            /// 対象のOBJを登録
            moveCollMgr.TrgContainer.Clear();
            ctrlResMgr.CtrlStg.SetCollisionActor(moveCollMgr.TrgContainer, trgObjPos);

            shapeMove.Set(0, movePos, 0.001f);
            calCollGrav.GetMovePos(moveCollMgr, ref movePos);
            shapeMove.Set(0, trgObjPos, 0.001f);

            calCollGrav.Check(moveCollMgr, movePos);


            trgObjPos = calCollGrav.NextPos;
            setTrgObjMove(new Vector3(0.0f, 0.0f, 0.0f));

            changeTask(debugMenuTaskId.SelectObj);
            return(true);
        }
Ejemplo n.º 2
0
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set(0, StaticDataList.getVectorZero(), 0.4f);

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize);

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize);

            appearCount = 30;
            glowCounter = 0;
            scale       = (int)Data.SetupValue.WallScale / 100.0f;

            farFlag = false;

            distance = Common.VectorUtil.DistanceXZ(pos1, pos2);
            angle    = FMath.Atan((pos1.X - pos2.X) / (pos1.Z - pos2.Z)) + FMath.PI / 2;

            return(true);
        }
Ejemplo n.º 3
0
        /// シーンの初期化
        public bool Init(DemoGame.SceneManager sceneMgr)
        {
            useSceneMgr = sceneMgr;

            calCollGrav = new ActorUnitCollGravity();
            calCollGrav.Init();

            moveCollMgr = new GameActorCollManager();
            moveCollMgr.Init();

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set(0, StaticDataList.getVectorZero(), 0.001f);

            renderSph = new DemoGame.RenderGeometry();
            renderSph.MakeSphere();
///        trgObj        = null;

            /// 移動する自身のOBJを登録
            moveCollMgr.SetMoveShape(shapeMove);


            trgObjMoveSpd = 1.0f;
            setPlaceTypeParam(trgObjType);

            nowTaskId = debugMenuTaskId.SelectObj;
            changeTask(debugMenuTaskId.SelectObj);
            return(true);
        }
Ejemplo n.º 4
0
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set(0, StaticDataList.getVectorZero(), 0.3f);

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize);

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize);
            scale = (int)Data.SetupValue.CharScale / 100.0f;

            moveAngle   = false;
            preDeadFlag = false;



//			useMdlHdl = new Common.ModelHandle();
//        useMdlHdl.Init();
            return(true);
        }
Ejemplo n.º 5
0
/// 継承メソッド
///---------------------------------------------------------------------------

        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set(0, StaticDataList.getVectorZero(), objWidth);

//		titanModel = new BasicModel("/Application/res/data/3D/char/titan.mdx", 0);
            program = new BasicProgram();
            return(true);
        }
Ejemplo n.º 6
0
        /// 継承メソッド
        ///---------------------------------------------------------------------------
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set( 0, new Vector3(0.0f, 0.0f, 0.0f), objWidth );

            useMdlHdl = new Common.ModelHandle();
            useMdlHdl.Init();
            baseScale = new Vector3( 1.0f, 1.0f, 1.0f );
            return true;
        }
Ejemplo n.º 7
0
/// 継承メソッド
///---------------------------------------------------------------------------

        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set(0, new Vector3(0.0f, 0.0f, 0.0f), objWidth);

            useMdlHdl = new Common.ModelHandle();
            useMdlHdl.Init();
            baseScale = new Vector3(1.0f, 1.0f, 1.0f);
            return(true);
        }
Ejemplo n.º 8
0
/// 継承メソッド
///---------------------------------------------------------------------------

        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set(0, StaticDataList.getVectorZero(), 0.4f);

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize);

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize);

            return(true);
        }
Ejemplo n.º 9
0
/// public メソッド
///--------------------------------------------------------------------------   -

        /// 初期化
        public bool Init()
        {
            boundingShape = new ShapeSphere();
            boundingShape.Init(1);
            boundingShape.Set(0, new Vector3(0.0f, 0.0f, 0.0f), 1.0f);
            deadFlag    = false;
            changeFlag  = false;
            glowNumber  = 0;
            glowCounter = 0;
            appearCount = (int)Data.SetupValue.AppearAndLeaveTime;
            firstFlag   = true;
            eatFlag     = false;
            glowFinish  = false;
            farFlag     = false;
            rotation.Z  = 0.0f;

            return(DoInit());
        }
Ejemplo n.º 10
0
        /// 継承メソッド
        ///---------------------------------------------------------------------------
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set( 0, StaticDataList.getVectorZero(), 0.4f );

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set( 0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize );

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set( 0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize );

            farFlag = false;
            return true;
        }
Ejemplo n.º 11
0
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set(0, StaticDataList.getVectorZero(), 0.4f);

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize);

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize);
            farFlag       = false;
            countForHouse = (int)Data.SetupValue.NewHouseAppearTime;
            return(true);
        }
Ejemplo n.º 12
0
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set(0, StaticDataList.getVectorZero(), 0.4f);

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize);

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set(0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize);

            glowCounter = 0;
            scale       = (int)Data.SetupValue.TowerScale / 100.0f;
            farFlag     = false;
            return(true);
        }
Ejemplo n.º 13
0
        /// public メソッド
        ///--------------------------------------------------------------------------  	-
        /// 初期化
        public bool Init()
        {
            boundingShape    = new ShapeSphere();
            boundingShape.Init( 1 );
            boundingShape.Set( 0, new Vector3( 0.0f, 0.0f, 0.0f ), 1.0f );
            deadFlag = false;
            changeFlag = false;
            glowNumber = 0;
            glowCounter = 0;
            appearCount = (int)Data.SetupValue.AppearAndLeaveTime;
            firstFlag = true;
            eatFlag = false;
            glowFinish = false;
            farFlag = false;
            rotation.Z = 0.0f;

            return( DoInit() );
        }
Ejemplo n.º 14
0
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set( 0, StaticDataList.getVectorZero(), 0.4f );

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set( 0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize );

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set( 0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize );

            scale = (int)Data.SetupValue.WallScale /100.0f;

            farFlag = false;

            distance = Common.VectorUtil.DistanceXZ( pos1 ,pos2 );
            angle = FMath.Atan((pos1.X-pos2.X)/(pos1.Z-pos2.Z)) +FMath.PI/2;

            return true;
        }
Ejemplo n.º 15
0
        /// シーンの初期化
        public bool Init( DemoGame.SceneManager sceneMgr )
        {
            useSceneMgr = sceneMgr;

            calCollGrav    = new ActorUnitCollGravity();
            calCollGrav.Init();

            moveCollMgr = new GameActorCollManager();
            moveCollMgr.Init();

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set( 0, StaticDataList.getVectorZero(), 0.001f );

            renderSph = new DemoGame.RenderGeometry();
            renderSph.MakeSphere();
            ///        trgObj        = null;

            /// 移動する自身のOBJを登録
            moveCollMgr.SetMoveShape( shapeMove );

            trgObjMoveSpd = 1.0f;
            setPlaceTypeParam( trgObjType );

            nowTaskId    = debugMenuTaskId.SelectObj;
            changeTask( debugMenuTaskId.SelectObj );
            return true;
        }
Ejemplo n.º 16
0
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set( 0, StaticDataList.getVectorZero(), 0.3f );

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set( 0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize );

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set( 0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize );
            scale = (int)Data.SetupValue.CharScale/100.0f;

            moveAngle = false;

            //			useMdlHdl = new Common.ModelHandle();
            //        useMdlHdl.Init();
            return true;
        }
Ejemplo n.º 17
0
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set( 0, StaticDataList.getVectorZero(), 0.4f );

            shapeColl = new ShapeCapsule();
            shapeColl.Init(1);
            shapeColl.Set( 0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TitanSize );

            shapeCollforDis = new ShapeCapsule();
            shapeCollforDis.Init(1);
            shapeCollforDis.Set( 0, StaticDataList.getVectorZero(), new Vector3(0.0f, 2.0f, 0.0f), (float)Data.SetupValue.TouchSize );

            glowCounter = 0;
            scale = (int)Data.SetupValue.TowerScale /100.0f;
            return true;
        }
Ejemplo n.º 18
0
        /// 継承メソッド
        ///---------------------------------------------------------------------------
        /// 初期化
        public override bool DoInit()
        {
            shapeMove = null;

            shapeMove = new ShapeSphere();
            shapeMove.Init(1);
            shapeMove.Set( 0, StaticDataList.getVectorZero(), objWidth );

            //		titanModel = new BasicModel("/Application/res/data/3D/char/titan.mdx", 0);
            program = new BasicProgram() ;
            return true;
        }