Raised This Month: $51 Target: $400
 12% 

AWP War + Shop + Admin Menu


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Counter-Strike        Category:   Gameplay       
Ardonicek
Senior Member
Join Date: Feb 2013
Location: My home
Old 03-25-2013 , 11:52   AWP War + Shop + Admin Menu
Reply With Quote #1

AWP War
Hello, i am new in amxx scripting, and this is my first plugin.
It's called "AWP War".
It contains:
AWP War
Shop
Admin Menu

- AWP War
At each round you will receive:
AWP (Ammo 10/50)
Knife
1x HE
Kevlar
Player menu with: Deagle [-10 HP] | No Footsteps [-5 HP] | 3x HE Grenade [-15 HP] | Speed Knife [-25 HP, -AWP] | Nothing (Exit)


- Shop
You may access it by saying /fragshop (Frag Currency)
------------------------------------
Shop Menu:
+50 Armor [1 Frag]
- 30% Gravity [2 Frags]
USP [2 Frags]
Green Glow [5 Frags]
Reset Score [+2 Deaths]
FAST AWP [10 Frags] [VIP]
+2 Frags [-95HP] [VIP]


- Admin menu
You may access it by saying /awpadmin or type amx_awpadmin into console.
Regular players may view what the menu contains, but only admins can actually press those buttons.
You need: ADMIN Level D [ADMIN_BAN] to use admin menu.
--------------------------------------------------------------------------
Admin Menu:
Knife round [disarms all weapons of all players]
Speed Knife round [disarms all weapons of all players + players have speed 600.0]
HE round [disarms all weapons of all players + gives 150 HE Grenades]
Moon round [Sets server gravity to 0.5 (sv_gravity 400)]
Glow Round [CT = Blue Glow | T = Red Glow]
Reset score of all players [You know what does that mean, no description needed.]
Restart map [uses sv_restart command]

- Summary
It's my very first plugin in amxx, if i am doing anything wrong, just write what i am actually doing wrong and i will try to repair it.
I hope, you will use this on AWP servers.
I don't know how to use register_concmd only for admins, if you know how, post it here. For now, please change the commands in "case x" and register_concmd. Thank you.
Attached Files
File Type: sma Get Plugin or Get Source (awpmod_shop_en.sma - 1328 views - 3.3 KB)
File Type: sma Get Plugin or Get Source (awpmod_menu_en.sma - 1233 views - 6.1 KB)
File Type: sma Get Plugin or Get Source (awpmod_en.sma - 1115 views - 3.6 KB)
__________________
Latest plugin: dHUD Round | Timeleft

Last edited by Ardonicek; 03-25-2013 at 15:56. Reason: Edited "Modification" info to Counter-Strike.
Ardonicek is offline
Send a message via ICQ to Ardonicek Send a message via Skype™ to Ardonicek
oxygen935
Veteran Member
Join Date: Jun 2012
Location: Athens, Greece
Old 03-25-2013 , 12:04   Re: AWP War + Shop + Admin Menu
Reply With Quote #2

hmmm, nice idea, i'll try it right now... thx for releasing...

Also it would better if you add cvars, lang text file or a configuration text where you can make changes...
__________________
Quote:
Originally Posted by quark View Post
You're a genius
Stopped any pawn work cause of university for computer science

Last edited by oxygen935; 03-25-2013 at 12:08.
oxygen935 is offline
Send a message via Skype™ to oxygen935
Ardonicek
Senior Member
Join Date: Feb 2013
Location: My home
Old 03-25-2013 , 12:13   Re: AWP War + Shop + Admin Menu
Reply With Quote #3

Don't worry, i will work on it, feel free to post your ideas.
I need to learn things with cvars, and know how to add lang file, and config.
Don't worry, i will surely add it.
__________________
Latest plugin: dHUD Round | Timeleft
Ardonicek is offline
Send a message via ICQ to Ardonicek Send a message via Skype™ to Ardonicek
FanatikSVK
Member
Join Date: Aug 2012
Location: Slovakia
Old 03-25-2013 , 13:32   Re: AWP War + Shop + Admin Menu
Reply With Quote #4

WOW, NICE!!
__________________
FanatikSVK is offline
Send a message via Skype™ to FanatikSVK
Ardonicek
Senior Member
Join Date: Feb 2013
Location: My home
Old 03-25-2013 , 15:33   Re: AWP War + Shop + Admin Menu
Reply With Quote #5

