This can easily be done using Expression2.
However, this needs the (almost) latest Wire to work. Make sure the server you’re on has the latest wire.
To make it work:
Get the Wire Button Tool. Check the checkbox saying “Output ID”. Make it non-toggle.
Spawn the E2.
Wire “Button” to the Button’s “Out” output.
Wire “ButtonID” to the Button’s “ID” output. (Names of the button’s outputs may be different, can’t remember exactly)
Edit the E2 code, with as many SteamIDs as you want.
@name SteamID Checker
@inputs Button ButtonID
@outputs Out
@persist Allowed:array
if (first()|duped()) {
Allowed:pushString("STEAM_0:0:00000") #Put your steamid here
Allowed:pushString("STEAM_0:0:00000") #Put someone elses steamid here
#Copy the above "Allowed:pushStr....." and paste it as many times as you like.
}
if (Button & ~Button) {
for(I=1,Allowed:count()) {#Loop through all the steamIDs
if (entity(ButtonID) == Allowed:string(I)) { #If the steamID of the player who pushed the button is equal to the steamID currently being checked..
Out = 1 #Set Out to 1
timer("ResetOut",50) #Start a timer.
break #Exit the loop. No need to continue looping through the rest of the IDs when we've already found the one we were looking for.
}
}
}
if (clk("ResetOut")) {Out = 0} #Reset Out back to 0
If you want, I can change it to work with names, or parts of names, if you’d rather have that.
NOTE: Also posted here: http://www.facepunch.com/showthread.php?t=765410&page=7
