Skip to content

Some addition for the headers of g3sdk while working on some features #17

Description

@Jackydima

gCSessionKeys

  • while working on a evade feature, I got to utilize the mapped sessionkeys for the game
  • it appears the Game.dll lib actually has the constructor gCSessionKeys::gCSessionKeys(class gCSessionKeys const &) protected
  • the sdk has this one public
  • error message was
Verweis auf nicht aufgelöstes externes Symbol ""__declspec(dllimport) public: __thiscall gCSessionKeys::gCSessionKeys(class gCSessionKeys const &)" (__imp_??0gCSessionKeys@@QAE@ABV0@@Z)" in Funktion ""void __stdcall EvadeMechanic(class gCScriptProcessingUnit *)" (?EvadeMechanic@@YGXPAVgCScriptProcessingUnit@@@Z)".
Image

Updated like that, instead of using Marko GE_PROPERTY_SET(gCSessionKeys, bCObjectRefBase)
Image

Had to use the funny method of getting sessionkey with these constraints

gCSessionKeys sessionKeys = gCSessionKeys();
sessionKeys = gCSession::GetInstance().GetSessionKeys();

instead of

gCSessionKeys sessionKeys = gCSession::GetInstance().GetSessionKeys();

gCScriptProcessingUnit

  • while analyzing and reversing the static gCScriptProcessingUnit::sAICombatMoveStart() function I found some more member fields for the gCScriptProcessingUnit.
...
public:
  bTObjStack<gScriptRunTimeSingleState> m_StateStack;
  bCString m_strCurrentTask;
  bCString m_strTaskCallback;
  GEFloat m_fTaskCallbackRelatedFloat_1000;
  GEFloat m_fLocalCallbackRelatedFloat_100;
  eCEntityProxy m_SelfEntity;
  eCEntityProxy m_OtherEntity;
  GEInt m_iIntParameter;
  GEFloat m_fTaskTime;
  GEFloat m_fStateTime;
  GEBool m_bTaskRelated;
  GE_PADDING(3)
  bCString m_strCaughtTask;
  GELPVoid m_pAudioChannel;
  GELPVoid m_pAudioSound;
  GELPVoid m_pfInstrCallback;
  eCEntityProxy m_Speaker;
  GEBool m_bOutputFinished;
  GE_PADDING(3)
  GEFloat m_fInstrPlayTime;
  GEFloat m_fInstrDuration;
  // TODO: Modified SDK Header
  // GE_UNIMPL_MEMBERS(0xEC)
  GE_UNIMPL_MEMBERS(0x5C)
  bCVector m_DirectionVec;
  eCEntityProxy m_CombatTarget;
  GE_UNIMPL_MEMBERS(0x4);
  gCNavigation_PS *m_SelfNavigationPS;
  gCCharacterMovement_PS *m_SelfMovementPS;
  eCVisualAnimation_PS *m_SelfAnimationPS;
  eCWrapper_emfx2Motion::eSMotionDesc m_sMotionDesc;
  bCString m_strAniString;
  gEAction m_InstrAction;
  GE_UNIMPL_MEMBERS(0x8)
  GEFloat m_fAniSpeedScale;
  GE_UNIMPL_MEMBERS(0x28)
  • also it seems like the eCEntityProxy m_Speaker; member is the Proxy for the SelfEntity aswell which is used in gCScriptProcessingUnit-Instr functionality

eCWrapper_emfx2Motion::eSMotionDesc

  • for using the eCVisualAnimation_PS::PlayMotion() method there the eSMotionDesc is needed.
  • I got the size of it, but still am still missing information about what each value means.
 struct eSMotionDesc
{
    //GE_UNIMPL_STRUCT(eSMotionDesc)
    // TODO SDK Update:
    GEFloat m_fFirst;
    GEInt m_iSecond;
    GEFloat m_fAniSpeedScale;
    GEInt m_iFourth;
    GEFloat m_fUnknown1;
    GEFloat m_fSixth;
    GEInt m_iUnknown2;
};

eCWrapper_emfx2Actor::eEMotionType

  • I figured SOME enum values for the eEMotionType, which is used for getting information about an Entities Motion.
  • Observed the ANI-Debug View of the Marvin mode and found correlations in the gCScriptProcessingUnit::sAICombatMoveStart() usage
enum eEMotionType
    {
        // TODO: Enumerator values
        // TODO Adjusted SDK
        eEMotionType_PrimaryFirst,
        eEMotionType_PrimarySecond,
        eEMotionType_PrimaryThird,
        eEMotionType_PrimaryFourth,
        eEMotionType_OverlayFirst,
        eEMotionType_OverlaySecond,
    };

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions