Wintermute Engine Forum

Wintermute Engine => Technical forum => Topic started by: eborr on June 24, 2009, 02:43:59 PM

Title: Current Layer
Post by: eborr on June 24, 2009, 02:43:59 PM
another newbie type question, how  can I progammatically get the current  active layer name,

I have tried expressions like

var x = Layer.Name;

and this just causes a compiler error -any thoughts
Title: Re: Current Layer
Post by: Azrael on June 24, 2009, 09:05:53 PM
Probably because the var "Layer" of "Layer.Name" was no initialized.

Try:
Code: WME Script
  1. var Layer = Scene.GetLayer("LayerName");
  2.  
  3. var x = Layer.Name;
  4.  

I hope it's what you need :)