G'day Gang.
I've spent quite a bit of time reading through
http://wiki.alliedmods.net, as well as studying other people's code here, so I could make my own admin menu additions.
Everything's going along fine, but I've run into a problem and I just can't seem to solve it. I was hoping one of you code guru's could help me out.
I'm sure this is an easy question for someone.
The problem is, when I have a menu which has multiple pages, if I were to select an item from a deeper page than the "top" one, when the menu is redrawn, it goes back to the "top" page. I'd like it to stay at the page it's on.
Now, I'm sure the solution to my problem is to use the functions DisplayMenuAtItem and GetMenuSelectionPosition but I can't for the life of me seem to get them to work how I want.
To demonstrate my problem/question - attached is just a quick sample of code - Most of this code is stripped from Fexxi's "Left 4 Dead Infected Spawner", but I'll use it just to show you what I mean:
This code compiles and runs fine, but if you select:
4. Left 4 Dead
1. Spawn Weapons
9. Next
then select any item there, it will take you back to the main "Spawn Weapons" menu.
(yes, I know that's exactly what I'm telling it to do)
Can someone please inform me exactly how I can make it so that it will stay on that second "weapons" panel, until I press "8. Back"?
Thank you!