Slap

Moved

Total Downloads: 980 - First Release: Nov 14, 2015 - Last Update: Dec 17, 2016

5/5, 4 likes
  1. Wulf

    Wulf Community Admin

    Wulf updated Slap with a new update entry:

    1.0.0

     
  2. Code:
    [Oxide] 07:31 [Info] Loaded plugin Slap v1.0.0 by Wulf/lukespragg
    [Oxide] 07:31 [Debug] ExType: TargetInvocationException
    [Oxide] 07:31 [Error] Failed to call hook 'IOnPlayerChat' on plugin 'HurtworldCore v1.0.0' (InvalidOperationException: Operation is not valid due to the current state of the object)
    [Oxide] 07:31 [Debug] at System.Linq.Enumerable.Single[IPlayer] (IEnumerable`1 source, System.Func`2 predicate, Fallback fallback) [0x00000] in <filename unknown>:0
    at System.Linq.Enumerable.SingleOrDefault[IPlayer] (IEnumerable`1 source) [0x00000] in <filename unknown>:0
    at Oxide.Game.Hurtworld.Libraries.Covalence.HurtworldPlayerManager.FindPlayer (System.String partialName) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.Slap.SlapCommand (IPlayer player, System.String command, System.String[] args) [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
     
    Last edited by a moderator: Sep 15, 2016
  3. Wulf

    Wulf Community Admin

    Looking into it. Appears to be an issue with Oxide, not the plugin though.
     
  4. Wulf

    Wulf Community Admin

    Fixed in the next build of Oxide once available. The issue was with multiple players with a similar name.
     
  5. Cheers.
     
  6. Is this working with the latest oxide build?
     
  7. Wulf

    Wulf Community Admin

    Should be, nothing changed that I am aware of.
     
  8. cheers, last we chatted you said it was an oxide issue and would be fixed with the next update.
     
  9. wulf tried this with hw workd but after 1 use all u see in chat is /slap instead of it working not sure why its doing it can u update please
     
  10. Wulf

    Wulf Community Admin

    Yeah, that was fixed a couple Oxide builds ago and noted in the changeling in the last.

    Tested it, no issues. If your chat commands show in the chat, it sounds like you do not have Oxide installed.
     
  11. i do have it installed it worked once then stopped ill test again maybe oxide needs updating :) thanks wulf
     
  12. Plugin compiles, no error message, but when I try to slap someone it says Player 'name' not not found...used on Oxide build 2.0.2478, also this is being used on Hurtworld.
     
  13. Wulf

    Wulf Community Admin

    What name did you use exactly?
     
  14. I tried it on myself and tried the following sans, Sans, "sans", "Sans"....I just slapped via steam64 and it worked. Very odd, some players can be slapped via name, while other players can't be found.
     
    Last edited by a moderator: Oct 7, 2016
  15. Wulf

    Wulf Community Admin

    Player finding in Oxide is case-sensitive, so if your name starts with "Sans", then it needs to start with a capital "S" in the command.
     
  16. Wulf

    Wulf Community Admin

    Wulf updated Slap with a new update entry:

    1.2.0

     
  17. This is genius.
     
  18. can there be a option for ["YouGotSlapped"] = "{0} slapped you!" the name showing who did the slap?
     
  19. correct russian translation:

    Code:
                // Russian
                lang.RegisterMessages(new Dictionary<string, string>
                {
                    ["CommandUsage"] = "Использование: {0} <имя или id> <amount> (сумма необязательно)",
                    ["Cooldown"] = "Подождите немного, прежде чем снова дать пощечину",
                    ["NotAllowed"] = "У вас нет прав на использование команды «{0}»",
                    ["PlayerNotFound"] = "Игрок «{0}» не найден",
                    ["PlayerSlapped"] = "{0} получил пощечину!",
                    ["YouGotSlapped"] = "Вы получили пощечину!"
                }, this, "ru");
     
    Last edited by a moderator: Dec 18, 2016
  20. Got an error when I slap certain people (works on most people though).. it says the command is not found, and console spits out an error. I believe it's related to special characters in names. PM me on Slack Wulf if you want the SteamID/Player name. Here's the console error:
    Code:
    16:57 [Debug] ExType: TargetInvocationException
    16:57 [Error] Failed to run command 'slap' on plugin 'Slap v1.2.0' (FormatException: Input string was not in a correct format.)
    16:57 [Debug]  at System.String.ParseFormatSpecifier (System.String str, System.Int32& ptr, System.Int32& n, System.Int32& width, System.Boolean& left_align, System.String& format) [0x00000] in <filename unknown>:0
      at System.String.FormatHelper (System.Text.StringBuilder result, IFormatProvider provider, System.String format, System.Object[] args) [0x00000] in <filename unknown>:0
      at System.String.Format (IFormatProvider provider, System.String format, System.Object[] args) [0x00000] in <filename unknown>:0
      at System.String.Format (System.String format, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Game.Rust.Libraries.Covalence.RustPlayer.Message (System.String message, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Game.Rust.Libraries.Covalence.RustPlayer.Reply (System.String message, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.Slap.SlapCommand (IPlayer player, System.String command, System.String[] args) [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
     
    Last edited by a moderator: Dec 17, 2016