Having trouble compiling UnrealScript with defaultproperties
- by Enchanter
Have just started scripting in Unreal Script and am following the instructions of the opening chapter of a book on the subject. I have set the development tools up as described in the book such that it is now possible to compile the scripts for UDK before adding them to a level. My issue is: the very first script the book asks you to compile is the following:
class AwesomeActor extends Actor
placeable;
defaultproperties
{
Begin Object Class=SpriteComponent Name = Sprite
Sprite = Texture2D'EditorResources.S_NavP'
End Object
Components.Add(Sprite)
}
And when I hit F9 in the compiler I get the following error message: Error, BEGIN OBJECT: Must specify valid name for suboject/copmponent: Begin Object class=SpriteComponent name = Sprite
My question: As far as I'm aware I've copied the code from the book veribatim including capital and smaller case letters but I'm getting this error and I was wondering if anyone knew why and if so how I would fix it?