1. Oxide 1.18 has been discontinued and is no longer supported. Please do not post requests for Oxide 1.18 plugins or support.
    We recommend upgrading to Oxide 2.0 as able. Plugins can be easily updated to support it as well.
  1. Ramil

    Ramil Scavenger

    OnGetClientMove(HumanController controller, Vector3 origin, int encoded, ushort stateFlags)
    in old Oxide 2.0 this hook work.
    Sorry my lang
    --- Double Post Merged, Nov 25, 2016 ---
    Hooks.HumanController_GetClientMove(this, origin, encoded, stateFlags, info);
     
  2. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    The hook is an internal hook, not meant for plugins. What is it needed for?
     
  3. Ramil

    Ramil Scavenger

    i enable damage Cold and Water Level, this hook need for
    waterLevelLitre
    coreTemperature
    --- Double Post Merged, Nov 25, 2016 ---
    and i use this Hook for Anticheat(bugfix) - double jump, running squatting and more
     
  4. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    I can probably expose it again, I'll take a look tonight.
     
    Ramil likes this.
  5. Ramil

    Ramil Scavenger

    Or create new hook_name this functions
     
  6. xandy3_sjb

    xandy3_sjb Scavenger

    Your problems Ramil, there is nothing to do with this hook, Wulf does not mess with the hook, it is working properly and free of hacks.
     
  7. Ramil

    Ramil Scavenger

    hmm. My problem in fix this hook( old version hook fixing very bad HACK.
    --- Double Post Merged, Nov 26, 2016 ---
    /Потому прошу не переворачивать мое представление хука. хук на бесконечный дамаг по метабализму и я мог сделать
     
  8. xandy3_sjb

    xandy3_sjb Scavenger

    The OnGetClientMove hook, does not interfere in what you want "double jump, running squatting and more", OnGetClientMove is used by hacks teleport, which is currently blocking fraudulent manipulations of this hook.
    If you have discovered any breach to teleport, inform the wulf, for the correct corrections.
     
  9. Ramil

    Ramil Scavenger

    void OnGetClientMoved(HumanController controller, Vector3 origin, int encoded, ushort stateFlags)
    {
    var netuser = controller.netUser;
    var inv = netuser.playerClient.rootControllable.idMain.GetComponent<Inventory>();
    var posx= controller.netUser.playerClient.lastKnownPosition.x;
    var posy= controller.netUser.playerClient.lastKnownPosition.y;
    var posz= controller.netUser.playerClient.lastKnownPosition.z;
    if (float.IsNaN(posx) || float.IsInfinity(posx) || float.IsNaN(posy) || float.IsInfinity(posy) || float.IsNaN(posz) || float.IsInfinity(pos.z))
    {
    controller.netUser.Kick(NetError.ConnectionBanned, true);
    BanList.Add(controller.netUser.userID, controller.netUser.displayName, "Sending bad packets (teleport hack)");
    }
    /////////////
    if (controller.stateFlags.sprint)/////UserClient RunChecker
    {Puts (controller.netUser.displayName + "run")}
    /////////////
    and more.
    This my old plug
     
    Last edited: Nov 27, 2016
  10. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    The entire first part is from Oxide, why are you handling it in a plugin too?
     
  11. Ramil

    Ramil Scavenger

    this old version my plugin. new :
    void IOnGetClientMoved(HumanController controller, Vector3 origin, int encoded, ushort stateFlags)
    {
    var netuser = controller.netUser;
    var inv = netuser.playerClient.rootControllable.idMain.GetComponent<Inventory>();
    var rootControllable = netuser.playerClient.rootControllable;
    Metabolism metabolism = rootControllable.GetComponent<Metabolism>();
    metabolism.coreTemperature=1f;
    if (controller.stateFlags.sprint) {Puts (controller.netUser.displayName + "run")}
    if ((metabolism.waterLevelLitre<=0.32f)&&(metabolism.waterLevelLitre>=0f))
    {
    SendReply(netuser,"Ваш уровень воды "+metabolism.waterLevelLitre);
    }

    if (metabolism.waterLevelLitre<=0f)
    {
    SendReply(netuser,"у вас обезвоживание Ваш уровень воды "+metabolism.waterLevelLitre);
    float healthp = rootCharacter.takeDamage.health+metabolism.waterLevelLitre;
    TakeDamage.HurtSelf(rootCharacter.idMain, rootCharacter.takeDamage.health -healthp);
    }

    ////////
     
  12. xandy3_sjb

    xandy3_sjb Scavenger

    ok,

    @Wulf in Assembly replace objArray
    Code (Text):
    object[] objArray = new object[] { this.netUser, origin, encoded, stateFlags };
    and replace method in rustlegacyCore
    Code (Text):
            [HookMethod("IOnGetClientMove")]
            private object IOnGetClientMove(NetUser netUser, Vector3 pos, int encoded, ushort stateFlags)

    Ramil, After this change your plugin will have the necessary information.
     
  13. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    What is the point of the last 2 arguments? The only change the user is requesting is it to not be internal anymore. Everything else can be handled the way it is.
     
  14. Ramil

    Ramil Scavenger

    stateFlags User status (run, aim, jump and ...)
    object[] objArray = new object[] { this.netUser, origin, encoded, stateFlags };
    Sorry hmm this Assembl dll where exactly?
     
  15. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    The DLL is patched using our patcher, you don't need to edit it manually.
     
  16. Ramil

    Ramil Scavenger

    ok(
    how link patcher for this hook only
    y edit mod for me(
     
  17. Ramil

    Ramil Scavenger

    It looks like pure Hook OnGetClientMove?
     
  18. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    Latest build/snapshot should have the OnPlayerMove(NetUser netUser, Vector3 pos) hook for you to use.
     
  19. Ramil

    Ramil Scavenger

    This hook in new clear oxide ? How view hook sourse ?
    --- Double Post Merged, Dec 1, 2016 ---
    source
     
  20. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    It's in the latest Oxide snapshot/build that you can download. Not sure what you mean by viewing source, but Oxide is open-source on GitHub; DLLs can be decompiled using a .NET decompiler too if you really want to look.