//IOpsCommand public void Run(OpsContext context, OpsStatement statement) { UnloadArguments args = statement.Arguments as UnloadArguments; if (args.Type == ContentType.GENERIC || args.Type == ContentType.MODELS) { ArrayList models = context.FindModels(args.Src); foreach (OpsModel model in models) { OpsConsole.WriteLine("Unloading model: '{0}'", model.Name); context.RemoveModel(model.Name); } } if (args.Type == ContentType.GENERIC || args.Type == ContentType.TEXTURES) { ArrayList textures = context.FindTextures(args.Src); foreach (OpsTexture texture in textures) { OpsConsole.WriteLine("Unloading texture: '{0}'", texture.Name); context.RemoveTexture(texture.Name); } } }