├── .gitignore ├── LICENSE ├── README.md ├── S3.sln ├── S3 ├── App.config ├── Character.cs ├── ComboboxItem.cs ├── Globals.cs ├── MainForm.Designer.cs ├── MainForm.cs ├── MainForm.resx ├── Program.cs ├── Properties │ ├── AssemblyInfo.cs │ ├── Resources.Designer.cs │ ├── Resources.resx │ ├── Settings.Designer.cs │ └── Settings.settings ├── S3.csproj ├── Server.cs ├── Settings.cs ├── SettingsForm.Designer.cs ├── SettingsForm.cs ├── SettingsForm.resx ├── Sponsor.cs ├── Stuff │ ├── Content │ │ └── html │ │ │ ├── config │ │ │ └── settings.json │ │ │ ├── css │ │ │ ├── pregame.css │ │ │ ├── scoreboard.css │ │ │ └── scoreboardnew.css │ │ │ ├── img │ │ │ ├── characters │ │ │ │ ├── 20xx.png │ │ │ │ ├── Super-Smash-Bros-Melee-large-2.jpg │ │ │ │ ├── bowser.png │ │ │ │ ├── dong.png │ │ │ │ ├── dr.png │ │ │ │ ├── falco.png │ │ │ │ ├── falcon.png │ │ │ │ ├── gandw.png │ │ │ │ ├── ganondorf.png │ │ │ │ ├── icies.png │ │ │ │ ├── jiggs.png │ │ │ │ ├── king.png │ │ │ │ ├── kirby.png │ │ │ │ ├── link.png │ │ │ │ ├── luigi.png │ │ │ │ ├── mario.png │ │ │ │ ├── marth.png │ │ │ │ ├── mqdefault.jpg │ │ │ │ ├── mvgLogo.png │ │ │ │ ├── ness.png │ │ │ │ ├── peach.png │ │ │ │ ├── pichu.png │ │ │ │ ├── pikachu.png │ │ │ │ ├── roy.png │ │ │ │ ├── samus.png │ │ │ │ ├── sheik.png │ │ │ │ ├── yoshi.png │ │ │ │ ├── younglink.png │ │ │ │ └── zelda.png │ │ │ ├── flags │ │ │ │ ├── spain.png │ │ │ │ ├── spainrep.png │ │ │ │ ├── uk.png │ │ │ │ └── usa.png │ │ │ ├── nocolor │ │ │ │ ├── camera.png │ │ │ │ ├── microphone.png │ │ │ │ ├── scoreboardbase.psd │ │ │ │ └── sponsor.png │ │ │ ├── overlay.png │ │ │ └── sponsors │ │ │ │ ├── modulous.png │ │ │ │ ├── mvg.png │ │ │ │ └── shrekboards.png │ │ │ ├── js │ │ │ ├── common.js │ │ │ ├── jquery.js │ │ │ ├── l.php.gif │ │ │ ├── paintbrush.js │ │ │ ├── pregame.js │ │ │ ├── scoreboard.js │ │ │ └── settings.js │ │ │ ├── scoreboard.html │ │ │ └── scoreboard2.html │ ├── characters.json │ ├── flags.json │ └── sponsors.json └── packages.config ├── pregame.psd ├── scoreboard.psd └── scoreboard_dualcam.psd /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | 4 | # User-specific files 5 | *.suo 6 | *.user 7 | *.userosscache 8 | *.sln.docstates 9 | 10 | # User-specific files (MonoDevelop/Xamarin Studio) 11 | *.userprefs 12 | 13 | # Build results 14 | [Dd]ebug/ 15 | [Dd]ebugPublic/ 16 | [Rr]elease/ 17 | [Rr]eleases/ 18 | x64/ 19 | x86/ 20 | build/ 21 | bld/ 22 | [Bb]in/ 23 | [Oo]bj/ 24 | 25 | # Visual Studio 2015 cache/options directory 26 | .vs/ 27 | # Uncomment if you have tasks that create the project's static files in wwwroot 28 | #wwwroot/ 29 | 30 | # MSTest test Results 31 | [Tt]est[Rr]esult*/ 32 | [Bb]uild[Ll]og.* 33 | 34 | # NUNIT 35 | *.VisualState.xml 36 | TestResult.xml 37 | 38 | # Build Results of an ATL Project 39 | [Dd]ebugPS/ 40 | [Rr]eleasePS/ 41 | dlldata.c 42 | 43 | # DNX 44 | project.lock.json 45 | artifacts/ 46 | 47 | *_i.c 48 | *_p.c 49 | *_i.h 50 | *.ilk 51 | *.meta 52 | *.obj 53 | *.pch 54 | *.pdb 55 | *.pgc 56 | *.pgd 57 | *.rsp 58 | *.sbr 59 | *.tlb 60 | *.tli 61 | *.tlh 62 | *.tmp 63 | *.tmp_proj 64 | *.log 65 | *.vspscc 66 | *.vssscc 67 | .builds 68 | *.pidb 69 | *.svclog 70 | *.scc 71 | 72 | # Chutzpah Test files 73 | _Chutzpah* 74 | 75 | # Visual C++ cache files 76 | ipch/ 77 | *.aps 78 | *.ncb 79 | *.opendb 80 | *.opensdf 81 | *.sdf 82 | *.cachefile 83 | 84 | # Visual Studio profiler 85 | *.psess 86 | *.vsp 87 | *.vspx 88 | *.sap 89 | 90 | # TFS 2012 Local Workspace 91 | $tf/ 92 | 93 | # Guidance Automation Toolkit 94 | *.gpState 95 | 96 | # ReSharper is a .NET coding add-in 97 | _ReSharper*/ 98 | *.[Rr]e[Ss]harper 99 | *.DotSettings.user 100 | 101 | # JustCode is a .NET coding add-in 102 | .JustCode 103 | 104 | # TeamCity is a build add-in 105 | _TeamCity* 106 | 107 | # DotCover is a Code Coverage Tool 108 | *.dotCover 109 | 110 | # NCrunch 111 | _NCrunch_* 112 | .*crunch*.local.xml 113 | nCrunchTemp_* 114 | 115 | # MightyMoose 116 | *.mm.* 117 | AutoTest.Net/ 118 | 119 | # Web workbench (sass) 120 | .sass-cache/ 121 | 122 | # Installshield output folder 123 | [Ee]xpress/ 124 | 125 | # DocProject is a documentation generator add-in 126 | DocProject/buildhelp/ 127 | DocProject/Help/*.HxT 128 | DocProject/Help/*.HxC 129 | DocProject/Help/*.hhc 130 | DocProject/Help/*.hhk 131 | DocProject/Help/*.hhp 132 | DocProject/Help/Html2 133 | DocProject/Help/html 134 | 135 | # Click-Once directory 136 | publish/ 137 | 138 | # Publish Web Output 139 | *.[Pp]ublish.xml 140 | *.azurePubxml 141 | # TODO: Comment the next line if you want to checkin your web deploy settings 142 | # but database connection strings (with potential passwords) will be unencrypted 143 | *.pubxml 144 | *.publishproj 145 | 146 | # NuGet Packages 147 | *.nupkg 148 | # The packages folder can be ignored because of Package Restore 149 | **/packages/* 150 | # except build/, which is used as an MSBuild target. 151 | !**/packages/build/ 152 | # Uncomment if necessary however generally it will be regenerated when needed 153 | #!**/packages/repositories.config 154 | 155 | # Windows Azure Build Output 156 | csx/ 157 | *.build.csdef 158 | 159 | # Windows Azure Emulator 160 | ecf/ 161 | rcf/ 162 | 163 | # Windows Store app package directory 164 | AppPackages/ 165 | BundleArtifacts/ 166 | 167 | # Visual Studio cache files 168 | # files ending in .cache can be ignored 169 | *.[Cc]ache 170 | # but keep track of directories ending in .cache 171 | !*.[Cc]ache/ 172 | 173 | # Others 174 | ClientBin/ 175 | [Ss]tyle[Cc]op.* 176 | ~$* 177 | *~ 178 | *.dbmdl 179 | *.dbproj.schemaview 180 | *.pfx 181 | *.publishsettings 182 | node_modules/ 183 | orleans.codegen.cs 184 | 185 | # RIA/Silverlight projects 186 | Generated_Code/ 187 | 188 | # Backup & report files from converting an old project file 189 | # to a newer Visual Studio version. Backup files are not needed, 190 | # because we have git ;-) 191 | _UpgradeReport_Files/ 192 | Backup*/ 193 | UpgradeLog*.XML 194 | UpgradeLog*.htm 195 | 196 | # SQL Server files 197 | *.mdf 198 | *.ldf 199 | 200 | # Business Intelligence projects 201 | *.rdl.data 202 | *.bim.layout 203 | *.bim_*.settings 204 | 205 | # Microsoft Fakes 206 | FakesAssemblies/ 207 | 208 | # GhostDoc plugin setting file 209 | *.GhostDoc.xml 210 | 211 | # Node.js Tools for Visual Studio 212 | .ntvs_analysis.dat 213 | 214 | # Visual Studio 6 build log 215 | *.plg 216 | 217 | # Visual Studio 6 workspace options file 218 | *.opt 219 | 220 | # Visual Studio LightSwitch build output 221 | **/*.HTMLClient/GeneratedArtifacts 222 | **/*.DesktopClient/GeneratedArtifacts 223 | **/*.DesktopClient/ModelManifest.xml 224 | **/*.Server/GeneratedArtifacts 225 | **/*.Server/ModelManifest.xml 226 | _Pvt_Extensions 227 | 228 | # Paket dependency manager 229 | .paket/paket.exe 230 | 231 | # FAKE - F# Make 232 | .fake/ -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # AuroraBoard 2 | AuroraBoard is a UI overlay for competitive videogames, it's been mainly designed for competitive fighting games. It runs on top of your favorite streaming software that supports loading webpages, for example OBS or XSplit. 3 | AuroraBoard's default UI is made for presential tournaments featuring two cameras players, however this can easily be modified, the default UI is also made to be tintable, which means you can set the color of the UI from the software itself, all of this of course, can be customized without limits. 4 | 5 | The default UI also includes Melee stuff, including but not limited to a picture of the king of the mews. 6 | 7 | In the default UI there are two animated parts, the character icons that regularly change into the flag of the player and back and the lower right corner where the streamer name fades to the name of whoever is doing the commentary. 8 | ## Screenshots 9 | ![](http://i.imgur.com/aLwu2ka.png) 10 | 11 | ![](http://i.imgur.com/xuOvFzo.jpg) 12 | 13 | ## Installing 14 | 15 | #OBS 16 | 17 | Run the program, set it up and then click start server, a URL will appear, copy it to your clipboard. 18 | 19 | Install the CLR Browser plugin and add the source to your scene. 20 | 21 | ![](http://i.imgur.com/OffF67T.png) 22 | 23 | Make the dimensions be 1920x1080 and paste the URL that the program gives you. 24 | 25 | ![](http://i.imgur.com/Z8mzZyW.png) 26 | 27 | Hit ok, and you are done. 28 | 29 | ![](http://i.imgur.com/RpTZ4Dw.png) 30 | 31 | Optionally, if you are going to customize, to make testing easier enable advanced properties and disable ApplicationCache and PageCach, this will prevent OBS from caching the stream images so you can test tints and stuff. 32 | 33 | #XSplit 34 | Although OBS is the recommended software XSplit works too. 35 | 36 | First add the Webpage URL source. 37 | 38 | ![](http://i.imgur.com/4VPl84d.png) 39 | 40 | Paste the URL that software gives you 41 | 42 | ![](http://i.imgur.com/hKSOQ3l.png) 43 | 44 | Hit ok, and in the source settings disable scrollbars and set the resolution to a 1920x1080. 45 | 46 | 47 | 48 | ![](http://i.imgur.com/Cnch0yY.png) 49 | 50 | And you are done. 51 | 52 | ![](http://i.imgur.com/Rv6ZLwg.jpg) 53 | 54 | ## Modifying the characters, flags and player sponsors 55 | Character, flags and sponsors are saved in three different folders, you will find them under Content\html\img. 56 | 57 | After you add your flag to the folder you must also add it to the corresponding .json file, characters.json, flags.json or sponsors.json. 58 | 59 | ## Adding your own sponsors, logos etc... 60 | Using scoreboard.psd as a base you can overlay your own logos over the stream UI, this is done by editing the file Content\img\nocolor\sponsor.png 61 | 62 | ## Building 63 | Build the software normally and then copy the files in the S3/Stuff folder to where the S3.exe has been compiled, this will serve as a starting point. -------------------------------------------------------------------------------- /S3.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 14 4 | VisualStudioVersion = 14.0.23107.0 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "S3", "S3\S3.csproj", "{EA0E4EBC-9A72-4BA9-BCD5-15D5FA477EA3}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Release|Any CPU = Release|Any CPU 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {EA0E4EBC-9A72-4BA9-BCD5-15D5FA477EA3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 15 | {EA0E4EBC-9A72-4BA9-BCD5-15D5FA477EA3}.Debug|Any CPU.Build.0 = Debug|Any CPU 16 | {EA0E4EBC-9A72-4BA9-BCD5-15D5FA477EA3}.Release|Any CPU.ActiveCfg = Release|Any CPU 17 | {EA0E4EBC-9A72-4BA9-BCD5-15D5FA477EA3}.Release|Any CPU.Build.0 = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | EndGlobal 23 | -------------------------------------------------------------------------------- /S3/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /S3/Character.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace S3 8 | { 9 | public class Character 10 | { 11 | public string name; 12 | public string icon; 13 | } 14 | public class Flag 15 | { 16 | public string name; 17 | public string icon; 18 | } 19 | class CharacterList 20 | { 21 | public IList characters; 22 | } 23 | 24 | class FlagList 25 | { 26 | public IList flags; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /S3/ComboboxItem.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace S3 8 | { 9 | public class ComboboxItem 10 | { 11 | public string Text { get; set; } 12 | public object Value { get; set; } 13 | 14 | public override string ToString() 15 | { 16 | return Text; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /S3/Globals.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace S3 8 | { 9 | class Globals 10 | { 11 | public static InformationUpdate CurrentInformationUpdate; 12 | public static Settings settings = new Settings(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /S3/MainForm.Designer.cs: -------------------------------------------------------------------------------- 1 | namespace S3 2 | { 3 | partial class MainForm 4 | { 5 | /// 6 | /// Required designer variable. 7 | /// 8 | private System.ComponentModel.IContainer components = null; 9 | 10 | /// 11 | /// Clean up any resources being used. 12 | /// 13 | /// true if managed resources should be disposed; otherwise, false. 14 | protected override void Dispose(bool disposing) 15 | { 16 | if (disposing && (components != null)) 17 | { 18 | components.Dispose(); 19 | } 20 | base.Dispose(disposing); 21 | } 22 | 23 | #region Windows Form Designer generated code 24 | 25 | /// 26 | /// Required method for Designer support - do not modify 27 | /// the contents of this method with the code editor. 28 | /// 29 | private void InitializeComponent() 30 | { 31 | this.Player1Name = new System.Windows.Forms.TextBox(); 32 | this.groupBox1 = new System.Windows.Forms.GroupBox(); 33 | this.FlagsCombo = new System.Windows.Forms.ComboBox(); 34 | this.label4 = new System.Windows.Forms.Label(); 35 | this.Player1Score = new System.Windows.Forms.NumericUpDown(); 36 | this.label3 = new System.Windows.Forms.Label(); 37 | this.Player1Character = new System.Windows.Forms.ComboBox(); 38 | this.label2 = new System.Windows.Forms.Label(); 39 | this.Player1Sponsor = new System.Windows.Forms.ComboBox(); 40 | this.label1 = new System.Windows.Forms.Label(); 41 | this.groupBox2 = new System.Windows.Forms.GroupBox(); 42 | this.FlagsComboP2 = new System.Windows.Forms.ComboBox(); 43 | this.label5 = new System.Windows.Forms.Label(); 44 | this.Player2Score = new System.Windows.Forms.NumericUpDown(); 45 | this.label6 = new System.Windows.Forms.Label(); 46 | this.Player2Character = new System.Windows.Forms.ComboBox(); 47 | this.label7 = new System.Windows.Forms.Label(); 48 | this.Player2Sponsor = new System.Windows.Forms.ComboBox(); 49 | this.label8 = new System.Windows.Forms.Label(); 50 | this.Player2Name = new System.Windows.Forms.TextBox(); 51 | this.SendUpdateButton = new System.Windows.Forms.Button(); 52 | this.RoundNameTextbox = new System.Windows.Forms.TextBox(); 53 | this.tournamentNameTextbox = new System.Windows.Forms.TextBox(); 54 | this.groupBox3 = new System.Windows.Forms.GroupBox(); 55 | this.label10 = new System.Windows.Forms.Label(); 56 | this.label9 = new System.Windows.Forms.Label(); 57 | this.groupBox4 = new System.Windows.Forms.GroupBox(); 58 | this.label11 = new System.Windows.Forms.Label(); 59 | this.label12 = new System.Windows.Forms.Label(); 60 | this.CasterTextbox = new System.Windows.Forms.TextBox(); 61 | this.StreamerTextbox = new System.Windows.Forms.TextBox(); 62 | this.SettingsButton = new System.Windows.Forms.Button(); 63 | this.menuStrip1 = new System.Windows.Forms.MenuStrip(); 64 | this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 65 | this.openToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 66 | this.saveAsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 67 | this.StartServer = new System.Windows.Forms.Button(); 68 | this.UrlLinkLabel = new System.Windows.Forms.LinkLabel(); 69 | this.groupBox1.SuspendLayout(); 70 | ((System.ComponentModel.ISupportInitialize)(this.Player1Score)).BeginInit(); 71 | this.groupBox2.SuspendLayout(); 72 | ((System.ComponentModel.ISupportInitialize)(this.Player2Score)).BeginInit(); 73 | this.groupBox3.SuspendLayout(); 74 | this.groupBox4.SuspendLayout(); 75 | this.menuStrip1.SuspendLayout(); 76 | this.SuspendLayout(); 77 | // 78 | // Player1Name 79 | // 80 | this.Player1Name.Location = new System.Drawing.Point(6, 32); 81 | this.Player1Name.Name = "Player1Name"; 82 | this.Player1Name.Size = new System.Drawing.Size(100, 20); 83 | this.Player1Name.TabIndex = 0; 84 | // 85 | // groupBox1 86 | // 87 | this.groupBox1.Controls.Add(this.FlagsCombo); 88 | this.groupBox1.Controls.Add(this.label4); 89 | this.groupBox1.Controls.Add(this.Player1Score); 90 | this.groupBox1.Controls.Add(this.label3); 91 | this.groupBox1.Controls.Add(this.Player1Character); 92 | this.groupBox1.Controls.Add(this.label2); 93 | this.groupBox1.Controls.Add(this.Player1Sponsor); 94 | this.groupBox1.Controls.Add(this.label1); 95 | this.groupBox1.Controls.Add(this.Player1Name); 96 | this.groupBox1.Location = new System.Drawing.Point(12, 30); 97 | this.groupBox1.Name = "groupBox1"; 98 | this.groupBox1.Size = new System.Drawing.Size(245, 158); 99 | this.groupBox1.TabIndex = 1; 100 | this.groupBox1.TabStop = false; 101 | this.groupBox1.Text = "Player 1"; 102 | // 103 | // FlagsCombo 104 | // 105 | this.FlagsCombo.FormattingEnabled = true; 106 | this.FlagsCombo.Location = new System.Drawing.Point(6, 98); 107 | this.FlagsCombo.Name = "FlagsCombo"; 108 | this.FlagsCombo.Size = new System.Drawing.Size(121, 21); 109 | this.FlagsCombo.TabIndex = 7; 110 | // 111 | // label4 112 | // 113 | this.label4.AutoSize = true; 114 | this.label4.Location = new System.Drawing.Point(130, 55); 115 | this.label4.Name = "label4"; 116 | this.label4.Size = new System.Drawing.Size(35, 13); 117 | this.label4.TabIndex = 6; 118 | this.label4.Text = "Score"; 119 | // 120 | // Player1Score 121 | // 122 | this.Player1Score.Location = new System.Drawing.Point(133, 71); 123 | this.Player1Score.Name = "Player1Score"; 124 | this.Player1Score.Size = new System.Drawing.Size(43, 20); 125 | this.Player1Score.TabIndex = 2; 126 | // 127 | // label3 128 | // 129 | this.label3.AutoSize = true; 130 | this.label3.Location = new System.Drawing.Point(6, 55); 131 | this.label3.Name = "label3"; 132 | this.label3.Size = new System.Drawing.Size(53, 13); 133 | this.label3.TabIndex = 5; 134 | this.label3.Text = "Character"; 135 | // 136 | // Player1Character 137 | // 138 | this.Player1Character.FormattingEnabled = true; 139 | this.Player1Character.Location = new System.Drawing.Point(6, 71); 140 | this.Player1Character.Name = "Player1Character"; 141 | this.Player1Character.Size = new System.Drawing.Size(121, 21); 142 | this.Player1Character.TabIndex = 4; 143 | // 144 | // label2 145 | // 146 | this.label2.AutoSize = true; 147 | this.label2.Location = new System.Drawing.Point(115, 16); 148 | this.label2.Name = "label2"; 149 | this.label2.Size = new System.Drawing.Size(46, 13); 150 | this.label2.TabIndex = 3; 151 | this.label2.Text = "Sponsor"; 152 | // 153 | // Player1Sponsor 154 | // 155 | this.Player1Sponsor.FormattingEnabled = true; 156 | this.Player1Sponsor.Location = new System.Drawing.Point(118, 31); 157 | this.Player1Sponsor.Name = "Player1Sponsor"; 158 | this.Player1Sponsor.Size = new System.Drawing.Size(121, 21); 159 | this.Player1Sponsor.TabIndex = 2; 160 | // 161 | // label1 162 | // 163 | this.label1.AutoSize = true; 164 | this.label1.Location = new System.Drawing.Point(6, 16); 165 | this.label1.Name = "label1"; 166 | this.label1.Size = new System.Drawing.Size(35, 13); 167 | this.label1.TabIndex = 2; 168 | this.label1.Text = "Name"; 169 | // 170 | // groupBox2 171 | // 172 | this.groupBox2.Controls.Add(this.FlagsComboP2); 173 | this.groupBox2.Controls.Add(this.label5); 174 | this.groupBox2.Controls.Add(this.Player2Score); 175 | this.groupBox2.Controls.Add(this.label6); 176 | this.groupBox2.Controls.Add(this.Player2Character); 177 | this.groupBox2.Controls.Add(this.label7); 178 | this.groupBox2.Controls.Add(this.Player2Sponsor); 179 | this.groupBox2.Controls.Add(this.label8); 180 | this.groupBox2.Controls.Add(this.Player2Name); 181 | this.groupBox2.Location = new System.Drawing.Point(263, 30); 182 | this.groupBox2.Name = "groupBox2"; 183 | this.groupBox2.Size = new System.Drawing.Size(245, 158); 184 | this.groupBox2.TabIndex = 7; 185 | this.groupBox2.TabStop = false; 186 | this.groupBox2.Text = "Player 2"; 187 | // 188 | // FlagsComboP2 189 | // 190 | this.FlagsComboP2.FormattingEnabled = true; 191 | this.FlagsComboP2.Location = new System.Drawing.Point(6, 98); 192 | this.FlagsComboP2.Name = "FlagsComboP2"; 193 | this.FlagsComboP2.Size = new System.Drawing.Size(121, 21); 194 | this.FlagsComboP2.TabIndex = 8; 195 | // 196 | // label5 197 | // 198 | this.label5.AutoSize = true; 199 | this.label5.Location = new System.Drawing.Point(130, 55); 200 | this.label5.Name = "label5"; 201 | this.label5.Size = new System.Drawing.Size(35, 13); 202 | this.label5.TabIndex = 6; 203 | this.label5.Text = "Score"; 204 | // 205 | // Player2Score 206 | // 207 | this.Player2Score.Location = new System.Drawing.Point(133, 71); 208 | this.Player2Score.Name = "Player2Score"; 209 | this.Player2Score.Size = new System.Drawing.Size(43, 20); 210 | this.Player2Score.TabIndex = 2; 211 | // 212 | // label6 213 | // 214 | this.label6.AutoSize = true; 215 | this.label6.Location = new System.Drawing.Point(6, 55); 216 | this.label6.Name = "label6"; 217 | this.label6.Size = new System.Drawing.Size(53, 13); 218 | this.label6.TabIndex = 5; 219 | this.label6.Text = "Character"; 220 | // 221 | // Player2Character 222 | // 223 | this.Player2Character.FormattingEnabled = true; 224 | this.Player2Character.Location = new System.Drawing.Point(6, 71); 225 | this.Player2Character.Name = "Player2Character"; 226 | this.Player2Character.Size = new System.Drawing.Size(121, 21); 227 | this.Player2Character.TabIndex = 4; 228 | // 229 | // label7 230 | // 231 | this.label7.AutoSize = true; 232 | this.label7.Location = new System.Drawing.Point(115, 16); 233 | this.label7.Name = "label7"; 234 | this.label7.Size = new System.Drawing.Size(46, 13); 235 | this.label7.TabIndex = 3; 236 | this.label7.Text = "Sponsor"; 237 | // 238 | // Player2Sponsor 239 | // 240 | this.Player2Sponsor.FormattingEnabled = true; 241 | this.Player2Sponsor.Location = new System.Drawing.Point(118, 31); 242 | this.Player2Sponsor.Name = "Player2Sponsor"; 243 | this.Player2Sponsor.Size = new System.Drawing.Size(121, 21); 244 | this.Player2Sponsor.TabIndex = 2; 245 | // 246 | // label8 247 | // 248 | this.label8.AutoSize = true; 249 | this.label8.Location = new System.Drawing.Point(6, 16); 250 | this.label8.Name = "label8"; 251 | this.label8.Size = new System.Drawing.Size(35, 13); 252 | this.label8.TabIndex = 2; 253 | this.label8.Text = "Name"; 254 | // 255 | // Player2Name 256 | // 257 | this.Player2Name.Location = new System.Drawing.Point(6, 32); 258 | this.Player2Name.Name = "Player2Name"; 259 | this.Player2Name.Size = new System.Drawing.Size(100, 20); 260 | this.Player2Name.TabIndex = 0; 261 | // 262 | // SendUpdateButton 263 | // 264 | this.SendUpdateButton.Location = new System.Drawing.Point(454, 329); 265 | this.SendUpdateButton.Name = "SendUpdateButton"; 266 | this.SendUpdateButton.Size = new System.Drawing.Size(106, 23); 267 | this.SendUpdateButton.TabIndex = 8; 268 | this.SendUpdateButton.Text = "Send Update"; 269 | this.SendUpdateButton.UseVisualStyleBackColor = true; 270 | this.SendUpdateButton.Click += new System.EventHandler(this.SendUpdateButton_Click); 271 | // 272 | // RoundNameTextbox 273 | // 274 | this.RoundNameTextbox.Location = new System.Drawing.Point(6, 35); 275 | this.RoundNameTextbox.Name = "RoundNameTextbox"; 276 | this.RoundNameTextbox.Size = new System.Drawing.Size(100, 20); 277 | this.RoundNameTextbox.TabIndex = 9; 278 | // 279 | // tournamentNameTextbox 280 | // 281 | this.tournamentNameTextbox.Location = new System.Drawing.Point(6, 74); 282 | this.tournamentNameTextbox.Name = "tournamentNameTextbox"; 283 | this.tournamentNameTextbox.Size = new System.Drawing.Size(100, 20); 284 | this.tournamentNameTextbox.TabIndex = 10; 285 | // 286 | // groupBox3 287 | // 288 | this.groupBox3.Controls.Add(this.label10); 289 | this.groupBox3.Controls.Add(this.label9); 290 | this.groupBox3.Controls.Add(this.tournamentNameTextbox); 291 | this.groupBox3.Controls.Add(this.RoundNameTextbox); 292 | this.groupBox3.Location = new System.Drawing.Point(12, 194); 293 | this.groupBox3.Name = "groupBox3"; 294 | this.groupBox3.Size = new System.Drawing.Size(200, 100); 295 | this.groupBox3.TabIndex = 11; 296 | this.groupBox3.TabStop = false; 297 | this.groupBox3.Text = "Tournament"; 298 | // 299 | // label10 300 | // 301 | this.label10.AutoSize = true; 302 | this.label10.Location = new System.Drawing.Point(6, 16); 303 | this.label10.Name = "label10"; 304 | this.label10.Size = new System.Drawing.Size(39, 13); 305 | this.label10.TabIndex = 12; 306 | this.label10.Text = "Round"; 307 | // 308 | // label9 309 | // 310 | this.label9.AutoSize = true; 311 | this.label9.Location = new System.Drawing.Point(6, 58); 312 | this.label9.Name = "label9"; 313 | this.label9.Size = new System.Drawing.Size(64, 13); 314 | this.label9.TabIndex = 11; 315 | this.label9.Text = "Tournament"; 316 | // 317 | // groupBox4 318 | // 319 | this.groupBox4.Controls.Add(this.label11); 320 | this.groupBox4.Controls.Add(this.label12); 321 | this.groupBox4.Controls.Add(this.CasterTextbox); 322 | this.groupBox4.Controls.Add(this.StreamerTextbox); 323 | this.groupBox4.Location = new System.Drawing.Point(263, 194); 324 | this.groupBox4.Name = "groupBox4"; 325 | this.groupBox4.Size = new System.Drawing.Size(200, 100); 326 | this.groupBox4.TabIndex = 13; 327 | this.groupBox4.TabStop = false; 328 | this.groupBox4.Text = "Misc"; 329 | // 330 | // label11 331 | // 332 | this.label11.AutoSize = true; 333 | this.label11.Location = new System.Drawing.Point(6, 16); 334 | this.label11.Name = "label11"; 335 | this.label11.Size = new System.Drawing.Size(49, 13); 336 | this.label11.TabIndex = 12; 337 | this.label11.Text = "Streamer"; 338 | // 339 | // label12 340 | // 341 | this.label12.AutoSize = true; 342 | this.label12.Location = new System.Drawing.Point(6, 58); 343 | this.label12.Name = "label12"; 344 | this.label12.Size = new System.Drawing.Size(42, 13); 345 | this.label12.TabIndex = 11; 346 | this.label12.Text = "Casters"; 347 | // 348 | // CasterTextbox 349 | // 350 | this.CasterTextbox.Location = new System.Drawing.Point(6, 74); 351 | this.CasterTextbox.Name = "CasterTextbox"; 352 | this.CasterTextbox.Size = new System.Drawing.Size(100, 20); 353 | this.CasterTextbox.TabIndex = 10; 354 | // 355 | // StreamerTextbox 356 | // 357 | this.StreamerTextbox.Location = new System.Drawing.Point(6, 35); 358 | this.StreamerTextbox.Name = "StreamerTextbox"; 359 | this.StreamerTextbox.Size = new System.Drawing.Size(100, 20); 360 | this.StreamerTextbox.TabIndex = 9; 361 | // 362 | // SettingsButton 363 | // 364 | this.SettingsButton.Location = new System.Drawing.Point(373, 329); 365 | this.SettingsButton.Name = "SettingsButton"; 366 | this.SettingsButton.Size = new System.Drawing.Size(75, 23); 367 | this.SettingsButton.TabIndex = 14; 368 | this.SettingsButton.Text = "Settings"; 369 | this.SettingsButton.UseVisualStyleBackColor = true; 370 | this.SettingsButton.Click += new System.EventHandler(this.SettingsButton_Click); 371 | // 372 | // menuStrip1 373 | // 374 | this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { 375 | this.fileToolStripMenuItem}); 376 | this.menuStrip1.Location = new System.Drawing.Point(0, 0); 377 | this.menuStrip1.Name = "menuStrip1"; 378 | this.menuStrip1.Size = new System.Drawing.Size(572, 24); 379 | this.menuStrip1.TabIndex = 15; 380 | this.menuStrip1.Text = "menuStrip1"; 381 | // 382 | // fileToolStripMenuItem 383 | // 384 | this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { 385 | this.openToolStripMenuItem, 386 | this.saveAsToolStripMenuItem}); 387 | this.fileToolStripMenuItem.Name = "fileToolStripMenuItem"; 388 | this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20); 389 | this.fileToolStripMenuItem.Text = "File"; 390 | // 391 | // openToolStripMenuItem 392 | // 393 | this.openToolStripMenuItem.Name = "openToolStripMenuItem"; 394 | this.openToolStripMenuItem.Size = new System.Drawing.Size(121, 22); 395 | this.openToolStripMenuItem.Text = "Open"; 396 | this.openToolStripMenuItem.Click += new System.EventHandler(this.openToolStripMenuItem_Click); 397 | // 398 | // saveAsToolStripMenuItem 399 | // 400 | this.saveAsToolStripMenuItem.Name = "saveAsToolStripMenuItem"; 401 | this.saveAsToolStripMenuItem.Size = new System.Drawing.Size(121, 22); 402 | this.saveAsToolStripMenuItem.Text = "Save as..."; 403 | this.saveAsToolStripMenuItem.Click += new System.EventHandler(this.saveAsToolStripMenuItem_Click); 404 | // 405 | // StartServer 406 | // 407 | this.StartServer.Location = new System.Drawing.Point(294, 329); 408 | this.StartServer.Name = "StartServer"; 409 | this.StartServer.Size = new System.Drawing.Size(75, 23); 410 | this.StartServer.TabIndex = 16; 411 | this.StartServer.Text = "Start Server"; 412 | this.StartServer.UseVisualStyleBackColor = true; 413 | this.StartServer.Click += new System.EventHandler(this.StartServer_Click); 414 | // 415 | // UrlLinkLabel 416 | // 417 | this.UrlLinkLabel.AutoSize = true; 418 | this.UrlLinkLabel.Location = new System.Drawing.Point(304, 313); 419 | this.UrlLinkLabel.Name = "UrlLinkLabel"; 420 | this.UrlLinkLabel.Size = new System.Drawing.Size(0, 13); 421 | this.UrlLinkLabel.TabIndex = 17; 422 | this.UrlLinkLabel.Click += new System.EventHandler(this.UrlLinkLabel_Click); 423 | // 424 | // MainForm 425 | // 426 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 427 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 428 | this.ClientSize = new System.Drawing.Size(572, 360); 429 | this.Controls.Add(this.UrlLinkLabel); 430 | this.Controls.Add(this.StartServer); 431 | this.Controls.Add(this.SettingsButton); 432 | this.Controls.Add(this.groupBox4); 433 | this.Controls.Add(this.groupBox3); 434 | this.Controls.Add(this.SendUpdateButton); 435 | this.Controls.Add(this.groupBox2); 436 | this.Controls.Add(this.groupBox1); 437 | this.Controls.Add(this.menuStrip1); 438 | this.MainMenuStrip = this.menuStrip1; 439 | this.Name = "MainForm"; 440 | this.Text = "Super Hyper Ultra Scoreboard"; 441 | this.Load += new System.EventHandler(this.Form1_Load); 442 | this.groupBox1.ResumeLayout(false); 443 | this.groupBox1.PerformLayout(); 444 | ((System.ComponentModel.ISupportInitialize)(this.Player1Score)).EndInit(); 445 | this.groupBox2.ResumeLayout(false); 446 | this.groupBox2.PerformLayout(); 447 | ((System.ComponentModel.ISupportInitialize)(this.Player2Score)).EndInit(); 448 | this.groupBox3.ResumeLayout(false); 449 | this.groupBox3.PerformLayout(); 450 | this.groupBox4.ResumeLayout(false); 451 | this.groupBox4.PerformLayout(); 452 | this.menuStrip1.ResumeLayout(false); 453 | this.menuStrip1.PerformLayout(); 454 | this.ResumeLayout(false); 455 | this.PerformLayout(); 456 | 457 | } 458 | 459 | #endregion 460 | 461 | private System.Windows.Forms.TextBox Player1Name; 462 | private System.Windows.Forms.GroupBox groupBox1; 463 | internal System.Windows.Forms.Label label4; 464 | private System.Windows.Forms.NumericUpDown Player1Score; 465 | internal System.Windows.Forms.Label label3; 466 | private System.Windows.Forms.ComboBox Player1Character; 467 | internal System.Windows.Forms.Label label2; 468 | private System.Windows.Forms.ComboBox Player1Sponsor; 469 | internal System.Windows.Forms.Label label1; 470 | private System.Windows.Forms.GroupBox groupBox2; 471 | internal System.Windows.Forms.Label label5; 472 | private System.Windows.Forms.NumericUpDown Player2Score; 473 | internal System.Windows.Forms.Label label6; 474 | private System.Windows.Forms.ComboBox Player2Character; 475 | internal System.Windows.Forms.Label label7; 476 | private System.Windows.Forms.ComboBox Player2Sponsor; 477 | internal System.Windows.Forms.Label label8; 478 | private System.Windows.Forms.TextBox Player2Name; 479 | private System.Windows.Forms.Button SendUpdateButton; 480 | private System.Windows.Forms.TextBox RoundNameTextbox; 481 | private System.Windows.Forms.TextBox tournamentNameTextbox; 482 | private System.Windows.Forms.GroupBox groupBox3; 483 | private System.Windows.Forms.Label label10; 484 | private System.Windows.Forms.Label label9; 485 | private System.Windows.Forms.GroupBox groupBox4; 486 | private System.Windows.Forms.Label label11; 487 | private System.Windows.Forms.Label label12; 488 | private System.Windows.Forms.TextBox CasterTextbox; 489 | private System.Windows.Forms.TextBox StreamerTextbox; 490 | private System.Windows.Forms.ComboBox FlagsCombo; 491 | private System.Windows.Forms.ComboBox FlagsComboP2; 492 | private System.Windows.Forms.Button SettingsButton; 493 | private System.Windows.Forms.MenuStrip menuStrip1; 494 | private System.Windows.Forms.ToolStripMenuItem fileToolStripMenuItem; 495 | private System.Windows.Forms.ToolStripMenuItem openToolStripMenuItem; 496 | private System.Windows.Forms.ToolStripMenuItem saveAsToolStripMenuItem; 497 | private System.Windows.Forms.Button StartServer; 498 | private System.Windows.Forms.LinkLabel UrlLinkLabel; 499 | } 500 | } 501 | 502 | -------------------------------------------------------------------------------- /S3/MainForm.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Diagnostics; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | using System.IO; 12 | using ImageMagick; 13 | using Nancy.Hosting.Self; 14 | using Newtonsoft.Json; 15 | namespace S3 16 | { 17 | public partial class MainForm : Form 18 | { 19 | private NancyHost hostg; 20 | public MainForm() 21 | { 22 | InitializeComponent(); 23 | Globals.CurrentInformationUpdate = new InformationUpdate(); 24 | Globals.CurrentInformationUpdate.Player1 = new Player(); 25 | Globals.CurrentInformationUpdate.Player2 = new Player(); 26 | Globals.CurrentInformationUpdate.Player1.name = "EIREXE"; 27 | Globals.CurrentInformationUpdate.Player2.name = "BoastingToast"; 28 | parseComboBoxItems(); 29 | SendUpdate(); 30 | } 31 | 32 | private void Form1_Load(object sender, EventArgs e) 33 | { 34 | 35 | } 36 | 37 | private void SendUpdateButton_Click(object sender, EventArgs e) 38 | { 39 | SendUpdate(); 40 | 41 | } 42 | 43 | private void SendUpdate() 44 | { 45 | Globals.CurrentInformationUpdate.Player1.name = Player1Name.Text; 46 | Globals.CurrentInformationUpdate.Player2.name = Player2Name.Text; 47 | Globals.CurrentInformationUpdate.Player1.sponsor = (Sponsor)((ComboboxItem)Player1Sponsor.SelectedItem).Value; 48 | Globals.CurrentInformationUpdate.Player2.sponsor = (Sponsor)((ComboboxItem)Player2Sponsor.SelectedItem).Value; 49 | Globals.CurrentInformationUpdate.Player1.character = (Character)((ComboboxItem)Player1Character.SelectedItem).Value; 50 | Globals.CurrentInformationUpdate.Player2.character = (Character)((ComboboxItem)Player2Character.SelectedItem).Value; 51 | Globals.CurrentInformationUpdate.Player1.score = Decimal.ToInt32(Player1Score.Value); 52 | Globals.CurrentInformationUpdate.Player2.score = Decimal.ToInt32(Player2Score.Value); 53 | Globals.CurrentInformationUpdate.tournamentName = tournamentNameTextbox.Text; 54 | Globals.CurrentInformationUpdate.round = RoundNameTextbox.Text; 55 | Globals.CurrentInformationUpdate.caster = CasterTextbox.Text; 56 | Globals.CurrentInformationUpdate.streamer = StreamerTextbox.Text; 57 | Globals.CurrentInformationUpdate.Player1.flag = ((Flag) ((ComboboxItem) FlagsCombo.SelectedItem).Value); 58 | Globals.CurrentInformationUpdate.Player2.flag = ((Flag)((ComboboxItem)FlagsComboP2.SelectedItem).Value); 59 | } 60 | private void parseComboBoxItems() 61 | { 62 | string file = Path.Combine(Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location), "characters.json"); 63 | string contents = File.ReadAllText(file); 64 | CharacterList list = JsonConvert.DeserializeObject(contents); 65 | 66 | foreach(Character c in list.characters) 67 | { 68 | ComboboxItem item = new ComboboxItem(); 69 | item.Text = c.name; 70 | item.Value = c; 71 | Player1Character.Items.Add(item); 72 | Player2Character.Items.Add(item); 73 | 74 | } 75 | Player1Character.SelectedIndex = 0; 76 | Player2Character.SelectedIndex = 0; 77 | 78 | 79 | string sponsors = Path.Combine(Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location), "sponsors.json"); 80 | string sponsorsContents = File.ReadAllText(sponsors); 81 | SponsorList sponsorslist = JsonConvert.DeserializeObject(sponsorsContents); 82 | 83 | foreach (Sponsor s in sponsorslist.sponsors) 84 | { 85 | ComboboxItem item = new ComboboxItem(); 86 | item.Text = s.name; 87 | item.Value = s; 88 | Player1Sponsor.Items.Add(item); 89 | Player2Sponsor.Items.Add(item); 90 | 91 | } 92 | Player1Character.SelectedIndex = 0; 93 | Player2Character.SelectedIndex = 0; 94 | Player1Sponsor.SelectedIndex = 0; 95 | Player2Sponsor.SelectedIndex = 0; 96 | string flags = Path.Combine(Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location), "flags.json"); 97 | string flagsContents = File.ReadAllText(flags); 98 | FlagList flagsList = JsonConvert.DeserializeObject(flagsContents); 99 | foreach (Flag flag in flagsList.flags) 100 | { 101 | ComboboxItem item = new ComboboxItem(); 102 | item.Text = flag.name; 103 | item.Value = flag; 104 | FlagsCombo.Items.Add(item); 105 | FlagsComboP2.Items.Add(item); 106 | } 107 | FlagsCombo.SelectedIndex = 0; 108 | FlagsComboP2.SelectedIndex = 0; 109 | } 110 | 111 | private void SettingsButton_Click(object sender, EventArgs e) 112 | { 113 | SettingsForm form = new SettingsForm(); 114 | form.ShowDialog(); 115 | } 116 | 117 | private void openToolStripMenuItem_Click(object sender, EventArgs e) 118 | { 119 | OpenFileDialog dialog = new OpenFileDialog(); 120 | dialog.Filter = "Scoreboard Settings Data(.auboard)|*.auboard|All Files(*.*) | *.*"; 121 | DialogResult result = dialog.ShowDialog(); 122 | if (result == DialogResult.OK || result == DialogResult.Yes) 123 | { 124 | string contents = File.ReadAllText(dialog.FileName); 125 | Settings settings = JsonConvert.DeserializeObject(contents); 126 | Globals.settings = settings; 127 | updateData(); 128 | } 129 | } 130 | 131 | private void saveAsToolStripMenuItem_Click(object sender, EventArgs e) 132 | { 133 | SaveFileDialog dialog = new SaveFileDialog(); 134 | dialog.Filter = "Scoreboard Settings Data(.auboard)|*.auboard|All Files(*.*) | *.*"; 135 | Globals.settings.streamData = Globals.CurrentInformationUpdate; 136 | DialogResult result = dialog.ShowDialog(); 137 | if (result == DialogResult.OK || result == DialogResult.Yes) 138 | { 139 | File.WriteAllText(dialog.FileName,JsonConvert.SerializeObject(Globals.settings, Formatting.Indented)); 140 | } 141 | 142 | } 143 | 144 | private void updateData() 145 | { 146 | Player1Name.Text = Globals.settings.streamData.Player1.name; 147 | Player2Name.Text = Globals.settings.streamData.Player2.name; 148 | Player1Sponsor.Text = Globals.settings.streamData.Player1.sponsor.name; 149 | Player2Sponsor.Text = Globals.settings.streamData.Player2.sponsor.name; 150 | Player1Character.Text = Globals.settings.streamData.Player1.character.name; 151 | Player2Character.Text = Globals.settings.streamData.Player2.character.name; 152 | Player1Score.Text = Globals.settings.streamData.Player1.score.ToString(); 153 | Player2Score.Text = Globals.settings.streamData.Player2.score.ToString(); 154 | FlagsCombo.Text = Globals.settings.streamData.Player1.flag.name; 155 | FlagsComboP2.Text = Globals.settings.streamData.Player2.flag.name; 156 | RoundNameTextbox.Text = Globals.settings.streamData.round; 157 | tournamentNameTextbox.Text = Globals.settings.streamData.tournamentName; 158 | StreamerTextbox.Text = Globals.settings.streamData.streamer; 159 | CasterTextbox.Text = Globals.settings.streamData.caster; 160 | SendUpdate(); 161 | } 162 | private bool isServerUp = false; 163 | private void StartServer_Click(object sender, EventArgs e) 164 | { 165 | 166 | 167 | 168 | if (isServerUp) 169 | { 170 | hostg.Stop(); 171 | StartServer.Text = "Start Server"; 172 | isServerUp = false; 173 | } 174 | else 175 | { 176 | if (Globals.settings.tintEnabled) 177 | { 178 | foreach (string file in Directory.GetFiles(Path.Combine(Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location), "Content/html/img"))) 179 | { 180 | using (MagickImage image = new MagickImage(file)) 181 | { 182 | image.Colorize(new MagickColor(Globals.settings.tintColor), new Percentage(100)); 183 | image.Write(file); 184 | } 185 | } 186 | } 187 | isServerUp = true; 188 | try 189 | { 190 | UrlLinkLabel.Text = "http://127.0.0.1:" + Globals.settings.serverPort + "/Content/html/scoreboard.html"; 191 | HostConfiguration config = new HostConfiguration(); 192 | config.UrlReservations.CreateAutomatically = true; 193 | NancyHost host = new NancyHost(config, new Uri("http://127.0.0.1:" + Globals.settings.serverPort)); 194 | 195 | host.Start(); 196 | hostg = host; 197 | StartServer.Text = "Stop Server"; 198 | } 199 | catch (Exception ee) 200 | { 201 | Console.WriteLine(ee.Message); 202 | throw; 203 | } 204 | } 205 | } 206 | 207 | private void UrlLinkLabel_Click(object sender, EventArgs e) 208 | { 209 | Process.Start(UrlLinkLabel.Text); 210 | } 211 | } 212 | } 213 | -------------------------------------------------------------------------------- /S3/MainForm.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 17, 17 122 | 123 | -------------------------------------------------------------------------------- /S3/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using System.Windows.Forms; 6 | 7 | namespace S3 8 | { 9 | static class Program 10 | { 11 | /// 12 | /// The main entry point for the application. 13 | /// 14 | [STAThread] 15 | static void Main() 16 | { 17 | Application.EnableVisualStyles(); 18 | Application.SetCompatibleTextRenderingDefault(false); 19 | Application.Run(new MainForm()); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /S3/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("S3")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("S3")] 13 | [assembly: AssemblyCopyright("Copyright © 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("ea0e4ebc-9a72-4ba9-bcd5-15d5fa477ea3")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /S3/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace S3.Properties 12 | { 13 | 14 | 15 | /// 16 | /// A strongly-typed resource class, for looking up localized strings, etc. 17 | /// 18 | // This class was auto-generated by the StronglyTypedResourceBuilder 19 | // class via a tool like ResGen or Visual Studio. 20 | // To add or remove a member, edit your .ResX file then rerun ResGen 21 | // with the /str option, or rebuild your VS project. 22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] 23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 25 | internal class Resources 26 | { 27 | 28 | private static global::System.Resources.ResourceManager resourceMan; 29 | 30 | private static global::System.Globalization.CultureInfo resourceCulture; 31 | 32 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 33 | internal Resources() 34 | { 35 | } 36 | 37 | /// 38 | /// Returns the cached ResourceManager instance used by this class. 39 | /// 40 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 41 | internal static global::System.Resources.ResourceManager ResourceManager 42 | { 43 | get 44 | { 45 | if ((resourceMan == null)) 46 | { 47 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("S3.Properties.Resources", typeof(Resources).Assembly); 48 | resourceMan = temp; 49 | } 50 | return resourceMan; 51 | } 52 | } 53 | 54 | /// 55 | /// Overrides the current thread's CurrentUICulture property for all 56 | /// resource lookups using this strongly typed resource class. 57 | /// 58 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 59 | internal static global::System.Globalization.CultureInfo Culture 60 | { 61 | get 62 | { 63 | return resourceCulture; 64 | } 65 | set 66 | { 67 | resourceCulture = value; 68 | } 69 | } 70 | } 71 | } 72 | -------------------------------------------------------------------------------- /S3/Properties/Resources.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | text/microsoft-resx 107 | 108 | 109 | 2.0 110 | 111 | 112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 113 | 114 | 115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | -------------------------------------------------------------------------------- /S3/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace S3.Properties 12 | { 13 | 14 | 15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")] 17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 18 | { 19 | 20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 21 | 22 | public static Settings Default 23 | { 24 | get 25 | { 26 | return defaultInstance; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /S3/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /S3/S3.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {EA0E4EBC-9A72-4BA9-BCD5-15D5FA477EA3} 8 | WinExe 9 | Properties 10 | S3 11 | S3 12 | v4.5.2 13 | 512 14 | true 15 | 16 | 17 | AnyCPU 18 | true 19 | full 20 | false 21 | bin\Debug\ 22 | DEBUG;TRACE 23 | prompt 24 | 4 25 | 26 | 27 | AnyCPU 28 | pdbonly 29 | true 30 | bin\Release\ 31 | TRACE 32 | prompt 33 | 4 34 | 35 | 36 | 37 | ..\packages\Magick.NET-Q16-HDRI-AnyCPU.7.0.0.0022\lib\net40-client\Magick.NET-AnyCPU.dll 38 | True 39 | 40 | 41 | ..\packages\Magick.NET-Q16-HDRI-AnyCPU.7.0.0.0022\lib\net40-client\Magick.NET.Core.dll 42 | True 43 | 44 | 45 | ..\packages\Nancy.1.4.2\lib\net40\Nancy.dll 46 | True 47 | 48 | 49 | ..\packages\Nancy.Hosting.Self.1.4.1\lib\net40\Nancy.Hosting.Self.dll 50 | True 51 | 52 | 53 | ..\packages\Newtonsoft.Json.7.0.1\lib\net45\Newtonsoft.Json.dll 54 | True 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | Form 73 | 74 | 75 | MainForm.cs 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | Form 84 | 85 | 86 | SettingsForm.cs 87 | 88 | 89 | 90 | MainForm.cs 91 | 92 | 93 | ResXFileCodeGenerator 94 | Resources.Designer.cs 95 | Designer 96 | 97 | 98 | True 99 | Resources.resx 100 | 101 | 102 | SettingsForm.cs 103 | 104 | 105 | 106 | SettingsSingleFileGenerator 107 | Settings.Designer.cs 108 | 109 | 110 | True 111 | Settings.settings 112 | True 113 | 114 | 115 | 116 | 117 | 118 | 119 | 126 | -------------------------------------------------------------------------------- /S3/Server.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | using Nancy; 8 | using Nancy.Bootstrapper; 9 | using Nancy.Conventions; 10 | using Nancy.Diagnostics; 11 | using Nancy.Hosting.Self; 12 | using Nancy.Routing; 13 | using Nancy.TinyIoc; 14 | using Newtonsoft.Json; 15 | 16 | namespace S3 17 | { 18 | public class InformationUpdate 19 | { 20 | public Player Player1; 21 | public Player Player2; 22 | public string round; 23 | public string tournamentName; 24 | public string caster; 25 | public string streamer; 26 | 27 | } 28 | 29 | public class Player 30 | { 31 | public string name; 32 | public Character character; 33 | public Sponsor sponsor; 34 | public int score; 35 | public Flag flag; 36 | } 37 | public class Server : NancyModule 38 | { 39 | public Server() 40 | { 41 | Get["/getCurrentValues"] = parameters => 42 | { 43 | InformationUpdate update = Globals.CurrentInformationUpdate; 44 | string data = JsonConvert.SerializeObject(update); 45 | Response response = (Response)data; 46 | response.ContentType = "application/json"; 47 | return response; 48 | }; 49 | Get["/scoreboard"] = paramaters => 50 | { 51 | return Response.AsFile("Content/index.html", "text/html"); 52 | }; 53 | } 54 | 55 | public static NancyHost Run(Uri uri) 56 | { 57 | try 58 | { 59 | HostConfiguration config = new HostConfiguration(); 60 | config.UrlReservations.CreateAutomatically = true; 61 | NancyHost host = new NancyHost(config, uri); 62 | 63 | host.Start(); 64 | return host; 65 | } 66 | catch (Exception e) 67 | { 68 | Console.WriteLine(e.Message); 69 | throw; 70 | } 71 | 72 | } 73 | } 74 | 75 | public class CustomBootstrapper : DefaultNancyBootstrapper 76 | { 77 | protected override void ApplicationStartup(TinyIoCContainer container, IPipelines pipelines) 78 | { 79 | // your customization goes here 80 | } 81 | 82 | protected override void RequestStartup(TinyIoCContainer container, IPipelines pipelines, NancyContext context) 83 | { 84 | 85 | //CORS Enable 86 | pipelines.AfterRequest.AddItemToEndOfPipeline((ctx) => 87 | { 88 | ctx.Response.WithHeader("Access-Control-Allow-Origin", "*") 89 | .WithHeader("Access-Control-Allow-Methods", "POST,GET") 90 | .WithHeader("Access-Control-Allow-Headers", "Accept, Origin, Content-type"); 91 | 92 | }); 93 | } 94 | protected override void ConfigureConventions(NancyConventions conventions) 95 | { 96 | base.ConfigureConventions(conventions); 97 | 98 | conventions.StaticContentsConventions.Add( 99 | StaticContentConventionBuilder.AddDirectory("assets", @"Content/html/*") 100 | ); 101 | } 102 | } 103 | } 104 | -------------------------------------------------------------------------------- /S3/Settings.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace S3 8 | { 9 | class Settings 10 | { 11 | public bool tintEnabled = false; 12 | public string tintColor = "#FFF"; 13 | public int serverPort = 8081; 14 | public InformationUpdate streamData; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /S3/SettingsForm.Designer.cs: -------------------------------------------------------------------------------- 1 | namespace S3 2 | { 3 | partial class SettingsForm 4 | { 5 | /// 6 | /// Required designer variable. 7 | /// 8 | private System.ComponentModel.IContainer components = null; 9 | 10 | /// 11 | /// Clean up any resources being used. 12 | /// 13 | /// true if managed resources should be disposed; otherwise, false. 14 | protected override void Dispose(bool disposing) 15 | { 16 | if (disposing && (components != null)) 17 | { 18 | components.Dispose(); 19 | } 20 | base.Dispose(disposing); 21 | } 22 | 23 | #region Windows Form Designer generated code 24 | 25 | /// 26 | /// Required method for Designer support - do not modify 27 | /// the contents of this method with the code editor. 28 | /// 29 | private void InitializeComponent() 30 | { 31 | this.groupBox1 = new System.Windows.Forms.GroupBox(); 32 | this.label1 = new System.Windows.Forms.Label(); 33 | this.ServerPortbox = new System.Windows.Forms.NumericUpDown(); 34 | this.groupBox2 = new System.Windows.Forms.GroupBox(); 35 | this.ColorTextBox = new System.Windows.Forms.TextBox(); 36 | this.TintingEnableCheckbox = new System.Windows.Forms.CheckBox(); 37 | this.OkButton = new System.Windows.Forms.Button(); 38 | this.CancelButton = new System.Windows.Forms.Button(); 39 | this.groupBox1.SuspendLayout(); 40 | ((System.ComponentModel.ISupportInitialize)(this.ServerPortbox)).BeginInit(); 41 | this.groupBox2.SuspendLayout(); 42 | this.SuspendLayout(); 43 | // 44 | // groupBox1 45 | // 46 | this.groupBox1.Controls.Add(this.label1); 47 | this.groupBox1.Controls.Add(this.ServerPortbox); 48 | this.groupBox1.Location = new System.Drawing.Point(12, 12); 49 | this.groupBox1.Name = "groupBox1"; 50 | this.groupBox1.Size = new System.Drawing.Size(134, 58); 51 | this.groupBox1.TabIndex = 0; 52 | this.groupBox1.TabStop = false; 53 | this.groupBox1.Text = "Ports"; 54 | // 55 | // label1 56 | // 57 | this.label1.AutoSize = true; 58 | this.label1.Location = new System.Drawing.Point(6, 21); 59 | this.label1.Name = "label1"; 60 | this.label1.Size = new System.Drawing.Size(59, 13); 61 | this.label1.TabIndex = 1; 62 | this.label1.Text = "Server port"; 63 | // 64 | // ServerPortbox 65 | // 66 | this.ServerPortbox.Location = new System.Drawing.Point(76, 19); 67 | this.ServerPortbox.Maximum = new decimal(new int[] { 68 | 9999, 69 | 0, 70 | 0, 71 | 0}); 72 | this.ServerPortbox.Name = "ServerPortbox"; 73 | this.ServerPortbox.Size = new System.Drawing.Size(52, 20); 74 | this.ServerPortbox.TabIndex = 1; 75 | // 76 | // groupBox2 77 | // 78 | this.groupBox2.Controls.Add(this.ColorTextBox); 79 | this.groupBox2.Controls.Add(this.TintingEnableCheckbox); 80 | this.groupBox2.Location = new System.Drawing.Point(152, 12); 81 | this.groupBox2.Name = "groupBox2"; 82 | this.groupBox2.Size = new System.Drawing.Size(97, 73); 83 | this.groupBox2.TabIndex = 1; 84 | this.groupBox2.TabStop = false; 85 | this.groupBox2.Text = "Tinting"; 86 | // 87 | // ColorTextBox 88 | // 89 | this.ColorTextBox.Location = new System.Drawing.Point(7, 38); 90 | this.ColorTextBox.Name = "ColorTextBox"; 91 | this.ColorTextBox.Size = new System.Drawing.Size(84, 20); 92 | this.ColorTextBox.TabIndex = 1; 93 | // 94 | // TintingEnableCheckbox 95 | // 96 | this.TintingEnableCheckbox.AutoSize = true; 97 | this.TintingEnableCheckbox.Location = new System.Drawing.Point(6, 19); 98 | this.TintingEnableCheckbox.Name = "TintingEnableCheckbox"; 99 | this.TintingEnableCheckbox.Size = new System.Drawing.Size(90, 17); 100 | this.TintingEnableCheckbox.TabIndex = 0; 101 | this.TintingEnableCheckbox.Text = "Enable tinting"; 102 | this.TintingEnableCheckbox.UseVisualStyleBackColor = true; 103 | this.TintingEnableCheckbox.CheckedChanged += new System.EventHandler(this.TintingEnableCheckbox_CheckedChanged); 104 | // 105 | // OkButton 106 | // 107 | this.OkButton.Location = new System.Drawing.Point(12, 91); 108 | this.OkButton.Name = "OkButton"; 109 | this.OkButton.Size = new System.Drawing.Size(75, 23); 110 | this.OkButton.TabIndex = 2; 111 | this.OkButton.Text = "OK"; 112 | this.OkButton.UseVisualStyleBackColor = true; 113 | this.OkButton.Click += new System.EventHandler(this.OkButton_Click); 114 | // 115 | // CancelButton 116 | // 117 | this.CancelButton.Location = new System.Drawing.Point(93, 91); 118 | this.CancelButton.Name = "CancelButton"; 119 | this.CancelButton.Size = new System.Drawing.Size(75, 23); 120 | this.CancelButton.TabIndex = 3; 121 | this.CancelButton.Text = "Cancel"; 122 | this.CancelButton.UseVisualStyleBackColor = true; 123 | this.CancelButton.Click += new System.EventHandler(this.CancelButton_Click); 124 | // 125 | // SettingsForm 126 | // 127 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 128 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 129 | this.ClientSize = new System.Drawing.Size(273, 117); 130 | this.Controls.Add(this.CancelButton); 131 | this.Controls.Add(this.OkButton); 132 | this.Controls.Add(this.groupBox2); 133 | this.Controls.Add(this.groupBox1); 134 | this.MaximizeBox = false; 135 | this.Name = "SettingsForm"; 136 | this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide; 137 | this.Text = "SettingsForm"; 138 | this.groupBox1.ResumeLayout(false); 139 | this.groupBox1.PerformLayout(); 140 | ((System.ComponentModel.ISupportInitialize)(this.ServerPortbox)).EndInit(); 141 | this.groupBox2.ResumeLayout(false); 142 | this.groupBox2.PerformLayout(); 143 | this.ResumeLayout(false); 144 | 145 | } 146 | 147 | #endregion 148 | 149 | private System.Windows.Forms.GroupBox groupBox1; 150 | private System.Windows.Forms.Label label1; 151 | private System.Windows.Forms.NumericUpDown ServerPortbox; 152 | private System.Windows.Forms.GroupBox groupBox2; 153 | private System.Windows.Forms.CheckBox TintingEnableCheckbox; 154 | private System.Windows.Forms.Button OkButton; 155 | private System.Windows.Forms.Button CancelButton; 156 | private System.Windows.Forms.TextBox ColorTextBox; 157 | } 158 | } -------------------------------------------------------------------------------- /S3/SettingsForm.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | 11 | namespace S3 12 | { 13 | public partial class SettingsForm : Form 14 | { 15 | public SettingsForm() 16 | { 17 | InitializeComponent(); 18 | if (!Globals.settings.tintEnabled) 19 | { 20 | ColorTextBox.Enabled = false; 21 | 22 | } 23 | else 24 | { 25 | 26 | TintingEnableCheckbox.Checked = true; 27 | 28 | } 29 | ServerPortbox.Value = Globals.settings.serverPort; 30 | ColorTextBox.Text = Globals.settings.tintColor; 31 | } 32 | 33 | private void TintingEnableCheckbox_CheckedChanged(object sender, EventArgs e) 34 | { 35 | if (TintingEnableCheckbox.Checked) 36 | { 37 | ColorTextBox.Enabled = true; 38 | } 39 | else 40 | { 41 | ColorTextBox.Enabled = false; 42 | } 43 | } 44 | 45 | private void OkButton_Click(object sender, EventArgs e) 46 | { 47 | Globals.settings.serverPort = Convert.ToInt32(ServerPortbox.Value); 48 | Globals.settings.tintColor = ColorTextBox.Text; 49 | Globals.settings.tintEnabled = TintingEnableCheckbox.Checked; 50 | Close(); 51 | } 52 | 53 | private void CancelButton_Click(object sender, EventArgs e) 54 | { 55 | Close(); 56 | } 57 | } 58 | } 59 | -------------------------------------------------------------------------------- /S3/SettingsForm.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | -------------------------------------------------------------------------------- /S3/Sponsor.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace S3 8 | { 9 | public class Sponsor 10 | { 11 | public string name; 12 | public string icon; 13 | } 14 | 15 | class SponsorList 16 | { 17 | public IList sponsors; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /S3/Stuff/Content/html/config/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "test": "hello world", 3 | } -------------------------------------------------------------------------------- /S3/Stuff/Content/html/css/pregame.css: -------------------------------------------------------------------------------- 1 | .pregameContainerLeft 2 | { 3 | position: absolute; 4 | bottom: 14%; 5 | left: 0%; 6 | } 7 | .pregameContainerRight 8 | { 9 | position: absolute; 10 | bottom: 14%; 11 | right: 0%; 12 | } 13 | .content { 14 | font-family: 'Montserrat', sans-serif; 15 | left: -5%; 16 | position:absolute; 17 | text-align: center; 18 | top: 15px; 19 | color: #fff; 20 | font-size: 40px; 21 | width: 100%; 22 | vertical-align: middle; 23 | } 24 | .contentRight { 25 | font-family: 'Montserrat', sans-serif; 26 | right: -5%; 27 | position:absolute; 28 | text-align: center; 29 | top: 15px; 30 | color: #fff; 31 | font-size: 40px; 32 | width: 100%; 33 | vertical-align: middle; 34 | } 35 | .sponsorImg { 36 | vertical-align: middle; 37 | margin-bottom: 10px; 38 | height: 50px; 39 | } 40 | .characterImageLeft 41 | { 42 | position: absolute; 43 | display: flex; 44 | -webkit-filter: brightness(0%); 45 | justify-content: center; 46 | left: 0; 47 | bottom: 200px; 48 | width: 700px; 49 | font-family: 'Montserrat', sans-serif; 50 | font-size: 20px; 51 | text-align: center; 52 | z-index: -1; 53 | margin: 0 auto; 54 | -webkit-animation-name: moveInL; 55 | animation-name: moveInL; 56 | -webkit-animation-duration: 1s; 57 | animation-duration: 1s; 58 | -webkit-animation-iteration-count: 1; 59 | animation-iteration-count: 1; 60 | -webkit-animation-fill-mode: forwards; 61 | animation-fill-mode: forwards; 62 | } 63 | .characterImageRight 64 | { 65 | position: absolute; 66 | display: flex; 67 | -webkit-filter: brightness(0%); 68 | justify-content: center; 69 | right: 0; 70 | width: 700px; 71 | 72 | bottom: 200px; 73 | font-family: 'Montserrat', sans-serif; 74 | font-size: 20px; 75 | text-align: center; 76 | z-index: -1; 77 | filter: fliph(); 78 | 79 | -webkit-animation-name: moveInR; 80 | animation-name: moveInR; 81 | -webkit-animation-duration: 1s; 82 | animation-duration: 1s; 83 | -webkit-animation-iteration-count: 1; 84 | animation-iteration-count: 1; 85 | -webkit-animation-fill-mode: forwards; 86 | animation-fill-mode: forwards; 87 | 88 | } 89 | 90 | .imageRight 91 | { 92 | 93 | } 94 | @-webkit-keyframes moveInL { 95 | 0% { 96 | -webkit-transform: translate(-100%, 0); 97 | transform: translate(-100%, 0); 98 | } 99 | 100% { 100 | -webkit-transform: translate(0%, 0); 101 | transform: translate(0%, 0); 102 | } 103 | } 104 | @keyframes moveInL { 105 | 0% { 106 | -webkit-transform: translate(-100%, 0); 107 | transform: translate(-100%, 0); 108 | } 109 | 100% { 110 | -webkit-transform: translate(0%, 0); 111 | transform: translate(0%, 0); 112 | } 113 | } 114 | @-webkit-keyframes moveInR { 115 | 0% { 116 | -webkit-transform: translate(100%, 0) scaleX(-1); 117 | transform: translate(100%, 0) scaleX(-1); 118 | } 119 | 100% { 120 | -webkit-transform: translate(0%, 0) scaleX(-1); 121 | transform: translate(0%, 0) scaleX(-1); 122 | } 123 | } 124 | @keyframes moveInR { 125 | 0% { 126 | -webkit-transform: translate(100%, 0); 127 | transform: translate(100%, 0); 128 | 129 | } 130 | 100% { 131 | -webkit-transform: translate(0%, 0); 132 | transform: translate(0%, 0); 133 | } 134 | } 135 | .pregameImageRight 136 | { 137 | transform:scale(-1,1); 138 | -webkit-transform:scale(-1,1); 139 | -moz-transform:scale(-1,1); 140 | -o-transform:scale(-1,1)' 141 | } 142 | .white 143 | { 144 | position:fixed; 145 | background: #fff; 146 | width: 100%; 147 | height: 100%; 148 | z-index: -2; 149 | } 150 | .black 151 | { 152 | position:fixed; 153 | background: #fff; 154 | width: 100%; 155 | height: 100%; 156 | z-index: -2; 157 | } 158 | .tournament 159 | { 160 | position: fixed; 161 | left: 50%; 162 | top: 25%; 163 | /* bring your own prefixes */ 164 | transform: translate(-50%, -50%); 165 | 166 | } 167 | .round 168 | { 169 | font-family: 'Montserrat', sans-serif; 170 | text-align: center; 171 | color: #fff; 172 | font-size: 100px; 173 | vertical-align: middle; 174 | position: fixed; 175 | left: 50%; 176 | top: 75%; 177 | /* bring your own prefixes */ 178 | transform: translate(-50%, -50%); 179 | text-shadow: 3px 0 0 #000, 0 -1px 0 #000, 0 1px 0 #000, -1px 0 0 #000; 180 | } -------------------------------------------------------------------------------- /S3/Stuff/Content/html/css/scoreboard.css: -------------------------------------------------------------------------------- 1 | .upLeftCharacterName { 2 | position:absolute; 3 | left: 0; 4 | top: 0; 5 | } 6 | .upRightCharacterName { 7 | position:absolute; 8 | top: 0; 9 | right: 0; 10 | } 11 | .scoreboardBottomLeft { 12 | 13 | } 14 | .background { 15 | position:absolute; 16 | height: 1080px; 17 | width: 1920px; 18 | left: 0; 19 | top: 0; 20 | z-index: -1; 21 | } 22 | .scoreboardContainerLeft 23 | { 24 | position: absolute; 25 | bottom: 60px; 26 | width: 570px; 27 | left: 0%; 28 | } 29 | .content { 30 | font-family: 'Montserrat', sans-serif; 31 | left: -5%; 32 | position:absolute; 33 | text-align: center; 34 | top: 15px; 35 | color: #fff; 36 | font-size: 30px; 37 | width: 100%; 38 | vertical-align: middle; 39 | } 40 | .contentDownRight { 41 | font-family: 'Montserrat', sans-serif; 42 | left: -5%; 43 | position:absolute; 44 | text-align: center; 45 | top: 7px; 46 | color: #fff; 47 | font-size: 25px; 48 | width: 100%; 49 | vertical-align: middle; 50 | } 51 | .contentDownRightText { 52 | margin-bottom: 15px; 53 | } 54 | .contentTop { 55 | font-family: 'Montserrat', sans-serif; 56 | left: 0%; 57 | position:absolute; 58 | text-align: center; 59 | top: 11px; 60 | color: #fff; 61 | font-size: 25px; 62 | width: 100%; 63 | vertical-align: middle; 64 | } 65 | .upUI { 66 | position: absolute; 67 | top: 0px; 68 | left: 0%; 69 | width: 560px; 70 | } 71 | .upUIR { 72 | position: absolute; 73 | top: 0px; 74 | left: 740px; 75 | width: 570px; 76 | } 77 | .microphone { 78 | 79 | } 80 | .rightDownContainer 81 | { 82 | position: absolute; 83 | bottom: 50px; 84 | right: 30px; 85 | width: 500px; 86 | } 87 | .rightDown 88 | { 89 | 90 | } 91 | .contentRightDown { 92 | font-family: 'Montserrat', sans-serif; 93 | bottom: 0; 94 | position:absolute; 95 | text-align: center; 96 | top: 15px; 97 | color: #fff; 98 | font-size: 30px; 99 | width: 100%; 100 | vertical-align: middle; 101 | } 102 | .contentRight { 103 | font-family: 'Montserrat', sans-serif; 104 | position:absolute; 105 | text-align: center; 106 | top: 15px; 107 | color: #fff; 108 | font-size: 30px; 109 | width: 100%; 110 | vertical-align: middle; 111 | } 112 | .sponsorImg { 113 | vertical-align: middle; 114 | margin-bottom: 10px; 115 | } 116 | .microphoneImage { 117 | vertical-align: middle; 118 | margin-bottom: 6px; 119 | 120 | } 121 | .characterImgP2 { 122 | font-family: 'Montserrat', sans-serif; 123 | position:absolute; 124 | top: 14px; 125 | right: 2%; 126 | height: 40px; 127 | transform:scale(-1,1); 128 | -webkit-transform:scale(-1,1); 129 | -moz-transform:scale(-1,1); 130 | -o-transform:scale(-1,1); 131 | } 132 | .player1StreamCamName 133 | { 134 | position:absolute; 135 | top: 260px; 136 | width: 500px; 137 | right: 60px; 138 | font-family: 'Montserrat', sans-serif; 139 | color: #fff; 140 | font-size: 20px; 141 | text-align: center; 142 | } 143 | 144 | .player2StreamCamName 145 | { 146 | position:absolute; 147 | top: 545px; 148 | width: 500px; 149 | right: 60px; 150 | font-family: 'Montserrat', sans-serif; 151 | color: #fff; 152 | font-size: 20px; 153 | text-align: center; 154 | } 155 | .characterImgP1 { 156 | font-family: 'Montserrat', sans-serif; 157 | position:absolute; 158 | top: 14px; 159 | left: 2%; 160 | height: 40px; 161 | } 162 | .flagImgP2 { 163 | font-family: 'Montserrat', sans-serif; 164 | position:absolute; 165 | top: 22px; 166 | right: 2%; 167 | } 168 | .flagImgP1 { 169 | font-family: 'Montserrat', sans-serif; 170 | position:absolute; 171 | top: 22px; 172 | left: 2%; 173 | } 174 | .scoreboardBottomRight { 175 | 176 | } 177 | .scoreboardContainerRight{ 178 | position: absolute; 179 | bottom: 60px; 180 | right: 610px; 181 | width: 570px; 182 | } 183 | .dummy 184 | { 185 | 186 | } 187 | .sponsors { 188 | position: absolute; 189 | left: 250px; 190 | top: 50px; 191 | 192 | } 193 | body { 194 | } 195 | -------------------------------------------------------------------------------- /S3/Stuff/Content/html/css/scoreboardnew.css: -------------------------------------------------------------------------------- 1 | body { 2 | background: url('../img/scoreboard.png') no-repeat fixed; 3 | -webkit-background-size: cover; 4 | -moz-background-size: cover; 5 | -o-background-size: cover; 6 | background-size: cover; 7 | } 8 | .Player1Text 9 | { 10 | font-family: 'Montserrat', sans-serif; 11 | position: absolute; 12 | text-align: center; 13 | top: 15px; 14 | color: #fff; 15 | bottom: 0px; 16 | } -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/20xx.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/20xx.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/Super-Smash-Bros-Melee-large-2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/Super-Smash-Bros-Melee-large-2.jpg -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/bowser.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/bowser.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/dong.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/dong.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/dr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/dr.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/falco.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/falco.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/falcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/falcon.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/gandw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/gandw.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/ganondorf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/ganondorf.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/icies.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/icies.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/jiggs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/jiggs.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/king.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/king.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/kirby.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/kirby.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/link.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/link.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/luigi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/luigi.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/mario.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/mario.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/marth.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/marth.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/mqdefault.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/mqdefault.jpg -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/mvgLogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/mvgLogo.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/ness.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/ness.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/peach.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/peach.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/pichu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/pichu.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/pikachu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/pikachu.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/roy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/roy.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/samus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/samus.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/sheik.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/sheik.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/yoshi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/yoshi.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/younglink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/younglink.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/characters/zelda.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/characters/zelda.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/flags/spain.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/flags/spain.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/flags/spainrep.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/flags/spainrep.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/flags/uk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/flags/uk.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/flags/usa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/flags/usa.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/nocolor/camera.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/nocolor/camera.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/nocolor/microphone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/nocolor/microphone.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/nocolor/scoreboardbase.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/nocolor/scoreboardbase.psd -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/nocolor/sponsor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/nocolor/sponsor.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/overlay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/overlay.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/sponsors/modulous.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/sponsors/modulous.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/sponsors/mvg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/sponsors/mvg.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/img/sponsors/shrekboards.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/img/sponsors/shrekboards.png -------------------------------------------------------------------------------- /S3/Stuff/Content/html/js/common.js: -------------------------------------------------------------------------------- 1 | // ----------------------------------------- 2 | // 3 | // common.js 4 | // Common functions used within PaintbrushJS 5 | // 6 | // ----------------------------------------- 7 | // 8 | // These are adapted from code examples written by other people, 9 | // and are excluded from the PaintbrushJS license. 10 | // 11 | // Please see respective URLs for usage and licensing restrictions. 12 | // 13 | 14 | 15 | // addLoadEvent function, to attach events to page load 16 | // by Simon Willison 17 | // http://simonwillison.net/2004/May/26/addLoadEvent/ 18 | 19 | function addLoadEvent(func) { 20 | var oldonload = window.onload; 21 | if (typeof window.onload != 'function') { 22 | window.onload = func; 23 | } else { 24 | window.onload = function() { 25 | if (oldonload) { 26 | oldonload(); 27 | } 28 | func(); 29 | } 30 | } 31 | } 32 | 33 | 34 | 35 | // getElementsByClassName 36 | // Developed by Robert Nyman, http://www.robertnyman.com 37 | // Code/licensing: http://code.google.com/p/getelementsbyclassname/ 38 | // Documentation: http://robertnyman.com/2008/05/27/the-ultimate-getelementsbyclassname-anno-2008/ 39 | var getElementsByClassName = function (className, tag, elm){ 40 | if (document.getElementsByClassName) { 41 | getElementsByClassName = function (className, tag, elm) { 42 | elm = elm || document; 43 | var elements = elm.getElementsByClassName(className), 44 | nodeName = (tag)? new RegExp("\\b" + tag + "\\b", "i") : null, 45 | returnElements = [], 46 | current; 47 | for(var i=0, il=elements.length; i= 2.5) { 141 | q = 0.98711 * amount - 0.96330; 142 | } else if (amount >= 0.5) { 143 | q = 3.97156 - 4.14554 * Math.sqrt(1.0 - 0.26891 * amount); 144 | } else { 145 | q = 2 * amount * (3.97156 - 4.14554 * Math.sqrt(1.0 - 0.26891 * 0.5)); 146 | } 147 | 148 | //compute b0, b1, b2, and b3 149 | var qq = q * q; 150 | var qqq = qq * q; 151 | var b0 = 1.57825 + (2.44413 * q) + (1.4281 * qq ) + (0.422205 * qqq); 152 | var b1 = ((2.44413 * q) + (2.85619 * qq) + (1.26661 * qqq)) / b0; 153 | var b2 = (-((1.4281 * qq) + (1.26661 * qqq))) / b0; 154 | var b3 = (0.422205 * qqq) / b0; 155 | var bigB = 1.0 - (b1 + b2 + b3); 156 | 157 | // horizontal 158 | for (var c = 0; c < 3; c++) { 159 | for (var y = 0; y < height; y++) { 160 | // forward 161 | var index = y * width4 + c; 162 | var indexLast = y * width4 + ((width - 1) << 2) + c; 163 | var pixel = data[index]; 164 | var ppixel = pixel; 165 | var pppixel = ppixel; 166 | var ppppixel = pppixel; 167 | for (; index <= indexLast; index += 4) { 168 | pixel = bigB * data[index] + b1 * ppixel + b2 * pppixel + b3 * ppppixel; 169 | data[index] = pixel; 170 | ppppixel = pppixel; 171 | pppixel = ppixel; 172 | ppixel = pixel; 173 | } 174 | // backward 175 | index = y * width4 + ((width - 1) << 2) + c; 176 | indexLast = y * width4 + c; 177 | pixel = data[index]; 178 | ppixel = pixel; 179 | pppixel = ppixel; 180 | ppppixel = pppixel; 181 | for (; index >= indexLast; index -= 4) { 182 | pixel = bigB * data[index] + b1 * ppixel + b2 * pppixel + b3 * ppppixel; 183 | data[index] = pixel; 184 | ppppixel = pppixel; 185 | pppixel = ppixel; 186 | ppixel = pixel; 187 | } 188 | } 189 | } 190 | 191 | // vertical 192 | for (var c = 0; c < 3; c++) { 193 | for (var x = 0; x < width; x++) { 194 | // forward 195 | var index = (x << 2) + c; 196 | var indexLast = (height - 1) * width4 + (x << 2) + c; 197 | var pixel = data[index]; 198 | var ppixel = pixel; 199 | var pppixel = ppixel; 200 | var ppppixel = pppixel; 201 | for (; index <= indexLast; index += width4) { 202 | pixel = bigB * data[index] + b1 * ppixel + b2 * pppixel + b3 * ppppixel; 203 | data[index] = pixel; 204 | ppppixel = pppixel; 205 | pppixel = ppixel; 206 | ppixel = pixel; 207 | } 208 | // backward 209 | index = (height - 1) * width4 + (x << 2) + c; 210 | indexLast = (x << 2) + c; 211 | pixel = data[index]; 212 | ppixel = pixel; 213 | pppixel = ppixel; 214 | ppppixel = pppixel; 215 | for (; index >= indexLast; index -= width4) { 216 | pixel = bigB * data[index] + b1 * ppixel + b2 * pppixel + b3 * ppppixel; 217 | data[index] = pixel; 218 | ppppixel = pppixel; 219 | pppixel = ppixel; 220 | ppixel = pixel; 221 | } 222 | } 223 | } 224 | 225 | return(pixels); 226 | } 227 | } 228 | 229 | 230 | // remove a specific class from an element 231 | // from http://www.openjs.com/scripts/dom/class_manipulation.php 232 | function removeClass(obj, cls) { 233 | if (hasClass(obj, cls)) { 234 | var reg = new RegExp('(\\s|^)' + cls + '(\\s|$)'); 235 | obj.className = obj.className.replace(reg, ' '); 236 | } 237 | } 238 | function addClass(obj, cls) { 239 | if (!this.hasClass(obj, cls)) { 240 | obj.className += " " + cls; 241 | } 242 | } 243 | function hasClass(obj, cls) { 244 | return obj.className.match(new RegExp('(\\s|^)' + cls + '(\\s|$)')); 245 | } -------------------------------------------------------------------------------- /S3/Stuff/Content/html/js/l.php.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/js/l.php.gif -------------------------------------------------------------------------------- /S3/Stuff/Content/html/js/paintbrush.js: -------------------------------------------------------------------------------- 1 | // -------------------------------------------------- 2 | // 3 | // paintbrush.js, v0.3 4 | // A browser-based image processing library for HTML5 canvas 5 | // Developed by Dave Shea, http://www.mezzoblue.com/ 6 | // 7 | // This project lives on GitHub: 8 | // http://github.com/mezzoblue/PaintbrushJS 9 | // 10 | // Except where otherwise noted, PaintbrushJS is licensed under the MIT License: 11 | // http://www.opensource.org/licenses/mit-license.php 12 | // 13 | // -------------------------------------------------- 14 | 15 | 16 | 17 | 18 | // basic loader function to attach all filters used within the page 19 | addLoadEvent(function() { 20 | processFilters(); 21 | }); 22 | 23 | 24 | 25 | // function to process all filters 26 | // (exists outside of loader to enable standalone use) 27 | function processFilters() { 28 | 29 | // create working buffer outside the main loop so it's only done once 30 | var buffer = document.createElement("canvas"); 31 | // get the canvas context 32 | var c = buffer.getContext('2d'); 33 | 34 | // only run if this browser supports canvas, obviously 35 | if (supports_canvas()) { 36 | // you can add or remove lines here, depending on which filters you're using. 37 | addFilter("filter-blur", buffer, c); 38 | addFilter("filter-edges", buffer, c); 39 | addFilter("filter-emboss", buffer, c); 40 | addFilter("filter-greyscale", buffer, c); 41 | addFilter("filter-matrix", buffer, c); 42 | addFilter("filter-mosaic", buffer, c); 43 | addFilter("filter-noise", buffer, c); 44 | addFilter("filter-posterize", buffer, c); 45 | addFilter("filter-sepia", buffer, c); 46 | addFilter("filter-sharpen", buffer, c); 47 | addFilter("filter-tint", buffer, c); 48 | } 49 | } 50 | 51 | 52 | // the main workhorse function 53 | function addFilter(filterType, buffer, c) { 54 | 55 | // get every element with the specified filter class 56 | var toFilter = getElementsByClassName(filterType.toLowerCase()); 57 | 58 | // now let's loop through those elements 59 | for(var current in toFilter) { 60 | 61 | // load all specified parameters for this filter 62 | var params = getFilterParameters(toFilter[current]); 63 | 64 | // get the image we're going to work with 65 | var img = getReferenceImage(toFilter[current]); 66 | 67 | // make sure we've actually got something to work with 68 | img.onLoad = processFilters(filterType, img, params, toFilter, current, buffer, c); 69 | } 70 | 71 | 72 | function processFilters(filterType, img, params, toFilter, current, buffer, c) { 73 | 74 | // quick access to original element 75 | var ref = toFilter[current]; 76 | 77 | // original image copy naming convention 78 | var originalSuffix = filterType + "-" + current; 79 | 80 | // set buffer dimensions to image dimensions 81 | c.width = buffer.width = img.width; 82 | c.height = buffer.height = img.height; 83 | 84 | 85 | if (img && c) { 86 | // create the temporary pixel array we'll be manipulating 87 | var pixels = initializeBuffer(c, img); 88 | 89 | if (pixels) { 90 | // 91 | // pre-processing for various filters 92 | // 93 | // blur and all matrix filters have to exist outside the main loop 94 | if (filterType == "filter-blur") { 95 | pixels = gaussianBlur(img, pixels, params.blurAmount); 96 | } 97 | 98 | if (filterType == "filter-edges") { 99 | var matrix = [ 100 | 0, 1, 0, 101 | 1, -4, 1, 102 | 0, 1, 0 103 | ]; 104 | pixels = applyMatrix(img, pixels, matrix, params.edgesAmount); 105 | } 106 | if (filterType == "filter-emboss") { 107 | var matrix = [ 108 | -2, -1, 0, 109 | -1, 1, 1, 110 | 0, 1, 2 111 | ]; 112 | pixels = applyMatrix(img, pixels, matrix, params.embossAmount); 113 | } 114 | if (filterType == "filter-matrix") { 115 | // 3x3 matrix can be any combination of digits, though to maintain brightness they should add up to 1 116 | // (-1 x 8 + 9 = 1) 117 | 118 | var matrix = [ 119 | // box blur default 120 | 0.111, 0.111, 0.111, 121 | 0.111, 0.111, 0.111, 122 | 0.111, 0.111, 0.111 123 | ]; 124 | 125 | pixels = applyMatrix(img, pixels, matrix, params.matrixAmount); 126 | } 127 | if (filterType == "filter-sharpen") { 128 | var matrix = [ 129 | -1, -1, -1, 130 | -1, 9, -1, 131 | -1, -1, -1 132 | ]; 133 | pixels = applyMatrix(img, pixels, matrix, params.sharpenAmount); 134 | } 135 | 136 | // we need to figure out RGB values for tint, let's do that ahead and not waste time in the loop 137 | if (filterType == "filter-tint") { 138 | var src = parseInt(createColor(params.tintColor), 16), 139 | dest = {r: ((src & 0xFF0000) >> 16), g: ((src & 0x00FF00) >> 8), b: (src & 0x0000FF)}; 140 | } 141 | 142 | if ((filterType != "filter-blur") 143 | && (filterType != "filter-emboss") 144 | && (filterType != "filter-matrix") 145 | && (filterType != "filter-sharpen") 146 | ) { 147 | // the main loop through every pixel to apply the simpler effects 148 | // (data is per-byte, and there are 4 bytes per pixel, so lets only loop through each pixel and save a few cycles) 149 | for (var i = 0, data = pixels.data, length = data.length; i < length >> 2; i++) { 150 | var index = i << 2; 151 | 152 | // get each colour value of current pixel 153 | var thisPixel = {r: data[index], g: data[index + 1], b: data[index + 2]}; 154 | 155 | // the biggie: if we're here, let's get some filter action happening 156 | pixels = applyFilters(filterType, params, img, pixels, index, thisPixel, dest); 157 | } 158 | } 159 | 160 | // redraw the pixel data back to the working buffer 161 | c.putImageData(pixels, 0, 0); 162 | 163 | 164 | // stash a copy and let the original know how to reference it 165 | stashOriginal(img, originalSuffix, ref, buffer); 166 | 167 | } 168 | } 169 | } 170 | 171 | 172 | // the function that actually manipulates the pixels 173 | function applyFilters(filterType, params, img, pixels, index, thisPixel, dest) { 174 | 175 | // speed up access 176 | var data = pixels.data, val; 177 | var imgWidth = img.width; 178 | 179 | // figure out which filter to apply, and do it 180 | switch(filterType) { 181 | 182 | case "filter-greyscale": 183 | val = (thisPixel.r * 0.21) + (thisPixel.g * 0.71) + (thisPixel.b * 0.07); 184 | data = setRGB(data, index, 185 | findColorDifference(params.greyscaleOpacity, val, thisPixel.r), 186 | findColorDifference(params.greyscaleOpacity, val, thisPixel.g), 187 | findColorDifference(params.greyscaleOpacity, val, thisPixel.b)); 188 | break; 189 | 190 | case "filter-mosaic": 191 | // a bit more verbose to reduce amount of math necessary 192 | var pos = index >> 2; 193 | var stepY = Math.floor(pos / imgWidth); 194 | var stepY1 = stepY % params.mosaicSize; 195 | var stepX = pos - (stepY * imgWidth); 196 | var stepX1 = stepX % params.mosaicSize; 197 | 198 | if (stepY1) pos -= stepY1 * imgWidth; 199 | if (stepX1) pos -= stepX1; 200 | pos = pos << 2; 201 | 202 | data = setRGB(data, index, 203 | findColorDifference(params.mosaicOpacity, data[pos], thisPixel.r), 204 | findColorDifference(params.mosaicOpacity, data[pos + 1], thisPixel.g), 205 | findColorDifference(params.mosaicOpacity, data[pos + 2], thisPixel.b)); 206 | break; 207 | 208 | case "filter-noise": 209 | val = noise(params.noiseAmount); 210 | 211 | if ((params.noiseType == "mono") || (params.noiseType == "monochrome")) { 212 | data = setRGB(data, index, 213 | checkRGBBoundary(thisPixel.r + val), 214 | checkRGBBoundary(thisPixel.g + val), 215 | checkRGBBoundary(thisPixel.b + val)); 216 | } else { 217 | data = setRGB(data, index, 218 | checkRGBBoundary(thisPixel.r + noise(params.noiseAmount)), 219 | checkRGBBoundary(thisPixel.g + noise(params.noiseAmount)), 220 | checkRGBBoundary(thisPixel.b + noise(params.noiseAmount))); 221 | } 222 | break; 223 | 224 | case "filter-posterize": 225 | data = setRGB(data, index, 226 | findColorDifference(params.posterizeOpacity, parseInt(params.posterizeValues * parseInt(thisPixel.r / params.posterizeAreas)), thisPixel.r), 227 | findColorDifference(params.posterizeOpacity, parseInt(params.posterizeValues * parseInt(thisPixel.g / params.posterizeAreas)), thisPixel.g), 228 | findColorDifference(params.posterizeOpacity, parseInt(params.posterizeValues * parseInt(thisPixel.b / params.posterizeAreas)), thisPixel.b)); 229 | break; 230 | 231 | case "filter-sepia": 232 | data = setRGB(data, index, 233 | findColorDifference(params.sepiaOpacity, (thisPixel.r * 0.393) + (thisPixel.g * 0.769) + (thisPixel.b * 0.189), thisPixel.r), 234 | findColorDifference(params.sepiaOpacity, (thisPixel.r * 0.349) + (thisPixel.g * 0.686) + (thisPixel.b * 0.168), thisPixel.g), 235 | findColorDifference(params.sepiaOpacity, (thisPixel.r * 0.272) + (thisPixel.g * 0.534) + (thisPixel.b * 0.131), thisPixel.b)); 236 | break; 237 | 238 | case "filter-tint": 239 | data = setRGB(data, index, 240 | findColorDifference(params.tintOpacity, dest.r, thisPixel.r), 241 | findColorDifference(params.tintOpacity, dest.g, thisPixel.g), 242 | findColorDifference(params.tintOpacity, dest.b, thisPixel.b)); 243 | break; 244 | 245 | 246 | } 247 | return(pixels); 248 | } 249 | 250 | 251 | // apply a convolution matrix 252 | function applyMatrix(img, pixels, matrix, amount) { 253 | 254 | // create a second buffer to hold matrix results 255 | var buffer2 = document.createElement("canvas"); 256 | // get the canvas context 257 | var c2 = buffer2.getContext('2d'); 258 | 259 | // set the dimensions 260 | c2.width = buffer2.width = img.width; 261 | c2.height = buffer2.height = img.height; 262 | 263 | // draw the image to the new buffer 264 | c2.drawImage(img, 0, 0, img.width , img.height); 265 | var bufferedPixels = c2.getImageData(0, 0, c.width, c.height) 266 | 267 | // speed up access 268 | var data = pixels.data, bufferedData = bufferedPixels.data, imgWidth = img.width; 269 | 270 | // make sure the matrix adds up to 1 271 | /* matrix = normalizeMatrix(matrix); */ 272 | 273 | // calculate the size of the matrix 274 | var matrixSize = Math.sqrt(matrix.length); 275 | // also store the size of the kernel radius (half the size of the matrix) 276 | var kernelRadius = Math.floor(matrixSize / 2); 277 | 278 | // loop through every pixel 279 | for (var i = 1; i < imgWidth - 1; i++) { 280 | for (var j = 1; j < img.height - 1; j++) { 281 | 282 | // temporary holders for matrix results 283 | var sumR = sumG = sumB = 0; 284 | 285 | // loop through the matrix itself 286 | for (var h = 0; h < matrixSize; h++) { 287 | for (var w = 0; w < matrixSize; w++) { 288 | 289 | // get a refence to a pixel position in the matrix 290 | var r = convertCoordinates(i + w - kernelRadius, j + h - kernelRadius, imgWidth) << 2; 291 | 292 | // find RGB values for that pixel 293 | var currentPixel = { 294 | r: bufferedData[r], 295 | g: bufferedData[r + 1], 296 | b: bufferedData[r + 2] 297 | }; 298 | 299 | // apply the value from the current matrix position 300 | sumR += currentPixel.r * matrix[w + h * matrixSize]; 301 | sumG += currentPixel.g * matrix[w + h * matrixSize]; 302 | sumB += currentPixel.b * matrix[w + h * matrixSize]; 303 | } 304 | } 305 | 306 | // get a reference for the final pixel 307 | var ref = convertCoordinates(i, j, imgWidth) << 2; 308 | var thisPixel = { 309 | r: data[ref], 310 | g: data[ref + 1], 311 | b: data[ref + 2] 312 | }; 313 | 314 | // finally, apply the adjusted values 315 | data = setRGB(data, ref, 316 | findColorDifference(amount, sumR, thisPixel.r), 317 | findColorDifference(amount, sumG, thisPixel.g), 318 | findColorDifference(amount, sumB, thisPixel.b)); 319 | } 320 | } 321 | 322 | // code to clean the secondary buffer out of the DOM would be good here 323 | 324 | return(pixels); 325 | } 326 | 327 | // ensure that values in a matrix add up to 1 328 | function normalizeMatrix(matrix) { 329 | var j = 0; 330 | for (var i = 0; i < matrix.length; i++) { 331 | j += matrix[i]; 332 | } 333 | for (var i = 0; i < matrix.length; i++) { 334 | matrix[i] /= j; 335 | } 336 | return matrix; 337 | } 338 | 339 | 340 | 341 | // convert x/y coordinates to pixel index reference 342 | function convertCoordinates(x, y, w) { 343 | return x + (y * w); 344 | } 345 | 346 | // calculate random noise. different every time! 347 | function noise(noiseValue) { 348 | return Math.floor((noiseValue >> 1) - (Math.random() * noiseValue)); 349 | } 350 | 351 | // ensure an RGB value isn't negative / over 255 352 | function checkRGBBoundary(val) { 353 | if (val < 0) { 354 | return 0; 355 | } else if (val > 255) { 356 | return 255; 357 | } else { 358 | return val; 359 | } 360 | } 361 | 362 | } 363 | 364 | 365 | 366 | // throw the data-* attributes into a JSON object 367 | function getFilterParameters(ref) { 368 | 369 | // create the params object and set some default parameters up front 370 | var params = { 371 | "blurAmount" : 1, // 0 and higher 372 | "edgesAmount" : 1, // between 0 and 1 373 | "embossAmount" : 0.25, // between 0 and 1 374 | "greyscaleOpacity" : 1, // between 0 and 1 375 | "matrixAmount" : 1, // between 0 and 1 376 | "mosaicOpacity" : 1, // between 0 and 1 377 | "mosaicSize" : 5, // 1 and higher 378 | "noiseAmount" : 30, // 0 and higher 379 | "noiseType" : "mono", // mono or color 380 | "posterizeAmount" : 5, // 0 - 255, though 0 and 1 are relatively useless 381 | "posterizeOpacity" : 1, // between 0 and 1 382 | "sepiaOpacity" : 1, // between 0 and 1 383 | "sharpenAmount" : 0.25, // between 0 and 1 384 | "tintColor" : "#FFF", // any hex color 385 | "tintOpacity" : 0.3 // between 0 and 1 386 | }; 387 | 388 | // check for every attribute, throw it into the params object if it exists. 389 | for (var filterName in params){ 390 | // "tintColor" ==> "data-pb-tint-color" 391 | var hyphenated = filterName.replace(/([A-Z])/g, function(all, letter) { 392 | return '-' + letter.toLowerCase(); 393 | }), 394 | attr = ref.getAttribute("data-pb-" + hyphenated); 395 | if (attr) { 396 | params[filterName] = attr; 397 | } 398 | } 399 | 400 | // O Canada, I got your back. (And UK, AU, NZ, IE, etc.) 401 | params['tintColor'] = ref.getAttribute("data-pb-tint-colour") || params['tintColor']; 402 | 403 | // Posterize requires a couple more generated values, lets keep them out of the loop 404 | params['posterizeAreas'] = 256 / params.posterizeAmount; 405 | params['posterizeValues'] = 255 / (params.posterizeAmount - 1); 406 | 407 | return(params); 408 | } 409 | 410 | 411 | 412 | function initializeBuffer(c, img) { 413 | // clean up the buffer between iterations 414 | c.clearRect(0, 0, c.width, c.height); 415 | // make sure we're drawing something 416 | if (img.width > 0 && img.height > 0) { 417 | 418 | // console.log(img.width, img.height, c.width, c.height); 419 | 420 | try { 421 | // draw the image to buffer and load its pixels into an array 422 | // (remove the last two arguments on this function if you choose not to 423 | // respect width/height attributes and want the original image dimensions instead) 424 | c.drawImage(img, 0, 0, img.width , img.height); 425 | return(c.getImageData(0, 0, c.width, c.height)); 426 | 427 | } catch(err) { 428 | // it's kinda strange, I'm explicitly checking for width/height above, but some attempts 429 | // throw an INDEX_SIZE_ERR as if I'm trying to draw a 0x0 or negative image, as per 430 | // http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#images 431 | // 432 | // AND YET, if I simply catch the exception, the filters render anyway and all is well. 433 | // there must be a reason for this, I just don't know what it is yet. 434 | // 435 | // console.log("exception: " + err); 436 | } 437 | } 438 | 439 | } 440 | 441 | 442 | // parse a shorthand or longhand hex string, with or without the leading '#', into something usable 443 | function createColor(src) { 444 | // strip the leading #, if it exists 445 | src = src.replace(/^#/, ''); 446 | // if it's shorthand, expand the values 447 | if (src.length == 3) { 448 | src = src.replace(/(.)/g, '$1$1'); 449 | } 450 | return(src); 451 | } 452 | 453 | // find a specified distance between two colours 454 | function findColorDifference(dif, dest, src) { 455 | return(dif * dest + (1 - dif) * src); 456 | } 457 | 458 | // throw three new RGB values into the pixels object at a specific spot 459 | function setRGB(data, index, r, g, b) { 460 | data[index] = r; 461 | data[index + 1] = g; 462 | data[index + 2] = b; 463 | return data; 464 | } 465 | 466 | 467 | // sniff whether this is an actual img element, or some other element with a background image 468 | function getReferenceImage(ref) { 469 | if (ref.nodeName == "IMG") { 470 | // create a reference to the image 471 | return ref; 472 | } 473 | 474 | // otherwise check if a background image exists 475 | var bg = window.getComputedStyle(ref, null).backgroundImage; 476 | 477 | // if so, we're going to pull it out and create a new img element in the DOM 478 | if (bg) { 479 | var img = new Image(); 480 | // kill quotes in background image declaration, if they exist 481 | // and return just the URL itself 482 | img.src = bg.replace(/['"]/g,'').slice(4, -1); 483 | return img; 484 | } 485 | return false; 486 | } 487 | 488 | // re-draw manipulated pixels to the reference image, regardless whether it was an img element or some other element with a background image 489 | function placeReferenceImage(ref, result, img) { 490 | // dump the buffer as a DataURL 491 | if (ref.nodeName == "IMG") { 492 | img.src = result; 493 | } else { 494 | ref.style.backgroundImage = "url(" + result + ")"; 495 | } 496 | } 497 | 498 | // add specified attribute name with specified value to passed object 499 | function addAttribute(obj, name, value) { 500 | var newAttr = document.createAttribute(name); 501 | newAttr.nodeValue = value; 502 | return obj.setAttributeNode(newAttr); 503 | } 504 | 505 | 506 | // clear reference object's data-pb-* attributes 507 | function flushDataAttributes(img) { 508 | for (var i = 0; i < img.attributes.length; i++) { 509 | var thisAttr = img.attributes[i].name; 510 | if (thisAttr.substr(0, 8) == "data-pb-") { 511 | img.removeAttribute(thisAttr); 512 | } 513 | } 514 | } 515 | 516 | // remove any Paintbrush classes from the reference image 517 | function removeClasses(obj) { 518 | // get classes of the reference image 519 | var classList = (obj.className.toLowerCase()).split(' '); 520 | for (var i = 0; i < classList.length; i++) { 521 | 522 | // clean up any existing filter-* classes 523 | if (classList[i].substr(0, 7) == "filter-") { 524 | removeClass(obj, classList[i]); 525 | } 526 | } 527 | } 528 | 529 | 530 | // clean up stashed original copies and reference classes 531 | function destroyStash(img, preserve) { 532 | 533 | var classList = (img.className.toLowerCase()).split(' '); 534 | for (var i = 0; i < classList.length; i++) { 535 | 536 | // quick reference 537 | var currentClass = classList[i]; 538 | 539 | // have we found an original class? 540 | if (currentClass.substr(0, 7) == "pb-ref-") { 541 | 542 | // get the original object too 543 | var original = document.getElementById("pb-original-" + currentClass.substr(7, currentClass.length - 7)); 544 | 545 | // replace current with original if the preserve flag is set 546 | if (preserve) { 547 | img.src = original.src; 548 | } 549 | 550 | // kill them, kill them all 551 | removeClass(img, currentClass); 552 | 553 | d = document.body; 554 | throwaway = d.removeChild(original); 555 | 556 | } 557 | } 558 | 559 | } 560 | 561 | function stashOriginal(img, originalSuffix, ref, buffer) { 562 | 563 | // store the original image in the DOM 564 | var stashed = stashInDom(img, originalSuffix); 565 | 566 | // then replace the original image data with the buffer 567 | placeReferenceImage(ref, buffer.toDataURL("image/png"), img); 568 | 569 | // and finally, add a class that references the stashed original image for later use 570 | // (but only if we actually stashed one above) 571 | if (stashed) { 572 | ref.className += " pb-ref-" + originalSuffix; 573 | } 574 | } 575 | 576 | // stash a copy of the original image in the DOM for later use 577 | function stashInDom(img, originalSuffix) { 578 | 579 | var orig = "pb-original-" + originalSuffix; 580 | 581 | // make sure we're not re-adding on repeat calls 582 | if (!document.getElementById(orig)) { 583 | 584 | // create the stashed img element 585 | var original = document.createElement("img"); 586 | 587 | // set the attributes 588 | original.src = img.src; 589 | original.id = orig; 590 | original.style.display = "none"; 591 | document.body.appendChild(original); 592 | 593 | return true; 594 | } else { 595 | return false; 596 | } 597 | } 598 | -------------------------------------------------------------------------------- /S3/Stuff/Content/html/js/pregame.js: -------------------------------------------------------------------------------- 1 | var pollingSpeed = 1000;//in ms 2 | var fadeSpeed = 3500; // in ms 3 | var fadeAnimationSpeed = 500; 4 | var informationBarSpeed = 6000; 5 | var enterAnimationDuration = 1000; 6 | var player1HasSponsor = false; 7 | var player2HasSponsor = false; 8 | function updateInformation() 9 | { 10 | $.get('http://127.0.0.1:8081/getCurrentValues', function (json) { 11 | //player names 12 | $('#player1Text').text(json.Player1.name); 13 | $('#player2Text').text(json.Player2.name); 14 | //scores 15 | $('#player1Score').text(json.Player1.score.toString()); 16 | $('#player2Score').text(json.Player2.score.toString()); 17 | //sponsors 18 | $("#sponsorImgP1").attr('src', json.Player1.SponsorIcon); 19 | $("#sponsorImgP2").attr('src', json.Player2.SponsorIcon); 20 | //topbar 21 | $("#round").text(json.round); 22 | $("#tournamentName").text(json.tournamentName); 23 | //information bar 24 | $("#casterText").text(json.caster); 25 | $("#streamerText").text(json.streamer); 26 | 27 | //playercamtext 28 | $('#player1streamname').text(json.Player1.name); 29 | $('#player2streamname').text(json.Player2.name); 30 | //character images 31 | $('#imgLeft').attr('src', "img/pregame/characters/" + json.Player1.character.icon); 32 | $('#imgRight').attr('src', "img/pregame/characters/" + json.Player2.character.icon); 33 | //flags 34 | $('#flagIMGP1').attr('src', "img/flags/" + json.Player1.flag.icon); 35 | $('#flagIMGP2').attr('src', "img/flags/" + json.Player2.flag.icon); 36 | //hide unnecesary stuff 37 | if(json.Player1.sponsor.name == 'None') 38 | { 39 | player1HasSponsor = false; 40 | } 41 | else 42 | { 43 | player1HasSponsor = true; 44 | $("#sponsorImgP1").attr('src', 'img/sponsors/' + json.Player1.sponsor.icon); 45 | } 46 | if(json.Player2.sponsor.name == 'None') 47 | { 48 | player2HasSponsor = false; 49 | } 50 | else 51 | { 52 | player2HasSponsor = true; 53 | $("#sponsorImgP2").attr('src', 'img/sponsors/' + json.Player2.sponsor.icon); 54 | } 55 | }, 'json'); 56 | //poll stuff periodically 57 | setTimeout("updateInformation()", pollingSpeed); 58 | } 59 | var nextFade = "caster"; 60 | var nextFlagFade = "country"; 61 | function fades() 62 | { 63 | if(nextFade == "caster") 64 | { 65 | nextFade = "streamer" 66 | $('#microphone').fadeOut(fadeAnimationSpeed, function() { fadeEnd(); /* makes sure one has been faded first */ }); 67 | setTimeout("fades()", informationBarSpeed); 68 | } 69 | else 70 | { 71 | nextFade = "caster" 72 | $('#streamer').fadeOut(fadeAnimationSpeed, function() { fadeEnd(); /* makes sure one has been faded first */ }); 73 | setTimeout("fades()", informationBarSpeed); 74 | } 75 | } 76 | function flagFades() 77 | { 78 | if(nextFlagFade == "country") 79 | { 80 | nextFlagFade = "character" 81 | $('#characterIMGP1').fadeOut(fadeAnimationSpeed); 82 | $('#flagIMGP1').fadeIn(fadeAnimationSpeed); 83 | $('#characterIMGP2').fadeOut(fadeAnimationSpeed); 84 | $('#flagIMGP2').fadeIn(fadeAnimationSpeed); 85 | setTimeout("flagFades()", fadeSpeed); 86 | } 87 | else 88 | { 89 | nextFlagFade = "country" 90 | $('#flagIMGP1').fadeOut(fadeAnimationSpeed); 91 | $('#characterIMGP1').fadeIn(fadeAnimationSpeed); 92 | $('#flagIMGP2').fadeOut(fadeAnimationSpeed); 93 | $('#characterIMGP2').fadeIn(fadeAnimationSpeed); 94 | 95 | setTimeout("flagFades()", fadeSpeed); 96 | } 97 | } 98 | var whiteFadeoutSpeed = 250; 99 | function fadeEnd() 100 | { 101 | if(nextFade == "caster") 102 | { 103 | $('#microphone').fadeIn(fadeAnimationSpeed); 104 | } 105 | else 106 | { 107 | $('#streamer').fadeIn(fadeAnimationSpeed); 108 | } 109 | } 110 | function whiteFadeOut() 111 | { 112 | $("#white").fadeOut(whiteFadeoutSpeed); 113 | } 114 | function enterAnimationEnd() 115 | { 116 | var brightness = "brightness(100%)"; 117 | $("#imgLeft").css("webkitFilter", brightness); 118 | $("#imgRight").css("webkitFilter", brightness); 119 | var fadeInSpeed = 0; 120 | var whiteFadeInSpeed = 0; 121 | $("#uiLeft").fadeIn(fadeInSpeed); 122 | $("#uiRight").fadeIn(fadeInSpeed); 123 | $("#player1Text").fadeIn(fadeInSpeed); 124 | $("#player2Text").fadeIn(fadeInSpeed); 125 | if(player1HasSponsor) 126 | { 127 | $("#sponsorImgP1").show(); 128 | 129 | $("#sponsorImgP1").fadeIn(fadeInSpeed); 130 | } 131 | 132 | if(player2HasSponsor) 133 | { 134 | $("#sponsorImgP2").show(); 135 | $("#sponsorImgP2").fadeIn(fadeInSpeed); 136 | } 137 | $("#white").fadeIn(whiteFadeInSpeed); 138 | $("#tournament").fadeIn(fadeInSpeed); 139 | $("#round").fadeIn(fadeInSpeed); 140 | setTimeout("whiteFadeOut()", whiteFadeInSpeed); 141 | } 142 | $(document).ready(function() { 143 | updateInformation(); 144 | $('#microphone').fadeOut(0); 145 | $('#flagIMGP1').fadeOut(0); 146 | $('#flagIMGP2').fadeOut(0); 147 | $("#sponsorImgP1").hide(); 148 | $("#sponsorImgP2").hide(); 149 | fades(); 150 | setTimeout("flagFades()", fadeSpeed); 151 | setTimeout("enterAnimationEnd()", enterAnimationDuration); 152 | $("#uiLeft").hide(); 153 | $("#uiRight").hide(); 154 | $("#player1Text").hide(); 155 | $("#player2Text").hide(); 156 | $("#white").hide(); 157 | $("#tournament").hide(); 158 | $("#round").hide(); 159 | }); -------------------------------------------------------------------------------- /S3/Stuff/Content/html/js/scoreboard.js: -------------------------------------------------------------------------------- 1 | var pollingSpeed = 1000;//in ms 2 | var fadeSpeed = 3500; // in ms 3 | var fadeAnimationSpeed = 500; 4 | var informationBarSpeed = 6000; 5 | document.documentElement.style.overflow = 'hidden'; // firefox, chrome 6 | 7 | function updateInformation() 8 | { 9 | $.get('http://127.0.0.1:8081/getCurrentValues', function (json) { 10 | //player names 11 | $('#player1Text').text(json.Player1.name); 12 | $('#player2Text').text(json.Player2.name); 13 | //scores 14 | $('#player1Score').text(json.Player1.score.toString()); 15 | $('#player2Score').text(json.Player2.score.toString()); 16 | //sponsors 17 | $("#sponsorImgP1").attr('src', json.Player1.SponsorIcon); 18 | $("#sponsorImgP2").attr('src', json.Player2.SponsorIcon); 19 | //topbar 20 | $("#round").text(json.round); 21 | $("#tournamentName").text(json.tournamentName); 22 | //information bar 23 | $("#casterText").text(json.caster); 24 | $("#streamerText").text(json.streamer); 25 | 26 | //playercamtext 27 | $('#player1streamname').text(json.Player1.name); 28 | $('#player2streamname').text(json.Player2.name); 29 | //character images 30 | $('#characterIMGP1').attr('src', "img/characters/" + json.Player1.character.icon); 31 | $('#characterIMGP2').attr('src', "img/characters/" + json.Player2.character.icon); 32 | //flags 33 | $('#flagIMGP1').attr('src', "img/flags/" + json.Player1.flag.icon); 34 | $('#flagIMGP2').attr('src', "img/flags/" + json.Player2.flag.icon); 35 | //hide unnecesary stuff 36 | if(json.Player1.sponsor.name == 'None') 37 | { 38 | $('#sponsorImgP1').hide(); 39 | } 40 | else 41 | { 42 | $('#sponsorImgP1').show(); 43 | $("#sponsorImgP1").attr('src', 'img/sponsors/' + json.Player1.sponsor.icon); 44 | } 45 | if(json.Player2.sponsor.name == 'None') 46 | { 47 | $('#sponsorImgP2').hide(); 48 | } 49 | else 50 | { 51 | $('#sponsorImgP2').show(); 52 | $("#sponsorImgP2").attr('src', 'img/sponsors/' + json.Player2.sponsor.icon); 53 | } 54 | }, 'json'); 55 | //poll stuff periodically 56 | setTimeout("updateInformation()", pollingSpeed); 57 | } 58 | var nextFade = "caster"; 59 | var nextFlagFade = "country"; 60 | function fades() 61 | { 62 | if(nextFade == "caster") 63 | { 64 | nextFade = "streamer" 65 | $('#microphone').fadeOut(fadeAnimationSpeed, function() { fadeEnd(); /* makes sure one has been faded first */ }); 66 | setTimeout("fades()", informationBarSpeed); 67 | } 68 | else 69 | { 70 | nextFade = "caster" 71 | $('#streamer').fadeOut(fadeAnimationSpeed, function() { fadeEnd(); /* makes sure one has been faded first */ }); 72 | setTimeout("fades()", informationBarSpeed); 73 | } 74 | } 75 | function flagFades() 76 | { 77 | if(nextFlagFade == "country") 78 | { 79 | nextFlagFade = "character" 80 | $('#characterIMGP1').fadeOut(fadeAnimationSpeed); 81 | $('#flagIMGP1').fadeIn(fadeAnimationSpeed); 82 | $('#characterIMGP2').fadeOut(fadeAnimationSpeed); 83 | $('#flagIMGP2').fadeIn(fadeAnimationSpeed); 84 | setTimeout("flagFades()", fadeSpeed); 85 | } 86 | else 87 | { 88 | nextFlagFade = "country" 89 | $('#flagIMGP1').fadeOut(fadeAnimationSpeed); 90 | $('#characterIMGP1').fadeIn(fadeAnimationSpeed); 91 | $('#flagIMGP2').fadeOut(fadeAnimationSpeed); 92 | $('#characterIMGP2').fadeIn(fadeAnimationSpeed); 93 | 94 | setTimeout("flagFades()", fadeSpeed); 95 | } 96 | } 97 | function fadeEnd() 98 | { 99 | if(nextFade == "caster") 100 | { 101 | $('#microphone').fadeIn(fadeAnimationSpeed); 102 | } 103 | else 104 | { 105 | $('#streamer').fadeIn(fadeAnimationSpeed); 106 | } 107 | } 108 | $(document).ready(function() { 109 | updateInformation(); 110 | $('#microphone').fadeOut(0); 111 | $('#flagIMGP1').fadeOut(0); 112 | $('#flagIMGP2').fadeOut(0); 113 | fades(); 114 | setTimeout("flagFades()", fadeSpeed); 115 | $('#ui').fadeIn(500); 116 | }); -------------------------------------------------------------------------------- /S3/Stuff/Content/html/js/settings.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/S3/Stuff/Content/html/js/settings.js -------------------------------------------------------------------------------- /S3/Stuff/Content/html/scoreboard.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 58 | 59 | -------------------------------------------------------------------------------- /S3/Stuff/Content/html/scoreboard2.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | test 14 | 15 | -------------------------------------------------------------------------------- /S3/Stuff/characters.json: -------------------------------------------------------------------------------- 1 | { 2 | "characters": 3 | [ 4 | {"name": "Fox", "icon":"20xx.png"}, 5 | {"name": "Bowser", "icon":"bowser.png"}, 6 | {"name": "D.K", "icon":"dong.png"}, 7 | {"name": "Dr. Mario", "icon":"dr.png"}, 8 | {"name": "Falco", "icon":"falco.png"}, 9 | {"name": "Falcon", "icon":"falcon.png"}, 10 | {"name": "Mr. Game & Watch", "icon":"gandw.png"}, 11 | {"name": "Ganondorf", "icon":"ganondorf.png"}, 12 | {"name": "Ice Climbers", "icon":"icies.png"}, 13 | {"name": "Jigglypuff", "icon":"jiggs.png"}, 14 | {"name": "Mewtwo", "icon":"king.png"}, 15 | {"name": "Kirby", "icon":"kirby.png"}, 16 | {"name": "Link", "icon":"link.png"}, 17 | {"name": "Luigi", "icon":"luigi.png"}, 18 | {"name": "Mario", "icon":"mario.png"}, 19 | {"name": "Marth", "icon":"marth.png"}, 20 | {"name": "Ness", "icon":"ness.png"}, 21 | {"name": "Peach", "icon":"peach.png"}, 22 | {"name": "Pichu", "icon":"pichu.png"}, 23 | {"name": "Pikachu", "icon":"pikachu.png"}, 24 | {"name": "Roy", "icon":"roy.png"}, 25 | {"name": "Samus", "icon":"samus.png"}, 26 | {"name": "Sheik", "icon":"sheik.png"}, 27 | {"name": "Yoshi", "icon":"yoshi.png"}, 28 | {"name": "Young Link", "icon":"younglink.png"}, 29 | {"name": "Zelda", "icon":"zelda.png"}, 30 | ] 31 | } -------------------------------------------------------------------------------- /S3/Stuff/flags.json: -------------------------------------------------------------------------------- 1 | { 2 | "Flags": 3 | [ 4 | {"name": "Spain", "icon":"spain.png"}, 5 | {"name": "USA", "icon":"usa.png"}, 6 | {"name": "UK", "icon":"uk.png"}, 7 | {"name": "Spain (Republican)", "icon":"spainrep.png"} 8 | ] 9 | } -------------------------------------------------------------------------------- /S3/Stuff/sponsors.json: -------------------------------------------------------------------------------- 1 | { 2 | "sponsors": 3 | [ 4 | {"name": "None", "icon":"none"}, 5 | {"name": "ShrekBoards", "icon":"shrekboards.png"}, 6 | {"name": "Modulous", "icon":"modulous.png"}, 7 | {"name": "MVG", "icon":"mvg.png"} 8 | ] 9 | } -------------------------------------------------------------------------------- /S3/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /pregame.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/pregame.psd -------------------------------------------------------------------------------- /scoreboard.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/scoreboard.psd -------------------------------------------------------------------------------- /scoreboard_dualcam.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ModulousSmash/AuroraBoard/4a5ef6e655db1699ab6dfa25f807b3d5046cecc2/scoreboard_dualcam.psd --------------------------------------------------------------------------------