Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void APlayerShip::Fire0() {
- TArray<FName> sockets = OurVisibleComponent->GetAllSocketNames();
- for (size_t i = 0; i < sockets.Num(); i++) {
- if (sockets[i].ToString().Contains("Weapon0")) {
- const FVector Socket0Loc = OurVisibleComponent->GetSocketLocation(sockets[i]);
- const FRotator Socket0Rot = OurVisibleComponent->GetSocketRotation(sockets[i]);
- ABullet* bul = APlayerShip::SpawnBP<ABullet>(GetWorld(), bullet, Socket0Loc, Socket0Rot);
- bul->SetVelocity(floatingMovement->Velocity);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement