|
|
<!--
|
|
|
TerranQuest - Augmented Reality fantasy game
|
|
|
|
|
|
Copyright 2016 Netsyms Technologies
|
|
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
you may not use this file except in compliance with the License.
|
|
|
You may obtain a copy of the License at
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
See the License for the specific language governing permissions and
|
|
|
limitations under the License.
|
|
|
-->
|
|
|
<div id="loading">
|
|
|
<div style="position: absolute; width: 100%; height: 100%; top: 0; left: 0; background-color: #324150;">
|
|
|
<img src="assets/logonobg.svg" alt="" style="display: block; position: absolute; max-width: 90%; top: 0; left: 0; right: 0; bottom: 25%; margin: auto; max-height: 20%;" />
|
|
|
<p style="font-family: sans-serif; color: white; position: absolute; max-width: 90%; left: 0; right: 0; bottom: 30%; margin: auto; text-align: center;">
|
|
|
<span data-localize="logging-in-spin">Logging in...</span>
|
|
|
<br /><i class="fa fa-spinner fa-pulse fa-fw"></i>
|
|
|
<br />
|
|
|
<span id="loading-error"></span></p>
|
|
|
<p class="splash-version"></p>
|
|
|
<div style="background: url(assets/mountains-simple.svg) repeat-x; background-size: auto 100%; height: 20%; position: absolute; bottom: 0; width: 100%;"></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
<div id="server-options-modal" class="modal fade" tabindex="-1" role="dialog">
|
|
|
<div class="modal-dialog">
|
|
|
<div class="modal-content">
|
|
|
<div class="modal-header">
|
|
|
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
|
|
<h4 class="modal-title" id="server-options-box-header">Server Options</h4>
|
|
|
</div>
|
|
|
<div class="modal-body">
|
|
|
You can connect to third-party game servers here.
|
|
|
Enter the URLs for the servers.
|
|
|
Leave a box empty to connect to the official servers.
|
|
|
<br /><br />
|
|
|
<i class="fa fa-warning"></i> Warning: Third-party servers can
|
|
|
see (and track) your location and other personal information
|
|
|
sent by TerranQuest.
|
|
|
<br /><br />
|
|
|
<b>Custom game server:</b>
|
|
|
<input type="text" class="form-control" placeholder="http://gs.terranquest.net/" id="gameserver-url-box" autocorrect="off" autocapitalize="off" spellcheck="false" />
|
|
|
<br />
|
|
|
<b>Custom chat server:</b>
|
|
|
<input type="text" class="form-control" placeholder="http://gs.terranquest.net/" id="chatserver-url-box" autocorrect="off" autocapitalize="off" spellcheck="false" />
|
|
|
</div>
|
|
|
<div class="modal-footer">
|
|
|
<button type="button" data-dismiss="modal" class="btn btn-default"><i class="fa fa-times"></i> Cancel</button>
|
|
|
<button type="button" onclick="setCustomServers()" data-dismiss="modal" class="btn btn-success"><i class="fa fa-check"></i> Save</button>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
<div class="row">
|
|
|
<div class="col-lg-12 text-center">
|
|
|
<div class="panel panel-default">
|
|
|
<div class="panel-heading whitetext clearfix" id="loginheader" style="color: white;" data-localize="login-header">
|
|
|
Login to TerranQuest <span class="pull-right" data-toggle="modal" data-target="#server-options-modal"><i class="fa fa-gear"></i></span>
|
|
|
</div>
|
|
|
<div class="panel-body">
|
|
|
<div id="errorbase" class="alert alert-danger alert-dismissable" style="display: none;">
|
|
|
<p id="errormsg">An error occurred.</p>
|
|
|
</div>
|
|
|
<div class="input-group">
|
|
|
<span class="input-group-addon" id="basic-addon-usericon"><i class="fa fa-user fa-fw"></i></span>
|
|
|
<input type="text" placeholder="Username" id="usernameBox" class="form-control" aria-describedby="basic-addon-usericon" autocorrect="off" autocapitalize="off" spellcheck="false" />
|
|
|
</div>
|
|
|
<br />
|
|
|
<div class="input-group">
|
|
|
<span class="input-group-addon" id="basic-addon-passicon"><i class="fa fa-key fa-fw"></i></span>
|
|
|
<input type="password" placeholder="Password" id="passwordBox" class="form-control" aria-describedby="basic-addon-passicon" autocorrect="off" autocapitalize="off" spellcheck="false" />
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="panel-footer">
|
|
|
<a href="#" onclick="dologin()" id="loginBtn" class="btn btn-success btn-wide"><i class="fa fa-sign-in"></i> Login</a><br /><br />
|
|
|
<p><i data-localize="signup-question">Don't have a Netsyms account?</i></p>
|
|
|
<a href="#" onclick="openscreen('signup')" id="openSignupBtn" class="btn btn-primary btn-wide"><i class="fa fa-user-plus"></i> Sign Up</a>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
<script>
|
|
|
$('#gameserver-url-box').val(localStorage.getItem("gameserv"));
|
|
|
$('#chatserver-url-box').val(localStorage.getItem("chatserv"));
|
|
|
|
|
|
function setCustomServers() {
|
|
|
localStorage.setItem("gameserv", $('#gameserver-url-box').val());
|
|
|
localStorage.setItem("chatserv", $('#chatserver-url-box').val());
|
|
|
}
|
|
|
|
|
|
$('.splash-version').text("v" + window.cordova.plugins.version.getAppVersion());
|
|
|
|
|
|
var userset = false;
|
|
|
var passset = false;
|
|
|
if (localStorage.getItem("username") !== null && localStorage.getItem("username") !== '') {
|
|
|
$('#usernameBox').val(localStorage.getItem("username"));
|
|
|
userset = true;
|
|
|
}
|
|
|
if (localStorage.getItem("password") !== null && localStorage.getItem("password") !== '') {
|
|
|
$('#passwordBox').val(localStorage.getItem("password"));
|
|
|
passset = true;
|
|
|
}
|
|
|
|
|
|
if (userset && passset && localStorage.getItem("no_autologin") !== "true") {
|
|
|
// Try to login with stored credentials
|
|
|
dologin();
|
|
|
} else {
|
|
|
$('#loading').css('display', 'none');
|
|
|
// Remove autologin block
|
|
|
localStorage.setItem("no_autologin", "");
|
|
|
updateStatusBarColor();
|
|
|
}
|
|
|
navigator.splashscreen.hide();
|
|
|
</script> |