ULX

Author Topic: Gun Admin Check  (Read 29591 times)

0 Members and 1 Guest are viewing this topic.

Offline Slayer_NL

  • Newbie
  • *
  • Posts: 13
  • Karma: 0
Re: Gun Admin Check
« Reply #30 on: March 31, 2006, 06:53:46 AM »
Can i put all the weapons in like one folder called Admin SWEPS and then put the steamid's in there too would that work?

Offline Slayer_NL

  • Newbie
  • *
  • Posts: 13
  • Karma: 0
Re: Gun Admin Check
« Reply #31 on: March 31, 2006, 09:45:18 AM »
It's not really working for me. It sees the wepadminlist as a SWEP weapon and when i add my steamid in the list im still not authorized to use the gun.

Offline Golden-Death

  • Hero Member
  • *****
  • Posts: 751
  • Karma: 0
  • Honored Lua Scripter
    • BlueFire
Re: Gun Admin Check
« Reply #32 on: March 31, 2006, 03:50:24 PM »
Just to make sure its proper, could you post the SWEP and the admin list for me?


Offline Slayer_NL

  • Newbie
  • *
  • Posts: 13
  • Karma: 0
Re: Gun Admin Check
« Reply #33 on: April 01, 2006, 02:23:22 AM »
Adminlist:
Code: [Select]
AUTHID1 = "STEAM_0:0:187892";
AUTHID2 = "Steam ID Here";
AUTHID3 = "Steam ID Here";
AUTHID4 = "Steam ID Here";
AUTHID5 = "Steam ID Here";
AUTHID6 = "Steam ID Here";
AUTHID7 = "Steam ID Here";
AUTHID8 = "Steam ID Here";
AUTHID9 = "Steam ID Here";
AUTHID10 = "Steam ID Here";
AUTHID11 = "Steam ID Here";

SWEP(Blackholegun):
Code: [Select]
function onPickup( pickerup )

_OpenScript( "wepadminlist.lua" );
if (_PlayerInfo( pickerup, "networkid" ) == AUTHID1) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID2) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID3) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID4) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID5) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID6) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID7) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID8) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID9) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID10) or
(_PlayerInfo( pickerup, "networkid" ) == AUTHID11) then
     _Msg( "Authorized." )
  else
    _Msg( "No acess!" )
    _ScreenText( pickerup, "You do not have permission to use this weapon",0, 0, 255,0,0,255,1,1,2,1,0)
_PlayerSilentKill( pickerup, 1, true )

  end



end

--[[  ______________________________________________
     |¡!¡!¡!¡!¡!¡     Black Hole Gun    !¡!¡!¡!¡!¡!¡|
     |!¤¡!¡!¡!¤¡!        v. 1.8         ¡!¤¡!¡!¡!¡¤!|
     |¡!¡!¡!¡!¡!¡!¡!¡      By     !¡!¡!¡!¡!¡!¡!¡!¡!¡|
     |!¡!¡!¤¡!¡!¡  TrinitronX (enTity)  !¡!¡!¡¤!¡!¡!|
     |¡!¡!¡!¡!¡!¡      ROBO DONUT       !¡!¡!¡!¡!¡!¡|
     |!¤¡!¡!¡!¤¡¡         and           ¡!¤¡!¡!¡!¡¤!|
     |¡!¡!¡!¡!¡!¡       dssalmon        !¡!¡!¡!¡!¡!¡|
     |¡¤¡!¡!¡¤¡ vector/angle functions by  ¡¤¡!¡!¡¤¡|
     |¡!¡!¤!¡!¡         GeoGriff           ¡!¡!¤!¡!¡|
     |¡¤¡!¡!¡¤¡  gun inspired by NeoSeeker ¡¤¡!¡!¡¤¡|
      ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Feel free to use this, or modify it.. as long as you give the authors credit.  Thanks!
]]

-- global variables that can tweak the effects of the black hole (feel free to change them if wanted)

affectplayers = true; -- whether or not the black hole will suck players in (default true). Set to false to not pull in players.
affectnpcs = true; -- whether or not the black hole will suck in npcs (default true)

-- Shot related settings
local fieldtime = 10; --default is 7 (the amount of time the black hole is in effect for.. note that changing this may offset the black hole's sound effects)
local shotmovetime = 3; --default is 3 (the amount of time the black hole ball can move around)

-- Black hole related settings
blackholeforce = 90000000; --90000000 is default for the black hole's force.  Use less to give it less pull
blackholeouterradius = 300000; --default is 300000 (effects the outer/pulling radius of the black hole)
blackholeinnerradius = 70; --default is 70 (effects the inner deletion/kill radius of the black hole)


Code for the SWEP is to long so i only posted the begin.

Offline Golden-Death

  • Hero Member
  • *****
  • Posts: 751
  • Karma: 0
  • Honored Lua Scripter
    • BlueFire
Re: Gun Admin Check
« Reply #34 on: April 01, 2006, 10:59:10 AM »
Works for me. Try making sure your Steamid is what it is when your ingame. WHen your on singleplayer, it may be UNKNOWN so thats what youd have to put in there.



Offline Slayer_NL

  • Newbie
  • *
  • Posts: 13
  • Karma: 0
Re: Gun Admin Check
« Reply #35 on: April 02, 2006, 12:43:29 AM »
Ok ill try. When not working i'll post again. :P

Offline Slayer_NL

  • Newbie
  • *
  • Posts: 13
  • Karma: 0
Re: Gun Admin Check
« Reply #36 on: April 02, 2006, 05:09:25 AM »
Ok i found out that i missed one number in my STEAMID. I put that number in and it still says No access and i get slayed.

Offline Golden-Death

  • Hero Member
  • *****
  • Posts: 751
  • Karma: 0
  • Honored Lua Scripter
    • BlueFire
Re: Gun Admin Check
« Reply #37 on: April 02, 2006, 09:46:54 AM »
And your steamid that you entered is the exact one that comes up when you type status?


Offline Slayer_NL

  • Newbie
  • *
  • Posts: 13
  • Karma: 0
Re: Gun Admin Check
« Reply #38 on: April 02, 2006, 11:16:48 AM »
Yes i copied it.

Offline Golden-Death

  • Hero Member
  • *****
  • Posts: 751
  • Karma: 0
  • Honored Lua Scripter
    • BlueFire
Re: Gun Admin Check
« Reply #39 on: April 02, 2006, 12:07:45 PM »
Huh... I don't really know. However, when I was testing it, I never had a problem with it not giving access... when it was broken, it always gave access, not vice versa, so there must be something wrong with the steam id list or something


Offline Slayer_NL

  • Newbie
  • *
  • Posts: 13
  • Karma: 0
Re: Gun Admin Check
« Reply #40 on: April 03, 2006, 06:34:23 AM »
Can be, because i have another admin only SWEP script and when i add my id there it doesn't give me access. So I'll try it with my friend his id and see if he get's access.

Offline purplg

  • Newbie
  • *
  • Posts: 1
  • Karma: 0
Re: Gun Admin Check
« Reply #41 on: August 14, 2006, 06:47:49 PM »
I found out the problem with the script.

Well, move your wepadminlist.lua to the GMod9/lua folder, but leave everything else the same. It worked perfectly.

I'm currently using ULX v1.13 if that has anything to do with it. I'm just now starting to teach myself LUA so I don't know much.