mirror of
https://github.com/swordbluesword/PalWorld-NetCrack.git
synced 2025-04-29 02:47:17 +09:00
move feature
This commit is contained in:
parent
54cc65378d
commit
b22c602634
21
feature.cpp
21
feature.cpp
@ -531,6 +531,27 @@ void ForgeActor(SDK::AActor* pTarget, float mDistance, float mHeight, float mAng
|
|||||||
pTarget->K2_SetActorRotation(targetRotation, true);
|
pTarget->K2_SetActorRotation(targetRotation, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// credit:
|
||||||
|
void SendDamageToActor(APalCharacter* character, int32 damage, bool bSpoofAttacker)
|
||||||
|
{
|
||||||
|
APalPlayerState* pPalPlayerState = Config.GetPalPlayerState();
|
||||||
|
APalPlayerCharacter* pPalPlayerCharacter = Config.GetPalPlayerCharacter();
|
||||||
|
if (!pPalPlayerState || !pPalPlayerCharacter)
|
||||||
|
return;
|
||||||
|
|
||||||
|
FPalDamageInfo info = FPalDamageInfo();
|
||||||
|
info.AttackElementType = EPalElementType::Normal;
|
||||||
|
info.Attacker = pPalPlayerCharacter; // @TODO: spoof attacker
|
||||||
|
info.AttackerGroupID = Config.GetPalPlayerState()->IndividualHandleId.PlayerUId;
|
||||||
|
info.AttackerLevel = 50;
|
||||||
|
info.AttackType = EPalAttackType::Weapon;
|
||||||
|
info.bApplyNativeDamageValue = true;
|
||||||
|
info.bAttackableToFriend = true;
|
||||||
|
info.IgnoreShield = true;
|
||||||
|
info.NativeDamageValue = damage;
|
||||||
|
pPalPlayerState->SendDamage_ToServer(character, info);
|
||||||
|
}
|
||||||
|
|
||||||
// credit: xCENTx
|
// credit: xCENTx
|
||||||
void TeleportAllPalsToCrosshair(float mDistance)
|
void TeleportAllPalsToCrosshair(float mDistance)
|
||||||
{
|
{
|
||||||
|
@ -55,6 +55,8 @@ float GetDistanceToActor(SDK::AActor* pLocal, SDK::AActor* pTarget);
|
|||||||
|
|
||||||
void ForgeActor(SDK::AActor* pTarget, float mDistance, float mHeight = 0.0f, float mAngle = 0.0f);
|
void ForgeActor(SDK::AActor* pTarget, float mDistance, float mHeight = 0.0f, float mAngle = 0.0f);
|
||||||
|
|
||||||
|
void SendDamageToActor(SDK::APalCharacter* character, int32 damage, bool bSpoofAttacker = false);
|
||||||
|
|
||||||
void TeleportAllPalsToCrosshair(float mDistance);
|
void TeleportAllPalsToCrosshair(float mDistance);
|
||||||
|
|
||||||
void AddWaypointLocation(std::string wpName);
|
void AddWaypointLocation(std::string wpName);
|
||||||
|
16
src/Menu.cpp
16
src/Menu.cpp
@ -15,20 +15,6 @@ std::string rand_str(const int len)
|
|||||||
}
|
}
|
||||||
return str;
|
return str;
|
||||||
}
|
}
|
||||||
void Damage(SDK::APalCharacter* character, int32 damage)
|
|
||||||
{
|
|
||||||
SDK::FPalDamageInfo info = SDK::FPalDamageInfo();
|
|
||||||
info.AttackElementType = SDK::EPalElementType::Normal;
|
|
||||||
info.Attacker = Config.GetPalPlayerCharacter();
|
|
||||||
info.AttackerGroupID = Config.GetPalPlayerState()->IndividualHandleId.PlayerUId;
|
|
||||||
info.AttackerLevel = 50;
|
|
||||||
info.AttackType = SDK::EPalAttackType::Weapon;
|
|
||||||
info.bApplyNativeDamageValue = true;
|
|
||||||
info.bAttackableToFriend = true;
|
|
||||||
info.IgnoreShield = true;
|
|
||||||
info.NativeDamageValue = damage;
|
|
||||||
Config.GetPalPlayerState()->SendDamage_ToServer(character, info);
|
|
||||||
}
|
|
||||||
|
|
||||||
int InputTextCallback(ImGuiInputTextCallbackData* data) {
|
int InputTextCallback(ImGuiInputTextCallbackData* data) {
|
||||||
char inputChar = data->EventChar;
|
char inputChar = data->EventChar;
|
||||||
@ -547,7 +533,7 @@ namespace DX11_Base
|
|||||||
if (ImGui::Button("Kill"))
|
if (ImGui::Button("Kill"))
|
||||||
{
|
{
|
||||||
if (T[i]->IsA(SDK::APalCharacter::StaticClass()))
|
if (T[i]->IsA(SDK::APalCharacter::StaticClass()))
|
||||||
Damage(Character, 99999999999);
|
SendDamageToActor(Character, 99999999999);
|
||||||
}
|
}
|
||||||
ImGui::SameLine();
|
ImGui::SameLine();
|
||||||
if (ImGui::Button("TP"))
|
if (ImGui::Button("TP"))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user