I wasn't expecting those good replies.
Thank you so much.
/ Working on a register_concmd bug
__________________
Latest plugin: dHUD Round | Timeleft
Ardonicek is offline
Send a message via ICQ to Ardonicek Send a message via Skype™ to Ardonicek
pokemonmaster
princess milk
Join Date: Nov 2010
Location: Somewhere in this world
Old 03-25-2013 , 15:35   Re: AWP War + Shop + Admin Menu
Reply With Quote #6

In awpmod_en.sma

PHP Code:
    if( item == MENU_EXIT )
    {
        
menu_destroy(menu);
    } 

PHP Code:
    if( item == MENU_EXIT )
    {
        
menu_destroy(menu);
        return
    } 
PHP Code:
get_players(playerspnum"a");
if(
is_user_alive(player))
// code 
You shouldn't check if user is alive as you have already filtered it using get_players.

I'm not sure about this, but it would be better to give weapons on Ham_Spawn (my opinion)

Also, you can remove all the menu_destroy natives in the cases and just keep the one at the end of the forward
__________________
اَشْهَدُ اَنْ لَّآ اِلٰهَ اِلَّا اللہُ وَحْدَه لَا شَرِيْكَ لَه وَ اَشْهَدُ اَنَّ مُحَمَّدًا عَبْدُه وَرَسُوْلُه
No longer active in AMXX. Sorry.

Last edited by pokemonmaster; 03-25-2013 at 15:38.
pokemonmaster is offline
Ardonicek
Senior Member
Join Date: Feb 2013
Location: My home
Old 03-25-2013 , 15:56   Re: AWP War + Shop + Admin Menu
Reply With Quote #7

Edited - i'm goin' to sleep, see ya tomorrow xD
Updated the script you said, and some info also.
__________________
Latest plugin: dHUD Round | Timeleft
Ardonicek is offline
Send a message via ICQ to Ardonicek Send a message via Skype™ to Ardonicek
oxygen935
Veteran Member
Join Date: Jun 2012
Location: Athens, Greece
Old 03-25-2013 , 16:09   Re: AWP War + Shop + Admin Menu
Reply With Quote #8

Quote:
Originally Posted by pokemonmaster View Post
You shouldn't check if user is alive as you have already filtered it using get_players.
+1

Quote:
Originally Posted by pokemonmaster View Post
I'm not sure about this, but it would be better to give weapons on Ham_Spawn (my opinion)
I also prefer ham_spawn BUT remember to add if(is_user_connected(id)) cause if you forget this will you get errors like run time error 10: blah blah... and the server will lags
__________________
Quote:
Originally Posted by quark View Post
You're a genius
Stopped any pawn work cause of university for computer science

Last edited by oxygen935; 03-25-2013 at 16:10.
oxygen935 is offline
Send a message via Skype™ to oxygen935
pokemonmaster
princess milk
Join Date: Nov 2010
Location: Somewhere in this world
Old 03-26-2013 , 08:44   Re: AWP War + Shop + Admin Menu
Reply With Quote #9

Spoiler

Spoiler

Spoiler
__________________
اَشْهَدُ اَنْ لَّآ اِلٰهَ اِلَّا اللہُ وَحْدَه لَا شَرِيْكَ لَه وَ اَشْهَدُ اَنَّ مُحَمَّدًا عَبْدُه وَرَسُوْلُه
No longer active in AMXX. Sorry.
pokemonmaster is offline
Ardonicek
Senior Member
Join Date: Feb 2013
Location: My home
Old 03-26-2013 , 08:56   Re: AWP War + Shop + Admin Menu
Reply With Quote #10

Sorry, but the code with if(is_user_alive) is wrong, there must be
Quote:
{
new players[32], player, pnum;
get_players(players, pnum, "a");
for(new i = 0; i < pnum; i++)
{
player = players[i];
if(is_user_alive(player))
{
-----
(Causes compile errors, if i delete it, and only use "is_user_alive" line.
__________________
Latest plugin: dHUD Round | Timeleft

Last edited by Ardonicek; 03-26-2013 at 08:56.
Ardonicek is offline
Send a message via ICQ to Ardonicek Send a message via Skype™ to Ardonicek
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 11:58.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode