Skip to main content
November 15, 2011
Question

Error #1127: Type application attempted on a non-parameterized type.

  • November 15, 2011
  • 1 reply
  • 1433 views

Hi,

I've been getting the above error at runtime on a game I'm creating, google reports back absolutely nothing so I was wondering if anyone can explain it to me?

Thanks.

This topic has been closed for replies.

1 reply

Participating Frequently
November 15, 2011

Can you please explain what you were doing when you got the error.  Also a stack trace would be nice.

November 15, 2011

It happens during preload whilst initializing the rest of the game, specifically creating the map, heres a stack trace:

TypeError: Error #1127: Type application attempted on a non-parameterized type.

    at lollib.world::MapCells$cinit()

    at global$init()

    at local.world::GameObject()

    at local.world::World()

    at local.world::World$/get singleton()

    at local.data::aLevels()

    at local.data::aLevels$/get singleton()

    at Main/loadData()

    at Main/initialize()

    at flash.display::ShowObjContainer/addChild()

    at flash.display::Stage/addChild()

    at local.net::PreLoader/state_worldload_enter()

    at gblib1.game::State/setState()

    at local.net::PreLoader/state_main_process()

    at gblib1.game::State/process()

    at local.net::PreLoader/onEnterFrame()

And the code around the error:

public class MapCells {

     public static const DIRECTION_PARTNERS:Vector.<Point> = Vector.<Point>([new Point(0, -1), new Point(1, 0), new Point(0, 1), new Point(-1, 0)]);    public static const DIRECTION_DELTAS:Vector.<Point> = Vector.<Point>([new Point(0, -1), new Point(1, 0), new Point(0, 1), new Point(-1, 0)]);

     public var mapIndex:Point;

    public var gameObjects:Vector.<GameObject>;

    public var map:WorldMap;

    public var partners:Vector.<MapCells>;

    public var session:int;

    public var slots:Object;

    private var _levels:Vector.<MapNode>;

     public function MapCells(_arg1:int=0, _arg2:int=0):void{

    this.slots = {};

    super();

    this.mapIndex = new Point(_arg1, _arg2);

    this.slots[0] = World.singleton.gameObjectContainer;

    }

Participating Frequently
November 15, 2011

Well off the bat you should change your Vector name:

t_mac1989 wrote:

public class MapCells{
    

     public var partners:Vector.<MapCells>;

     public function MapCells(){}

}


ERROR: lollib.world::MapCells$cinit()

AS3 is smart MOST OF THE TIME... but not all.  This is a situation where it could be thinking your referencing the class [MapCells] as a Vector.  Changing the name of the Vector should remove referencing issues.

Can you show what cinit() looks like.