Game Development Reference
In-Depth Information
return SocketLocation;
* Overridden from UTWeapon.uc
* @return the location + offset from which to spawn effects
(primarily tracers)
simulated function vector GetEffectLocation()
Local SkeletalMeshComponent AttachedMesh;
local vector SocketLocation;
Local TutorialPawn TutPawn;
TutPawn = TutorialPawn(Owner);
AttachedMesh = TutPawn.CurrentWeaponAttachment.Mesh;
if (TutPawn != none)
(MuzzleFlashSocket, SocketLocation);
MuzzleFlashSocket, SocketLocation);
return SocketLocation;
Now we're ready to dive into the parts of code that are applicable to the actual
homing of the weapon. Let's start by adding our debug info, which allows us to
troubleshoot any issues we may have along the way.
* Prints debug info for the weapon
simulated function GetWeaponDebug( out Array<String> DebugInfo )
DebugInfo[DebugInfo.Length] = "Locked:
DebugInfo[DebugInfo.Length] =
Here we are simply stating which target our weapon is currently locked onto, in
addition to the pending target. It does this by grabbing the variables we've listed
before, after they've returned from their functions, which we'll add in the next part.
Search Nedrilad ::

Custom Search