I search for solutions in this order: Past Code, Unreal Source, Wiki, BUF, groups.yahoo, google, screaming at monitor. – RegularX
Difference between revisions of "UE3:UT MDB GR Bloodlust (UT3)"
From Unreal Wiki, The Unreal Engine Documentation Site
(Created page with '==Introduction== ==Code== {{Infobox class | package = UT_GDP_Newtators | class = UT_MDB_GR_Bloodlust | game = UT3 | engine = UE3 | custom = yes | parent1 = UT_MDB_GameRu…') |
(Subobjects now go in here, makes deeper but... event notifiers should clear call stack) |
||
Line 17: | Line 17: | ||
// Class: UT_MDB_GR_Bloodlust | // Class: UT_MDB_GR_Bloodlust | ||
// Creation date: 18/12/2007 04:30 | // Creation date: 18/12/2007 04:30 | ||
− | // Last updated: | + | // Last updated: 21/03/2010 18:54 |
// Contributors: 00zX | // Contributors: 00zX | ||
//--------------------------------------------------- | //--------------------------------------------------- | ||
Line 25: | Line 25: | ||
class UT_MDB_GR_Bloodlust extends UT_MDB_GR_Vampire; | class UT_MDB_GR_Bloodlust extends UT_MDB_GR_Vampire; | ||
− | function int | + | function int ModifyDamageTaken(UT_GR_Info.EnemyInfo Enemy, optional pawn Injured) |
{ | { | ||
if(Enemy.Type == ET_Infantry) | if(Enemy.Type == ET_Infantry) | ||
if(UTInventoryManager(Enemy.Pawn.InvManager).HasInventoryOfClass(class'UT_GDP_Newtators.UT_TPG_VDamage') != None) | if(UTInventoryManager(Enemy.Pawn.InvManager).HasInventoryOfClass(class'UT_GDP_Newtators.UT_TPG_VDamage') != None) | ||
− | Super. | + | return Super.ModifyDamageTaken(Enemy, Injured); |
− | // return Super( | + | // return Enemy.Damage; |
− | + | return Super(UT_MDB_GR_DamageConversion).ModifyDamageTaken(Enemy, Injured); | |
} | } | ||
− | + | ||
− | + | defaultproperties | |
{ | { | ||
− | + | GameRulesInfo.Add((Key="Bloodlust", Value="Powerup Enabled")) | |
− | + | bUseSuperHealth=True | |
+ | bUseForVehicles=False | ||
+ | bUseForKnights=False | ||
+ | bUseForRooks=False | ||
− | + | Begin Object Class=UT_MDB_GR_FactoryReplacer Name=UT_MDB_GR_FactoryReplacer0 | |
− | + | ReplacerSet.Add((ReplacedGroup="FT_Powerup", ReplacedName="UTPickupFactory_UDamage", ReplacedWithName="UT_PF_VDamage", ReplacedWithPath="UT_GDP_Newtators.UT_PF_VDamage")) | |
− | + | End Object | |
− | + | GameRules.Add(UT_MDB_GR_FactoryReplacer0) | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | Begin Object Class=UT_MDB_GR_ItemReplacer Name=UT_MDB_GR_ItemReplacer0 | |
− | + | ReplacerSet.Add((ReplacedGroup="FT_Powerup", ReplacedName="UTUDamage", ReplacedWithClass=class'UT_GDP_Newtators.UT_TPG_VDamage')) | |
− | + | End Object | |
− | + | GameRules.Add(UT_MDB_GR_ItemReplacer0) | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
} | } | ||
</uscript> | </uscript> |
Latest revision as of 23:08, 18 April 2010
Introduction[edit]
Code[edit]
UT_MDB >> UT_MDB_GameRules >> UT_MDB_GR_Bloodlust (custom) |
Contents
- Package:
- UT_GDP_Newtators
Script[edit]
//=================================================== // Class: UT_MDB_GR_Bloodlust // Creation date: 18/12/2007 04:30 // Last updated: 21/03/2010 18:54 // Contributors: 00zX //--------------------------------------------------- // Attribution-Noncommercial-Share Alike 3.0 Unported // http://creativecommons.org/licenses/by-nc-sa/3.0/ //=================================================== class UT_MDB_GR_Bloodlust extends UT_MDB_GR_Vampire; function int ModifyDamageTaken(UT_GR_Info.EnemyInfo Enemy, optional pawn Injured) { if(Enemy.Type == ET_Infantry) if(UTInventoryManager(Enemy.Pawn.InvManager).HasInventoryOfClass(class'UT_GDP_Newtators.UT_TPG_VDamage') != None) return Super.ModifyDamageTaken(Enemy, Injured); // return Enemy.Damage; return Super(UT_MDB_GR_DamageConversion).ModifyDamageTaken(Enemy, Injured); } defaultproperties { GameRulesInfo.Add((Key="Bloodlust", Value="Powerup Enabled")) bUseSuperHealth=True bUseForVehicles=False bUseForKnights=False bUseForRooks=False Begin Object Class=UT_MDB_GR_FactoryReplacer Name=UT_MDB_GR_FactoryReplacer0 ReplacerSet.Add((ReplacedGroup="FT_Powerup", ReplacedName="UTPickupFactory_UDamage", ReplacedWithName="UT_PF_VDamage", ReplacedWithPath="UT_GDP_Newtators.UT_PF_VDamage")) End Object GameRules.Add(UT_MDB_GR_FactoryReplacer0) Begin Object Class=UT_MDB_GR_ItemReplacer Name=UT_MDB_GR_ItemReplacer0 ReplacerSet.Add((ReplacedGroup="FT_Powerup", ReplacedName="UTUDamage", ReplacedWithClass=class'UT_GDP_Newtators.UT_TPG_VDamage')) End Object GameRules.Add(UT_MDB_GR_ItemReplacer0) }