alliedmodders / sourcemod

SourceMod - Source Engine Scripting and Administration
http://www.sourcemod.net/
981 stars 423 forks source link

ArrayStack A few needed methods #1402

Open Howtoadamin opened 3 years ago

Howtoadamin commented 3 years ago

I just noticed the ArrayStack does not have the methods Peek, Erase or Clear.

So for peeking you basically have to pop and push to get the top value. Same with erasing, you need a variable to store the result from pop just to delete.

PeakKS commented 7 months ago

This should be closed by https://github.com/alliedmodders/sourcemod/pull/2019 and https://github.com/alliedmodders/sourcemod/pull/1676 shouldn't it?

peace-maker commented 7 months ago

I think the erasing part is still open?

PeakKS commented 7 months ago

Oh when I read "Erase or Clear" I was thinking they were the same but yeah it looks like there still needs to be a method for erasing a single entry.