public override void StateStart() { mAnimator.SetBool("Healthy", true); MoveTimerTotal = CitizenMgr.GenerateMovePeriod(); mCitizen.timeAlive = 0; mCitizen.transform.name = "Latent"; mCitizen.CitizenType = CitizenType.Latent; CitizenMgr.LatentCnt++; }
public override void StateStart() { MoveTimerTotal = CitizenMgr.GenerateMovePeriod(); mCitizen.CitizenType = CitizenType.Cured; mCitizen.ClearAllStatus(false); mCitizen.AddStatus(CitizenStatusType.Healthy); mCitizen.name = "Cured"; mAnimator.SetBool("Healthy", true); CitizenMgr.CuredCnt++; }
public override void StateStart() { mCitizen.timeAlive = 0; mAnimator.SetBool("Healthy", false); MoveTimerTotal = CitizenMgr.GenerateMovePeriod(); mCitizen.transform.name = "Ill"; mCitizen.CitizenType = CitizenType.Ill; mCitizen.AddStatus(CitizenStatusType.Ill); CitizenMgr.IllCnt++; }
public override void StateStart() { mCitizen.CitizenType = CitizenType.Healthy; mCitizen.timeAlive = 0; mCitizen.bWearingMask = false; MoveTimerTotal = CitizenMgr.GenerateMovePeriod(); mCitizen.transform.name = "Healthy"; mAnimator.SetBool("Healthy", true); CitizenMgr.HealthyCnt++; }
void RandomMove() { currentMoveTimer += Time.fixedDeltaTime; if (currentMoveTimer > MoveTimerTotal) { currentMoveTimer = 0; MoveTimerTotal = CitizenMgr.GenerateMovePeriod(); if (mCitizen.CheckReachDest()) { int loopTimes = 0; while (loopTimes++ < 10) { if (mCitizen.TryMove(CitizenMgr.GenerateMoveDest(), 0.1f)) { break; } } } } }