mirror of
https://github.com/Milxnor/Project-Reboot-3.0.git
synced 2026-01-13 02:42:22 +01:00
a bit of stuff
toys, ammo in bottom right kinda, fix lootin speeds, being inaccurate, playlist looting kindof, or some things just not working.
This commit is contained in:
@@ -96,46 +96,6 @@ void UAbilitySystemComponent::InternalServerTryActivateAbilityHook(UAbilitySyste
|
||||
{
|
||||
// LOG_INFO(LogAbilities, "InternalServerTryActivateAbility. Activated {}", AbilityToActivate->GetName());
|
||||
}
|
||||
|
||||
// bro ignore this next part idk where to put it ok
|
||||
|
||||
/* static auto OwnerActorOffset = AbilitySystemComponent->GetOffset("OwnerActor");
|
||||
auto PlayerState = Cast<AFortPlayerStateAthena>(AbilitySystemComponent->Get<AActor*>(OwnerActorOffset));
|
||||
|
||||
if (!PlayerState)
|
||||
return;
|
||||
|
||||
auto Controller = Cast<AFortPlayerController>(PlayerState->GetOwner());
|
||||
LOG_INFO(LogAbilities, "Owner {}", PlayerState->GetOwner()->GetFullName());
|
||||
|
||||
if (!Controller)
|
||||
return;
|
||||
|
||||
auto Pawn = Controller->GetMyFortPawn();
|
||||
|
||||
if (!Pawn)
|
||||
return;
|
||||
|
||||
auto CurrentWeapon = Pawn->GetCurrentWeapon();
|
||||
auto WorldInventory = Controller ? Controller->GetWorldInventory() : nullptr;
|
||||
|
||||
if (!WorldInventory || !CurrentWeapon)
|
||||
return;
|
||||
|
||||
auto CurrentWeaponInstance = WorldInventory->FindItemInstance(CurrentWeapon->GetItemEntryGuid());
|
||||
auto CurrentWeaponReplicatedEntry = WorldInventory->FindReplicatedEntry(CurrentWeapon->GetItemEntryGuid());
|
||||
|
||||
static auto AmmoCountOffset = CurrentWeapon->GetOffset("AmmoCount");
|
||||
auto AmmoCount = CurrentWeapon->Get<int>(AmmoCountOffset);
|
||||
|
||||
if (CurrentWeaponReplicatedEntry->GetLoadedAmmo() != AmmoCount)
|
||||
{
|
||||
CurrentWeaponInstance->GetItemEntry()->GetLoadedAmmo() = AmmoCount;
|
||||
CurrentWeaponReplicatedEntry->GetLoadedAmmo() = AmmoCount;
|
||||
|
||||
WorldInventory->GetItemList().MarkItemDirty(CurrentWeaponInstance->GetItemEntry());
|
||||
WorldInventory->GetItemList().MarkItemDirty(CurrentWeaponReplicatedEntry);
|
||||
} */
|
||||
}
|
||||
|
||||
FGameplayAbilitySpecHandle UAbilitySystemComponent::GiveAbilityEasy(UClass* AbilityClass)
|
||||
|
||||
Reference in New Issue
Block a user