Skocz do zawartości

Witamy w Nieoficjalnym polskim support'cie AMX Mod X

Witamy w Nieoficjalnym polskim support'cie AMX Mod X, jak w większości społeczności internetowych musisz się zarejestrować aby móc odpowiadać lub zakładać nowe tematy, ale nie bój się to jest prosty proces w którym wymagamy minimalnych informacji.
  • Rozpoczynaj nowe tematy i odpowiedaj na inne
  • Zapisz się do tematów i for, aby otrzymywać automatyczne uaktualnienia
  • Dodawaj wydarzenia do kalendarza społecznościowego
  • Stwórz swój własny profil i zdobywaj nowych znajomych
  • Zdobywaj nowe doświadczenia

Dołączona grafika Dołączona grafika

Guest Message by DevFuse
 

Zdjęcie

[forums.alliedmods.net] Extended Commands


  • Nie możesz napisać tematu
  • Zaloguj się, aby dodać odpowiedź
Brak odpowiedzi do tego tematu

#1 Adminek AMXX.PL

    Admin :)

  • Bot

Reputacja: 156
Profesjonalista

  • Postów:7 489
  • Lokalizacja:AMXX.PL
Offline

Napisano 25.04.2012 12:20

What it does:

Provides an API and modules for administrative functions for your servers (Think advanced commands, but without the necessity of all of those disparate commands being in one plugin. If you don't like a set of commands, simply unload them!).
It provides these natives:


PHP Code:

native RegExtendedCommand(Function:command,const String:name[],const String:category[]="misc"); // A short note on categories: They can be anything you want, they will automatically be added to the menus.
native UnRegExtendedCommand(Function:command);
native GetGame();

It also provides these stocks:


PHP Code:

stock bool:IsValidPlayer(i)
stock AddClientsToMenu(Handle:menu,FilterType:filter=filter_all)

And this enums (for the AddClientsToMenu):


PHP Code:

enum FilterType
{
filter_all = 0,
filter_alive,
filter_dead,
filter_unassigned,
filter_spec,
filter_t,
filter_ct
};

These commands:
sm_advmenu - Shows the plugin's primary menu
sm_advitem <item> - Shows that particular command's menu (e.g. !advitem Set player HP). Note: this one was sort of shoehorned in, as you could possibly tell - I'm interested in feedback on it.

Current Modules:

As this was a project that I had dropped a few weeks back due to lack of time, I haven't really added all that many modules to it.
Player Commands:
Set Player HP - Provides a menu to set client HP to 150/125/100/75/50/25.
Respawn Player - Provides a menu to respawn currently dead players
Kill Player - Provides a menu to kill currently living players
War3Source commands:
Heal To Max HP - Provides a menu to heal players to their maximum War3 health
Reset Cooldowns - Provides a menu to reset the cooldowns of any player.

Current Issues:

None to my knowledge, although this plugin has not been thoroughly tested yet.

What it requires:

My Improved Commands plugin: https://forums.allie...ad.php?t=180761
War3Source's extensive include files are required to compile the war3source_commands module.

Future plans:

Currently I took a bit of a lazy approach and only attached admin flags to the menus (and by extension, the commands), I will later correct this with overrideable admin flags per command, but don't have the time to do that small, yet important, change quite yet.

Attached Files Dołączona grafika extended_commands.zip (28.8 KB) Dołączona grafika extended_commands.inc (1.6 KB)

Wyświetl pełny artykuł




Użytkownicy przeglądający ten temat: 0

0 użytkowników, 0 gości, 0 anonimowych