My program doesn't have bugs. It just develops random features.

Legacy:MutNukeRifles

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search

NukeRifles[edit]

MutNukeRifles[edit]

//=============================================================================
// Nuke Rifles
//=============================================================================
class MutNukeRifles extends Mutator;
 
var name WeaponName, AmmoName;
var string WeaponString, AmmoString;
var bool bAllowTranslocator;
 
 
function string RecommendCombo(string ComboName)
{
	if ( (ComboName != "xGame.ComboSpeed") && (ComboName != "xGame.ComboInvis") )
	{
		if ( FRand() < 0.65 )
			ComboName = "xGame.ComboInvis";
		else
			ComboName = "xGame.ComboSpeed";
	}
	if ( NextMutator != None )
		return NextMutator.RecommendCombo(ComboName);
	return ComboName;
}
 
function bool AlwaysKeep(Actor Other)
{
	if ( Other.IsA(WeaponName) || Other.IsA(AmmoName) )
		return true;
 
	if ( NextMutator != None )
		return ( NextMutator.AlwaysKeep(Other) );
	return false;
}
 
function bool CheckReplacement(Actor Other, out byte bSuperRelevant)
{
	if ( Other.IsA('Weapon') )
	{
        if ( Other.IsA('BallLauncher') )
        {
            bSuperRelevant = 0;
            return true;
        }
 
		if ( Other.IsA('TransLauncher') && bAllowTranslocator )
		{
            bSuperRelevant = 0;
            return true;
        }
 
		if ( !Other.IsA(WeaponName) )
		{
			Level.Game.bWeaponStay = false;
			return false;
		}
	}
 
	if ( Other.IsA('SniperRifle') )
		return false;
 
//	if ( Other.IsA('xPickupBase') )
//		Other.bHidden = true;
 
	bSuperRelevant = 0;
	return true;
}
 
defaultproperties
{
	AmmoName=ShockAmmo
	AmmoString="xWeapons.ShockAmmo"
	WeaponName=NukeRifle
	WeaponString="my_mod2.ZoomNukeRifle"
	DefaultWeaponName="my_mod2.ZoomNukeRifle"
 
    IconMaterialName="MutatorArt.nosym"
    ConfigMenuClassName=""
    GroupName="Arena"
    FriendlyName="Zoom NukeRifles!"
    Description="Very dangerous long-range combat using zoom rifles that fire nuclear projectiles! he he he"
}

–..–

I tried it,but it din't work.please help,this is a brilliant idea,and right now i'm trying to make enforcers which fire ripper blades in primary fire and sniper rifle guided bullets in secondary fire.Any suggestions?