ServerRewards

Moved

Total Downloads: 14,031 - First Release: Mar 2, 2016 - Last Update: Jun 9, 2018

5/5, 61 likes
  1. I cant get the images to work for the life of me. I'm using a smaller image, I'm placing them correctly. When I do "loadimages" in rcon the command runs through but I don't get any type of confirmation. Only about 7 of these have the URL but its basically a Sample to see if I did any of the scripting wrong. No images are loading for the ones I attached URL's too. Is their anyway to manually place the .png into my server to avoid this?

    I get the error code after about 5mins of loading images:

    [BUNDLE] Not Found: assets/content/Generic textures/fulltransparent.tga
     

    Attached Files:

    Last edited by a moderator: May 26, 2016
  2. How can I reset data RP of players? It`s console command or?
     
  3. Removes the players reward profile

    in game - /sr clear <playername>
    console - sr clear <playername>
     
  4. I can clear use 1 command - rp all players ?
     
  5. Hey everyone. So recently a lot of my plugins have stopped working. My server rewards don't work at all. I type the command to bring up the ui (/s) and I get this error:

    ([Oxide] 09:37 [Error] Failed to call hook 'OnPlayerInit' on plugin 'ServerRewards v0.2.29' (NullReferenceException: Object reference not set to an instance of an object))

    Love some help.
     

    Attached Files:

  6. [Oxide] 22:36 [Error] Failed to call hook 'OnPlayerInit' on plugin 'ServerRewards v0.2.29' (NullReferenceException: Obje
    ct reference not set to an instance of an object)
    [Oxide] 22:36 [Debug] at Oxide.Plugins.ServerRewards.ResetTimer (.BasePlayer player, Boolean logIn) [0x00000] in <file
    name unknown>:0
    at Oxide.Plugins.ServerRewards.InitPlayerData (.BasePlayer player) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.ServerRewards.OnPlayerInit (.BasePlayer player) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.ServerRewards.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00000]
    in <filename unknown>:0
    at Oxide.Plugins.CSharpPlugin.InvokeMethod (System.Reflection.MethodInfo method, System.Object[] args) [0x00000] in <f
    ilename unknown>:0
    at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0
    at Oxide.Core.Plugins.Plugin.CallHook (System.String hookname, System.Object[] args) [0x00000] in <filename unknown>:0

    any idea's using TimedExecute could that be causing problems
     
  7. I think its the most recent oxide update that is conflicting with plugins. I only noticed some of my plugins not working after the most recent update
     
  8. First off, great plugin here, very neat stuff!!

    I'm trying to set up a list of "commands" to be purchased. I want these to require certain oxide groups for certain command purchases. Example:

    Purchasing MVP adds players to MVP oxide group, and gives access to fire arrows plugin.
    Purchasing Veteran adds players to Veteran oxide group, and gives access to magiccraft plugin, BUT cannot be purchased until after MVP has been purchased.

    Is this possible via the configs, or would it require the serverrewards plugin to be tweaked?
     
  9. switched hosting and started to get this error in the console:

    [Oxide] 08:21 [Error] Failed to run a 3159.52 timer in 'ServerRewards v0.2.29' (DirectoryNotFoundException: Could not find a part of the path "C:\blah\blah\blah\blah\server\my_server_identity\oxide\logs\ServerRewards_RP_Log.txt".)
    [Oxide] 08:21 [Debug] at System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean anonymous, FileOptions options) [0x00000] in <filename unknown>:0
    at System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share) [0x00000] in <filename unknown>:0
    at (wrapper remoting-invoke-with-check) System.IO.FileStream:.ctor (string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare)
    at System.IO.StreamWriter..ctor (System.String path, Boolean append, System.Text.Encoding encoding, Int32 bufferSize) [0x00000] in <filename unknown>:0
    at System.IO.StreamWriter..ctor (System.String path, Boolean append) [0x00000] in <filename unknown>:0
    at (wrapper remoting-invoke-with-check) System.IO.StreamWriter:.ctor (string,bool)
    at System.IO.File.AppendAllText (System.String path, System.String contents) [0x00000] in <filename unknown>:0
    at ConVar.Server.Log (System.String strFilename, System.String strMessage) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.ServerRewards.AddPoints (UInt64 ID, Int32 amount) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.ServerRewards.CheckForReward (.BasePlayer player) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.ServerRewards.SaveActivePlayer (.BasePlayer player) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.ServerRewards+<ResetTimer>c__AnonStorey2.<>m__0 () [0x00000] in <filename unknown>:0
    at Oxide.Core.Libraries.Timer+TimerInstance.Update () [0x00000] in <filename unknown>:0
    [Oxide] 08:22 [Info] [ServerRewards] Saved player data

    this hosting uses different than original paths to store oxide data. looks like SR do not using oxide.root.json path info at all.
    [DOUBLEPOST=1464940330][/DOUBLEPOST]in my case oxide dir looks like this: Screenshot
    oxide.root.json: Screenshot
     
  10. Hey Everyone.. Getting these weird errors when I try to use the server rewards ingame

    11:36 [Error] Failed to call hook 'OnPlayerInit' on plugin 'ServerRewards v0.2.29' (NullReferenceException: Object reference not set to an instance of an object)

    [Oxide] 11:37 [Error] Failed to call hook 'cmdRewards' on plugin 'ServerRewards v0.2.29' (NullReferenceException: Object reference not set to an instance of an object)

    11:39 [Error] Failed to call hook 'OnPlayerDisconnected' on plugin 'ServerRewards v0.2.29' (KeyNotFoundException: The given key was not present in the dictionary.)

    How do I fix this
    Thanks :)
     
  11. you need to run this command in rcon that I see you have not done
    loadimages
    Here you go I made this for you after you upload it run the above command

    The only thing do make sure your kit name are the same in this file and your kit file they need to be the same this will help with errors
     

    Attached Files:

    Last edited by a moderator: Jun 4, 2016
  12. Your player and referral data have been corrupted somehow, unload the plugin and remove both of those files
    You most likely have the same issue ^^ Check your data files, if any of them only contain the word "null" then something has gone wrong and you will need to delete it

    It would require modification of the plugin, Why not just increase the price of the second on and include both options in it?
    Don't even know where to begin with this lol, the plugin doesn't force a directory so it should just use what ever directory oxide is using
     
  13. Love the new file. Thanks :) But the load images weren't the problem.

    That was the problem. THANK YOU FOR ALL YOUR HELP. :) :) :) :) FINALLY MY SERVER CAN FUNCTION AGAIN :) :D :D :D :p
     
  14. I was not even trying to fix your problem only giving you a working file
     
  15. Alright. Been playing with this all day. I've got the rewards properly added (done via in-game). I then have gone to the data file, made my changes (such as adding a URL) but once I run loadimages, it updates the data file and completely un-does any of my changes. Removes all the URLs I've entered, etc. Have we seen this before? On the latest Oxide version.
     
  16. Make sure you unload the plugin prior to making changes to data files. Leaving them loaded will just restore the data that is currently loaded to memory
     
  17. So unload the plugin, make changes, "loadimages" in console, then restart the plugin?
     
  18. Unload the plugin, upload your modified data files, reload plugin, run command
     
  19. Hm. I'll give that a shot. Thanks.
     
  20. Code:
    (01:41:17) | [Oxide] 01:41 [Error] Failed to call hook 'cmdChangeElement' on plugin 'ServerRewards v0.2.28' (KeyNotFoundException: The given key was not present in the dictionary.)
    (01:41:17) | [Oxide] 01:41 [Debug]   at System.Collections.Generic.Dictionary`2[System.Int32,System.UInt32].get_Item (Int32 key) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.ServerRewards.CreateItemEntry (Oxide.Game.Rust.Cui.CuiElementContainer& container, System.String panelName, System.String itemname, Int32 itemnumber, Int32 amount, Int32 number) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.ServerRewards.ItemElement (.BasePlayer player, Int32 page) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.ServerRewards.cmdChangeElement (.Arg arg) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.ServerRewards.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.CSharpPlugin.InvokeMethod (HookMethod method, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Core.Plugins.Plugin.CallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0