Multi purpose ammobuy alias
Code: Select all
Pattern: ^ammobuy\s?(\w*)\s?(\d*)$ Usage 1: ammobuy type num -- buys num of type Usage 2: ammobuy type -- buys up to ammoUpperLimit of this type Usage 3: ammobuy num -- buys more of last type bought Usage 4: ammobuy -- buys up to ammoUpperLimit of last type bought
Yes, just something definitive to test against later on. You could of set it to nil, false, whatever you want, but I figured that sense it was going to be a number at some point that I would keep it a number throughout, and 0 always tests true in Lua unlike other languages.