Game Development Community

Scripting Problem on Space Warrior Tutorial

by Aidan Green · in Torque X 2D · 10/03/2008 (4:16 am) · 1 replies

Hello, I just recently started on this, and now that I'm nearly done I've hit a snag.
I reached the part where I am asked to put this bit of code:

public static ShipControlsComponent.OnDestructionDelegate RestartOnDestruction
{
get { return ShipDestroyed; }
}

into the Public properties, operators, constants, and enums region of my CombatManagerComponent script.
But with that done, when I try to build the project I get the error:
"The type of namespace name 'ShipControlsComponent' could not be found (are you missing a using directive or an assembly reference?)"
I'm not sure what that means, but I do know that "ShipControlsComponent" is an entirely different file, so it's trying to reference a method in a different component and it can't find the other component.

What am I doing wrong? this was all going so well until this. I can't even play the game at all because VisualC#EE won't let me build the project with that error.

Thanks.

About the author

Recent Threads

  • Annoying Error

  • #1
    10/07/2008 (10:12 pm)
    Make sure that ShipControlsComponent has a namespace....it should be

    namespace StarterGame2D