装备跨界

This commit is contained in:
2025-12-15 15:02:34 +08:00
parent 374f3673ca
commit 7edd836c63
19 changed files with 875 additions and 35 deletions

View File

@@ -235,7 +235,13 @@ function Lenheart_Each_Fun(obj) {
}
}
getroottable()["LenheartFuncTab"].rawset("Lenheart_EachN", Lenheart_Each_Fun);
function Lenheart_Get_EachObj()
{
Lenheart_Each_Fun(1);
return getroottable().L_Each_Obj;
}
getroottable()["LenheartFuncTab"].rawset("_Lenheart_EachN", Lenheart_Each_Fun);

View File

@@ -529,6 +529,26 @@ function CheackMouseInOldWindows() {
//设定鼠标逻辑
function RunMouseLogic(MousePos_X, MousePos_Y) {
// if (CheackMouseInNewWindows(MousePos_X, MousePos_Y)) {
// //悬停鼠标变更
// Sq_Memory_WriteByteArr(L_sq_I2P(0x110BA8D), [0x90, 0x90, 0x90]);
// //点击头顶图标
// Sq_Memory_WriteByteArr(L_sq_I2P(0xE7220C), [0xEB]);
// //点击NPC打开交互
// Sq_Memory_WriteByteArr(L_sq_I2P(0xE72234), [0xE9, 0xD0, 0x00, 0x00, 0x00, 0x90]);
// //点击仓库交互
// Sq_Memory_WriteByteArr(L_sq_I2P(0xFCF380), [0xC3]);
// //点击邮箱交互
// Sq_Memory_WriteByteArr(L_sq_I2P(0x94FDA0), [0xC3]);
// } else {
// Sq_Memory_WriteByteArr(L_sq_I2P(0x110BA8D), [0x89, 0x5F, 0x48]);
// Sq_Memory_WriteByteArr(L_sq_I2P(0xE7220C), [0x75]);
// Sq_Memory_WriteByteArr(L_sq_I2P(0xE72234), [0x0F, 0x85, 0xCF, 0x00, 0x00, 0x00]);
// Sq_Memory_WriteByteArr(L_sq_I2P(0xFCF380), [0x55]);
// Sq_Memory_WriteByteArr(L_sq_I2P(0x94FDA0), [0x55]);
// }
//解锁鼠标 如果鼠标已处于锁定状态 并且没有悬停在任何窗口上 解锁鼠标
if (R_Mouse.IsLock()) {
//不在任何新窗口上

View File

@@ -429,4 +429,4 @@ function sq_GetCharacterAttribute(address) {
function sq_GetCharacterEquipAttribute(offest, Slot) {
return L_sq_GetCharacterAttribute(offest, Slot);
}
}

View File

@@ -291,7 +291,25 @@ class Rindro_BaseToolClass {
Rindro_Image_GlobalMap[Img].DrawPng(StartIndex + 8, X + Width - LeftTopW, Y + Height - LeftTopH);
}
//品级颜色
function GetRarityColor(rarity) {
switch (rarity) {
case 0:
return sq_RGBA(255, 255, 255, 255);
case 1:
return sq_RGBA(104, 213, 237, 255);
case 2:
return sq_RGBA(179, 107, 254, 255);
case 3:
return sq_RGBA(255, 0, 240, 255);
case 4:
return sq_RGBA(255, 177, 0, 255);
case 5:
return sq_RGBA(255, 102, 102, 255);
case 6:
return sq_RGBA(255, 50, 50, 255);
}
}
}
//获取文字绘制长度
class LenheartTextClass {

View File

@@ -9,6 +9,9 @@ class _Rindro_Hacker {
HookData = null;
NextReturnAddress = null;
CpuContext = null;
constructor() {
HookTable = {};
HookData = {};
@@ -29,6 +32,17 @@ class _Rindro_Hacker {
HookTable.rawset(AddressStr, Controler);
}
}
function _Haker_SetNextReturnAddress(Address) {
local Buffer = "" + Address;
Rindro_Haker.NextReturnAddress = Buffer.slice(Buffer.find("0x") + 2, -1);
}
function _Haker_SetCpuContext(tab) {
Rindro_Haker.CpuContext = tab;
}
//初始化Hacker
if (!(getroottable().rawin("Rindro_Haker"))) Rindro_Haker <- _Rindro_Hacker();
@@ -60,4 +74,5 @@ OnSetCharacter_Control.MarrySystem <- function() {
L_sq_WA(L_sq_RA(L_sq_RA(0x01ADE0CC) + 0x60 + (i * 0x4)) + 0x18, Yosin_14SkillYpos2);
}
}
};
};

View File

@@ -299,6 +299,24 @@ Rindro_Haker.LoadHook(0x67C560, ["pointer", "int", "int", "int", "int", "void"],
});
// getroottable()._11B47C0_OpenWindow_CallBackFunc <- {};
// Rindro_Haker.LoadHook(0x11B47C0, ["pointer", "int", "int"],
// function(args) {
// local Ret = null;
// foreach(Func in _11B47C0_OpenWindow_CallBackFunc) {
// local FRet = Func(args);
// if (FRet != null) Ret = FRet;
// }
// return Ret;
// },
// function(args) {
// return null;
// });
/*
local Flag = L_Sq_CallFunc(0x59E3D0, "bool", FFI_MS_CDECL, ["int", "int", "int", "int"], ReadPath, ReadBuffer, AllocSize, ReadSizeBuffer);
if (Flag) {
@@ -315,12 +333,17 @@ Rindro_Haker.LoadHook(0x67C560, ["pointer", "int", "int", "int", "int", "void"],
// return null;
// },
// function(args) {
// print(NativePointer(L_sq_I2P(args[1])).readUnicodeString());
// if (NativePointer(L_sq_I2P(args[1])).readUnicodeString() == "SQR/../etc/rindro/ancientrelic/ancientrelic.nut") {
// printf("加载AP脚本");
// local str = "function sq_AddFunctionName(appendage)\n{\n}\n print(778899);";
// NativePointer(L_sq_I2P(args[4])).writeInt(str.len());
// NativePointer(L_sq_I2P(args[2])).writeByteArray(str);
// // print(NativePointer(L_sq_I2P(args[1])).readUnicodeString());
// // if (NativePointer(L_sq_I2P(args[1])).readUnicodeString() == "SQR/../etc/rindro/ancientrelic/ancientrelic.nut") {
// // printf("加载AP脚本");
// // local str = "function sq_AddFunctionName(appendage)\n{\n}\n print(778899);";
// // NativePointer(L_sq_I2P(args[4])).writeInt(str.len());
// // NativePointer(L_sq_I2P(args[2])).writeByteArray(str);
// // }
// if (NativePointer(L_sq_I2P(args[1])).readUnicodeString() == "ui/inventory/iteminventorywindow.ui") {
// printf("读取ui");
// print(Rindro_Haker.NextReturnAddress);
// }
// return null;
// });

43
Base/_Tool/HookMap.nut Normal file
View File

@@ -0,0 +1,43 @@
/*
文件名:HookMap.nut
路径:Base/_Tool/HookMap.nut
创建日期:2025-12-12 22:40
文件用途:
*/
//通用HOOK入口函数
function _Hook_Enter_Currency_Func_(args, TableObj) {
local Ret = null;
foreach(Func in TableObj) {
local Buf = Func(args);
if (Buf != null) Ret = Buf;
}
return Ret;
}
//通用HOOK出口函数
function _Hook_Leave_Currency_Func_(args, TableObj) {
local Ret = null;
foreach(Func in TableObj) {
local Buf = Func(args);
if (Buf != null) Ret = Buf;
}
return Ret;
}
//通用HOOK注册全局临时表名
_Hook_Register_Currency_TableName_ <- null;
//通用注册HOOK函数
function _Hook_Register_Currency_Func_(AddressString, ArgRetArr, TableName) {
getroottable().rawset(TableName + "Enter_Func", {});
getroottable().rawset(TableName + "Leave_Func", {});
_Hook_Register_Currency_TableName_ = TableName;
Rindro_Haker.LoadHook(AddressString, ArgRetArr,
function(args) {
return _Hook_Enter_Currency_Func_(args, getroottable()[getroottable()._Hook_Register_Currency_TableName_ + "Enter_Func"]);
},
function(args) {
return _Hook_Leave_Currency_Func_(args, getroottable()[getroottable()._Hook_Register_Currency_TableName_ + "Leave_Func"]);
}
);
}
_Hook_Register_Currency_Func_(0xE6E070, ["int", "int", "int", "int"], "Cb_OpenWindow_");