Healer

Moved

Total Downloads: 2,233 - First Release: Oct 17, 2014 - Last Update: Jan 10, 2018

5/5, 7 likes
  1. :(ok

    THX for Info ...
     
  2. not working since last few oxide updates could we get an update please
     
  3. Agree, heal does nothing.
     
  4. its a 2 minute change @Domestos,

    Code:
    // Instead of player.metabolism.health
    player.health = 100;
    
     
  5. So this:

    Code:
    targetPlayer.metabolism.health.value = targetPlayer.metabolism.health.value + amount
    Becomes??
     
  6. Code:
    targetPlayer.health = targetPlayer.health + amount;
     
  7. Wulf

    Wulf Community Admin

    Temporary build compatible with Oxide builds 266+. Above change included.
     

    Attached Files:

  8. Anyone else have a issue with /cure reporting player not found?
     
  9. Wulf

    Wulf Community Admin

    Do the other commands work? All commands would fail if that one fails, as they all use the same player checking function.
     
  10. Bare with me just a minute and I'll check
    [DOUBLEPOST=1430786584][/DOUBLEPOST]It would seem the player checking is broken, all report player not found
     
  11. Wulf

    Wulf Community Admin

    How are you using the commands?
     
  12. /(heal|cure|feed) in-game name and if necessary the amount to heal/feed by
     
  13. Wulf

    Wulf Community Admin

    Do you have an exact example?
     
  14. /heal DeathAngel 100 (I assume 100 would restore 100hp or restore to 100% health) his in-game name is DeathAngel

    EDIT 1: I did try partial name but that doesn't work either

    EDIT 2: As previously mentioned in another thread I'm not totally familiar with the language would I be right in saying this function is checking if "targetPlayer" is the one you are looking at or am I completely wrong?
    Code:
    function PLUGIN:GetTargetPlayer(player, target)
        local targetPlayer
        if not target then
            return player
        end
        local targetPlayer = global.BasePlayer.Find(target)
        if not targetPlayer then
            return false
        else
            return targetPlayer
        end
    end
    EDIT 3: Nevermind I think I answered my own question here "global.BasePlayer.Find(target)" must be global/all players :p

    EDIT 4: Where would I be able to find documentation on the Rust language? I'm actually interested in taking a look into it as I think I'd be able to fix half of the issues I come across myself lol.
     
    Last edited by a moderator: May 5, 2015
  15. Wulf

    Wulf Community Admin

    This plugin's language is Lua, which you can find documentation for via Google. For learning what exists in Rust, grab a .NET decompiler and point it at Rust's Assembly-CSharp.dll.
    [DOUBLEPOST=1430788210][/DOUBLEPOST]The version posted below is tested to be working fine. The only thing not working right now is curing radiation.
     

    Attached Files:

  16. Thanks, I've just found some info HERE this so it'll be a good start, this is going to be interesting coming from SQF, thanks again!
     
  17. For some reason with the cure command i get an error with radiation. Did they change the way radiation value is changed?

    Code:
    File: heal.lua Line: 166 attempt to index field 'radiation' (a string value):
      at NLua.Lua.ThrowExceptionFromError (Int32 oldTop) [0x00000] in <filename unknown>:0
      at NLua.Lua.CallFunction (System.Object function, System.Object[] args, System.Type[] returnTypes) [0x00000] in <filename unknown>:0
      at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (object,object[],System.Exception&)
      at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0
     
  18. Wulf

    Wulf Community Admin

    http://oxidemod.org/threads/heal-feed-and-cure.5778/page-2#post-85507
     
  19. kind of random but heal and cure dont work for me. feed works. they all did and then i added a few more plug ins and now only feed works, any advice?
    Code:
    [6/18/2015 10:10:23 PM] [Oxide] 10:10 PM [Error] Failed to call hook 'ChatCmd' on plugin 'Heal, Feed and Cure'
    File: heal.lua Line: 148 attempt to perform arithmetic on field 'value' (a nil value):
      at NLua.Lua.ThrowExceptionFromError (Int32 oldTop) [0x00000] in <filename unknown>:0
      at NLua.Lua.CallFunction (System.Object function, System.Object[] args, System.Type[] returnTypes) [0x00000] in <filename unknown>:0
      at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (object,object[],System.Exception&)
      at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0
    Edit, got the above error just now
     
    Last edited by a moderator: Jun 26, 2015
  20. How could i add permissions to this so i can add them to a usergroup?

    Thanks,