1. thats mine ...
    Code:
    if command == "say" then
            if not arg.connection == false then return
            else
               --my stuff Im calling ^^
                return false
            end
        end
     
  2. Wulf

    Wulf Community Admin

    Code:
    if command == "say" then
        if arg.connection then return end
        -- Your mess
        return false
    end
     
  3. changed it plugin is going to be uploaded now ^^
     
  4. Wulf

    Wulf Community Admin

    Regarding your plugin submission: locals locals locals, use them! :p
     
  5. ^^ yea I did, but sometimes I tought I need to use normals. Well im kinda tired though ^^
    Well, next update and next plugins ^^ Oh and I see I forgot to remove my outcommented stuff ^^
    [DOUBLEPOST=1430425039][/DOUBLEPOST]
    one more question to those locals though. Locals are used to keep that variable in that function right? So if I use that Local in my function 1 and I wont be able to use it like that in function 2 without setting it again
     
  6. Locals are limited to the block they are declared in. -> http://www.lua.org/pil/4.2.html
    If you want to use a plugin wide variable set it local to your whole plugin outside of a function.
     
  7. So never use without local? Why is it so important ? ^^
     
  8. Of course you can use global variables if you like to but they can be manipulated by every other plugin because they are globally available to all plugins not only yours.
     
  9. So if I want to have a variable which should be used to work with other plugins, I need to use as global... okay :)
     
  10. Wulf

    Wulf Community Admin

    More of "if I want to have a variable that can be screwed up by other plugins using the same global variable name", then yes, but generally use locals.
     
  11. No, you just offer them a function that returns the values you want them to use.
     
  12. ah well then yeah that can suck. Yeah working with other plugins would work with dataTabels or configfiles better I guess..
     
  13. Wulf

    Wulf Community Admin

    Here is a somewhat cleaner version of what you submitted, with a couple errors fixed, unnecessary global vars removed, config condensed, etc.
     
    Last edited: Jan 30, 2017
  14. Well yea ^^
    I made those extra variables for the configs, because it was easier and quicker for me ^^
    And you renamed some variables..
    And removed the little tables from the config
    and changed globals to locals
    and some more
     
    Last edited by a moderator: Jan 30, 2017
  15. Wulf

    Wulf Community Admin

    Yeah, it was all a bit redundant. There was a lot you added that is just extra bloat.
     
  16. planned to do some of that right after the release anyways so ^^
    [DOUBLEPOST=1430426941][/DOUBLEPOST]
    And, I used the PrefixName and not the fully set Prefix variable at the print command, because it would print out the tags then and won't use them, and that kinda sucks though.
     
  17. Wulf

    Wulf Community Admin

    I'd recommend doing so right away, as the current version will throw errors.
    [DOUBLEPOST=1430426995][/DOUBLEPOST]
    That hasn't changed in what I gave you, read it again.
     
  18. ah yeah sry ^^ seems like I slided to the wrong line while reading
    [DOUBLEPOST=1430428900][/DOUBLEPOST]
    well anyways, with your update it does not print to console anymore... So it seems like it does not work as it should get printed. No error though. Also now you changed it from
    Code:
    if arg.connection then return end
    to
    Code:
    if not arg.connection then return end
     
  19. Wulf

    Wulf Community Admin

    It was printing last I tested. The "if not arg.connection" was to prevent errors on server startup. The server itself will not have a connection, so you'd need to handle that, else just use what I gave you and only change it when sent from a player's F1 console.
     
  20. well just when im using it, I also asked the players, its just not working. its just white like it was. Im using Rusty. Also I think its unneeded to use it from F1 Console anyways, as you need to be ingame to do that and then you can also just chat.
    [DOUBLEPOST=1430429380][/DOUBLEPOST]
    also you are using gloabl.say now, does that just work the same?