Announcement

Collapse
No announcement yet.

Default properties and mutators

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Default properties and mutators

    Does anyone know if it's possble to have a mutator just adjust the default properties on an object withouy having to subclass the object and replace it with the mutator?

    #2
    just subclassing 'Mutator' is fine if you want to change default properties of other classes. like this:

    Code:
    class MutYourMutator extends Mutator;
    
    function PreBeginPlay()
    {
        super.PreBeginPlay();
        class'Package.Class'.default.WhateverProperty=10;
    }
    'Package.Class' is the package and class you're altering the default properties for

    Comment


      #3
      Hey, if I alter a default property like that midgame (not in PreBeginPlayer) will the game treat the property as changed?

      Comment


        #4
        I believe it will change the default property for the class 'template' itself... therefor any new objects spawned using that class will use the new default property. Any objects that already existed will not change.. they will have the default property specified when they were originally spawned. To change those, you'd need to have a For/ForEach statement to cycle thru all your already existing objects and change the property of each. does that make sense?

        Comment

        Working...
        X