diff --git a/CMakeLists.txt b/CMakeLists.txt index 66281fe0c..d4e9d41e8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,6 +37,21 @@ if(DEFINED ENV{MCSERVER_BUILD_ID}) endif() endif() +# We need C++11 features, Visual Studio has those from VS2012, but it needs a new platform toolset for those; VS2013 supports them natively: +# Adapted from http://binglongx.wordpress.com/2013/06/28/set-non-default-platform-toolset-in-cmake/ +if(MSVC OR MSVC_IDE) + if( MSVC_VERSION LESS 1700 ) # VC10- / VS2010- + message(FATAL_ERROR "The project requires C++11 features. " + "You need at least Visual Studio 11 (Microsoft Visual Studio 2012), " + "with Microsoft Visual C++ Compiler Nov 2012 CTP (v120_CTP_Nov2012).") + elseif( MSVC_VERSION EQUAL 1700 ) # VC11 / VS2012 + message( "VC11: using Microsoft Visual Studio 2012 " + "with Microsoft Visual C++ Compiler Nov 2012 CTP (v120_CTP_Nov2012)" ) + set(CMAKE_GENERATOR_TOOLSET "v120_CTP_Nov2012" CACHE STRING "Platform Toolset" FORCE) + else() # VC12+, assuming C++11 supported. + endif() +endif() + # This has to be done before any flags have been set up. if(${BUILD_TOOLS}) add_subdirectory(Tools/MCADefrag/) diff --git a/MCServer/Plugins/APIDump/APIDesc.lua b/MCServer/Plugins/APIDump/APIDesc.lua index 6a151b5ef..9b87781a6 100644 --- a/MCServer/Plugins/APIDump/APIDesc.lua +++ b/MCServer/Plugins/APIDump/APIDesc.lua @@ -534,6 +534,7 @@ end GetUUID = { Params = "", Return = "string", Notes = "Returns the authentication-based UUID of the client. This UUID should be used to identify the player when persisting any player-related data. Returns a 32-char UUID (no dashes)" }, GetUsername = { Params = "", Return = "string", Notes = "Returns the username that the client has provided" }, GetViewDistance = { Params = "", Return = "number", Notes = "Returns the viewdistance (number of chunks loaded for the player in each direction)" }, + GetRequestedViewDistance = { Params = "", Return = "number", Notes = "Returns the view distance that the player request, not the used view distance." }, HasPluginChannel = { Params = "ChannelName", Return = "bool", Notes = "Returns true if the client has registered to receive messages on the specified plugin channel." }, IsUUIDOnline = { Params = "UUID", Return = "bool", Notes = "(STATIC) Returns true if the UUID is generated by online auth, false if it is an offline-generated UUID. We use Version-3 UUIDs for offline UUIDs, online UUIDs are Version-4, thus we can tell them apart. Accepts both 32-char and 36-char UUIDs (with and without dashes). If the string given is not a valid UUID, returns false."}, Kick = { Params = "Reason", Return = "", Notes = "Kicks the user with the specified reason" }, @@ -614,7 +615,7 @@ function OnPlayerJoined(a_Player) -- Send an example composite chat message to the player: a_Player:SendMessage(cCompositeChat() :AddTextPart("Hello, ") - :AddUrlPart(a_Player:GetName(), "www.mc-server.org", "u@2") -- Colored underlined link + :AddUrlPart(a_Player:GetName(), "http://www.mc-server.org", "u@2") -- Colored underlined link :AddSuggestCommandPart(", and welcome.", "/help", "u") -- Underlined suggest-command :AddRunCommandPart(" SetDay", "/time set 0") -- Regular text that will execute command when clicked :SetMessageType(mtJoin) -- It is a join-message @@ -2137,6 +2138,7 @@ cPluginManager.AddHook(cPluginManager.HOOK_CHAT, OnChatMessage); BroadcastChatWarning = { Params = "MessageText", Return = "", Notes = "Broadcasts the specified message to all players, with its message type set to mtWarning. Use for concerning events, such as plugin reload etc." }, CreateAndInitializeWorld = { Params = "WorldName", Return = "{{cWorld|cWorld}}", Notes = "Creates a new world and initializes it. If there is a world whith the same name it returns nil.

