1111
This commit is contained in:
53
CallBack/BuyCeraShopItem/BuyCeraShopItem.md
Normal file
53
CallBack/BuyCeraShopItem/BuyCeraShopItem.md
Normal file
@@ -0,0 +1,53 @@
|
||||
# BuyCeraShopItem 回调函数文档
|
||||
|
||||
**回调说明**:
|
||||
`BuyCeraShopItem`类用于在服务端中持续锻造时的HOOK。
|
||||
|
||||
---
|
||||
|
||||
**注册方法**:
|
||||
- `Cb_Dispatcher_BuyCeraShopItem_useCountDownCoinInFreeCoinDungeonFunc.rawset(Key,Function)`
|
||||
|
||||
**参数**:
|
||||
- `未知对象(C指针)`
|
||||
- `角色对象`
|
||||
- `被购买的道具对象`
|
||||
- `原返回值`
|
||||
|
||||
**特殊说明**:
|
||||
- `如果返回值不为 -99 则返回你要返回的值`
|
||||
- `在此回调中可以对Item对象进行修改操作,并且不需要调用Flush函数`
|
||||
|
||||
|
||||
**例子**:
|
||||
|
||||
```squirrel
|
||||
function Test_Function(C_Point1,SUser,ItemObj,OldRet)
|
||||
{
|
||||
return -99;
|
||||
}
|
||||
Cb_Dispatcher_BuyCeraShopItem_useCountDownCoinInFreeCoinDungeonFunc.rawset("Test", Test_Function);
|
||||
```
|
||||
or
|
||||
```squirrel
|
||||
function Test_Function(C_Point1,SUser,ItemObj,OldRet)
|
||||
{
|
||||
return -99;
|
||||
}
|
||||
Cb_Dispatcher_BuyCeraShopItem_useCountDownCoinInFreeCoinDungeonFunc.Test <- Test_Function;
|
||||
```
|
||||
or
|
||||
```squirrel
|
||||
function Test_Function(C_Point1,SUser,ItemObj,OldRet)
|
||||
{
|
||||
return -99;
|
||||
}
|
||||
Cb_Dispatcher_BuyCeraShopItem_useCountDownCoinInFreeCoinDungeonFunc["Test"] <- Test_Function;
|
||||
```
|
||||
or
|
||||
```squirrel
|
||||
Cb_Dispatcher_BuyCeraShopItem_useCountDownCoinInFreeCoinDungeonFunc.Test <- function (C_Point1,SUser,ItemObj,OldRet)
|
||||
{
|
||||
return -99;
|
||||
};
|
||||
```
|
||||
Reference in New Issue
Block a user