登录验证
This commit is contained in:
parent
444b189089
commit
3f65103dea
40
gba/dist/gbajs.min.js
vendored
40
gba/dist/gbajs.min.js
vendored
@ -7553,9 +7553,45 @@ function run() {
|
||||
}
|
||||
})
|
||||
}
|
||||
window.onload = function() {
|
||||
|
||||
function startGame(){
|
||||
initGBA(), $(".key-btn").bind("touchstart", initAudioEvent)
|
||||
};
|
||||
}
|
||||
function checkSession_id(res){
|
||||
try{
|
||||
if(JSON.parse(res.target.response).errcode==0){
|
||||
startGame();
|
||||
}
|
||||
}catch(e){}
|
||||
}
|
||||
window.onload = function(){
|
||||
var account_id = getParameter("account_id")
|
||||
var session_id = getParameter("session_id")
|
||||
var url;
|
||||
if(getParameter("version")==="product"){
|
||||
url = "https://login.kingsome.cn/webapp/index.php?c=Login&a=sessionAuth"
|
||||
}
|
||||
else{
|
||||
url = "https://login-test.kingsome.cn/webapp/index.php?c=Login&a=sessionAuth"
|
||||
}
|
||||
url += "&account_id=";
|
||||
url += account_id;
|
||||
url += "&session_id=";
|
||||
url += session_id;
|
||||
|
||||
var ajax = new XMLHttpRequest();
|
||||
ajax.onload = checkSession_id;
|
||||
ajax.open("GET", url, true);
|
||||
ajax.send(null);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// window.onload = function() {
|
||||
// initGBA(), $(".key-btn").bind("touchstart", initAudioEvent)
|
||||
// };
|
||||
var KEY_MAP = {
|
||||
ST: 13,
|
||||
SE: 220,
|
||||
|
Loading…
x
Reference in New Issue
Block a user