NOTEThis function is currently unsafe, do not use!" }, FindAndDoWithPlayer = { Params = "PlayerName, CallbackFunction", Return = "", Notes = "Calls the given callback function for all players with names partially (or fully) matching the name string provided." }, + DoWithPlayerByUUID = { Params = "PlayerUUID, CallbackFunction, [CallbackData]", Return = "bool", Notes = "If there is the player with the uuid, calls the CallbackFunction with the {{cPlayer}} parameter representing the player. The CallbackFunction has the following signature:
function Callback({{cPlayer|Player}}, [CallbackData])
The function returns false if the player was not found, or whatever bool value the callback returned if the player was found." }, ForEachPlayer = { Params = "CallbackFunction", Return = "", Notes = "Calls the given callback function for each player. The callback function has the following signature:
function Callback({{cPlayer|cPlayer}})
" }, ForEachWorld = { Params = "CallbackFunction", Return = "", Notes = "Calls the given callback function for each world. The callback function has the following signature:
function Callback({{cWorld|cWorld}})
" }, Get = { Params = "", Return = "Root object", Notes = "(STATIC)This function returns the cRoot object." }, @@ -2406,6 +2408,7 @@ end { Params = "{{Vector3i|BlockCoords}}, BlockType, BlockMeta", Return = "", Notes = "Sets the block at the specified coords, without waking up the simulators or replacing the block entities for the previous block type. Do not use if the block being replaced has a block entity tied to it!" }, }, FindAndDoWithPlayer = { Params = "PlayerNameHint, CallbackFunction, [CallbackData]", Return = "bool", Notes = "If there is a player of a name similar to the specified name (weighted-match), calls the CallbackFunction with the {{cPlayer}} parameter representing the player. The CallbackFunction has the following signature:
function Callback({{cPlayer|Player}}, [CallbackData])
The function returns false if the player was not found, or whatever bool value the callback returned if the player was found. Note that the name matching is very loose, so it is a good idea to check the player name in the callback function." }, + DoWithPlayerByUUID = { Params = "PlayerUUID, CallbackFunction, [CallbackData]", Return = "bool", Notes = "If there is the player with the uuid, calls the CallbackFunction with the {{cPlayer}} parameter representing the player. The CallbackFunction has the following signature:
function Callback({{cPlayer|Player}}, [CallbackData])
The function returns false if the player was not found, or whatever bool value the callback returned if the player was found." }, ForEachBlockEntityInChunk = { Params = "ChunkX, ChunkZ, CallbackFunction, [CallbackData]", Return = "bool", Notes = "Calls the specified callback for each block entity in the chunk. Returns true if all block entities in the chunk have been processed (including when there are zero block entities), or false if the callback has aborted the enumeration by returning true. The CallbackFunction has the following signature:
function Callback({{cBlockEntity|BlockEntity}}, [CallbackData])
The callback should return false or no value to continue with the next block entity, or true to abort the enumeration. Use {{tolua}}.cast() to cast the Callback's BlockEntity parameter to the correct {{cBlockEntity}} descendant." }, ForEachChestInChunk = { Params = "ChunkX, ChunkZ, CallbackFunction, [CallbackData]", Return = "bool", Notes = "Calls the specified callback for each chest in the chunk. Returns true if all chests in the chunk have been processed (including when there are zero chests), or false if the callback has aborted the enumeration by returning true. The CallbackFunction has the following signature:
function Callback({{cChestEntity|ChestEntity}}, [CallbackData])
The callback should return false or no value to continue with the next chest, or true to abort the enumeration." }, ForEachEntity = { Params = "CallbackFunction, [CallbackData]", Return = "bool", Notes = "Calls the specified callback for each entity in the loaded world. Returns true if all the entities have been processed (including when there are zero entities), or false if the callback function has aborted the enumeration by returning true. The callback function has the following signature:
function Callback({{cEntity|Entity}}, [CallbackData])
The callback should return false or no value to continue with the next entity, or true to abort the enumeration." }, @@ -2497,7 +2500,7 @@ end SetCommandBlocksEnabled = { Params = "IsEnabled (bool)", Return = "", Notes = "Sets whether command blocks should be enabled on the (entire) server." }, SetShouldUseChatPrefixes = { Params = "", Return = "ShouldUse (bool)", Notes = "Sets whether coloured chat prefixes such as [INFO] is used with the SendMessageXXX() or BroadcastChatXXX(), or simply the entire message is coloured in the respective colour." }, ShouldUseChatPrefixes = { Params = "", Return = "bool", Notes = "Returns whether coloured chat prefixes are prepended to chat messages or the entire message is simply coloured." }, - SetSignLines = { Params = "X, Y, Z, Line1, Line2, Line3, Line4, [{{cPlayer|Player}}]", Return = "", Notes = "Sets the sign text at the specified coords. The sign-updating hooks are called for the change. The Player parameter is used to indicate the player from whom the change has come, it may be nil. Same as UpdateSign()." }, + SetSignLines = { Params = "X, Y, Z, Line1, Line2, Line3, Line4, [{{cPlayer|Player}}]", Return = "", Notes = "Sets the sign text at the specified coords. The sign-updating hooks are called for the change. The Player parameter is used to indicate the player from whom the change has come, it may be nil." }, SetTicksUntilWeatherChange = { Params = "NumTicks", Return = "", Notes = "Sets the number of ticks after which the weather will be changed." }, SetTimeOfDay = { Params = "TimeOfDayTicks", Return = "", Notes = "Sets the time of day, expressed as number of ticks past sunrise, in the range 0 .. 24000." }, SetWeather = { Params = "Weather", Return = "", Notes = "Sets the current weather (wSunny, wRain, wStorm) and resets the TicksUntilWeatherChange to the default value for the new weather. The normal weather-changing hooks are called for the change." }, @@ -2512,7 +2515,7 @@ end SpawnExperienceOrb = { Params = "X, Y, Z, Reward", Return = "EntityID", Notes = "Spawns an {{cExpOrb|experience orb}} at the specified coords, with the given reward" }, SpawnPrimedTNT = { Params = "X, Y, Z, FuseTicks, InitialVelocityCoeff", Return = "", Notes = "Spawns a {{cTNTEntity|primed TNT entity}} at the specified coords, with the given fuse ticks. The entity gets a random speed multiplied by the InitialVelocityCoeff, 1 being the default value." }, TryGetHeight = { Params = "BlockX, BlockZ", Return = "IsValid, Height", Notes = "Returns true and height of the highest non-air block if the chunk is loaded, or false otherwise." }, - UpdateSign = { Params = "X, Y, Z, Line1, Line2, Line3, Line4, [{{cPlayer|Player}}]", Return = "", Notes = "Sets the sign text at the specified coords. The sign-updating hooks are called for the change. The Player parameter is used to indicate the player from whom the change has come, it may be nil. Same as SetSignLiens()" }, + UpdateSign = { Params = "X, Y, Z, Line1, Line2, Line3, Line4, [{{cPlayer|Player}}]", Return = "", Notes = "(DEPRECATED) Please use SetSignLines()." }, UseBlockEntity = { Params = "{{cPlayer|Player}}, BlockX, BlockY, BlockZ", Return = "", Notes = "Makes the specified Player use the block entity at the specified coords (open chest UI, etc.) If the cords are in an unloaded chunk or there's no block entity, ignores the call." }, WakeUpSimulators = { Params = "BlockX, BlockY, BlockZ", Return = "", Notes = "Wakes up the simulators for the specified block." }, WakeUpSimulatorsInArea = { Params = "MinBlockX, MaxBlockX, MinBlockY, MaxBlockY, MinBlockZ, MaxBlockZ", Return = "", Notes = "Wakes up the simulators for all the blocks in the specified area (edges inclusive)." }, diff --git a/MCServer/Plugins/APIDump/Classes/Projectiles.lua b/MCServer/Plugins/APIDump/Classes/Projectiles.lua index aef6a048c..748f58b71 100644 --- a/MCServer/Plugins/APIDump/Classes/Projectiles.lua +++ b/MCServer/Plugins/APIDump/Classes/Projectiles.lua @@ -123,35 +123,47 @@ return cSplashPotionEntity = { - Desc = "", - Functions = {}, + Desc = [[ + Represents a thrown splash potion. + ]], + Functions = + { + GetEntityEffect = { Params = "", Return = "{{cEntityEffect}}", Notes = "Returns the entity effect in this potion" }, + GetEntityEffectType = { Params = "", Return = "{{cEntityEffect|Entity effect type}}", Notes = "Returns the effect type of this potion" }, + GetPotionColor = { Params = "", Return = "number", Notes = "Returns the color index of the particles emitted by this potion" }, + SetEntityEffect = { Params = "{{cEntityEffect}}", Return = "", Notes = "Sets the entity effect for this potion" }, + SetEntityEffectType = { Params = "{{cEntityEffect|Entity effect type}}", Return = "", Notes = "Sets the effect type of this potion" }, + SetPotionColor = { Params = "number", Return = "", Notes = "Sets the color index of the particles for this potion" }, + }, Inherits = "cProjectileEntity", }, -- cSplashPotionEntity cThrownEggEntity = { - Desc = "", + Desc = [[ + Represents a thrown egg. + ]], Functions = {}, Inherits = "cProjectileEntity", }, -- cThrownEggEntity cThrownEnderPearlEntity = { - Desc = "", + Desc = "Represents a thrown ender pearl.", Functions = {}, Inherits = "cProjectileEntity", }, -- cThrownEnderPearlEntity cThrownSnowballEntity = { - Desc = "", + Desc = "Represents a thrown snowball.", Functions = {}, Inherits = "cProjectileEntity", }, -- cThrownSnowballEntity cWitherSkullEntity = { - Desc = "", + Desc = "Represents a wither skull being shot.", Functions = {}, Inherits = "cProjectileEntity", }, -- cWitherSkullEntity diff --git a/MCServer/Plugins/InfoReg.lua b/MCServer/Plugins/InfoReg.lua index da5a9972c..92c4a2e59 100644 --- a/MCServer/Plugins/InfoReg.lua +++ b/MCServer/Plugins/InfoReg.lua @@ -51,6 +51,7 @@ local function MultiCommandHandler(a_Split, a_Player, a_CmdString, a_CmdInfo, a_ return a_CmdInfo.Handler(a_Split, a_Player); end -- Let the player know they need to give a subcommand: + assert(type(a_CmdInfo.Subcommands) == "table", "Info.lua error: There is no handler for command \"" .. a_CmdString .. "\" and there are no subcommands defined at level " .. a_Level) ListSubcommands(a_Player, a_CmdInfo.Subcommands, a_CmdString); return true; end diff --git a/MCServer/webadmin/files/guest.html b/MCServer/webadmin/files/guest.html new file mode 100644 index 000000000..7ae78a3f0 --- /dev/null +++ b/MCServer/webadmin/files/guest.html @@ -0,0 +1,2 @@ +Hello! Welcome to the MCServer WebAdmin.
+This is a default message, edit files/guest.html to add your own custom message. diff --git a/MCServer/webadmin/files/header.png b/MCServer/webadmin/files/header.png new file mode 100644 index 000000000..97b067715 Binary files /dev/null and b/MCServer/webadmin/files/header.png differ diff --git a/MCServer/webadmin/files/home.gif b/MCServer/webadmin/files/home.gif new file mode 100644 index 000000000..b10e0bed7 Binary files /dev/null and b/MCServer/webadmin/files/home.gif differ diff --git a/MCServer/webadmin/files/loading.gif b/MCServer/webadmin/files/loading.gif new file mode 100644 index 000000000..b8d06f669 Binary files /dev/null and b/MCServer/webadmin/files/loading.gif differ diff --git a/MCServer/webadmin/files/log_out.png b/MCServer/webadmin/files/log_out.png new file mode 100644 index 000000000..63232417a Binary files /dev/null and b/MCServer/webadmin/files/log_out.png differ diff --git a/MCServer/webadmin/files/login.css b/MCServer/webadmin/files/login.css new file mode 100644 index 000000000..5d87da4c5 --- /dev/null +++ b/MCServer/webadmin/files/login.css @@ -0,0 +1,219 @@ +/* Copyright Justin S and MCServer Team, licensed under CC-BY-SA 3.0 */ +* { + margin: 0; +} + +body { + font-family: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif; + -webkit-font-smoothing: antialiased; + background: #fff url(header.png) repeat-x top left; + width: 100%; + min-width: 100%; + overflow: hidden; +} + +a:link { + color: #555; + text-decoration: none; +} + +a:visited { + color: #444; + text-decoration: none; +} + +a:hover, a:active { + color: #000; + text-decoration: underline; +} + +img { + border: none; +} + +h1 { + color: #069; +} + +.row1 { + border-bottom: 1px solid #000; + height: 100px; + max-height: 100px; +} + +.row2 { + margin: 0 auto; + text-align: center; + vertical-align: middle; +} + +.contention { + color: #000; + text-align: left; + line-height: 1.4; + margin: 0; + font-family: Tahoma,Verdana,Arial,Sans-Serif; + font-size: 13px; +} + +button { + background: #fff; + color: #000; + border: 1px solid #ccc; + padding: 3px; + font-family: Tahoma,Verdana,Arial,Sans-Serif; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + border-radius: 5px; + margin: -3px 0; +} + +button:hover { + border-top-color: #28597a; + background: #28597a; + color: #ccc; +} + +button:active { + border-top-color: #1b435e; + background: #1b435e; +} + +.push10 { + padding-bottom: 75px; +} + +#panel .upper { + background: #dcdbdc url(tcat.png) repeat-x; + border-top: 1px solid #fff; + border-bottom: 1px solid #bbb; + padding: 7px; +} + +#footer { + z-index: 99999; +} + +#footer ul.menu { + margin: 0; + padding: 0; + list-style: none; +} + +#footer ul.menu li { + margin: 0 5px; + display: inline; +} + +#footer .upper { + background: #dcdbdc url(tcat.png) repeat-x; + border-top: 1px solid #bbb; + padding: 6px; + overflow: hidden; + font-size: 12px; +} + +#footer .upper ul.bottom_links { + float: left; + margin: 3px 0 0 -5px; +} + +#footer .lower { + background: #a1a2a2 url(thead.png) top left repeat-x; + color: #fff; + border-top: 1px solid #ccc; + border-bottom: 1px solid #ddd; + overflow: hidden; + padding: 8px; + font-size: 11px; +} + +#footer .lower a:link, #footer .lower a:visited { + color: #fff; + font-weight: 700; +} + +#footer .lower a:hover, #footer .lower a:active { + color: #fff; + font-weight: 700; +} + +#footer .lower #current_time { + float: right; + padding-right: 6px; +} + +.wrapper { + width: 85%; + min-width: 970px; + max-width: 1500px; + margin: auto; +} + +#footer { + position: fixed; + left: 0; + bottom: 0; + height: 60px; + width: 100%; + background: #999; + border-top: 1px #000 solid; +} + +* html #footer { + position: absolute; + top: expression((0-(footer.offsetHeight)+(document.documentElement.clientHeight ? document.documentElement.clientHeight : document.body.clientHeight)+(ignoreMe = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop))+'px'); +} + +tr td.trow2:first-child { + border-left: 0; +} + +tr td.trow2:last-child { + border-right: 0; +} + +.tborder { + -moz-border-radius: 7px; + -webkit-border-radius: 7px; + border-radius: 7px; +} + +.thead, .rounded_top { + -moz-border-radius-topleft: 6px; + -moz-border-radius-topright: 6px; + -webkit-border-top-left-radius: 6px; + -webkit-border-top-right-radius: 6px; + border-top-left-radius: 6px; + border-top-right-radius: 6px; +} + +table { + color: #000; + font-size: 13px; +} + +.tborder { + background: #fff; + width: 100%; + margin: auto; + border: 1px solid #ccc; + padding: 1px; +} + +.thead { + background: #a1a2a2 url(thead.png) top left repeat-x; + color: #fff; + border-bottom: 1px solid #8e8f8f; + padding: 8px; +} + +.trow2 { + background: #efefef; + border: 1px solid; + border-color: #fff #ddd #ddd #fff; +} + +.padtopp { + padding-top: 25px; +} diff --git a/MCServer/webadmin/files/login.gif b/MCServer/webadmin/files/login.gif new file mode 100644 index 000000000..ce2cb6fc0 Binary files /dev/null and b/MCServer/webadmin/files/login.gif differ diff --git a/MCServer/webadmin/files/logo_login.png b/MCServer/webadmin/files/logo_login.png new file mode 100644 index 000000000..d2155f928 Binary files /dev/null and b/MCServer/webadmin/files/logo_login.png differ diff --git a/MCServer/webadmin/files/pmfolder.gif b/MCServer/webadmin/files/pmfolder.gif new file mode 100644 index 000000000..3fc68fdcb Binary files /dev/null and b/MCServer/webadmin/files/pmfolder.gif differ diff --git a/MCServer/webadmin/files/style.css b/MCServer/webadmin/files/style.css index 7f01b34b2..7c0671970 100644 --- a/MCServer/webadmin/files/style.css +++ b/MCServer/webadmin/files/style.css @@ -1,353 +1,427 @@ -body, html -{ - font-family: "Open Sans", Tahoma, sans-serif; - padding: 0; - margin: 0; - font-weight: 400; - background-color: #fbe9e7; - color: rgba(0, 0, 0, 0.87); +/* Copyright Justin S and MCServer Team, licensed under CC-BY-SA 3.0 */ +* { + margin: 0; } -.light { font-weight: 300; } -.bold { font-weight: 600; } - -#wrapper -{ - background-color: #ff5722; - margin: 40px auto; - width: 99%; - max-width: 1200px; - box-sizing: border-box; - -moz-box-sizing: border-box; - box-shadow: 0px 4px 5px rgba(0, 0, 0, 0.15); - color: rgba(0, 0, 0, 0.87); +body { + font-family: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif; + -webkit-font-smoothing: antialiased; + background: #fff; + width: 100%; + min-width: 100%; + height:100%; + min-height:100%; + overflow-y: scroll; + overflow-x: hidden; } -.title -{ - font-size: 30pt; - padding: 10px 40px; - text-decoration: none; - color: white; - text-shadow: 0px 1px 2px rgba(0, 0, 0, 0.3); - display: block; +a:link { + color: #555; + text-decoration: none; } -#sidebar -{ - float: left; - width: 20%; +a:visited { + color: #444; + text-decoration: none; } -.sideNav -{ - list-style: none; - background-color: #fafafa; - margin: 20px 0; - padding: 5px 0; - width: 100%; - box-shadow: 1px 0px 10px rgba(0, 0, 0, 0.2); +a:hover, a:active { + color: #000; + text-decoration: underline; } -.sideNav li -{ - padding: 10px; - color: rgba(0, 0, 0, 0.54); +img { + border: none; } -.sideNav li.link -{ - padding-left: 30px; +h1 { + color: #069; + text-shadow: 2px 2px #000; } -.sideNav li.link a -{ - text-decoration: none; - color: rgba(0, 0, 0, 0.87); +.row1 { + border-bottom: 1px #000 solid; + height: 100px; + max-height: 100px; + background: #fff url(header.png) repeat-x top left; } -#container -{ - margin: 0; - padding: 0; - overflow: hidden; - background-color: #f5f5f5; +.row2 { + margin: 0 auto; + text-align: center; + vertical-align: middle; + margin-top: 25px; + margin-bottom: 25px; } -#main -{ - float: right; - width: 80%; - padding: 0 15px 20px 15px; - box-sizing: border-box; - -moz-box-sizing: border-box; +.contention { + color: #000; + text-align: left; + line-height: 1.4; + margin: 0; + font-family: Tahoma,Verdana,Arial,Sans-Serif; + font-size: 13px; + margin-bottom:75px; } -.clear -{ - clear: both; +.push25 { } -table -{ - width: 100%; - border-collapse: collapse; +#panel ul.menu { + margin: 0; + padding: 0; + list-style: none; } -table td -{ - padding: 5px; +#panel ul.menu li { + margin: 0 5px; + display: inline; } -table th -{ - border-bottom: 1px solid rgba(0, 0, 0, 0.12); - padding: 5px; - text-align: center; +#panel ul.menu li a { + padding-left: 20px; + background-repeat: no-repeat; + background-position: left center; } -table tr:nth-child(odd) -{ - background-color: rgba(0, 0, 0, 0.015); +#panel .upper ul.top_links { + float: right; + font-weight: 700; } -p -{ - margin: 8px 0; - padding: 8px 3px; +#panel .upper { + background: #dcdbdc url(tcat.png) repeat-x; + border-top: 1px solid #fff; + border-bottom: 1px solid #bbb; + padding: 7px; } -a -{ - text-decoration: none; - color: #0277bd; - -webkit-transition: color 0.1s linear; - -moz-transition: color 0.1s linear; - transition: color 0.1s linear; +#footer ul.menu { + margin: 0; + padding: 0; + list-style: none; } -a:hover -{ - color: #01579b; +#footer ul.menu li { + margin: 0 5px; + display: inline; } -.welcome-msg -{ - color: rgba(0, 0, 0, 0.54); +#footer .upper { + background: #dcdbdc url(tcat.png) repeat-x; + border-top: 1px solid #bbb; + padding: 6px; + overflow: hidden; + font-size: 12px; } -.username -{ - text-transform: capitalize; - color: rgba(0, 0, 0, 0.87); +#footer .upper ul.bottom_links { + float: left; + margin: 3px 0 0 -5px; } -a:hover -{ - color: black; +#footer .lower { + background: #a1a2a2 url(thead.png) top left repeat-x; + color: #fff; + border-top: 1px solid #ccc; + border-bottom: 1px solid #ddd; + overflow: hidden; + padding: 8px; + font-size: 11px; } -input, select -{ - padding: 8px; +#footer .lower a:link,#footer .lower a:visited { + color: #fff; + font-weight: 700; } -form -{ - padding: 4px; +#footer .lower a:hover,#footer .lower a:active { + color: #fff; + font-weight: 700; } -.info input[type="submit"], .info button, .info input[type="button"], -.warn input[type="submit"], .warn button, .warn input[type="button"], -.err input[type="submit"], .err button, .err input[type="button"] -{ - float: right; +#footer .lower #current_time { + float: right; + padding-right: 6px; } -.err -{ - color: white; - display: block; - background-color: #e51c23 !important; - padding: 15px; - line-height: 30px; - min-height: 30px; +.wrapper { + width: 85%; + min-width: 970px; + max-width: 1500px; + margin: auto; } -.err:before -{ - content: "ERROR: "; +#footer { + position: fixed; + left:0; + bottom:0; + height: 61px; + width: 100%; + background: #999; + border-top: 1px #000 solid; + border-bottom: 1px #000 solid; } -.warn -{ - color: white; - display: block; - background-color: #ff5722 !important; - padding: 15px; - line-height: 30px; - min-height: 30px; +* html #footer { + position: absolute; + top: expression((0-(footer.offsetHeight)+(document.documentElement.clientHeight ? document.documentElement.clientHeight : document.body.clientHeight)+(ignoreMe = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop))+'px'); } -.warn:before -{ - content: "WARNING: "; +tr td.trow1:first-child, tr td.trow2:first-child { + border-left: 0; } -.info -{ - color: white; - display: block; - background-color: #5677fc !important; - padding: 15px; - line-height: 30px; - min-height: 30px; +tr td.trow1:last-child, tr td.trow2:last-child { + border-right: 0; } -.info:before -{ - content: "INFORMATION: "; +.tborder { + -moz-border-radius: 7px; + -webkit-border-radius: 7px; + border-radius: 7px; } -#footer .fleft -{ - float: left; +.thead { + -moz-border-radius-topleft: 6px; + -moz-border-radius-topright: 6px; + -webkit-border-top-left-radius: 6px; + -webkit-border-top-right-radius: 6px; + border-top-left-radius: 6px; + border-top-right-radius: 6px; } -#footer .fright -{ - float: right; - text-align: right; +table { + color: #000; + font-size: 13px; } -#footer -{ - margin: 0; - padding: 10px; - font-size: 9pt; - color: rgba(255, 255, 255, 0.8); - box-shadow: 0px 2px 3px rgba(0, 0, 0, 0.2) inset; +.tborder { + background: #fff; + width: 100%; + margin: auto; + border: 1px solid #ccc; + padding: 1px; } -#footer a -{ - text-transform: none; - color: white; +.thead { + background: #a1a2a2 url(thead.png) top left repeat-x; + color: #fff; + border-bottom: 1px solid #8e8f8f; + padding: 8px; } -input[type="submit"], button, input[type="button"] -{ - background-color: #ffc107; - padding: 8px 15px 8px 15px; - margin: 0 2px; - display: inline-block; - text-align: center; - color: black; - box-shadow: 0px 2px 3px rgba(0,0,0,0.2); - border: none; - outline: none; - cursor: pointer; +.tcat { + background: #dcdbdc url(tcat.png) repeat-x; + color: #fff; + border-bottom: 1px solid #bbb; + padding: 6px; + font-size: 12px; } -input[type="submit"]:hover, button:hover, input[type="button"]:hover -{ - background-color: #ffca28; +.trow1 { + background: #f5f5f5; + border: 1px solid; + border-color: #fff #ddd #ddd #fff; } -input[type="submit"]:active, button:active, input[type="button"]:active -{ - background-color: #ffd54f; - -webkit-transform: translateY(1px); - -moz-transform: translateY(1px); - transform: translateY(1px); +.trow2 { + background: #efefef; + border: 1px solid; + border-color: #fff #ddd #ddd #fff; + padding: 15px; + box-sizing: border-box; + -moz-box-sizing: border-box; } -hr -{ - border: none; - height: 1px; - background-color: rgba(0, 0, 0, 0.12); +table { + color: #000; + font-size: 13px; + text-align: left; } -h4 -{ - padding-bottom: 10px; - margin-bottom: 12px; - border-bottom: 1px solid rgba(0, 0, 0, 0.12); +.tborder { + background: #fff; + width: 100%; + margin: auto; + border: 1px solid #ccc; + padding: 1px; } - -/**** PAGE SPECIFIC CSS ****/ - -/* remove the * for disabling: */ - -.page-core-server-settings table td -{ - text-align: center; - width: 25%; +.thead { + background: #a1a2a2 url(thead.png) top left repeat-x; + color: #fff; + border-bottom: 1px solid #8e8f8f; + padding: 8px; } -.page-core-server-settings.no-param table td:nth-child(1) a, -.page-core-server-settings.param-tab-general table td:nth-child(1) a -{ - font-weight: 600; - color: rgba(0, 0, 0, 0.87); +.tcat { + background: #dcdbdc url(tcat.png) repeat-x; + color: #fff; + border-bottom: 1px solid #bbb; + padding: 6px; + font-size: 12px; } -.page-core-server-settings.param-tab-monsters table td:nth-child(2) a -{ - font-weight: 600; - color: rgba(0, 0, 0, 0.87); +.trow1 { + background: #f5f5f5; + border: 1px solid; + border-color: #fff #ddd #ddd #fff; } -.page-core-server-settings.param-tab-worlds table td:nth-child(3) a -{ - font-weight: 600; - color: rgba(0, 0, 0, 0.87); +.trow2 { + background: #efefef; + border: 1px solid; + border-color: #fff #ddd #ddd #fff; } -.page-core-server-settings.param-tab-world table td:nth-child(4) a -{ - font-weight: 600; - color: rgba(0, 0, 0, 0.87); +.smalltext { + font-size: 11px; } -.page-core-permissions form table tr, -.page-core-permissions form table td, -.page-core-permissions form table th -{ - border: none; - background-color: transparent; +textarea { + background: #fff; + color: #000; + border: 1px solid #ccc; + padding: 2px; + line-height: 1.4; + font-family: Tahoma,Verdana,Arial,Sans-Serif; + font-size: 13px; } -.page-core-permissions form table tr:nth-child(1) th -{ - width: 35%; +select { + background: #fff; + padding: 3px; + border: 1px solid #ccc; + font-family: Tahoma,Verdana,Arial,Sans-Serif; } -.page-core-permissions form table tr:nth-child(1) td -{ - width: 65%; +.usercp_nav_item { + display: block; + padding: 1px 0 1px 23px; } -.page-core-permissions form table td input -{ - width: 100%; - box-sizing: border-box; - -moz-box-sizing: border-box; - margin: 0; +.usercp_nav_pmfolder { + background: url(pmfolder.gif) no-repeat left center; } -#ChatDiv -{ - margin-bottom: 10px; +.usercp_nav_sub_pmfolder { + padding-left: 40px; + background: url(sub_pmfolder.gif) no-repeat left center; } -#ChatMessage -{ - width: 100%; - box-sizing: border-box; - -moz-box-sizing: border-box; +.usercp_nav_home { + background: url(home.gif) no-repeat left center; } -/**/ +.pagehead { + top: 0; + left: 0; + width: 100%; +} + +table { + width: 100%; +} + +table th { + border-bottom: 1px solid rgba(0,0,0,0.12); + padding: 5px; + text-align: left; +} + +table tr:nth-child(odd) { + background-color: rgba(0,0,0,0.015); +} + +p { + margin: 4px 0; + padding: 4px 3px; +} + +a { + text-decoration: none; + color: #000; + -webkit-transition: color .1s linear; + -moz-transition: color .1s linear; + transition: color .1s linear; +} + +a:hover { + color: #888; +} + +input[type="text"] { + background: #fff; + color: #000; + border: 1px solid #ccc; + padding: 2px; + line-height: 1.4; + font-family: Tahoma,Verdana,Arial,Sans-Serif; + font-size: 13px; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + border-radius: 5px; +} + +input[type="text"]:hover { + background-color: #E5E4E2; +} + +input[type="text"]:focus { + background-color: #E5E4E2; +} + +hr { + border: none; + height: 1px; + background-color: rgba(0,0,0,0.12); +} + +h4 { + padding-bottom: 10px; + margin-bottom: 12px; + border-bottom: 1px solid rgba(0,0,0,0.12); +} + +#ChatDiv { + margin-bottom: 10px; +} + +#ChatMessage { + width: 92%; + margin-right: 5px; + box-sizing: border-box; + -moz-box-sizing: border-box; +} + +input[type="submit"] { + padding: 3px; + padding-left: 5px; + padding-right: 5px; + cursor: pointer; + font-family: Tahoma,Verdana,Arial,Sans-Serif; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + border-radius: 5px; + background: #f5f5f5; + border: 1px solid #ccc; +} + +input[type="submit"]:hover { + background-color: #E5E4E2; +} + +button:disabled,input:disabled { + padding: 3px; + padding-left: 5px; + padding-right: 5px; + cursor: pointer; + font-family: Tahoma,Verdana,Arial,Sans-Serif; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + border-radius: 5px; + border: none!important; + color: #fff!important; + background-color: #ccc!important; +} diff --git a/MCServer/webadmin/files/sub_pmfolder.gif b/MCServer/webadmin/files/sub_pmfolder.gif new file mode 100644 index 000000000..3d0d6e627 Binary files /dev/null and b/MCServer/webadmin/files/sub_pmfolder.gif differ diff --git a/MCServer/webadmin/files/tcat.png b/MCServer/webadmin/files/tcat.png new file mode 100644 index 000000000..eb64eb3d6 Binary files /dev/null and b/MCServer/webadmin/files/tcat.png differ diff --git a/MCServer/webadmin/files/thead.png b/MCServer/webadmin/files/thead.png new file mode 100644 index 000000000..81aa04bac Binary files /dev/null and b/MCServer/webadmin/files/thead.png differ diff --git a/MCServer/webadmin/login_template.html b/MCServer/webadmin/login_template.html index 913a85db0..7a8601065 100644 --- a/MCServer/webadmin/login_template.html +++ b/MCServer/webadmin/login_template.html @@ -1,25 +1,69 @@ + MCServer WebAdmin - Login - + + - - -
- -

MCServer - WebAdmin

-
- -
-
+
+
+
+ +
+
+
+
+
+
+
+ +
+
+
+
+
+
+
+ + + + + + + + + +
+
MCServer WebAdmin
+
+
+ +
+
+
+
+
+ - diff --git a/MCServer/webadmin/template.lua b/MCServer/webadmin/template.lua index 05ca224b1..4d3934da8 100644 --- a/MCServer/webadmin/template.lua +++ b/MCServer/webadmin/template.lua @@ -81,22 +81,56 @@ function ShowPage(WebAdmin, TemplateRequest) end Output([[ - + + - - -]] .. Title .. [[ - - + ]] .. Title .. [[ + + + -
-
- MCServer -
-