Thanks for the suggestion. Over-complications were due to me trying Everything I Could Think Of.
I implemented your suggestion as I understood it, and it made no difference. So I must be doing something else wrong?
Herewith the relevant part of one of the calling scripts:
on "New"
{
this.PlaySound("ui_elements\GenMoveClick.ogg");
var fn = this.GetControl("New");
NewPlayer = Game.LoadWindow("interface\IntroMenu\NewPlayer.window");
NewPlayer.GoExclusive();
while(NewPlayer != null)
{
Sleep(20);
}
InitButtons();
NoDelete();
NoNew();
fn.Pressed = false;
}
And here is the other calling script:
on "Play"
{
// If we don't have any players, create one
this.PlaySound("ui_elements\GenMoveClick.ogg");
if(Player.Num == 0)
{
NewPlayer = Game.LoadWindow("interface\IntroMenu\NewPlayer.window");
NewPlayer.GoExclusive();
while(NewPlayer != null)
{
Sleep(20);
}
DoPlayer();
}
else
{
Game.LoadGame(Player.Current);
}
}
In the New Player window where the Editor is, all components are set to Parent Notify TRUE and the relevant part of the script says:
on "OK"
{
Game.Interactive = false;
var ed = this.GetControl("NameEditor");
var pn = ed.Text;
Game.Msg("Player is "+pn);
Player.Num = Player.Num+1;
Game.Msg("Player.Num is "+Player.Num);
var px = Player.Num;
Player[px] = pn;
Player.Current = px;
Player.Changed = true;
Game.RegWriteNumber("PlayerNum", Player.Num);
Game.RegWriteNumber("PlayerCurrent", Player.Current);
for(var a = 1; a < Player.Num +1; a = a +1)
{
var RegKeyName = "Player" + a;
Game.RegWriteString(RegKeyName, Player[a]);
}
Game.Interactive = true;
NewPlayer = null;
this.Close();
Game.UnloadObject(this);
}
Still no keyboard input on the window. So what am I doing wrong? Thanks for your help on this.
(BTW, this 'Post Reply' box is very difficult to write in - it bounces what I'm typing out of sight and any corrections cause its window to scroll)