mirror of
https://github.com/whoahq/whoa.git
synced 2026-02-02 08:42:45 +03:00
Compare commits
16 Commits
837a8eff41
...
a328ff7475
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a328ff7475 | ||
|
|
b9f2c60966 | ||
|
|
5f7bf8c95c | ||
|
|
7d9173b880 | ||
|
|
98ea309985 | ||
|
|
ba5006a4d8 | ||
|
|
e872450202 | ||
|
|
bc1d7cbd66 | ||
|
|
61b05eb366 | ||
|
|
a168c6fd41 | ||
|
|
95a8f4287f | ||
|
|
c0ec4aed44 | ||
|
|
6dd15ed2cf | ||
|
|
dc071210ca | ||
|
|
cbbf491620 | ||
|
|
caf628145d |
@ -26,10 +26,11 @@
|
|||||||
#include "ui/FrameXML.hpp"
|
#include "ui/FrameXML.hpp"
|
||||||
#include "ui/Interface.hpp"
|
#include "ui/Interface.hpp"
|
||||||
#include "ui/Key.hpp"
|
#include "ui/Key.hpp"
|
||||||
#include "ui/ScriptFunctions.hpp"
|
#include "ui/ScriptFunctionsSystem.hpp"
|
||||||
#include "ui/game/CGVideoOptions.hpp"
|
#include "ui/game/CGVideoOptions.hpp"
|
||||||
#include "ui/simple/CSimpleModelFFX.hpp"
|
#include "ui/simple/CSimpleModelFFX.hpp"
|
||||||
#include "ui/simple/CSimpleTop.hpp"
|
#include "ui/simple/CSimpleTop.hpp"
|
||||||
|
#include "ui/simple/ScriptMethods.hpp"
|
||||||
#include "util/Filesystem.hpp"
|
#include "util/Filesystem.hpp"
|
||||||
#include "util/Locale.hpp"
|
#include "util/Locale.hpp"
|
||||||
#include "util/Log.hpp"
|
#include "util/Log.hpp"
|
||||||
@ -1186,6 +1187,10 @@ void CGlueMgr::Suspend() {
|
|||||||
|
|
||||||
// TODO
|
// TODO
|
||||||
|
|
||||||
|
SystemUnregisterFunctions();
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
|
||||||
FrameXML_FreeHashNodes();
|
FrameXML_FreeHashNodes();
|
||||||
|
|
||||||
// TODO
|
// TODO
|
||||||
|
|||||||
@ -522,36 +522,6 @@ int32_t Script_IsScanDLLFinished(lua_State* L) {
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t Script_IsWindowsClient(lua_State* L) {
|
|
||||||
#if defined(WHOA_SYSTEM_WIN)
|
|
||||||
lua_pushnumber(L, 1.0);
|
|
||||||
#else
|
|
||||||
lua_pushnil(L);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
int32_t Script_IsMacClient(lua_State* L) {
|
|
||||||
#if defined(WHOA_SYSTEM_MAC)
|
|
||||||
lua_pushnumber(L, 1.0);
|
|
||||||
#else
|
|
||||||
lua_pushnil(L);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
int32_t Script_IsLinuxClient(lua_State* L) {
|
|
||||||
#if defined(WHOA_SYSTEM_LINUX)
|
|
||||||
lua_pushnumber(L, 1.0);
|
|
||||||
#else
|
|
||||||
lua_pushnil(L);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
int32_t Script_SetRealmSplitState(lua_State* L) {
|
int32_t Script_SetRealmSplitState(lua_State* L) {
|
||||||
WHOA_UNIMPLEMENTED(0);
|
WHOA_UNIMPLEMENTED(0);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1047,6 +1047,15 @@ const char* FrameScript_Sprintf(lua_State* L, int32_t idx, char buffer[], uint32
|
|||||||
return buffer;
|
return buffer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void FrameScript_UnregisterFunction(const char* name) {
|
||||||
|
auto L = FrameScript::s_context;
|
||||||
|
|
||||||
|
lua_pushnil(L);
|
||||||
|
lua_pushstring(L, name);
|
||||||
|
lua_insert(L, -2);
|
||||||
|
lua_rawset(L, LUA_GLOBALSINDEX);
|
||||||
|
}
|
||||||
|
|
||||||
void FrameScript_UnregisterScriptEvent(FrameScript_Object* object, FrameScript_EventObject* event) {
|
void FrameScript_UnregisterScriptEvent(FrameScript_Object* object, FrameScript_EventObject* event) {
|
||||||
if (event->pendingSignalCount) {
|
if (event->pendingSignalCount) {
|
||||||
auto node = event->unregisterListeners.Head();
|
auto node = event->unregisterListeners.Head();
|
||||||
|
|||||||
@ -99,6 +99,8 @@ void FrameScript_SignalEvent(uint32_t index, const char* format, ...);
|
|||||||
|
|
||||||
const char* FrameScript_Sprintf(lua_State* L, int32_t idx, char buffer[], uint32_t bufferLen);
|
const char* FrameScript_Sprintf(lua_State* L, int32_t idx, char buffer[], uint32_t bufferLen);
|
||||||
|
|
||||||
|
void FrameScript_UnregisterFunction(const char* name);
|
||||||
|
|
||||||
void FrameScript_UnregisterScriptEvent(FrameScript_Object* object, FrameScript_EventObject* event);
|
void FrameScript_UnregisterScriptEvent(FrameScript_Object* object, FrameScript_EventObject* event);
|
||||||
|
|
||||||
void ScriptEventsInitialize();
|
void ScriptEventsInitialize();
|
||||||
|
|||||||
@ -1,65 +0,0 @@
|
|||||||
#include "ui/ScriptFunctions.hpp"
|
|
||||||
#include "ui/FrameScript.hpp"
|
|
||||||
#include "ui/simple/CSimpleButton.hpp"
|
|
||||||
#include "ui/simple/CSimpleCheckbox.hpp"
|
|
||||||
#include "ui/simple/CSimpleEditBox.hpp"
|
|
||||||
#include "ui/simple/CSimpleFont.hpp"
|
|
||||||
#include "ui/simple/CSimpleFontString.hpp"
|
|
||||||
#include "ui/simple/CSimpleFrame.hpp"
|
|
||||||
#include "ui/simple/CSimpleHTML.hpp"
|
|
||||||
#include "ui/simple/CSimpleModel.hpp"
|
|
||||||
#include "ui/simple/CSimpleModelFFX.hpp"
|
|
||||||
#include "ui/simple/CSimpleScrollFrame.hpp"
|
|
||||||
#include "ui/simple/CSimpleSlider.hpp"
|
|
||||||
#include "ui/simple/CSimpleTexture.hpp"
|
|
||||||
|
|
||||||
void RegisterSimpleFrameScriptMethods() {
|
|
||||||
for (int32_t i = 0; i < NUM_SCRIPT_FUNCTIONS_SIMPLE_FRAME; ++i) {
|
|
||||||
FrameScript_RegisterFunction(
|
|
||||||
FrameScript::s_ScriptFunctions_SimpleFrame[i].name,
|
|
||||||
FrameScript::s_ScriptFunctions_SimpleFrame[i].method
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
// CSimpleAnim::CreateScriptMetaTable();
|
|
||||||
// CSimpleTranslationAnim::CreateScriptMetaTable();
|
|
||||||
// CSimpleRotationAnim::CreateScriptMetaTable();
|
|
||||||
// CSimpleScaleAnim::CreateScriptMetaTable();
|
|
||||||
// CSimpleControlPoint::CreateScriptMetaTable();
|
|
||||||
// CSimplePathAnim::CreateScriptMetaTable();
|
|
||||||
// CSimpleAlphaAnim::CreateScriptMetaTable();
|
|
||||||
// CSimpleAnimGroup::CreateScriptMetaTable();
|
|
||||||
|
|
||||||
CSimpleFont::CreateScriptMetaTable();
|
|
||||||
CSimpleTexture::CreateScriptMetaTable();
|
|
||||||
CSimpleFontString::CreateScriptMetaTable();
|
|
||||||
CSimpleFrame::CreateScriptMetaTable();
|
|
||||||
CSimpleButton::CreateScriptMetaTable();
|
|
||||||
CSimpleCheckbox::CreateScriptMetaTable();
|
|
||||||
CSimpleEditBox::CreateScriptMetaTable();
|
|
||||||
CSimpleHTML::CreateScriptMetaTable();
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
// CSimpleMessageFrame::CreateScriptMetaTable();
|
|
||||||
// CSimpleMessageScrollFrame::CreateScriptMetaTable();
|
|
||||||
|
|
||||||
CSimpleModel::CreateScriptMetaTable();
|
|
||||||
CSimpleModelFFX::CreateScriptMetaTable();
|
|
||||||
CSimpleScrollFrame::CreateScriptMetaTable();
|
|
||||||
CSimpleSlider::CreateScriptMetaTable();
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
// CSimpleStatusBar::CreateScriptMetaTable();
|
|
||||||
// CSimpleColorSelect::CreateScriptMetaTable();
|
|
||||||
// CSimpleMovieFrame::CreateScriptMetaTable();
|
|
||||||
}
|
|
||||||
|
|
||||||
void SystemRegisterFunctions() {
|
|
||||||
for (int32_t i = 0; i < NUM_SCRIPT_FUNCTIONS_SYSTEM; ++i) {
|
|
||||||
FrameScript_RegisterFunction(
|
|
||||||
FrameScript::s_ScriptFunctions_System[i].name,
|
|
||||||
FrameScript::s_ScriptFunctions_System[i].method
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,21 +0,0 @@
|
|||||||
#ifndef UI_SCRIPT_FUNCTIONS_HPP
|
|
||||||
#define UI_SCRIPT_FUNCTIONS_HPP
|
|
||||||
|
|
||||||
#include "ui/Types.hpp"
|
|
||||||
#include <cstdint>
|
|
||||||
|
|
||||||
struct lua_State;
|
|
||||||
|
|
||||||
#define NUM_SCRIPT_FUNCTIONS_SIMPLE_FRAME 7
|
|
||||||
#define NUM_SCRIPT_FUNCTIONS_SYSTEM 7
|
|
||||||
|
|
||||||
namespace FrameScript {
|
|
||||||
extern FrameScript_Method s_ScriptFunctions_SimpleFrame[NUM_SCRIPT_FUNCTIONS_SIMPLE_FRAME];
|
|
||||||
extern FrameScript_Method s_ScriptFunctions_System[NUM_SCRIPT_FUNCTIONS_SYSTEM];
|
|
||||||
}
|
|
||||||
|
|
||||||
void RegisterSimpleFrameScriptMethods();
|
|
||||||
|
|
||||||
void SystemRegisterFunctions();
|
|
||||||
|
|
||||||
#endif
|
|
||||||
@ -1,4 +1,4 @@
|
|||||||
#include "ui/ScriptFunctions.hpp"
|
#include "ui/ScriptFunctionsShared.hpp"
|
||||||
#include "util/Lua.hpp"
|
#include "util/Lua.hpp"
|
||||||
#include "util/Unimplemented.hpp"
|
#include "util/Unimplemented.hpp"
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
@ -6,3 +6,33 @@
|
|||||||
int32_t Script_GetAccountExpansionLevel(lua_State* L) {
|
int32_t Script_GetAccountExpansionLevel(lua_State* L) {
|
||||||
WHOA_UNIMPLEMENTED(0);
|
WHOA_UNIMPLEMENTED(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsLinuxClient(lua_State* L) {
|
||||||
|
#if defined(WHOA_SYSTEM_LINUX)
|
||||||
|
lua_pushnumber(L, 1.0);
|
||||||
|
#else
|
||||||
|
lua_pushnil(L);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsMacClient(lua_State* L) {
|
||||||
|
#if defined(WHOA_SYSTEM_MAC)
|
||||||
|
lua_pushnumber(L, 1.0);
|
||||||
|
#else
|
||||||
|
lua_pushnil(L);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsWindowsClient(lua_State* L) {
|
||||||
|
#if defined(WHOA_SYSTEM_WIN)
|
||||||
|
lua_pushnumber(L, 1.0);
|
||||||
|
#else
|
||||||
|
lua_pushnil(L);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|||||||
@ -6,4 +6,10 @@
|
|||||||
|
|
||||||
int32_t Script_GetAccountExpansionLevel(lua_State* L);
|
int32_t Script_GetAccountExpansionLevel(lua_State* L);
|
||||||
|
|
||||||
|
int32_t Script_IsLinuxClient(lua_State* L);
|
||||||
|
|
||||||
|
int32_t Script_IsMacClient(lua_State* L);
|
||||||
|
|
||||||
|
int32_t Script_IsWindowsClient(lua_State* L);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
#include "ui/ScriptFunctions.hpp"
|
#include "ui/FrameScript.hpp"
|
||||||
#include "ui/ScriptFunctionsShared.hpp"
|
#include "ui/ScriptFunctionsShared.hpp"
|
||||||
#include "ui/Types.hpp"
|
#include "ui/Types.hpp"
|
||||||
#include "util/Lua.hpp"
|
#include "util/Lua.hpp"
|
||||||
@ -22,10 +22,12 @@ int32_t Script_ConsoleExec(lua_State* L) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int32_t Script_AccessDenied(lua_State* L) {
|
int32_t Script_AccessDenied(lua_State* L) {
|
||||||
return luaL_error(L, "Access Denied");
|
luaL_error(L, "Access Denied");
|
||||||
|
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
FrameScript_Method FrameScript::s_ScriptFunctions_System[NUM_SCRIPT_FUNCTIONS_SYSTEM] = {
|
static FrameScript_Method s_SystemFunctions[] = {
|
||||||
{ "GetTime", &Script_GetTime },
|
{ "GetTime", &Script_GetTime },
|
||||||
{ "GetGameTime", &Script_GetGameTime },
|
{ "GetGameTime", &Script_GetGameTime },
|
||||||
{ "ConsoleExec", &Script_ConsoleExec },
|
{ "ConsoleExec", &Script_ConsoleExec },
|
||||||
@ -34,3 +36,15 @@ FrameScript_Method FrameScript::s_ScriptFunctions_System[NUM_SCRIPT_FUNCTIONS_SY
|
|||||||
{ "AppendToFile", &Script_AccessDenied },
|
{ "AppendToFile", &Script_AccessDenied },
|
||||||
{ "GetAccountExpansionLevel", &Script_GetAccountExpansionLevel }
|
{ "GetAccountExpansionLevel", &Script_GetAccountExpansionLevel }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
void SystemRegisterFunctions() {
|
||||||
|
for (auto& func : s_SystemFunctions) {
|
||||||
|
FrameScript_RegisterFunction(func.name, func.method);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void SystemUnregisterFunctions() {
|
||||||
|
for (auto& func : s_SystemFunctions) {
|
||||||
|
FrameScript_UnregisterFunction(func.name);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
8
src/ui/ScriptFunctionsSystem.hpp
Normal file
8
src/ui/ScriptFunctionsSystem.hpp
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
#ifndef UI_SCRIPT_FUNCTIONS_SYSTEM_HPP
|
||||||
|
#define UI_SCRIPT_FUNCTIONS_SYSTEM_HPP
|
||||||
|
|
||||||
|
void SystemRegisterFunctions();
|
||||||
|
|
||||||
|
void SystemUnregisterFunctions();
|
||||||
|
|
||||||
|
#endif
|
||||||
@ -3,12 +3,31 @@
|
|||||||
#include "ui/FrameXML.hpp"
|
#include "ui/FrameXML.hpp"
|
||||||
#include "ui/Key.hpp"
|
#include "ui/Key.hpp"
|
||||||
#include "ui/game/CGWorldFrame.hpp"
|
#include "ui/game/CGWorldFrame.hpp"
|
||||||
|
#include "ui/game/GMTicketInfoScript.hpp"
|
||||||
|
#include "ui/game/GameScript.hpp"
|
||||||
|
#include "ui/game/ScriptEvents.hpp"
|
||||||
#include "ui/simple/CSimpleTop.hpp"
|
#include "ui/simple/CSimpleTop.hpp"
|
||||||
#include "util/CStatus.hpp"
|
#include "util/CStatus.hpp"
|
||||||
#include <common/MD5.hpp>
|
#include <common/MD5.hpp>
|
||||||
|
|
||||||
CSimpleTop* CGGameUI::s_simpleTop;
|
CSimpleTop* CGGameUI::s_simpleTop;
|
||||||
|
|
||||||
|
void LoadScriptFunctions() {
|
||||||
|
// TODO
|
||||||
|
|
||||||
|
GameScriptRegisterFunctions();
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
|
||||||
|
ScriptEventsRegisterFunctions();
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
|
||||||
|
GMTicketInfoRegisterScriptFunctions();
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
}
|
||||||
|
|
||||||
void CGGameUI::Initialize() {
|
void CGGameUI::Initialize() {
|
||||||
// TODO
|
// TODO
|
||||||
|
|
||||||
@ -16,6 +35,10 @@ void CGGameUI::Initialize() {
|
|||||||
|
|
||||||
// TODO
|
// TODO
|
||||||
|
|
||||||
|
LoadScriptFunctions();
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
|
||||||
CGGameUI::RegisterFrameFactories();
|
CGGameUI::RegisterFrameFactories();
|
||||||
|
|
||||||
// TODO
|
// TODO
|
||||||
|
|||||||
87
src/ui/game/GMTicketInfoScript.cpp
Normal file
87
src/ui/game/GMTicketInfoScript.cpp
Normal file
@ -0,0 +1,87 @@
|
|||||||
|
#include "ui/game/GMTicketInfoScript.hpp"
|
||||||
|
#include "ui/FrameScript.hpp"
|
||||||
|
#include "util/Unimplemented.hpp"
|
||||||
|
|
||||||
|
int32_t Script_GetGMTicket(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_NewGMTicket(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UpdateGMTicket(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_DeleteGMTicket(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMResponseNeedMoreHelp(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMResponseResolve(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetGMStatus(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMSurveyQuestion(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMSurveyNumAnswers(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMSurveyAnswer(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMSurveyAnswerSubmit(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMSurveyCommentSubmit(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMSurveySubmit(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GMReportLag(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_RegisterStaticConstants(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
static FrameScript_Method s_ScriptFunctions[] = {
|
||||||
|
{ "GetGMTicket", &Script_GetGMTicket },
|
||||||
|
{ "NewGMTicket", &Script_NewGMTicket },
|
||||||
|
{ "UpdateGMTicket", &Script_UpdateGMTicket },
|
||||||
|
{ "DeleteGMTicket", &Script_DeleteGMTicket },
|
||||||
|
{ "GMResponseNeedMoreHelp", &Script_GMResponseNeedMoreHelp },
|
||||||
|
{ "GMResponseResolve", &Script_GMResponseResolve },
|
||||||
|
{ "GetGMStatus", &Script_GetGMStatus },
|
||||||
|
{ "GMSurveyQuestion", &Script_GMSurveyQuestion },
|
||||||
|
{ "GMSurveyNumAnswers", &Script_GMSurveyNumAnswers },
|
||||||
|
{ "GMSurveyAnswer", &Script_GMSurveyAnswer },
|
||||||
|
{ "GMSurveyAnswerSubmit", &Script_GMSurveyAnswerSubmit },
|
||||||
|
{ "GMSurveyCommentSubmit", &Script_GMSurveyCommentSubmit },
|
||||||
|
{ "GMSurveySubmit", &Script_GMSurveySubmit },
|
||||||
|
{ "GMReportLag", &Script_GMReportLag },
|
||||||
|
{ "RegisterStaticConstants", &Script_RegisterStaticConstants },
|
||||||
|
};
|
||||||
|
|
||||||
|
void GMTicketInfoRegisterScriptFunctions() {
|
||||||
|
for (auto& func : s_ScriptFunctions) {
|
||||||
|
FrameScript_RegisterFunction(func.name, func.method);
|
||||||
|
}
|
||||||
|
}
|
||||||
6
src/ui/game/GMTicketInfoScript.hpp
Normal file
6
src/ui/game/GMTicketInfoScript.hpp
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
#ifndef UI_GAME_GM_TICKET_INFO_SCRIPT_HPP
|
||||||
|
#define UI_GAME_GM_TICKET_INFO_SCRIPT_HPP
|
||||||
|
|
||||||
|
void GMTicketInfoRegisterScriptFunctions();
|
||||||
|
|
||||||
|
#endif
|
||||||
1590
src/ui/game/GameScript.cpp
Normal file
1590
src/ui/game/GameScript.cpp
Normal file
File diff suppressed because it is too large
Load Diff
6
src/ui/game/GameScript.hpp
Normal file
6
src/ui/game/GameScript.hpp
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
#ifndef UI_GAME_GAME_SCRIPT_HPP
|
||||||
|
#define UI_GAME_GAME_SCRIPT_HPP
|
||||||
|
|
||||||
|
void GameScriptRegisterFunctions();
|
||||||
|
|
||||||
|
#endif
|
||||||
860
src/ui/game/ScriptEvents.cpp
Normal file
860
src/ui/game/ScriptEvents.cpp
Normal file
@ -0,0 +1,860 @@
|
|||||||
|
#include "ui/game/ScriptEvents.hpp"
|
||||||
|
#include "ui/FrameScript.hpp"
|
||||||
|
#include "ui/ScriptFunctionsSystem.hpp"
|
||||||
|
#include "util/Unimplemented.hpp"
|
||||||
|
|
||||||
|
int32_t Script_UnitExists(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsVisible(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsUnit(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsPlayer(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsInMyGuild(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsCorpse(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsPartyLeader(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitGroupRolesAssigned(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsRaidOfficer(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitInParty(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitPlayerOrPetInParty(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitInRaid(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitPlayerOrPetInRaid(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitPlayerControlled(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsAFK(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsDND(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsPVP(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsPVPSanctuary(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsPVPFreeForAll(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitFactionGroup(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitReaction(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsEnemy(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsFriend(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitCanCooperate(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitCanAssist(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitCanAttack(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsCharmed(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsPossessed(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_PlayerCanTeleport(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitClassification(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitSelectionColor(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitGUID(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitName(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitPVPName(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitXP(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitXPMax(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitHealth(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitHealthMax(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitMana(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitManaMax(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitPower(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitPowerMax(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitPowerType(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitOnTaxi(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsFeignDeath(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsDead(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsGhost(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsDeadOrGhost(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsConnected(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitAffectingCombat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitSex(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitLevel(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetMoney(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetHonorCurrency(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetArenaCurrency(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitRace(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitClass(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitClassBase(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitResistance(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitStat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitAttackBothHands(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitDamage(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitRangedDamage(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitRangedAttack(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitAttackSpeed(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitAttackPower(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitRangedAttackPower(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitDefense(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitArmor(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitCharacterPoints(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitBuff(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitDebuff(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitAura(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsTapped(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsTappedByPlayer(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsTappedByAllThreatList(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsTrivial(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitHasRelicSlot(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_SetPortraitTexture(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_HasFullControl(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetComboPoints(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsInGuild(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsGuildLeader(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsArenaTeamCaptain(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsInArenaTeam(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsResting(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetCombatRating(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetCombatRatingBonus(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetMaxCombatRatingBonus(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetDodgeChance(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetBlockChance(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetShieldBlock(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetParryChance(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetCritChanceFromAgility(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetSpellCritChanceFromIntellect(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetCritChance(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetRangedCritChance(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetSpellCritChance(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetSpellBonusDamage(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetSpellBonusHealing(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPetSpellBonusDamage(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetSpellPenetration(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetArmorPenetration(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetAttackPowerForStat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitCreatureType(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitCreatureFamily(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetResSicknessDuration(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPVPSessionStats(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPVPYesterdayStats(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPVPLifetimeStats(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitPVPRank(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPVPRankInfo(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPVPRankProgress(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitCastingInfo(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitChannelInfo(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsLoggedIn(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsFlyableArea(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsIndoors(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsOutdoors(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsOutOfBounds(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsFalling(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsSwimming(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsFlying(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsMounted(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsStealthed(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsSameServer(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetUnitHealthModifier(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetUnitMaxHealthModifier(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetUnitPowerModifier(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetUnitHealthRegenRateFromSpirit(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetUnitManaRegenRateFromSpirit(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetManaRegen(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPowerRegen(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetRuneCooldown(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetRuneCount(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetRuneType(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_ReportPlayerIsPVPAFK(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_PlayerIsPVPInactive(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetExpertise(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetExpertisePercent(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitInBattleground(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitInRange(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetUnitSpeed(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetUnitPitch(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitInVehicle(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitUsingVehicle(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitControllingVehicle(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitInVehicleControlSeat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitHasVehicleUI(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitTargetsVehicleInRaidUI(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitVehicleSkin(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitVehicleSeatCount(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitVehicleSeatInfo(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitSwitchToVehicleSeat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_CanSwitchVehicleSeat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetVehicleUIIndicator(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetVehicleUIIndicatorSeat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitThreatSituation(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitDetailedThreatSituation(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_UnitIsControlling(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_EjectPassengerFromSeat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_CanEjectPassengerFromSeat(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_RespondInstanceLock(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPlayerFacing(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetPlayerInfoByGUID(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetItemStats(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_GetItemStatDelta(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_IsXPUserDisabled(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int32_t Script_FillLocalizedClassList(lua_State* L) {
|
||||||
|
WHOA_UNIMPLEMENTED(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
static FrameScript_Method s_UnitFunctions[] = {
|
||||||
|
{ "UnitExists", &Script_UnitExists },
|
||||||
|
{ "UnitIsVisible", &Script_UnitIsVisible },
|
||||||
|
{ "UnitIsUnit", &Script_UnitIsUnit },
|
||||||
|
{ "UnitIsPlayer", &Script_UnitIsPlayer },
|
||||||
|
{ "UnitIsInMyGuild", &Script_UnitIsInMyGuild },
|
||||||
|
{ "UnitIsCorpse", &Script_UnitIsCorpse },
|
||||||
|
{ "UnitIsPartyLeader", &Script_UnitIsPartyLeader },
|
||||||
|
{ "UnitGroupRolesAssigned", &Script_UnitGroupRolesAssigned },
|
||||||
|
{ "UnitIsRaidOfficer", &Script_UnitIsRaidOfficer },
|
||||||
|
{ "UnitInParty", &Script_UnitInParty },
|
||||||
|
{ "UnitPlayerOrPetInParty", &Script_UnitPlayerOrPetInParty },
|
||||||
|
{ "UnitInRaid", &Script_UnitInRaid },
|
||||||
|
{ "UnitPlayerOrPetInRaid", &Script_UnitPlayerOrPetInRaid },
|
||||||
|
{ "UnitPlayerControlled", &Script_UnitPlayerControlled },
|
||||||
|
{ "UnitIsAFK", &Script_UnitIsAFK },
|
||||||
|
{ "UnitIsDND", &Script_UnitIsDND },
|
||||||
|
{ "UnitIsPVP", &Script_UnitIsPVP },
|
||||||
|
{ "UnitIsPVPSanctuary", &Script_UnitIsPVPSanctuary },
|
||||||
|
{ "UnitIsPVPFreeForAll", &Script_UnitIsPVPFreeForAll },
|
||||||
|
{ "UnitFactionGroup", &Script_UnitFactionGroup },
|
||||||
|
{ "UnitReaction", &Script_UnitReaction },
|
||||||
|
{ "UnitIsEnemy", &Script_UnitIsEnemy },
|
||||||
|
{ "UnitIsFriend", &Script_UnitIsFriend },
|
||||||
|
{ "UnitCanCooperate", &Script_UnitCanCooperate },
|
||||||
|
{ "UnitCanAssist", &Script_UnitCanAssist },
|
||||||
|
{ "UnitCanAttack", &Script_UnitCanAttack },
|
||||||
|
{ "UnitIsCharmed", &Script_UnitIsCharmed },
|
||||||
|
{ "UnitIsPossessed", &Script_UnitIsPossessed },
|
||||||
|
{ "PlayerCanTeleport", &Script_PlayerCanTeleport },
|
||||||
|
{ "UnitClassification", &Script_UnitClassification },
|
||||||
|
{ "UnitSelectionColor", &Script_UnitSelectionColor },
|
||||||
|
{ "UnitGUID", &Script_UnitGUID },
|
||||||
|
{ "UnitName", &Script_UnitName },
|
||||||
|
{ "UnitPVPName", &Script_UnitPVPName },
|
||||||
|
{ "UnitXP", &Script_UnitXP },
|
||||||
|
{ "UnitXPMax", &Script_UnitXPMax },
|
||||||
|
{ "UnitHealth", &Script_UnitHealth },
|
||||||
|
{ "UnitHealthMax", &Script_UnitHealthMax },
|
||||||
|
{ "UnitMana", &Script_UnitMana },
|
||||||
|
{ "UnitManaMax", &Script_UnitManaMax },
|
||||||
|
{ "UnitPower", &Script_UnitPower },
|
||||||
|
{ "UnitPowerMax", &Script_UnitPowerMax },
|
||||||
|
{ "UnitPowerType", &Script_UnitPowerType },
|
||||||
|
{ "UnitOnTaxi", &Script_UnitOnTaxi },
|
||||||
|
{ "UnitIsFeignDeath", &Script_UnitIsFeignDeath },
|
||||||
|
{ "UnitIsDead", &Script_UnitIsDead },
|
||||||
|
{ "UnitIsGhost", &Script_UnitIsGhost },
|
||||||
|
{ "UnitIsDeadOrGhost", &Script_UnitIsDeadOrGhost },
|
||||||
|
{ "UnitIsConnected", &Script_UnitIsConnected },
|
||||||
|
{ "UnitAffectingCombat", &Script_UnitAffectingCombat },
|
||||||
|
{ "UnitSex", &Script_UnitSex },
|
||||||
|
{ "UnitLevel", &Script_UnitLevel },
|
||||||
|
{ "GetMoney", &Script_GetMoney },
|
||||||
|
{ "GetHonorCurrency", &Script_GetHonorCurrency },
|
||||||
|
{ "GetArenaCurrency", &Script_GetArenaCurrency },
|
||||||
|
{ "UnitRace", &Script_UnitRace },
|
||||||
|
{ "UnitClass", &Script_UnitClass },
|
||||||
|
{ "UnitClassBase", &Script_UnitClassBase },
|
||||||
|
{ "UnitResistance", &Script_UnitResistance },
|
||||||
|
{ "UnitStat", &Script_UnitStat },
|
||||||
|
{ "UnitAttackBothHands", &Script_UnitAttackBothHands },
|
||||||
|
{ "UnitDamage", &Script_UnitDamage },
|
||||||
|
{ "UnitRangedDamage", &Script_UnitRangedDamage },
|
||||||
|
{ "UnitRangedAttack", &Script_UnitRangedAttack },
|
||||||
|
{ "UnitAttackSpeed", &Script_UnitAttackSpeed },
|
||||||
|
{ "UnitAttackPower", &Script_UnitAttackPower },
|
||||||
|
{ "UnitRangedAttackPower", &Script_UnitRangedAttackPower },
|
||||||
|
{ "UnitDefense", &Script_UnitDefense },
|
||||||
|
{ "UnitArmor", &Script_UnitArmor },
|
||||||
|
{ "UnitCharacterPoints", &Script_UnitCharacterPoints },
|
||||||
|
{ "UnitBuff", &Script_UnitBuff },
|
||||||
|
{ "UnitDebuff", &Script_UnitDebuff },
|
||||||
|
{ "UnitAura", &Script_UnitAura },
|
||||||
|
{ "UnitIsTapped", &Script_UnitIsTapped },
|
||||||
|
{ "UnitIsTappedByPlayer", &Script_UnitIsTappedByPlayer },
|
||||||
|
{ "UnitIsTappedByAllThreatList", &Script_UnitIsTappedByAllThreatList },
|
||||||
|
{ "UnitIsTrivial", &Script_UnitIsTrivial },
|
||||||
|
{ "UnitHasRelicSlot", &Script_UnitHasRelicSlot },
|
||||||
|
{ "SetPortraitTexture", &Script_SetPortraitTexture },
|
||||||
|
{ "HasFullControl", &Script_HasFullControl },
|
||||||
|
{ "GetComboPoints", &Script_GetComboPoints },
|
||||||
|
{ "IsInGuild", &Script_IsInGuild },
|
||||||
|
{ "IsGuildLeader", &Script_IsGuildLeader },
|
||||||
|
{ "IsArenaTeamCaptain", &Script_IsArenaTeamCaptain },
|
||||||
|
{ "IsInArenaTeam", &Script_IsInArenaTeam },
|
||||||
|
{ "IsResting", &Script_IsResting },
|
||||||
|
{ "GetCombatRating", &Script_GetCombatRating },
|
||||||
|
{ "GetCombatRatingBonus", &Script_GetCombatRatingBonus },
|
||||||
|
{ "GetMaxCombatRatingBonus", &Script_GetMaxCombatRatingBonus },
|
||||||
|
{ "GetDodgeChance", &Script_GetDodgeChance },
|
||||||
|
{ "GetBlockChance", &Script_GetBlockChance },
|
||||||
|
{ "GetShieldBlock", &Script_GetShieldBlock },
|
||||||
|
{ "GetParryChance", &Script_GetParryChance },
|
||||||
|
{ "GetCritChanceFromAgility", &Script_GetCritChanceFromAgility },
|
||||||
|
{ "GetSpellCritChanceFromIntellect", &Script_GetSpellCritChanceFromIntellect },
|
||||||
|
{ "GetCritChance", &Script_GetCritChance },
|
||||||
|
{ "GetRangedCritChance", &Script_GetRangedCritChance },
|
||||||
|
{ "GetSpellCritChance", &Script_GetSpellCritChance },
|
||||||
|
{ "GetSpellBonusDamage", &Script_GetSpellBonusDamage },
|
||||||
|
{ "GetSpellBonusHealing", &Script_GetSpellBonusHealing },
|
||||||
|
{ "GetPetSpellBonusDamage", &Script_GetPetSpellBonusDamage },
|
||||||
|
{ "GetSpellPenetration", &Script_GetSpellPenetration },
|
||||||
|
{ "GetArmorPenetration", &Script_GetArmorPenetration },
|
||||||
|
{ "GetAttackPowerForStat", &Script_GetAttackPowerForStat },
|
||||||
|
{ "UnitCreatureType", &Script_UnitCreatureType },
|
||||||
|
{ "UnitCreatureFamily", &Script_UnitCreatureFamily },
|
||||||
|
{ "GetResSicknessDuration", &Script_GetResSicknessDuration },
|
||||||
|
{ "GetPVPSessionStats", &Script_GetPVPSessionStats },
|
||||||
|
{ "GetPVPYesterdayStats", &Script_GetPVPYesterdayStats },
|
||||||
|
{ "GetPVPLifetimeStats", &Script_GetPVPLifetimeStats },
|
||||||
|
{ "UnitPVPRank", &Script_UnitPVPRank },
|
||||||
|
{ "GetPVPRankInfo", &Script_GetPVPRankInfo },
|
||||||
|
{ "GetPVPRankProgress", &Script_GetPVPRankProgress },
|
||||||
|
{ "UnitCastingInfo", &Script_UnitCastingInfo },
|
||||||
|
{ "UnitChannelInfo", &Script_UnitChannelInfo },
|
||||||
|
{ "IsLoggedIn", &Script_IsLoggedIn },
|
||||||
|
{ "IsFlyableArea", &Script_IsFlyableArea },
|
||||||
|
{ "IsIndoors", &Script_IsIndoors },
|
||||||
|
{ "IsOutdoors", &Script_IsOutdoors },
|
||||||
|
{ "IsOutOfBounds", &Script_IsOutOfBounds },
|
||||||
|
{ "IsFalling", &Script_IsFalling },
|
||||||
|
{ "IsSwimming", &Script_IsSwimming },
|
||||||
|
{ "IsFlying", &Script_IsFlying },
|
||||||
|
{ "IsMounted", &Script_IsMounted },
|
||||||
|
{ "IsStealthed", &Script_IsStealthed },
|
||||||
|
{ "UnitIsSameServer", &Script_UnitIsSameServer },
|
||||||
|
{ "GetUnitHealthModifier", &Script_GetUnitHealthModifier },
|
||||||
|
{ "GetUnitMaxHealthModifier", &Script_GetUnitMaxHealthModifier },
|
||||||
|
{ "GetUnitPowerModifier", &Script_GetUnitPowerModifier },
|
||||||
|
{ "GetUnitHealthRegenRateFromSpirit", &Script_GetUnitHealthRegenRateFromSpirit },
|
||||||
|
{ "GetUnitManaRegenRateFromSpirit", &Script_GetUnitManaRegenRateFromSpirit },
|
||||||
|
{ "GetManaRegen", &Script_GetManaRegen },
|
||||||
|
{ "GetPowerRegen", &Script_GetPowerRegen },
|
||||||
|
{ "GetRuneCooldown", &Script_GetRuneCooldown },
|
||||||
|
{ "GetRuneCount", &Script_GetRuneCount },
|
||||||
|
{ "GetRuneType", &Script_GetRuneType },
|
||||||
|
{ "ReportPlayerIsPVPAFK", &Script_ReportPlayerIsPVPAFK },
|
||||||
|
{ "PlayerIsPVPInactive", &Script_PlayerIsPVPInactive },
|
||||||
|
{ "GetExpertise", &Script_GetExpertise },
|
||||||
|
{ "GetExpertisePercent", &Script_GetExpertisePercent },
|
||||||
|
{ "UnitInBattleground", &Script_UnitInBattleground },
|
||||||
|
{ "UnitInRange", &Script_UnitInRange },
|
||||||
|
{ "GetUnitSpeed", &Script_GetUnitSpeed },
|
||||||
|
{ "GetUnitPitch", &Script_GetUnitPitch },
|
||||||
|
{ "UnitInVehicle", &Script_UnitInVehicle },
|
||||||
|
{ "UnitUsingVehicle", &Script_UnitUsingVehicle },
|
||||||
|
{ "UnitControllingVehicle", &Script_UnitControllingVehicle },
|
||||||
|
{ "UnitInVehicleControlSeat", &Script_UnitInVehicleControlSeat },
|
||||||
|
{ "UnitHasVehicleUI", &Script_UnitHasVehicleUI },
|
||||||
|
{ "UnitTargetsVehicleInRaidUI", &Script_UnitTargetsVehicleInRaidUI },
|
||||||
|
{ "UnitVehicleSkin", &Script_UnitVehicleSkin },
|
||||||
|
{ "UnitVehicleSeatCount", &Script_UnitVehicleSeatCount },
|
||||||
|
{ "UnitVehicleSeatInfo", &Script_UnitVehicleSeatInfo },
|
||||||
|
{ "UnitSwitchToVehicleSeat", &Script_UnitSwitchToVehicleSeat },
|
||||||
|
{ "CanSwitchVehicleSeat", &Script_CanSwitchVehicleSeat },
|
||||||
|
{ "GetVehicleUIIndicator", &Script_GetVehicleUIIndicator },
|
||||||
|
{ "GetVehicleUIIndicatorSeat", &Script_GetVehicleUIIndicatorSeat },
|
||||||
|
{ "UnitThreatSituation", &Script_UnitThreatSituation },
|
||||||
|
{ "UnitDetailedThreatSituation", &Script_UnitDetailedThreatSituation },
|
||||||
|
{ "UnitIsControlling", &Script_UnitIsControlling },
|
||||||
|
{ "EjectPassengerFromSeat", &Script_EjectPassengerFromSeat },
|
||||||
|
{ "CanEjectPassengerFromSeat", &Script_CanEjectPassengerFromSeat },
|
||||||
|
{ "RespondInstanceLock", &Script_RespondInstanceLock },
|
||||||
|
{ "GetPlayerFacing", &Script_GetPlayerFacing },
|
||||||
|
{ "GetPlayerInfoByGUID", &Script_GetPlayerInfoByGUID },
|
||||||
|
{ "GetItemStats", &Script_GetItemStats },
|
||||||
|
{ "GetItemStatDelta", &Script_GetItemStatDelta },
|
||||||
|
{ "IsXPUserDisabled", &Script_IsXPUserDisabled },
|
||||||
|
{ "FillLocalizedClassList", &Script_FillLocalizedClassList },
|
||||||
|
};
|
||||||
|
|
||||||
|
void ScriptEventsRegisterFunctions() {
|
||||||
|
SystemRegisterFunctions();
|
||||||
|
|
||||||
|
for (auto& func : s_UnitFunctions) {
|
||||||
|
FrameScript_RegisterFunction(func.name, func.method);
|
||||||
|
}
|
||||||
|
}
|
||||||
6
src/ui/game/ScriptEvents.hpp
Normal file
6
src/ui/game/ScriptEvents.hpp
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
#ifndef UI_GAME_SCRIPT_EVENTS_HPP
|
||||||
|
#define UI_GAME_SCRIPT_EVENTS_HPP
|
||||||
|
|
||||||
|
void ScriptEventsRegisterFunctions();
|
||||||
|
|
||||||
|
#endif
|
||||||
@ -73,7 +73,16 @@ int32_t CSimpleFontString_Hide(lua_State* L) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int32_t CSimpleFontString_IsVisible(lua_State* L) {
|
int32_t CSimpleFontString_IsVisible(lua_State* L) {
|
||||||
WHOA_UNIMPLEMENTED(0);
|
auto type = CSimpleFontString::GetObjectType();
|
||||||
|
auto string = static_cast<CSimpleFontString*>(FrameScript_GetObjectThis(L, type));
|
||||||
|
|
||||||
|
if (string->IsVisible()) {
|
||||||
|
lua_pushnumber(L, 1.0);
|
||||||
|
} else {
|
||||||
|
lua_pushnil(L);
|
||||||
|
}
|
||||||
|
|
||||||
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t CSimpleFontString_IsShown(lua_State* L) {
|
int32_t CSimpleFontString_IsShown(lua_State* L) {
|
||||||
|
|||||||
@ -1342,7 +1342,7 @@ void CSimpleFrame::SetBeingScrolled(int32_t a2, int32_t a3) {
|
|||||||
this->m_batchDirty |= 0x1F;
|
this->m_batchDirty |= 0x1F;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (auto child = this->m_children.Head(); child; this->m_children.Link(child)->Next()) {
|
for (auto child = this->m_children.Head(); child; child = this->m_children.Link(child)->Next()) {
|
||||||
if (!(child->frame->m_flags & 0x4000)) {
|
if (!(child->frame->m_flags & 0x4000)) {
|
||||||
child->frame->SetBeingScrolled(a2, -1);
|
child->frame->SetBeingScrolled(a2, -1);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -49,6 +49,10 @@ bool CSimpleRegion::IsShown() {
|
|||||||
return this->m_shown == 1;
|
return this->m_shown == 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool CSimpleRegion::IsVisible() {
|
||||||
|
return this->m_visible == 1;
|
||||||
|
}
|
||||||
|
|
||||||
void CSimpleRegion::OnColorChanged(bool a2) {
|
void CSimpleRegion::OnColorChanged(bool a2) {
|
||||||
if (this->m_parent) {
|
if (this->m_parent) {
|
||||||
uint8_t effectiveAlpha = this->m_parent->m_alpha * this->m_parent->alphaBD / 255;
|
uint8_t effectiveAlpha = this->m_parent->m_alpha * this->m_parent->alphaBD / 255;
|
||||||
|
|||||||
@ -32,6 +32,7 @@ class CSimpleRegion : public CScriptRegion {
|
|||||||
void Hide();
|
void Hide();
|
||||||
void HideThis();
|
void HideThis();
|
||||||
bool IsShown();
|
bool IsShown();
|
||||||
|
bool IsVisible();
|
||||||
void OnRegionChanged();
|
void OnRegionChanged();
|
||||||
void SetVertexColor(const CImVector& color);
|
void SetVertexColor(const CImVector& color);
|
||||||
void SetVertexGradient(ORIENTATION orientation, const CImVector& minColor, const CImVector& maxColor);
|
void SetVertexGradient(ORIENTATION orientation, const CImVector& minColor, const CImVector& maxColor);
|
||||||
|
|||||||
@ -97,11 +97,29 @@ int32_t CSimpleTexture_Hide(lua_State* L) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int32_t CSimpleTexture_IsVisible(lua_State* L) {
|
int32_t CSimpleTexture_IsVisible(lua_State* L) {
|
||||||
WHOA_UNIMPLEMENTED(0);
|
auto type = CSimpleTexture::GetObjectType();
|
||||||
|
auto texture = static_cast<CSimpleTexture*>(FrameScript_GetObjectThis(L, type));
|
||||||
|
|
||||||
|
if (texture->IsVisible()) {
|
||||||
|
lua_pushnumber(L, 1.0);
|
||||||
|
} else {
|
||||||
|
lua_pushnil(L);
|
||||||
|
}
|
||||||
|
|
||||||
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t CSimpleTexture_IsShown(lua_State* L) {
|
int32_t CSimpleTexture_IsShown(lua_State* L) {
|
||||||
WHOA_UNIMPLEMENTED(0);
|
auto type = CSimpleTexture::GetObjectType();
|
||||||
|
auto texture = static_cast<CSimpleTexture*>(FrameScript_GetObjectThis(L, type));
|
||||||
|
|
||||||
|
if (texture->IsShown()) {
|
||||||
|
lua_pushnumber(L, 1.0);
|
||||||
|
} else {
|
||||||
|
lua_pushnil(L);
|
||||||
|
}
|
||||||
|
|
||||||
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t CSimpleTexture_GetTexture(lua_State* L) {
|
int32_t CSimpleTexture_GetTexture(lua_State* L) {
|
||||||
|
|||||||
@ -1,13 +1,24 @@
|
|||||||
|
#include "ui/simple/ScriptMethods.hpp"
|
||||||
#include "ui/FrameXML.hpp"
|
#include "ui/FrameXML.hpp"
|
||||||
#include "ui/ScriptFunctions.hpp"
|
|
||||||
#include "ui/Types.hpp"
|
#include "ui/Types.hpp"
|
||||||
|
#include "ui/simple/CSimpleButton.hpp"
|
||||||
|
#include "ui/simple/CSimpleCheckbox.hpp"
|
||||||
|
#include "ui/simple/CSimpleEditBox.hpp"
|
||||||
|
#include "ui/simple/CSimpleFont.hpp"
|
||||||
|
#include "ui/simple/CSimpleFontString.hpp"
|
||||||
#include "ui/simple/CSimpleFrame.hpp"
|
#include "ui/simple/CSimpleFrame.hpp"
|
||||||
|
#include "ui/simple/CSimpleHTML.hpp"
|
||||||
|
#include "ui/simple/CSimpleModel.hpp"
|
||||||
|
#include "ui/simple/CSimpleModelFFX.hpp"
|
||||||
|
#include "ui/simple/CSimpleScrollFrame.hpp"
|
||||||
|
#include "ui/simple/CSimpleSlider.hpp"
|
||||||
|
#include "ui/simple/CSimpleTexture.hpp"
|
||||||
#include "util/CStatus.hpp"
|
#include "util/CStatus.hpp"
|
||||||
#include "util/Lua.hpp"
|
#include "util/Lua.hpp"
|
||||||
#include "util/Unimplemented.hpp"
|
#include "util/Unimplemented.hpp"
|
||||||
#include <common/XML.hpp>
|
#include <common/XML.hpp>
|
||||||
#include <cstdint>
|
|
||||||
#include <storm/String.hpp>
|
#include <storm/String.hpp>
|
||||||
|
#include <cstdint>
|
||||||
|
|
||||||
int32_t Script_GetText(lua_State* L) {
|
int32_t Script_GetText(lua_State* L) {
|
||||||
WHOA_UNIMPLEMENTED(0);
|
WHOA_UNIMPLEMENTED(0);
|
||||||
@ -137,7 +148,7 @@ int32_t Script_GetCurrentKeyBoardFocus(lua_State* L) {
|
|||||||
WHOA_UNIMPLEMENTED(0);
|
WHOA_UNIMPLEMENTED(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
FrameScript_Method FrameScript::s_ScriptFunctions_SimpleFrame[NUM_SCRIPT_FUNCTIONS_SIMPLE_FRAME] = {
|
static FrameScript_Method s_ScriptFunctions[] = {
|
||||||
{ "GetText", &Script_GetText },
|
{ "GetText", &Script_GetText },
|
||||||
{ "GetNumFrames", &Script_GetNumFrames },
|
{ "GetNumFrames", &Script_GetNumFrames },
|
||||||
{ "EnumerateFrames", &Script_EnumerateFrames },
|
{ "EnumerateFrames", &Script_EnumerateFrames },
|
||||||
@ -146,3 +157,42 @@ FrameScript_Method FrameScript::s_ScriptFunctions_SimpleFrame[NUM_SCRIPT_FUNCTIO
|
|||||||
{ "GetFramesRegisteredForEvent", &Script_GetFramesRegisteredForEvent },
|
{ "GetFramesRegisteredForEvent", &Script_GetFramesRegisteredForEvent },
|
||||||
{ "GetCurrentKeyBoardFocus", &Script_GetCurrentKeyBoardFocus },
|
{ "GetCurrentKeyBoardFocus", &Script_GetCurrentKeyBoardFocus },
|
||||||
};
|
};
|
||||||
|
|
||||||
|
void RegisterSimpleFrameScriptMethods() {
|
||||||
|
for (auto& func : s_ScriptFunctions) {
|
||||||
|
FrameScript_RegisterFunction(func.name, func.method);
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
// CSimpleAnim::CreateScriptMetaTable();
|
||||||
|
// CSimpleTranslationAnim::CreateScriptMetaTable();
|
||||||
|
// CSimpleRotationAnim::CreateScriptMetaTable();
|
||||||
|
// CSimpleScaleAnim::CreateScriptMetaTable();
|
||||||
|
// CSimpleControlPoint::CreateScriptMetaTable();
|
||||||
|
// CSimplePathAnim::CreateScriptMetaTable();
|
||||||
|
// CSimpleAlphaAnim::CreateScriptMetaTable();
|
||||||
|
// CSimpleAnimGroup::CreateScriptMetaTable();
|
||||||
|
|
||||||
|
CSimpleFont::CreateScriptMetaTable();
|
||||||
|
CSimpleTexture::CreateScriptMetaTable();
|
||||||
|
CSimpleFontString::CreateScriptMetaTable();
|
||||||
|
CSimpleFrame::CreateScriptMetaTable();
|
||||||
|
CSimpleButton::CreateScriptMetaTable();
|
||||||
|
CSimpleCheckbox::CreateScriptMetaTable();
|
||||||
|
CSimpleEditBox::CreateScriptMetaTable();
|
||||||
|
CSimpleHTML::CreateScriptMetaTable();
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
// CSimpleMessageFrame::CreateScriptMetaTable();
|
||||||
|
// CSimpleMessageScrollFrame::CreateScriptMetaTable();
|
||||||
|
|
||||||
|
CSimpleModel::CreateScriptMetaTable();
|
||||||
|
CSimpleModelFFX::CreateScriptMetaTable();
|
||||||
|
CSimpleScrollFrame::CreateScriptMetaTable();
|
||||||
|
CSimpleSlider::CreateScriptMetaTable();
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
// CSimpleStatusBar::CreateScriptMetaTable();
|
||||||
|
// CSimpleColorSelect::CreateScriptMetaTable();
|
||||||
|
// CSimpleMovieFrame::CreateScriptMetaTable();
|
||||||
|
}
|
||||||
6
src/ui/simple/ScriptMethods.hpp
Normal file
6
src/ui/simple/ScriptMethods.hpp
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
#ifndef UI_SIMPLE_SCRIPT_METHODS_HPP
|
||||||
|
#define UI_SIMPLE_SCRIPT_METHODS_HPP
|
||||||
|
|
||||||
|
void RegisterSimpleFrameScriptMethods();
|
||||||
|
|
||||||
|
#endif
|
||||||
Loading…
Reference in New Issue
Block a user