[Solved] Menu Problem
Hey All. I decided it was time to sit down to right a menu, so you can change Alliances and Occupation ("Races" and "Classes") in the mod i'm working on. I cannot get the menu to work though. I can see it, it looks fine; it just doesn't DO anything. Not sure what's wrong, I've looked at a few examples and it looks ok to me.
Code:
Now, when I type AllianceMenu in the console, the menu comes up. I hit a key and it goes away, but I don't see any of the debug messages. Also, I created a GetAlliance procedure that tells me a user's alliance. By this check, the alliancevar for that player is never changed. Also, I want this menu to show when a new player logs in for the fisrt time. I added a call to the procedure (ShowAllianceMenu(id)), but it doesn't show when I delete my vault.ini file and log in. Also, I don't see any of the debug messages there. I think it's because the code is run BEFORE you get into the server. Is there a way to catch an event for say, when they join a team? If somebody could answer all that i'd be really grateful :) Thanx |
Quote:
Code:
Code:
Stare at those two lines until you figure it out. |
lol, i am a nub.. never done menus before. Now i'm going to assume that the name you register the menu with has to be the same as the beginning of the menu. Correct? I don't get how that would work though, is it everything until the first ^n? Well, I'll give that a try, hope it works.
|
Basically, AMXX searches for a menu whos text starts with the same substring you registered the menu with..
The longer the substring you use to register the menu, the more unique it will be, so it won't collide with other registered menus.. |
OK, thanx :)
|
Although, one thing that hardly anyone does because they probably neglect to look at the native definition is to assign a menu a title instead of using its starting text.
|
| All times are GMT -4. The time now is 10:02. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.