ULX

Poll

Was this module useful, and helpful?

Yes :)
59 (93.7%)
No :(
4 (6.3%)

Total Members Voted: 63

Author Topic: Give Weapon Addon [1.08v]  (Read 51591 times)

0 Members and 1 Guest are viewing this topic.

Offline RDGXTECHX

  • Newbie
  • *
  • Posts: 7
  • Karma: 0
Re: Give Weapon Addon
« Reply #30 on: December 04, 2014, 03:03:54 AM »
When you go to the admin tab of the pointshop, you'll be able to give the weapon to the player and then it becomes permanent for them. You would have to set yourself as admin and give yourself the weapons from that tab. That's what I was talking about because there's multiple options like in this photo

http://i.imgur.com/zpyjyF5.jpg


I wanted an option in that section that would be similar to the "give item" button but it would say something like "All Weapons" and the button would only show if the person matched a specific group or if they were an admin.


For example: If I was in a group called Platinum, and I asked an admin for my weapons, they would go to the "admin" tab, click the player's name and right below "take weapon," there would be a button "All Weapons [Platinum]." The same thing would show up if an admin was giving weapons to himself or another admin.


But if I wasn't in that group and I asked an admin, it wouldn't show up because I didn't match the prerequisites. I would like to be able to change these settings though whenever I wanted to. I can do that part in notepad++, I would just need an explanation of the values and the setup to stay consistent with the code.

Offline Bite That Apple

  • Hero Member
  • *****
  • Posts: 858
  • Karma: 416
  • Apple Innovations 2010®
    • Fun 4 Everyone Gaming
Re: Give Weapon Addon
« Reply #31 on: December 05, 2014, 08:46:07 PM »
For example: If I was in a group called Platinum, and I asked an admin for my weapons, they would go to the "admin" tab, click the player's name and right below "take weapon," there would be a button "All Weapons [Platinum]." The same thing would show up if an admin was giving weapons to himself or another admin.


But if I wasn't in that group and I asked an admin, it wouldn't show up because I didn't match the prerequisites. I would like to be able to change these settings though whenever I wanted to. I can do that part in notepad++, I would just need an explanation of the values and the setup to stay consistent with the code.

What you're asking for isn't really similar to your original post. This requires more information, and well a lot more time than I have to do this. You're pretty much asking for a complete makeover on this addon, that is well above my paygrade as well as I'm not the original creator of this addon, so I don't and can't think like him (as well as I have issues looking at other peoples code{I think other people code look too messy and hard to read}). As said previously, I could make a very simple command to remove weapons on players database.

Edit:
After further investigation on this addon, I decided that I'm not going to be able to touch this at all. Because the person who made this decided to make it really complex and complicated database speaking. Instead of a thing called "line separation", he just puts everything in there, and I don't feel like breaking things down in a table, just to remove weapons.. Sorry. On the other hand, it could be really easy and I'm just being lazy.
Quote from: John F. Kennedy 1963
A man may die, nations may rise and fall, but an idea lives on.

Offline RDGXTECHX

  • Newbie
  • *
  • Posts: 7
  • Karma: 0
Re: Give Weapon Addon
« Reply #32 on: December 12, 2014, 04:00:26 PM »
Sorry for the late reply, are you still able to do an add all weapons feature and not the remove all? Or you can't do either because the code is complicated?

If it is possible, but you're unable to do it, could point me in the right direction for setting it up? I've had some experience with databases and some experience with lua. So by table you mean that you need to list out every weapon to be added/removed with that button? Or is there an easier way to read what weapons are in the pointshop and then give them to the player. Then read what's in the database and remove those from the player?

If it helps at all, the sql version is on on this post (no information is on it obviously).
« Last Edit: December 13, 2014, 12:15:55 PM by RDGXTECHX »

An Error Has Occurred!

array_keys(): Argument #1 ($array) must be of type array, null given