The editinline UnrealScript keywords are used by the editor to make editing much more convenient for the mapper. If a property with editinline is selected in the Actor Properties Window it can be expanded to edit that actors properties within the same actor property window. Without editinline only the reference to the actor will be visible. A good example of this is in the Emitter class, or in the KParams of any actor. (Note that both of those examples are actually editinlinenew examples. Editinline without the new will allow you to edit the class that the variable in question refers to, but will not allow you to create an instance of that class from within the Actor Properties Window.)
Contents
Variables
var editinline SomeClass SomeInstanceofSaidClass< SEMI > var editinlineuse Material SomeMaterialIllUseatSomepoint;
- editinline
- As described above, editinline allows you to edit an actor within the Actor Properties Window of another actor by expanding the refence of any variable pointing to the latter actor. If the class of variable has editinlinenew in it's class definition, a "new" button will appear in the Actor Properties Window if the variable's reference is "None." Clicking said button will create an instance of the class and allow you to edit that. If subclasses of the class of the variable reference are loaded in the editor a drop-down box will be provided to let you choose which class you would like to instantiate. After the class has been instantiated you can edit it like any other editinlinenew actor. It is important to use this only for variable references, otherwise you risk crashing UnrealEd.
- editinlineuse
- Similar to editinline, editinlineuse will also add a "use" button for the property. This will only work for Materials, StaticMeshes, Sounds and anything else UnrealEd has a browser for, probably with the exception of the class browser. Everything else will crash UnrealEd.
- editinlinenotify
- This will notify the outer object if the property is changed.:
struct native NotifyInfo
{ var() FLOAT NotifyFrame; var() editinlinenotify AnimNotify Notify; var INT OldRevisionNum;
};
Classes
class FadeColor extends ConstantMaterial native editinlinenew; class Texture extends BitmapMaterial safereplace native noteditinlinenew dontcollapsecategories noexport;
- editinlinenew
- This tag signifies that a "new" button should be added when this class is used as a variable type with the modifier editinline. See above for details. Note that classes that are subclasses of this should not have editinlinenew set.
- noteditinlinenew
- Editinlinenew is inherited by the subclasses of the class with editinlinenew defined. This can be overridden through the use of this modifier.
Related Topics
- Class Syntax
- Variable Syntax
- Displaying Variables In UnrealEd
- Add An Inline Object in the UnrealEd Interface
Discussion
Mychaeel: Apparently editinline
doesn't work with Actor-derived classes; or at least, the "New" button in the UnrealEd property sheet doesn't. (There are reasons why this seems plausible, but there's no reason to assume that it couldn't possibly be working. Plus, Epic or Digital Extremes use an editinline
ZoneInfo array themselves in ZoneInfo.)
- The effect I'm seeing on an Actor-derived
editinline
object is that I can use the "New" button without problems; the actor instance appears, and I can set its properties as I like. However, the actor simply disappears in the game – its reference in the parent actor is set toNone
, and the actor itself is completely gone. - Does anybody have an idea why this is happening, and whether it can be worked around? (Background: I'd like to have replication, states and the "Tick" event in my
editinline
class.)
Mysterial: editinline
just specifies that you can expand a property of that actor's class to edit it from the property editor. For example, in the case you mentioned, if you are editing the properties of a ZoneInfo, you can expand an element of the ManualExcludes array and edit the ZoneInfo it points to, right from within the ZoneInfo's property window. The presence of a "New" option there is probably a bug, since that's what editinlinenew
is supposed to do. In any case, editinlinenew
is not supported for Actor-derived classes. I'm somewhat surprised it doesn't crash the editor.
Solid Snake: Yes, I've found this rather annoying. It appears that you must base the classes of 'Object'. I'll assume for proper replication, you'll need to use the parent actor, which can be annoying since it's not really OOP compliant.
Mychaeel: More editinlinenew
trouble: I've defined a class "within SomeOuterClass" to be used with editinlinenew
. UnrealEd crashes when I try to create a new instance of that class, giving me an error message "Object MyInnerClass None created in Package instead of SomeOuterClass."
- Now, the error message is descriptive enough – I suppose I just can't have UnrealEd instantiate an inner class – but isn't there a way around this limitation (or have I been misunderstanding the concept of "inner classes" all the way)?