Mutator: Difference between revisions

From Tripwire Interactive Wiki
Jump to navigation Jump to search
(Created page with "''Taken from <ref>http://udn.epicgames.com/Three/UT3Mods.html#Mutators</ref>'': <blockquote>Mutators are mini-mods. They have limited functionality as defined by the Mutator ...")
 
No edit summary
Line 1: Line 1:
''Taken from <ref>http://udn.epicgames.com/Three/UT3Mods.html#Mutators</ref>'':
''Taken from [http://udn.epicgames.com/Three/UT3Mods.html#Mutators UDN]'':


<blockquote>Mutators are mini-mods. They have limited functionality as defined by the Mutator class. Mutators should follow certain rules - rules that are established by the GameType. If these rules can't be followed or are too limiting, you should probably work on a GameType mod.</blockquote>
<blockquote>Mutators are mini-mods. They have limited functionality as defined by the Mutator class. Mutators should follow certain rules - rules that are established by the GameType. If these rules can't be followed or are too limiting, you should probably work on a GameType mod.</blockquote>
Line 8: Line 8:


<blockquote>The third rule is that Mutators should share resources with other Mutators. If your Mutator implements the ModifyPlayer function, you need to call NextMutator.ModifyPlayer somewhere inside your version of the function. This ensures that any Mutator on the Mutator list after your mod gets a chance to deal with the function call. Failing to do this is poor programming style and not community-friendly.</blockquote>
<blockquote>The third rule is that Mutators should share resources with other Mutators. If your Mutator implements the ModifyPlayer function, you need to call NextMutator.ModifyPlayer somewhere inside your version of the function. This ensures that any Mutator on the Mutator list after your mod gets a chance to deal with the function call. Failing to do this is poor programming style and not community-friendly.</blockquote>
==References==
<references/>

Revision as of 21:05, 21 September 2012

Taken from UDN:

Mutators are mini-mods. They have limited functionality as defined by the Mutator class. Mutators should follow certain rules - rules that are established by the GameType. If these rules can't be followed or are too limiting, you should probably work on a GameType mod.

The first rule is that Mutators should be able to work with any other Mutator - especially the ones that come with the game. If you write a "Vampire" Mutator that allows the player to drain life from an enemy he shoots, the Mutator should work well if combined with one of the Arena mutators or the No Powerups Mutator. This is one of the beneficial features of the Mutator system. They slightly change (or mutate) gameplay, allowing for interesting combinations.

The second rule is that Mutators should only change gameplay in a slight fashion. Although that's a vague way of putting it, you need to try and restrict your Mutator behavior. Careful Mutator design will increase the chances of your Mutator working with other mods and will decrease your support effort.

The third rule is that Mutators should share resources with other Mutators. If your Mutator implements the ModifyPlayer function, you need to call NextMutator.ModifyPlayer somewhere inside your version of the function. This ensures that any Mutator on the Mutator list after your mod gets a chance to deal with the function call. Failing to do this is poor programming style and not community-friendly.