111
This commit is contained in:
@@ -50,4 +50,46 @@ class GameManager extends Base_C_Object {
|
||||
NativePointer("0x8542AD9").writeInt(time);
|
||||
NativePointer("0x8542BDE").writeInt(time);
|
||||
}
|
||||
|
||||
//开启创建鼠标妹
|
||||
function OpenCreateJob_CreatorMage() {
|
||||
Sq_WriteByteArr(S_Ptr("0x81C029F"), [0xf]);
|
||||
}
|
||||
|
||||
//开启获得魔法封印时自动解除魔法封印
|
||||
function OpenRandomAutomaticUnblocking() {
|
||||
Cb_User_Insert_Item_Leave_Func.Rindro <- function(args) {
|
||||
local SUser = User(NativePointer(args[0]).readPointer());
|
||||
local InvenObj = SUser.GetInven();
|
||||
local idx = args.pop();
|
||||
if (idx > 0) {
|
||||
local inven_item = InvenObj.GetSlot(1, idx);
|
||||
local item_id = inven_item.GetIndex();
|
||||
local pvfitem = PvfItem.GetPvfItemById(item_id);
|
||||
//如果是魔法封印装备
|
||||
if (!pvfitem.IsRandomOption()) {
|
||||
return;
|
||||
}
|
||||
local random_option = NativePointer(inven_item.C_Object).add(37);
|
||||
if (random_option.readU32() || random_option.add(4).readU32() || random_option.add(8).readShort()) {
|
||||
return;
|
||||
}
|
||||
NativePointer(inven_item.C_Object).add(37).add(0).writeU8(1);
|
||||
}
|
||||
SUser.SendItemSpace(0);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
//开启自动热重载
|
||||
function OpenHotFix(Path = "/dp_s/MyProject") {
|
||||
print("DP-S开启自动重载脚本功能,重载目录为: " + Path + " .");
|
||||
print("请注意如果你不处于DP-S开发环境,请关闭此功能,以免对性能造成影响");
|
||||
Sq_AutoReload(Path);
|
||||
}
|
||||
}
|
||||
//热重载
|
||||
function _Reload_List_Write_(Path) {
|
||||
sq_RunScript(Path);
|
||||
print("位于 [" + Path + "] 的脚本已重载")
|
||||
}
|
||||
Reference in New Issue
Block a user