Skip to content

Commit

Permalink
Updated whitelist patterns to match with newest GMad
Browse files Browse the repository at this point in the history
  • Loading branch information
whisperity committed Sep 29, 2014
1 parent 54b1465 commit 9ef00a0
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 16 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ C# of Garry Newman's [GMad](http://github.com/garrynewman/gmad) tool, but
ever since it has been given more functionality.

(The current version implements and complies with
[`f2a0de4`](http://github.com/garrynewman/gmad/tree/f2a0de42f5d124221ea080f18f338cf8fc23c15f).)
[`a121a70`](http://github.com/garrynewman/gmad/tree/a121a70e298ab6e07fa77a5e4f72018c7480f758).)

Usage
-----
Expand Down
4 changes: 2 additions & 2 deletions SharpGMad/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.1.1")]
[assembly: AssemblyFileVersion("1.1.1")]
[assembly: AssemblyVersion("1.1.2.1")]
[assembly: AssemblyFileVersion("1.1.2.1")]
61 changes: 48 additions & 13 deletions SharpGMad/Whitelist.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,30 +29,62 @@ static class Whitelist
/// A list of string patterns of allowed files.
/// </summary>
private static string[] Wildcard = new string[]{
"maps/*.bsp",
"maps/*.png",
"lua/*.lua",
"scenes/*.vcd",
"particles/*.pcf",
"resource/fonts/*.ttf",
"scripts/vehicles/*.txt",
"resource/localization/*/*.properties",
"maps/*.bsp",
"maps/*.nav",
"maps/*.ain",
"maps/thumb/*.png",
"sound/*.wav",
"sound/*.mp3",
"lua/*.lua",
"sound/*.ogg",
"materials/*.vmt",
"materials/*.vtf",
"materials/*.png",
"materials/*.jpg",
"materials/*.jpeg",
"models/*.mdl",
"models/*.vtx",
"models/*.phy",
"models/*.ani",
"models/*.vvd",
"gamemodes/*.txt",
"gamemodes/*.lua",
"scenes/*.vcd",
"particles/*.pcf",
"gamemodes/*/backgrounds/*.jpg",
"gamemodes/*/icon24.png",
"gamemodes/*/*.txt",
"gamemodes/*/*.fgd",
"gamemodes/*/logo.png",
"scripts/vehicles/*.txt",
"resource/fonts/*.ttf",
"gamemodes/*/icon24.png",
"gamemodes/*/gamemode/*.lua",
"gamemodes/*/entities/effects/*.lua",
"gamemodes/*/entities/weapons/*.lua",
"gamemodes/*/entities/entities/*.lua",
"gamemodes/*/backgrounds/*.png",
"gamemodes/*/backgrounds/*.jpg",
"gamemodes/*/backgrounds/*.jpeg",
"gamemodes/*/content/models/*.mdl",
"gamemodes/*/content/models/*.vtx",
"gamemodes/*/content/models/*.phy",
"gamemodes/*/content/models/*.ani",
"gamemodes/*/content/models/*.vvd",
"gamemodes/*/content/materials/*.vmt",
"gamemodes/*/content/materials/*.vtf",
"gamemodes/*/content/materials/*.png",
"gamemodes/*/content/materials/*.jpg",
"gamemodes/*/content/materials/*.jpeg",
"gamemodes/*/content/scenes/*.vcd",
"gamemodes/*/content/particles/*.pcf",
"gamemodes/*/content/resource/fonts/*.ttf",
"gamemodes/*/content/scripts/vehicles/*.txt",
"gamemodes/*/content/resource/localization/*/*.properties",
"gamemodes/*/content/maps/*.bsp",
"gamemodes/*/content/maps/*.nav",
"gamemodes/*/content/maps/*.ain",
"gamemodes/*/content/maps/thumb/*.png",
"gamemodes/*/content/sound/*.wav",
"gamemodes/*/content/sound/*.mp3",
"gamemodes/*/content/sound/*.ogg",
null
};

Expand All @@ -77,15 +109,18 @@ public static Dictionary<string, string[]> WildcardFileTypes
static Whitelist()
{
// Initialize the known file types into the internal dictionary.
_WildcardFileTypes.Add("Maps", new string[] { "*.bsp", "*.png", "*.nav", "*.ain" });
_WildcardFileTypes.Add("Maps", new string[] { "*.bsp", "*.png", "*.nav", "*.ain", "*.fgd" });
_WildcardFileTypes.Add("Lua script files", new string[] { "*.lua" });
_WildcardFileTypes.Add("Materials", new string[] { "*.vmt", "*.vtf", "*.png" });
_WildcardFileTypes.Add("Models", new string[] { "*.mdl", "*.vtx", "*.phy", "*.ani", "*.vvd" });
_WildcardFileTypes.Add("Text files", new string[] { "*.txt" });
_WildcardFileTypes.Add("Fonts", new string[] { "*.ttf" });
_WildcardFileTypes.Add("Images", new string[] { "*.png", "*.jpg" });
_WildcardFileTypes.Add("Images", new string[] { "*.png", "*.jpg", "*.jpeg" });
_WildcardFileTypes.Add("Scenes", new string[] { "*.vcd" });
_WildcardFileTypes.Add("Particle effects", new string[] { "*.pcf" });
_WildcardFileTypes.Add("Localization properties", new string[] { "*.properties" });
_WildcardFileTypes.Add("Sounds", new string[] { "*.wav", "*.mp3", "*.ogg" });

}

/// <summary>
Expand Down

0 comments on commit 9ef00a0

Please sign in to comment.