mirror of
https://github.com/whoahq/whoa.git
synced 2026-03-18 13:41:06 +03:00
feat(glue): implement Script_ContestAccepted (#161)
Co-authored-by: fallenoak <git@fallenoak.me>
This commit is contained in:
parent
d19658185a
commit
0a91d44600
@ -38,6 +38,7 @@
|
|||||||
#include <common/MD5.hpp>
|
#include <common/MD5.hpp>
|
||||||
#include <cstdio>
|
#include <cstdio>
|
||||||
|
|
||||||
|
int32_t CGlueMgr::m_acceptedContest = 1; // TODO
|
||||||
int32_t CGlueMgr::m_acceptedEULA = 1; // TODO
|
int32_t CGlueMgr::m_acceptedEULA = 1; // TODO
|
||||||
int32_t CGlueMgr::m_acceptedTerminationWithoutNotice;
|
int32_t CGlueMgr::m_acceptedTerminationWithoutNotice;
|
||||||
int32_t CGlueMgr::m_acceptedTOS = 1; // TODO
|
int32_t CGlueMgr::m_acceptedTOS = 1; // TODO
|
||||||
|
|||||||
@ -32,6 +32,7 @@ class CGlueMgr {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// Static variables
|
// Static variables
|
||||||
|
static int32_t m_acceptedContest;
|
||||||
static int32_t m_acceptedEULA;
|
static int32_t m_acceptedEULA;
|
||||||
static int32_t m_acceptedTerminationWithoutNotice;
|
static int32_t m_acceptedTerminationWithoutNotice;
|
||||||
static int32_t m_acceptedTOS;
|
static int32_t m_acceptedTOS;
|
||||||
|
|||||||
@ -234,7 +234,13 @@ int32_t Script_ShowContestNotice(lua_State* L) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int32_t Script_ContestAccepted(lua_State* L) {
|
int32_t Script_ContestAccepted(lua_State* L) {
|
||||||
WHOA_UNIMPLEMENTED(0);
|
if (CGlueMgr::m_acceptedContest) {
|
||||||
|
lua_pushnumber(L, 1.0);
|
||||||
|
} else {
|
||||||
|
lua_pushnil(L);
|
||||||
|
}
|
||||||
|
|
||||||
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t Script_AcceptContest(lua_State* L) {
|
int32_t Script_AcceptContest(lua_State* L) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user