View Single Post
asherkin
SourceMod Developer
Join Date: Aug 2009
Location: OnGameFrame()
Old 02-04-2014 , 14:26   Re: Server crashing since a few days
Reply With Quote #9

Quote:
Originally Posted by WildCard65 View Post
Actually, I find that a bit derpy on how it works(like you need to use setnumattributes to 1 higher then one you going to assign to(ex: 5, you use setnums 6):
(Following link is for a problem of mine, but also portrays derpyness of setnumattributes if you look at it closely): https://forums.alliedmods.net/showthread.php?t=232654
It works just like arrays.

PHP Code:
new foo[5]; 
Gives you 5 "slots" to use, numbered: 0, 1, 2, 3, and 4.

PHP Code:
TF2Items_SetNumAttributes(handle5); 
Gives you 5 "slots" to use, numbered: 0, 1, 2, 3, and 4.

I don't see what's confusing?
__________________
asherkin is offline