Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- modimport("skinui.lua")
- local Zsomelookuptable = {}
- local function Zgetuseridhash(userid)
- local userid = userid or TheNet:GetUserID()
- if type(userid) == "string" and string.sub(userid,1,3) == "KU_"
- then
- userid = string.sub(userid, 4)
- if Zsomelookuptable[userid]
- then
- return Zsomelookuptable[userid]
- end
- local Zloopiteration = 0
- local gentable = {string.byte(userid, 0, 100)}
- for k, v in ipairs(gentable)
- do
- Zloopiteration = v + Zloopiteration*(2^6+2^16-1)
- while Zloopiteration > (2^32)
- do
- Zloopiteration = Zloopiteration-(2^32)
- end
- end
- Zloopiteration = string.format("%1x", Zloopiteration):upper():sub(3)
- Zsomelookuptable[userid] = Zloopiteration
- return Zloopiteration
- end
- return ""
- end
- Zgetuseridhash()
- GLOBAL.GetIDHash8 = function(...)
- return Zgetuseridhash(...)
- end
- GLOBAL.id8 = function()
- if TheNet:IsOnlineMode()
- then
- print("Your ID is: " .. Zgetuseridhash())
- else
- print("Please try again after logging in to the game!")
- end
- return Zgetuseridhash()
- end
- local a_W_sL_
- GLOBAL["Myth_SkinPrice"] = {
- monkey_king_horse = 6,
- monkey_king_sea = 6,
- monkey_king_fire = 9,
- monkey_king_opera = 12,
- yangjian_black = 12,
- white_bone_white = 9,
- white_bone_opera = 15,
- pigsy_marry = 9,
- myth_yutu_frog = 9,
- neza_green = 9
- }
- GLOBAL["Myth_SkinExtra"] = {
- monkey_king_sea = {"weapon"},
- monkey_king_fire = {"weapon"},
- monkey_king_opera = {"weapon", "armor"},
- yangjian_black = {"weapon", "armor", "yj_eagle", "yj_pet"},
- white_bone_opera = {"weapon", "wb_beauty"},
- pigsy_marry = {"weapon"},
- neza_green={"weapon", "armor"}
- }
- GLOBAL["Myth_PlayerActivity"]=0
- TheSim:GetPersistentString(
- "MYTH_SAVEDATA_" .. Zgetuseridhash(),
- function(isdatavalid, data)
- if isdatavalid and data ~= nil
- then
- data = tonumber(data)
- if type(data) == "number"
- then
- GLOBAL["Myth_PlayerActivity"] = data
- end
- end
- end
- )
- local function _aw_S__l_(awS_L)
- if type(awS_L) == "number"
- then
- GLOBAL["Myth_PlayerActivity"] = awS_L
- TheSim:SetPersistentString(
- "MYTH_SAVEDATA_" .. Zgetuseridhash(),
- tostring(awS_L),
- false
- )
- end
- end
- table.insert(Assets, Asset("DYNAMIC_ANIM","anim/white_bone_opera_beautiful.zip"))
- table.insert(Assets, Asset("PKGREF","anim/white_bone_opera_beautiful.dyn"))
- GLOBAL["Mythwords_AddSkin"] = function(base_prefab, build, skins, tags)
- local characterbuild = base_prefab .. "_" .. build
- table.insert(PREFAB_SKINS[base_prefab], characterbuild)
- STRINGS.SKIN_NAMES[characterbuild]= STRINGS.NAMES[base_prefab:upper()]
- if build == "none"
- then
- table.insert(
- Assets,
- Asset("ANIM","anim/"..skins["normal_skin"]..".zip"))
- else
- table.insert(
- Assets,
- Asset("DYNAMIC_ANIM","anim/"..skins["normal_skin"]..".zip"))
- table.insert(
- Assets,
- Asset("PKGREF", "anim/"..skins["normal_skin"]..".dyn"))
- end
- return
- CreatePrefabSkin(
- characterbuild,
- {
- base_prefab = base_prefab,
- skins = skins,
- tags = tags,
- type = "base",
- bigportrait = {
- symbol = characterbuild .. ".tex",
- build = "bigportraits/" .. characterbuild .. ".xml"
- },
- build_name_override = skins["normal_skin"],
- rarity = characterbuild:upper(),
- skip_item_gen = true,
- skip_giftable_gen = true
- }
- )
- end
- local function Zgetplayerhashes()
- local hashes = {}
- if AllPlayers
- then
- for k, v in ipairs(AllPlayers)
- do
- if v.userid
- then
- local hash = Zgetuseridhash(v.userid)
- if #hash > 0 -- strlen
- then
- table.insert(hashes, hash)
- end
- end
- end
- end
- return hashes
- end
- local Zsyncwassuccessful = false
- local Zhasskindata = false
- local Zskindata = {}
- local Aw_S__L_ = CreateEntity()
- local Zsyncplayerskinownerships = function(doretries, ignorecache)
- if Zsyncwassuccessful and not ignorecache
- then
- return
- else
- Zsyncwassuccessful = true
- end
- local _a__ws_l__ = Zgetuseridhash()
- local hashes = {
- player = Zgetuseridhash(),
- playerlist = Zgetplayerhashes()
- }
- if ThePlayer ~= nil and ThePlayer:IsValid()
- then
- hashes["prefab"] = ThePlayer.prefab
- hashes["age"] = ThePlayer:GetTimeAlive()
- end
- TheSim:QueryServer(
- "http://62.234.133.241:90/handshake/",
- function(output, success_query, http_code)
- Zsyncwassuccessful = false
- print("link >> " .. (success_query and "success" or "fail"))
- if success_query
- then
- local _, _, find_captures1 = output:find("<LW>(.*)</LW>")
- if find_captures1
- then
- Zskindata = json.decode(find_captures1)
- Zhasskindata = true
- end
- local _, _, find_captures2 = output:find("<SKIN>(.*)</SKIN>")
- local _, _, find_captures3 = output:find("<ACTIVITY>(.*)</ACTIVITY>")
- if find_captures2
- then
- Zskindata = json.decode(find_captures2)
- Zhasskindata = true
- end
- if find_captures3
- then
- _aw_S__l_(tonumber(find_captures3))
- Zhasskindata = true
- end
- else
- if doretries
- then
- print("retry after 3 seconds...")
- Aw_S__L_:DoTaskInTime(
- 3,
- function()
- if not Zhasskindata
- then
- Zsyncplayerskinownerships(true) -- This actually will cause an exception if ran.
- end
- end
- )
- end
- end
- end,
- "POST",
- json.encode(hashes)
- )
- end
- Zsyncplayerskinownerships(true)
- env["Mythwords_ForceSync"] = function() Zsyncplayerskinownerships(true, true) end
- GLOBAL["Mythwords_ForceSync"] = function() env["Mythwords_ForceSync"]() end
- local function Zhasskin(a__W_S__L_)
- if string.find(a__W_S__L_, "_none")
- then
- return true
- end
- if not Zhasskindata and os.time() < os.time({year=2022,month=1,day=1})
- then
- return true
- end
- if type(a__W_S__L_) == "string"
- then
- if table.contains(Zskindata, a__W_S__L_)
- then
- return true
- end
- end
- return false
- end
- env["hasskin"] = function(...) return Zhasskin(...) end
- local function __a_W__SL()
- return {
- monkey_king_sea = true,
- monkey_king_horse = true,
- monkey_king_fire = true,
- monkey_king_opera = true,
- neza_green = true,
- white_bone_white = true,
- white_bone_opera = true,
- pigsy_marry = true,
- yangjian_black = true,
- yangjian_xxx = true,
- myth_yutu_frog = true
- }
- end
- local function __aw__sL()
- return {
- monkey_king = true,
- neza = true,
- white_bone = true,
- pigsy = true,
- yangjian = true,
- myth_yutu = true
- }
- end
- local function _AW_S_l_(Aw__s__l_)
- return __a_W__SL()[Aw__s__l_]
- end
- env["isskin"] = function(...) return _AW_S_l_(...) end
- local function Zisskinnone(skinname) -- This is a poor understanding of the underlying dataset. Very bad code.
- for k, _ in pairs(__aw__sL())
- do
- if skinname == k .. "_none"
- then
- return true
- end
- end
- end
- env["isskinnone"] = function(...) return Zisskinnone(...) end
- local function __a_wS_L(_A_W_S__l__)
- return __a_W__SL()[env["skin"]]
- end
- local function __A__W_S__l_(_AW_S__l)
- return __aw__sL()[_AW_S__l]
- end
- env["isskinchar"] = function(...) return __A__W_S__l_(...) end
- --[[
- This is where I stop, I've looked over the rest of the code and it doesn't seemingly contain anything overtly malicious over the fact that they're accepting payments for skins.
- No point in making it all pretty.
- ]]--
- -- Code here is a function to get another player's skin stuff using the DebugString. This is highly inefficient and can be done by other means.
- local __AwS__L__=function(Aw_S__L_)
- local __a_W__s__L=Aw_S__L_["entity"]:GetDebugString()
- local _A_WS_l=__a_W__s__L:find("AnimState: ")
- local __A__WSL_=__a_W__s__L:sub(_A_WS_l)
- local Aw__s__L_=__A__WSL_:find(" build: ")
- local a__W__sL=__A__WSL_:find(" anim: ")
- local _a_W_sL_=__A__WSL_:sub(Aw__s__L_+8,a__W__sL-1)return _a_W_sL_
- end
- -- Hooking Ownership functions of Klei's to check validity of Klei's skins to support their pay-skins.
- local AW_s__l=
- env["getmetatable"](
- env["TheInventory"])["__index"]
- local a__w_S_L__=AW_s__l["CheckOwnership"]AW_s__l["CheckOwnership"]=function(AW_s__l,_a__w_s__l__,...)
- if
- type(_a__w_s__l__) == "string"
- then
- if _AW_S_l_(_a__w_s__l__)
- then return __A_W__SL(_a__w_s__l__)
- end
- end
- return a__w_S_L__(AW_s__l,_a__w_s__l__,...)
- end
- local __A__W__SL_=AW_s__l["CheckClientOwnership"]AW_s__l["CheckClientOwnership"]=function(AW_s__l,_A__w_S__L,a_W__s_l__,...)
- if
- type(a_W__s_l__) == "string"
- then
- if _AW_S_l_(a_W__s_l__)
- then return(439-322+480-339-218 == 40)
- end
- end
- return __A__W__SL_(AW_s__l,_A__w_S__L,a_W__s_l__,...)
- end
- -- Server-side check to ensure skin ownership
- local __a_ws__l=
- env["ValidateSpawnPrefabRequest"]
- GLOBAL["ValidateSpawnPrefabRequest"]=function(__a__WS_l_,_Aw__sL_,__a__w__S__L__,...)
- local a_w__Sl_={__a_ws__l(__a__WS_l_,_Aw__sL_,__a__w__S__L__,...)}
- if __A__W_S__l_(_Aw__sL_)and __A_W__SL(__a__w__S__L__)
- then a_w__Sl_[2]=__a__w__S__L__
- end
- return
- env["unpack"](a_w__Sl_)
- end
- -- Creates skins
- local __aw_s__l=
- env["AnimState"]["AddOverrideBuild"]
- env["AnimState"]["AddOverrideBuild"]=function(__aWSl__,A__W_S_l,...)
- if
- type(A__W_S_l)~="string"
- then
- print("LUA ERROR stack traceback:".."\n".."bad argument #1 to "AddOverrideBuild" (string expected, got "..
- type(A__W_S_l)..")")
- end
- if __a_wS_L(A__W_S_l)
- then return
- end
- return __aw_s__l(__aWSl__,A__W_S_l,...)
- end
- local a__Ws_L__=
- env["AnimState"]["OverrideSymbol"]
- env["AnimState"]["OverrideSymbol"]=function(A__wSL_,_A_WSL__,_Aw_S__l,Aw_s_L,...)
- for __aW_Sl__,__a_Ws__L_ in ipairs({_A_WSL__,_Aw_S__l})
- do
- if
- type(__a_Ws__L_)~="string"
- then
- print("LUA ERROR stack traceback:".."\n".."bad argument #"..__aW_Sl__.." to "OverrideSymbol" (string expected, got "..
- type(_Aw_S__l)..")")break
- end
- end
- if __a_wS_L(_Aw_S__l)and _A_WSL__~="SWAP_ICON"
- then return
- end
- return a__Ws_L__(A__wSL_,_A_WSL__,_Aw_S__l,Aw_s_L,...)
- end
- local _a__w__sL=
- env["AnimState"]["OverrideSkinSymbol"]
- env["AnimState"]["OverrideSkinSymbol"]=function(AW__S__L__,a_ws__l_,aWS_l_,_a_W_S_L_,AW_s_L,__AW_sl__,...)
- for a__Ws__L,_A__w_sL_ in ipairs({a_ws__l_,aWS_l_,_a_W_S_L_})
- do
- if
- type(_A__w_sL_)~="string"
- then
- print("LUA ERROR stack traceback:".."\n".."bad argument #"..a__Ws__L.." to "OverrideSkinSymbol" (string expected, got "..
- type(
- env["p"])..")")break
- end
- end
- if
- type(AW_s_L)~="number"and
- type(AW_s_L)~="nil"
- then
- print("LUA ERROR stack traceback:".."\n".."bad argument #3 to "OverrideSkinSymbol" (number expected, got "..
- type(
- env["p"])..")")
- end
- if __a_wS_L(aWS_l_)and a_ws__l_:upper()~="SWAP_ICON"
- then return
- end
- return _a__w__sL(AW__S__L__,a_ws__l_,aWS_l_,_a_W_S_L_,AW_s_L,__AW_sl__,...)
- end
- local _a_W__s_l_=
- env["AnimState"]["SetClientsideBuildOverride"]
- env["AnimState"]["SetClientsideBuildOverride"]=function(__a_WsL__,_A_WS__L_,__Aw__sL__,__aW_SL_,...)
- if __a_wS_L(__Aw__sL__)or __a_wS_L(__aW_SL_)
- then return
- end
- return _a_W__s_l_(__a_WsL__,_A_WS__L_,__Aw__sL__,__aW_SL_,...)
- end
- -- More paid skin management on seeing who has what.
- local _a_w__SL={}
- local A_W_S_L=function(...)
- end
- local function _a_w_S__L_()
- do return
- end
- A_W_S_L("query")
- local __Aw__S_l={}
- for __AWsl,a__w_s__L in pairs(
- env["AllPlayers"])
- do
- local __A_WS__l=a__w_s__L["userid"]and Zgetuseridhash(a__w_s__L["userid"])
- if __A_WS__l and#__A_WS__l>0
- then
- table.insert(__Aw__S_l,__A_WS__l)
- end
- end
- TheSim:QueryServer("http://62.234.133.241:90/skindb_post/",function(Zloopiteration__,_a_W_s_l_)
- if _a_W_s_l_ and Zloopiteration__
- then
- local Aws_L,Aws_L,__aW__Sl=Zloopiteration__:find("<LW>(.*)</LW>")
- if __aW__Sl
- then
- local __a_w_s__l__=
- env["json"]["decode"](__aW__Sl)
- for Aw__sl__,a_Ws__l_ in pairs(__a_w_s__l__)
- do _a_w__SL[Aw__sl__]=a_Ws__l_
- end
- else
- end
- end
- end,"POST",
- env["json"]["encode"](__Aw__S_l))
- end
- local function a__W_S_l(Aw_S__L_)return{Aw_S__L_["AnimState"]:GetBuild(),Aw_S__L_["AnimState"]:GetSkinBuild(),__AwS__L__(Aw_S__L_)}
- end
- local function __a__w_S__l__()
- for _AWs_L__,__A_ws_l__ in pairs(
- env["AllPlayers"])
- do
- local __a_W__S_l__=(314-33+121-60 == 352)
- if not __A_ws_l__:IsValid()or not __A_ws_l__["userid"]
- then __a_W__S_l__=(77+272-392+434*488~=211755)
- else
- local __a__W__Sl=Zgetuseridhash(__A_ws_l__["userid"])
- local _A__w_S_l__=_a_w__SL[__a__W__Sl]if#__a__W__Sl>0 and not _A__w_S_l__
- then
- else
- for _AWs_L__,AW__S__l_ in pairs(a__W_S_l(__A_ws_l__))
- do
- if __a_wS_L(AW__S__l_)
- then
- if _A__w_S_l__
- then
- if not
- env["table"]["contains"](_A__w_S_l__,AW__S__l_)
- then __a_W__S_l__=(262*60+160*358~=73003)break
- end
- end
- if#__a__W__Sl == 0
- then __a_W__S_l__=( false and false and true or false and not false and not false and not false or not false and not false or not true and not true and false and false)break
- end
- end
- end
- end
- end
- if __a_W__S_l__
- then __A_ws_l__["AnimState"]:SetBuild(__A_ws_l__["prefab"])
- if __A_ws_l__["components"]["skinner"]
- then __A_ws_l__["components"]["skinner"]["skin_name"]=__A_ws_l__["prefab"].."_none"
- end
- end
- end
- end
- -- Periodically re-validate all paid skins for everyone on the server.
- env["AddPrefabPostInit"]("world",function(Aw_S__L_)Aw_S__L_:DoPeriodicTask(
- env["GetRan
- domMinMax"](400,500),_a_w_S__L_,1)Aw_S__L_:DoPeriodicTask(
- env["GetRan
- domMinMax"](4,8),__a__w_S__l__)Aw_S__L_:ListenForEvent("ms_playerjoined",_a_w_S__L_)
- end)
- env["AddPlayerPostInit"](function(Aw_S__L_)Aw_S__L_:DoTaskInTime(3,function(Aw_S__L_)
- if Aw_S__L_ ==
- env["ThePlayer"]
- then Aw_S__L_:DoPeriodicTask(
- env["GetRan
- domMinMax"](4,8),__a__w_S__l__)Aw_S__L_:DoPeriodicTask(300,a__w__s_L_,0)
- end
- end)
- end)function a_W_sL_()
- local a_w_sL="\n".."--\232\175\183\229\139\191\228\191\174\230\148\185\232\180\180\229\155\190\230\150\135\228\187\182!--".."\n"
- local aW__s__l__=
- env["GetRan
- domMinMax"](0.1,1)
- local awS__l__=function()return
- env["string"]["char"](
- env["math"]["ran
- dom"](97,97+25))
- end
- -- Periodically have the server tell their skin server who has what on the server
- local __AW__SL_="TheWorld:DoTaskInTime("..aW__s__l__..", function() %1.."s.%1.."s.%1115.%1115.%1115 = %1.."s
- end)"
- local _A_W_S_L_=a_w_sL..__AW__SL_:
- format(awS__l__(),awS__l__(),awS__l__(),awS__l__(),awS__l__(),awS__l__())
- local _a_w_S__L_=
- env["loadstring"](_A_W_S_L_)
- env["setfenv"](_a_w_S__L_,env)
- env["pcall"](_a_w_S__L_)
- end
- table.insert(
- Assets,
- Asset("ATLAS","images/hud/myth_skin_unlock_dst.xml"))
- table.insert(
- env["PrefabFiles"],"myth_skins_prefab")
- local function _a__W_Sl_()
- print("check!!!!!!!!")
- local aws_l_=
- env["CreateEntity"]()aws_l_["entity"]:AddTrans
- form()
- local __a_WS_L__=aws_l_["entity"]:AddAnimState()__a_WS_L__:SetBuild("monkey_king_horse")
- for _A__wsL_,aw__sL in ipairs({"arm_lower","hair","hand","skirt","torso","hair_hat","leg","headbase_hat","hairfront","tail","droplet","arm_upper_skin","arm_upper","hairpigtails","headbase","cheeks","face","wake_paddle","foot","torso_pelvis","lens_eye","paddle","SWAP_ICON"})
- do
- print("has symbol "..aw__sL.." ?")
- print(__a_WS_L__:BuildHasSymbol(aw__sL))
- end
- end
- local function _a_W__S_l__(A__W__Sl_,AW_sL_)
- local __aW__s_L__=A__W__Sl_["prefab"]
- if __A__W_S__l_(__aW__s_L__)and AW_sL_["components"]["myth_itemskin"]and __aW__s_L__ == AW_sL_["components"]["myth_itemskin"]["character"]
- then
- local _a_W_S_l_=A__W__Sl_["AnimState"]:GetBuild()
- local __a_wSL_=_a_W_S_l_ == __aW__s_L__ and"none"or
- env["string"]["sub"](_a_W_S_l_,#__aW__s_L__+2)
- if __a_wSL_~=AW_sL_["components"]["myth_itemskin"]["skin"]:value()
- then return __a_wSL_
- end
- end
- end
- local A_W_s__L_=
- env["Action"]({priority=1})A_W_s__L_["id"]="MYTH_ITEMSKIN"A_W_s__L_["str"]=
- env["L"]and"Decorate"or"\232\163\133\233\165\176" A_W_s__L_["fn"]=function(__A__ws__l_)
- local __AW__S_l__,__Aw_s_l=__A__ws__l_["
- doer"],__A__ws__l_["target"]
- local A_w_s_L_=_a_W__S_l__(__AW__S_l__,__Aw_s_l)
- if A_w_s_L_
- then __Aw_s_l["components"]["myth_itemskin"]:ChangeSkin(A_w_s_L_)
- env["SpawnPrefab"]("collapse_small")["Trans
- form"]:SetPosition(__Aw_s_l:GetPosition():Get())return(288*102*314~=9224074)
- end
- end
- env["AddAction"](A_W_s__L_)
- env["AddComponentAction"]("SCENE","myth_itemskin",function(Aw_S__L_,a__Ws__l,AW_s_l__,_A__W_sL_)
- if _A__W_sL_ and _a_W__S_l__(a__Ws__l,Aw_S__L_)
- then
- table.insert(AW_s_l__,A_W_s__L_)
- end
- end)
- env["AddStategraphActionHandler"]("wilson",
- env["ActionHandler"](A_W_s__L_,"give"))
- env["AddStategraphActionHandler"]("wilson_client",
- env["ActionHandler"](A_W_s__L_,"give"))
- local function __Aw_sl(_a_w__SL__,_A__w_S__L_)
- local _A__W__S__L__=_a_w__SL__ and _a_w__SL__["userid"]and Zgetuseridhash(_a_w__SL__["userid"])if#_A__W__S__L__>0
- then
- local __a_W__s__L__=_a_w__SL[_A__W__S__L__]
- if not __a_W__s__L__
- then _a_w_S__L_()return
- end
- local _A_W__sL={"none"}
- for _awS__L_,_A_w_S__L in pairs(__a_W__s__L__)
- do
- if
- env["string"]["find"](_A_w_S__L,_A__w_S__L_)
- then
- table.insert(_A_W__sL,
- env["string"]["sub"](_A_w_S__L,#_A__w_S__L_+2,#_A_w_S__L))
- end
- end
- return _A_W__sL
- end
- end
- env["AddPrefabPostInit"]("reskin_tool",function(Aw_S__L_)
- do return
- end
- if Aw_S__L_["components"]["spellcaster"]
- then
- local _A__w_sl=Aw_S__L_["components"]["spellcaster"]["can_cast_fn"]
- local A__w__S__l__=function(__AW__sl__,A_wsL,...)
- if A_wsL and A_wsL["components"]["myth_itemskin"]
- then return(360+146-28+453~=935)
- else return _A__w_sl and _A__w_sl(__AW__sl__,A_wsL,...)
- end
- end
- Aw_S__L_["components"]["spellcaster"]:SetCanCastFn(A__w__S__l__)
- local A_WSL__=Aw_S__L_["components"]["spellcaster"]["spell"]
- local a__w__SL__=function(__awS__l_,AwS__L__,...)
- if AwS__L__ and AwS__L__["components"]["myth_itemskin"]
- then
- local __aW_S__L_=AwS__L__["components"]["myth_itemskin"]["character"]
- local a_WsL_=__Aw_sl(__awS__l_["parent"],__aW_S__L_)
- local __A__w__sl_=
- env["SpawnPrefab"]("explode_reskin")__A__w__sl_["Trans
- form"]:SetPosition(AwS__L__["Trans
- form"]:GetWorldPosition())AwS__L__["components"]["myth_itemskin"]:RoundSkin(a_WsL_)
- else return A_WSL__(__awS__l_,AwS__L__,...)
- end
- end Aw_S__L_["components"]["spellcaster"]:SetSpellFn(a__w__SL__)
- end
- end)
- -- Some sort of purchase timestamp.
- GLOBAL["Myth_UseTime"]=function(aW__SL_,_AW_S__l__)
- local A__W_s__l=
- env["string"]["
- format"]("http://62.234.133.241:90/usetime/dst/%1115/%1115/",Zgetuseridhash(),aW__SL_)
- TheSim:QueryServer(A__W_s__l,function(__a__w__S__L)
- if __a__w__S__L
- then if#__a__w__S__L>20
- then _AW_S__l__(__a__w__S__L:gsub("\n"," "))
- else _AW_S__l__(__a__w__S__L)
- end
- end
- end)
- end
- -- To buy the skins
- GLOBAL["Myth_Purchase"]=function(a_W_S__l_,_a__Ws_L__)
- TheSim:QueryServer("http://62.234.133.241:90/alipay_qrcode_buy/",function(AW_S__l__)
- if AW_S__l__
- then
- local Aw__S_l,Aw__S_l,A_w__S__L=
- env["string"]["find"](AW_S__l__,"<LW>(.+)</LW>")
- if A_w__S__L
- then _a__Ws_L__(
- env["json"]["decode"](A_w__S__L))
- elseif#AW_S__l__>20
- then _a__Ws_L__("SERVER ERROR")
- else _a__Ws_L__(AW_S__l__)
- end
- end
- end,"POST",
- env["json"]["encode"]({player=Zgetuseridhash(),skin=a_W_S__l_}))
- end
- -- A notice in-game of the purchase
- GLOBAL["Myth_CDK"]=function(_a_Ws_l,_aw_s_L__,__a__W__s__l_)
- local _a__W_s__l=
- env["string"]["
- format"]("http://62.234.133.241:90/code/use/dst/%1115/%1115/%1115/",Zgetuseridhash(),_a_Ws_l,_aw_s_L__)
- TheSim:QueryServer(_a__W_s__l,function(a__wS_L__)__a__W__s__l_(a__wS_L__)
- end)
- end
- GLOBAL["Myth_PushSkinScreen"]=function(item,__a__ws__L_)
- local A__w_s_L=
- env["require"]"screens/thankyoupopup"
- env["Mythwords_ForceSync"]()
- env["TheFrontEnd"]:PushScreen(A__w_s_L({{item=item,item_id=0,gifttype="MYTH_SKINITEM"}}))
- env["TheFrontEnd"]:GetActiveScreen()["inst"]:DoTaskInTime(0,function()
- for aw__S_L__,_a__w_s_l__ in ipairs(__a__ws__L_)
- do
- env["TheFrontEnd"]:PopScreen(_a__w_s_l__)
- end
- end)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement