Files
firestorm/Gameleap/code/mw4/Code/MW4/MechAnimationState.hpp
T
Cyd 2b8ca921cb Initial full mirror of c:\VWE (source + assets + toolchain + outputs) via Git LFS
Complete disaster-recovery snapshot: engine/game source, game data assets,
VC6 toolchain + DX SDKs, build outputs, deployed game, and _UNUSED archive.
Large binaries in Git LFS; text preserved byte-for-byte (core.autocrlf=false,
no eol attributes). See RECOVERY.md for the one-clone rebuild procedure.
2026-06-24 21:28:16 -05:00

161 lines
3.5 KiB
C++

//===========================================================================//
// File: AnimationState.hpp
//---------------------------------------------------------------------------//
// Date Who Modification //
// -------- --- ---------------------------------------------------------- //
// 02/23/999 JSE Inital coding
//---------------------------------------------------------------------------//
// Copyright (C) 1998, Microsoft Corp. //
// All Rights reserved worldwide //
// This unpublished sourcecode is PROPRIETARY and CONFIDENTIAL //
//===========================================================================//
#pragma once
#include "AnimationState.hpp"
namespace MechWarrior4
{
class Vehicle;
class Mech;
class MechAnimationStateEngine:
public AnimationStateEngine
{
public:
static void
InitializeClass();
static void
TerminateClass();
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Run-time Construction and Destruction Support
//
public:
static MechAnimationStateEngine*
Make(Vehicle *vehicle, const FactoryRequest *request);
void
Save(FactoryRequest *request);
void
Reuse(const FactoryRequest *request);
~MechAnimationStateEngine();
protected:
MechAnimationStateEngine(
Vehicle *vehicle,
ClassData *class_data,
const FactoryRequest *request
);
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Shared Data support
//
public:
ClassData*
GetClassData();
static ClassData
*DefaultData;
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// State entries
//
public:
enum {
StandState = AnimationStateEngine::StateCount,//10
StandHalfState,
Stand_1_8_thState,
Stand_2_8_thState,
Stand_3_8_thState,
Stand_5_8_thState,
Stand_6_8_thState,
Stand_7_8_thState,
ForwardState,//18
BackwardState,
TurnLeftState,
TurnRightState,
LGimpTurnRightState,
RGimpTurnRightState,
LGimpTurnLeftState,
RGimpTurnLeftState,
GimpStandLeftState,
GimpForwardLeftState,
GimpStandRightState,
GimpForwardRightState,
FallForwardState,
FallBackwardState,
FallLeftState,
FallRightState,
FallCataclysmicState,
PowerDownState,
PowerDownCataclysmicState,
CrouchState,
FlyState,
StateCount
};
protected:
static const StateEntry
StateEntries[];
public:
int
RequestState(
int new_state,
bool run_minimal = false,
void* data = NULL
);
void
RunStates(Stuff::Scalar time_slice, bool run_minimal = false);
Mech *
m_Mech;
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Test Support
//
public:
void
TestClass();
};
//#############################################################################
//########################## Inlines ########################
//#############################################################################
inline MechAnimationStateEngine::ClassData*
MechAnimationStateEngine::GetClassData()
{
Check_Object(this);
return Cast_Pointer(ClassData*, classData);
}
}