Skip to content
New issue

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

Object sync - fixes and improvements #3405

Draft
wants to merge 20 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Client/mods/deathmatch/logic/CClientCommon.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@
// Defines the maximum size for a HTTP Download URL (with file / directory information appended)
#define MAX_HTTP_DOWNLOAD_URL_WITH_FILE 768

#define WITH_OBJECT_SYNC 1

enum eHTTPDownloadType
{
HTTP_DOWNLOAD_DISABLED = 0,
Expand Down
8 changes: 7 additions & 1 deletion Client/mods/deathmatch/logic/CClientGame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4783,7 +4783,13 @@ bool CClientGame::ObjectDamageHandler(CObjectSAInterface* pObjectInterface, floa
else
Arguments.PushNil();

return pClientObject->CallEvent("onClientObjectDamage", Arguments, true);
bool bContinue = pClientObject->CallEvent("onClientObjectDamage", Arguments, true);
if (bContinue && !pClientObject->IsLocalEntity() && pClientAttacker)
{
pClientObject->SetAttackerID(pClientAttacker->GetID());
}

return bContinue;
}
}
return true;
Expand Down
Loading
Loading