public ASTVisitor(RuntimeKernel kernel, FireMLRoot root) { this.kernel = kernel; this.root = root; exprProcessor = new ExprProcessor(kernel); varRefProcessor = new StrVarRefProcessor(kernel); }
public override void Visit(BackgroundStmt backgroundStmt, object[] args) { if (backgroundStmt.Img != null && !StrVarRefProcessor.IsVariableIncluded(backgroundStmt.Img)) { CheckContent(backgroundStmt.Img, ContentType.Texture, backgroundStmt.Location); } if (backgroundStmt.Asset != null) { CheckAsset(backgroundStmt.Asset, typeof(CGAsset), backgroundStmt.Location); } }
public override void Visit(MusicStmt musicStmt, object[] args) { if (musicStmt.Source != null && !StrVarRefProcessor.IsVariableIncluded(musicStmt.Source)) { CheckContent(musicStmt.Source, ContentType.Music, musicStmt.Location); } if (musicStmt.Asset != null) { CheckAsset(musicStmt.Asset, typeof(MusicAsset), musicStmt.Location); } base.Visit(musicStmt, args); }
public override void Visit(ActorStmt actorStmt, object[] args) { if (actorStmt.Img != null && !StrVarRefProcessor.IsVariableIncluded(actorStmt.Img)) { CheckContent(actorStmt.Img, ContentType.Texture, actorStmt.Location); } if (actorStmt.Asset != null) { CheckAsset(actorStmt.Asset, typeof(ActorAsset), actorStmt.Location); } if (actorStmt.Avatar != null && !StrVarRefProcessor.IsVariableIncluded(actorStmt.Avatar)) { CheckContent(actorStmt.Avatar, ContentType.Texture, actorStmt.Location); } if (actorStmt.AvaAsset != null) { CheckAsset(actorStmt.AvaAsset, typeof(ActorAsset), actorStmt.Location); } }