Anther WTF moment with Typescript. It is similar to a previous problem I had, but doesn't have the same solution. Could someone explain this, please? module TestGame{export class StateSettingStage extends Phaser.State { sally: TargetSprite; //subclass of Phaser.Sprite shoes: Token; //subclass of Phaser.Sprite this.sally = new TargetSprite(this.game, 350, 20, "sally"); this.game.add.existing(this.sally); this.shoes= new TargetSprite(this.game, 350, 20, "shoes"); this.game.add.existing(this.shoes); ->this.shoes.setTargetSprite(this.sally); <--- No problem this.clothes.children.forEach(function (val: Token) { val.anchor.setTo(0.5, 0.5); //val.setTargetSprite(this.sally); <-- this is what I really wanted to do, but...-> this.shoes.setTargetSprite(this.sally); <-- this.shoes and this.marry are undefined! }) }}Why are "shoes" and "sally" undefined when within the foreach callback function? I checked, and there is no argument I can use to pass these variables to the callback function (not that I should need to anyway, because they are within scope!)