OnRentableShopClosed
OxideCarbonApartmentsvoid OnRentableShopClosed(RentableShop rentableShop, bool notify)Works — the game method in this build is the one the hook was written for.
Parameters
- rentableShop
- RentableShop
- notify
- bool
Return value
voidThe return value is ignored — the hook only notifies.
Example
private void OnRentableShopClosed(RentableShop rentableShop, bool notify)
{
Puts("OnRentableShopClosed");
}Works in both Oxide and Carbon: Carbon loads Oxide plugins as is.
Injection point
Rust.opj (Oxide)
void RentableShop.OnShopClosed(bool)
Passes: RentableShop rentableShop, bool notify
WorksReturnBehavior: ContinueArgumentBehavior: AllAssembly-CSharp.dll
Where it is called (this branch's game code)
// …
}
else
{
BasePlayer.RecordToastToPlayOnReconnect(GameTip.Styles.Error, Phrase_ShopClosedNotificationPhrase, ShopOwnerId);
}
}
ShopOwnerId = 0uL;
CancelInvoke(DeductRent);
Interface.CallHook("OnRentableShopClosed", this, notify);
}Sources: Rust.opj from OxideMod/Oxide.Rust (MIT) and hook metadata of the Carbon documentation (MIT). Method code is decompiled from this branch's server.