游戏地址
Vp>|hj po www.fgcq996.com n_3O-X( 那年传奇百区1.76 2tal TLoz)&
@ 找到 lua_State 然后调用下面的函数就能实现功能
$Y5)( 一个跑单狗注意qq1946913194
o.q/O)'V u 游戏账号密码。fanren9527 qq2293307009
QtvY v!
4)1s M=u 搞完演示完,删除好友跑单 $95h2oXt S[7WW$lF --自动寻路Ex
TDd{.8qf function API_AutoMoveEx(mapX, mapY)
.BFYY13H ssr.AutoMoveBegin(mapX, mapY, ssr.GetCurMapData().mapID)
&ZL3{M local inputProxy = global.Facade:retrieveProxy(global.ProxyTable.PlayerInputProxy)
oh$Q6G local pathPoints = inputProxy:GetPathFindPoints()
u|4$+QiD if pathPoints == nil then
;j4?>3 return 0
_E@:O+K end
?_I[,N?@41 return #pathPoints
EvOJ~'2 Y% end
^h{)Gf,+\ Zh_|m#) --自动寻路
L[=a/|)TBV function API_AutoMove(mapX, mapY)
rk)##) ssr.AutoMoveBegin(mapX, mapY, ssr.GetCurMapData().mapID)
271&i local inputProxy = global.Facade:retrieveProxy(global.ProxyTable.PlayerInputProxy)
` AY_2>7 local pathPoints = inputProxy:GetPathFindPoints()
Z!U)I-x& if pathPoints == nil then
F'hHK.tT return 0
-WYAN:s end
!qX_I db\ return #pathPoints
v%fu end
/="~gq@ :O(^w}sle --停止寻路
A45A:hqs function API_AutoMoveEnd()
Ot]Ru,y->+ global.Facade:sendNotification(global.NoticeTable.AutoMoveEnd)
PssMTEf end
wC5ee:u C% 8P=o4lO+ --自动打怪
H@ t'~ZO function API_AutoFight(isAFK)
_6wFba@>/n if isAFK then
:>+s0~ if not IsAFKState() then
JGuN:c$ global.networkCtl:SendMsg(global.MsgType.MSG_CS_AUTOPLAYGAME_REQUEST, 1)
I_A@BnM{I global.Facade:sendNotification(global.NoticeTable.AFKBegin)
N 5 $c]
E end
/~^rr
f else
A'2w>8 if IsAFKState() then
Offu9`DiZ global.networkCtl:SendMsg(global.MsgType.MSG_CS_AUTOPLAYGAME_REQUEST, 2)
y.[Mnj global.Facade:sendNotification(global.NoticeTable.AFKEnd)
e^O(e end
qu|B4?Y/CR end
ij? end
TC<@e<-%Sq P3oI2\)*i function IsAFKState()
zA[0mkC?$ local AutoProxy = global.Facade:retrieveProxy(global.ProxyTable.Auto)
4._(| return AutoProxy:IsAFKState()
|jM4E$
end
?:w1je7 r3>i+i42 --打开自动穿戴
4Z/f@ZD function API_AutoDress()
",!1m7[wF --不抢别人归属
F+@5C:<? global.MMO.SETTING_IDX_NO_ATTACK_HAVE_BELONG =1
s>^dxF!+ global.MMO.SETTING_IDX_AUTO_PUT_IN_EQUIP = 1
/Ml.}7& local ServerOptionsProxy = global.Facade:retrieveProxy(global.ProxyTable.ServerOptionsProxy)
$ aUo aI ServerOptionsProxy._data["autoDress"] = 1
5|1T}Z#; global.ConstantConfig.autousetimes = 0
/tUy3myJ end
VO"("7L 1bH;!
J --强制打开自动挂机拾取
*V+j%^91} function API_AutoPick()
8cA~R- local ItemConfigProxy = global.Facade:retrieveProxy(global.ProxyTable.ItemConfigProxy)
aXL{TD:] local config = ItemConfigProxy.config
ai
{Sa U for k, v in pairs(config) do
x:QgjK --local res = string.gsub(v.pickset, "0", "1")
VZ\B<i v.pickset = v.pickset .. 1
CP6LHkM9 end
"I
Ql Vi end
f"St&q>[s V
=-WYu --获取人物坐标
435;Vns\n function API_GetMapXY()
SCz(5[MZJ return ssr.GetMainPlayerMapPos()
rfq;%C end
0@EwM D_x+:1( --获取人物状态
8HP6+c% function API_GetAction()
c_V;DcZ local player = global.gamePlayerController:GetMainPlayer()
<A#
l
35 local list = global.playerManager.mPlayersInCurrViewField
n(el]_d return player:GetAction()
I}t#%/'YA end
&-mX ,
?]x|Zy --设置宠物状态
,~"$k[M function API_PetSleep(isSleep)
3K_A<j: local SummonsProxy = global.Facade:retrieveProxy(global.ProxyTable.SummonsProxy)
6qp%$>$Vt; if not SummonsProxy:IsAlived() then
wR^ RM(1 return false
qkC/\![@ end
xe*aC if isSleep then
ak;*W SummonsProxy:RequestModeChange(2)
Ovj^IjG-` else
'z$Q rFW SummonsProxy:RequestModeChange(4)
3JVK end
S*n@81Z end
0A( +ZM
d d$
^ ,bL2p --获取人物数据
?`4+cx}n function API_GetGamePlayer()
*<J*S#] local player = global.gamePlayerController:GetMainPlayer()
MX@_=Sp- local list = global.playerManager.mPlayersInCurrViewField
1n@8Kv local person = {}
qs QNjt person["等级"] = player:GetLevel()
,%)6jYHR w person["职业"] = player:GetJobID()
[h,Q Bz person["名字"] = player:GetName()
'z[Sp~I\ person["金币"] = ssr.GetMoneyCountById(1)
ObiT-D?)g person["元宝"] = ssr.GetMoneyCountById(2)
PpgP&;z4
person["绑金"] = ssr.GetMoneyCountById(3)
Dre]AsgiV return person
rf$X>M=G end
%%4t~XC# 3:C oZ function API_GetGamePlayerLevel()
uh?>-
]r` local player = global.gamePlayerController:GetMainPlayer()
}6@pJG return player:GetLevel()
(x3.poSt end
B:+6~&,- O/<K!;(@? --获取周围怪物
|JVk&8
?8 function API_GetMonster()
_~T!9 local list = global.monsterManager.mMonstersInCurrViewField
'CN|'W)g7 local actors = {}
B4mR9HMh for k, v in pairs(list) do
*;Ed*ibf local actor = {}
(e[}/hf6 actor["mID"] = v:GetID()
Q_Gi]M9 actor["mName"] = v:GetName()
t8dm)s[r8 actor["mRace"] = v:GetRace()
IqD_GL)Ms actor["mType"] = v:GetType()
ETXZ?\<a5 actor["mSubType"] = v:GetSubType()
!Uq^7Mw actor["mX"] = v:GetMapX()
smry2*g actor["mY"] = v:GetMapY()
iURk=
*Z= actor["mAction"] = v:GetAction()
E~_]Lfs) actor["mTypeIndex"] = v:GetTypeIndex()
^/U|2'$'>E actor["mAnimationID"] = v:GetAnimationID()
1+U actor["mLv"] = (v.GetLevel and { v:GetLevel() } or { 0 })[1]
m`FNIY actor["mSex"] = (v.GetSexID and { v:GetSexID() } or { 0 })[1]
/, ! B2 actor["mJobID"] = (v.GetJobID and { v:GetJobID() } or { 0 })[1]
jb^N|zb
actor["mHP"] = (v.GetHP and { v:GetHP() } or { 0 })[1]
x(eb5YS actor["mHPMax"] = (v.GetMaxHP and { v:GetMaxHP() } or { 0 })[1]
1SR+m
>pL actor["mMP"] = (v.GetMP and { v:GetMP() } or { 0 })[1]
qIAoA. actor["mMPMax"] = (v.GetMaxMP and { v:GetMaxMP() } or { 0 })[1]
4A2?Uhpy actor["mOwnerID"] = (v.GetOwnerID and { v:GetOwnerID() } or { "" })[1]
o!!yd8~*r actor["mOwnerName"] = (v.GetOwnerName and { v:GetOwnerName() } or { "" })[1]
A$a1(8H actor["mGuildName"] = (v.mGuildName and { v.mGuildName } or { "" })[1]
n2fbp\ I actor["mColor"] = "0xFFFFFF"
x*Y@Q?`>5W if v:GetType() == global.MMO.ACTOR_PLAYER then
$9ky{T?YG local batch_label = global.MMO.HUD_TYPE_BATCH_LABEL
Y2?.}Z O local label_name = global.MMO.HUD_LABEL_NAME
9s_,crq5 local hudName = global.HUDManager:GetHUD(v:GetID(), batch_label, label_name)
#jxe%2'Ot if hudName then
N+y&,N, actor["mColor"] = GetColorHexFromRBG(hudName:getColor())
th&[Nt7 end
;asP4R= end
:.45u}[ table.insert(actors, actor);
\
5,MyB2/` end
~PHB_cyth ?IGVErnJJC return actors
g'|MA~4yB end
aM$W*-
Y >G~R,{6U --遍历周围玩家
,qYJioWX function API_GetPlayer()
>z.<u|r2 local list = global.playerManager.mPlayersInCurrViewField
`2PLWo local actors = {}
Ed
,D8ND for k, v in pairs(list) do
|USX[jm\ local actor = {}
J|w)&bV actor["mID"] = v:GetID()
_z1(y}u} actor["mName"] = v:GetName()
S!sqbLrBn actor["mRace"] = v:GetRace()
$VxA0
=ad actor["mType"] = v:GetType()
b&5lY p"d actor["mSubType"] = v:GetSubType()
F<(i.o( actor["mX"] = v:GetMapX()
Z%x\~)~ actor["mY"] = v:GetMapY()
@`,1: actor["mAction"] = v:GetAction()
Uv4`6>Ix
actor["mTypeIndex"] = v:GetTypeIndex()
HO''&hz actor["mAnimationID"] = v:GetAnimationID()
tT79p.z B actor["mLv"] = (v.GetLevel and { v:GetLevel() } or { 0 })[1]
w#g#8o>' actor["mSex"] = (v.GetSexID and { v:GetSexID() } or { 0 })[1]
]Qe{e3p; actor["mJobID"] = (v.GetJobID and { v:GetJobID() } or { 0 })[1]
4sP2g&