Skip to content
This repository has been archived by the owner on May 10, 2021. It is now read-only.

港澳IP不能用 #65

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 6 additions & 46 deletions Changes.txt
Original file line number Diff line number Diff line change
@@ -1,51 +1,11 @@
{
"1.1c":
"1.1p-TW":
[
"Removed LoLLoader. Now uses process injection.",
"Fixed resizing",
"Fixed exceptions in the main thread not being logged",
"Fixed rare null reference when retreiving player stats."
"更新更新鏈接"
],
"1.1b":
"1.1o-TW":
[
"Note color now properly refreshes if there is no note.",
"When lolnotes is made smaller vertically there will be a scrollbar.",
"Fixed null reference in OnAccept."
],
"1.1a":
[
"Added database import/export",
"Added player stats lookup (Includes recent matches, rankings, top champions)",
"Made UI bigger to allow for more information. Can be made a bitsmaller horizontally.",
"Install/Uninstall now takes care of the certificates for you",
"Added Dev tab which logs packets for developers.",
"Disabled lobby logging and player stats logging. Became obsolete with the stats lookup. Improved performance removing them.",
"Added dropdown for quickly changing all tabs to the selected."
],
"1.1":
[
"Now works after log files were broken.",
],
"1.0f":
[
"Fixed LoLLoader depending on msvcrt (crashing origin)",
"Fixed crashing when editing a player twice in a row",
],
"1.0e":
[
"Added displaying end of game stats",
"Fixed not updating stale stats when in a lobby that is newer than the stats",
"Fixed player control flickering when rotating stats",
"Fixed crashing when lacking permissions to read appinit key",
"Fixed null reference in SetStats",
],
"1.0d":
[
"Fixed crashing if the AppInit key does not exist",
"Added Changes tab which displays the changes",
],
"1.0c":
[
"Fixed LoLNotes eating up cpu when idling",
"介面繁化",
"按召喚師名稱將會開啟戰績網頁面"
]
}
}
Binary file added Dependencies/FluorineFx.dll
Binary file not shown.
29 changes: 1 addition & 28 deletions LoLNotes.sln
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
# SharpDevelop 4.4
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LoLNotes", "LoLNotes\LoLNotes.csproj", "{E5AB8F67-7BBC-48DF-9A1D-8D0D3DE685DD}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FluorineFx-3.5", "FluorineFx\FluorineFx-3.5.csproj", "{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NotMissing", "NotMissing\NotMissing\NotMissing.csproj", "{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -31,30 +28,6 @@ Global
{E5AB8F67-7BBC-48DF-9A1D-8D0D3DE685DD}.Release|Win32.ActiveCfg = Release|x86
{E5AB8F67-7BBC-48DF-9A1D-8D0D3DE685DD}.Release|x86.ActiveCfg = Release|x86
{E5AB8F67-7BBC-48DF-9A1D-8D0D3DE685DD}.Release|x86.Build.0 = Release|x86
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Debug|Win32.ActiveCfg = Debug|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Debug|x86.ActiveCfg = Debug|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Release|Any CPU.Build.0 = Release|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Release|Win32.ActiveCfg = Release|Any CPU
{A9B8375B-579D-4F8A-B00C-F2828DB58F3A}.Release|x86.ActiveCfg = Release|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Debug|Win32.ActiveCfg = Debug|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Debug|x86.ActiveCfg = Debug|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Release|Any CPU.Build.0 = Release|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Release|Win32.ActiveCfg = Release|Any CPU
{85D59D64-9158-42F7-BBBA-23F14E9F3E2A}.Release|x86.ActiveCfg = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
204 changes: 102 additions & 102 deletions LoLNotes/Assets/ChampIcons.cs
Original file line number Diff line number Diff line change
@@ -1,102 +1,102 @@
/*
copyright (C) 2011-2012 by [email protected]
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
using System;
using System.Collections.Generic;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using NotMissing.Logging;
namespace LoLNotes.Assets
{
public class ChampIcons
{
const string ImagePath = "Content\\Images\\";
const string ChampPath = ImagePath + "ChampIcons\\";
static readonly object _sync;
static readonly Dictionary<int, Bitmap> _cache;
static Bitmap _unknown;
static ChampIcons()
{
_sync = new object();
_cache = new Dictionary<int, Bitmap>();
_unknown = SafeBitmap(ImagePath + "unknown.png");
}
static void AddCached(int key, Bitmap bmp)
{
lock (_sync)
{
_cache[key] = bmp;
}
}
static Bitmap FindCached(int key)
{
lock (_sync)
{
Bitmap ret;
return _cache.TryGetValue(key, out ret) ? ret : null;
}
}
static Bitmap SafeBitmap(string file)
{
try
{
return File.Exists(file) ? new Bitmap(file) : null;
}
catch (Exception e)
{
StaticLogger.Debug(e);
return null;
}
}
public static Bitmap Get(int key)
{
var name = ChampNames.GetOrDefault(key);
if (name == null)
{
StaticLogger.Debug("Unknown champid " + key);
return _unknown;
}
var bmp = FindCached(key);
if (bmp != null)
return bmp;
bmp = SafeBitmap(string.Format("{0}{1}_Square_0.png", ChampPath, name));
if (bmp == null)
{
StaticLogger.Debug("Unknown champ icon " + name);
return _unknown;
}
AddCached(key, bmp);
return bmp;
}
}
}
/*
copyright (C) 2011-2012 by [email protected]

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
using System;
using System.Collections.Generic;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using NotMissing.Logging;

namespace LoLNotes.Assets
{
public class ChampIcons
{
const string ImagePath = "Content\\Images\\";
const string ChampPath = ImagePath + "ChampIcons\\";
static readonly object _sync;
static readonly Dictionary<int, Bitmap> _cache;
static Bitmap _unknown;


static ChampIcons()
{
_sync = new object();
_cache = new Dictionary<int, Bitmap>();
_unknown = SafeBitmap(ImagePath + "unknown.png");
}


static void AddCached(int key, Bitmap bmp)
{
lock (_sync)
{
_cache[key] = bmp;
}
}
static Bitmap FindCached(int key)
{
lock (_sync)
{
Bitmap ret;
return _cache.TryGetValue(key, out ret) ? ret : null;
}
}

static Bitmap SafeBitmap(string file)
{
try
{
return File.Exists(file) ? new Bitmap(file) : null;
}
catch (Exception e)
{
StaticLogger.Debug(e);
return null;
}
}

public static Bitmap Get(int key)
{
var name = ChampNames.GetOrDefault(key);
if (name == null)
{
StaticLogger.Debug("Unknown champid " + key);
return _unknown;
}

var bmp = FindCached(key);
if (bmp != null)
return bmp;

bmp = SafeBitmap(string.Format("{0}{1}_Square_0.png", ChampPath, name));
if (bmp == null)
{
StaticLogger.Debug("Unknown champ icon " + name);
return _unknown;
}

AddCached(key, bmp);
return bmp;
}
}
}
Loading