We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
this is how i'm getting pre and post engine prediction flags:
int iPreFlags = pLocal->GetFlags(); /* * CL_RunPrediction * correct prediction when framerate is lower than tickrate * https://github.com/VSES/SourceEngine2007/blob/master/se2007/engine/cl_pred.cpp#L41 */ if (I::ClientState->iDeltaTick > 0) I::Prediction->Update(I::ClientState->iDeltaTick, I::ClientState->iDeltaTick > 0, I::ClientState->iLastCommandAck, I::ClientState->iLastOutgoingCommand + I::ClientState->nChokedCommands); CPrediction::Get().Start(pCmd, pLocal); { int iPostFlags = pLocal->GetFlags(); CMiscellaneous::Get().Test(pCmd, iPreFlags, iPostFlags);
that test function does this:
void CMiscellaneous::Test(CUserCmd* pCmd, int iPreFlags, int iPostFlags) { if (iPreFlags & FL_ONGROUND) { L::PushConsoleColor(FOREGROUND_RED); L::Print(XorStr("PREFLAGS: ONGROUND")); } else if (!(iPreFlags & FL_ONGROUND)) { L::PushConsoleColor(FOREGROUND_GREEN); L::Print(XorStr("PREFLAGS: ONAIR")); } if (iPostFlags & FL_ONGROUND) { L::PushConsoleColor(FOREGROUND_RED); L::Print(XorStr("POSTFLAGS: ONGROUND")); } else if (!(iPostFlags & FL_ONGROUND)) { L::PushConsoleColor(FOREGROUND_GREEN); L::Print(XorStr("POSTFLAGS: ONAIR")); } }
here's an example of what it looks like:
as you can see, post and pre engine prediction flags update at the same time, even tho post should update 1 tick before pre.
The text was updated successfully, but these errors were encountered:
u should call CMiscellaneous::Test after CPrediction::End stop disinformation
CMiscellaneous::Test
CPrediction::End
also rn im maked simple edge jump implementation and all works fine men
Sorry, something went wrong.
do you mind sharing your code? i did that too and the result is the same
CPrediction::Get().End(pCmd, pLocal); int iPostFlags = pLocal->GetFlags(); CMiscellaneous::Get().Test(pCmd, iPreFlags, iPostFlags)
already removed the code but can write pseudo for u
void PrePredictionEdgeJump(CBaseEntity* pLocal) { if (pLocal->GetMoveType() == MOVETYPE_LADDER || pLocal->GetMoveType() == MOVETYPE_NOCLIP) return; /* save flags to static var in class */ iFlagsBackup = pLocal->GetFlags(); } void PostPredictionEdjeJump(CUserCmd* pCmd, CBaseEntity* pLocal) { if (pLocal->GetMoveType() == MOVETYPE_LADDER || pLocal->GetMoveType() == MOVETYPE_NOCLIP) return; if (iFlagsBackup & FL_ONGROUND && !(pLocal->GetFlags() & FL_ONGROUND)) pCmd->iButtons |= IN_JUMP; }
then in cm
PrePredictionEdgeJump(pLocal); CPrediction::Get().Start(); { // ... } CPrediction::Get().End(); PostPredictionEdgeJump(pCmd, pLocal);
No branches or pull requests
this is how i'm getting pre and post engine prediction flags:
that test function does this:
here's an example of what it looks like:
as you can see, post and pre engine prediction flags update at the same time, even tho post should update 1 tick before pre.
The text was updated successfully, but these errors were encountered: