public static void LMS_OnCommand(CommandEventArgs e) { string which = ""; if (e.Arguments.Length > 0) { try { which = e.Arguments[0]; } catch (Exception ex) { Console.WriteLine("Invalid arguments. " + ex); } } if (which != "") { try { SkinHelper.LoadSkin(which, typeof(TMSS4Skin), true); } catch (Exception ex) { Console.WriteLine("Invalid skin name argument: " + ex); } } else { try { DirectoryInfo di = new DirectoryInfo("TMSS/Data/Skins"); foreach (FileInfo f in di.GetFiles()) { if (f.Extension == ".tskn") { string skname = f.Name.Remove(f.Name.IndexOf(".tskn"), 5); try { BaseSkin sk = SkinHelper.skList[skname]; try { TMSS4Skin skfour = (TMSS4Skin)sk; SkinHelper.LoadSkin(skname, typeof(TMSS4Skin), true); } catch { SkillSkin skskill = (SkillSkin)sk; SkinHelper.LoadSkin(skname, typeof(SkillSkin), true); } finally { DoTell("Attempted reload of skin. Filename: " + f.FullName); } } catch { DoTell("Unable to load skin: " + skname + ". Please use the function provided by the creating class to load it."); } } } } catch (Exception ex) { SystemWrite("Error when reloading a skin. " + ex); } } //LoadSkin(SkillSettings.CCSkinName, true); }
public static BaseSkin GenerateDefaultSkin(string name) { TMSS4Skin sk = new TMSS4Skin(); sk.SkinName = name; SkinHelper.WriteSkin(sk); SkillSkin skin = new SkillSkin("Skill Skin"); SkinHelper.WriteSkin(skin); return(sk); }
public static void GSW_OnCommand(CommandEventArgs arg) { SkillSkin skin = new SkillSkin( "Skill Skin" ); SkinHelper.WriteSkin( skin ); }
public static void GSW_OnCommand(CommandEventArgs arg) { SkillSkin skin = new SkillSkin("Skill Skin"); SkinHelper.WriteSkin(skin); }
public static BaseSkin GenerateDefaultSkin(string name) { TMSS4Skin sk = new TMSS4Skin(); sk.SkinName = name; SkinHelper.WriteSkin(sk); SkillSkin skin = new SkillSkin( "Skill Skin" ); SkinHelper.WriteSkin( skin ); return sk; }