Cogito, ergo sum

Legacy:Selethrial/LinkGun

From Unreal Wiki, The Unreal Engine Documentation Site
< Legacy:Selethrial
Revision as of 20:06, 29 June 2005 by Selethrial (Talk) (Fixing array)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
// The Five UC Files of just trying to modify Link Gun Protectiles
 
// MutXLinkgun.uc
class MutXLinkgun extends Mutator;
 
function bool CheckReplacement( Actor Other, out byte bSuperRelevant )
{
    local int i;
    local WeaponLocker L;
 
    bSuperRelevant = 0;
 
    if ( xWeaponBase(Other) != None )
    {
        if ( string( xWeaponBase(Other).WeaponType ) ~= "XWeapons.Linkgun" )
        {
            xWeaponBase(Other).WeaponType = class'XLinkgun';
            return false;
        }
    }
    else if ( WeaponPickup(Other) != None )
    {
        if ( string(Other.Class) ~= "XWeapons.LinkgunPickup" )
        {
            ReplaceWith( Other, "XLinkgunPickup" );
            return false;
        }
    }
    else if ( WeaponLocker(Other) != None )
    {
        L = WeaponLocker(Other);
 
        for (i = 0; i < L.Weapons.Length; i++)
        {
            if ( string( L.Weapons[i].WeaponClass ) ~= "XWeapons.Linkgun" )
                L.Weapons[i].WeaponClass = class'XLinkgun';
        }
    }
 
    return true;
}
 
//=============================================================================
defaultproperties
{
    GroupName="XLinkGun"
    FriendlyName="Xtreme Link Gun"
    Description="Tweaking the Link Gun"
}
 
// XLinkGun.ux
 
class XLinkGun extends Linkgun;
 
//=============================================================================
defaultproperties
{
    FireModeClass(0)=Class'XLinkgunAltFire'
    PickupClass=Class'XLinkgunPickup'
}
 
// XLinkgunAltFire.uc
 
class XLinkgunAltFire extends LinkAltFire;
 
defaultproperties
{
    ProjectileClass=Class'XLinkProjectile'
}
 
// XLinkGunPickup.uc
 
class XLinkgunPickup extends LinkgunPickup;
 
//=============================================================================
defaultproperties
{
    InventoryType=Class'XLinkGun'
    PickupMessage="You got the Xtreme Linkgun."
}
 
// XLinkProjectile.uc
 
class XLinkProjectile extends LinkProjectile;
 
defaultproperties
{
    Speed=10.00
    MaxSpeed=100.00
    Damage=200.00
}