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

Execution (Gears of War) 1.5 - 16/09/2009


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Counter-Strike        Category:   Gameplay        Approver:   Hawk552 (427)
JoshGomez
Member
Join Date: Apr 2006
Location: Sweden
Old 02-15-2008 , 20:06   Execution (Gears of War) 1.5 - 16/09/2009
Reply With Quote #1

Execution based on gears of war, a gametype which add health regenerating, downing your enemies and rescuing your teammates before they bleedout.

While downed, the enemies can only HS, stab and nade you. To rescue a friend you have to walk to them and press your use buttom on them.

The person who is downed will bleed, get red screen and get freezed. There is a status icon which indicate when they are downed and also when you regenerating health.

Code:
amx_execution, sv_execution = 1/0
- Turn on and off the plugin.

amx_ex_bleedout, sv_ex_bleedout = Float
- Bleed out time, the time it takes to die.
- Should be higher than 10.0 and lower than 60.0.
amx_ex_regenerate, sv_ex_regenerate = Float
- Health regenerate time.
- Should be higher than 0.2 and lower than 3.0.
amx_ex_heal, sv_ex_heal = Float
- The time it takes to start health regenerating, the time will 
  reset each time you take damage.
- Should be higher than 3.0 and lower than 8.0.

amx_ex_*
- Console commands
sv_ex_*
- Server commands
Version 1.0
- First release
Version 1.1
- Removed module:Engine
- Removed module:Cstrike
- Replaced touch with fm_touch
Version 1.2
- Fixed the broken pcvar's
Version 1.3
- More headshot blood when downed
- Replaced [set|get]_user_health
- Temporary fix for downed
Version 1.4
- Fixed critical bugs
- Less screen shake
Version 1.5
- Fixed minor bugs
- Fixed New Round bug
- Fixed errors from bots
- Less sound clashes
- Removed silent sound in the wav files
- Changed cvar commands
Attached Files
File Type: txt execution.txt (364 Bytes, 1260 views)
File Type: zip sound.zip (583.0 KB, 1108 views)
File Type: sma Get Plugin or Get Source (execution.sma - 2095 views - 15.9 KB)

Last edited by JoshGomez; 09-16-2009 at 11:50. Reason: New Version
JoshGomez is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 02-15-2008 , 20:14   Re: Execution 1.0 - 16/02/08
Reply With Quote #2

sounds good.
attach files here, and attach the .sma separately so the "Get Plugin" option will come into effect
also, you cannot upload .amxx files since the UAIO incident
i suggest a .zip for sounds, attach the .sma, attach the lang file, and just have installation instructions on your first post.

EDIT: also, seeing as you are using cstrike module, change the Modification to Counter-Strike
o, and change the category, because this is a gameplay type plugin, not admin commands
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
JoshGomez
Member
Join Date: Apr 2006
Location: Sweden
Old 02-15-2008 , 20:20   Re: Execution 1.0 - 16/02/08
Reply With Quote #3

Oh, thanks. I will attach the files then.
JoshGomez is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 02-15-2008 , 21:00   Re: Execution (Gears of War) 1.0 - 16/02/08
Reply With Quote #4

- require_module() is depreciated since AMX Mod X autoloads the necessary module.

- uhh ? Just use pcvar. What's the point to use [set|get]_cvar_*() too ?
Code:
cvar_execution=register_cvar("ex_execution","1"); // [..] set_cvar_num("ex_execution",1); set_pcvar_num(cvar_execution,1);
- Since you are using fakemeta, you can remove cstrike requirement:
cs_get_weapon_id() replaced by a macro for example :

Code:
#define OFFSET_WEAPONTYPE 43 #define LINUX_EXTRAOFFSET 4 #define cs_get_weapon_id(%1) get_pdata_int( %1, OFFSET_WEAPONTYPE, LINUX_EXTRAOFFSET )
cs_get_user_team() replaced by get_user_team()
- You can also remove engine requirement. Just use FM_Touch forward instead of register_touch()


That's all for my suggestions for the moment.
__________________
Arkshine is offline
JoshGomez
Member
Join Date: Apr 2006
Location: Sweden
Old 02-15-2008 , 21:12   Re: Execution (Gears of War) 1.0 - 16/02/08
Reply With Quote #5

I see, I don't understand the OFFSET thing, but I can fix the other suggestions you made.

get_pdata_int( %1, OFFSET_WEAPONTYPE, LINUX_EXTRAOFFSET ) almost same as cs_get_weapon_id(%1) and %1 are the index?

And with the cvar I tought it looks much better if you for exemple type ex_execution in the console then you know if the plugin are on or off.

Last edited by JoshGomez; 02-15-2008 at 21:14.
JoshGomez is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 02-15-2008 , 21:24   Re: Execution (Gears of War) 1.0 - 16/02/08
Reply With Quote #6

It's a macro. I've wrote 'cs_get_weapon_id' but you write what you want, like GetWeaponID(). %1 is the player's index. ( You can see the source of this function. cstrike.cpp / cstrike.h )

Quote:
And with the cvar I tought it looks much better if you for exemple type ex_execution in the console then you know if the plugin are on or off.
I don't understand... *_pcvar_* or *_cvar* do the same thing, except using pcvar is a lot better.
__________________

Last edited by Arkshine; 02-15-2008 at 21:26.
Arkshine is offline
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 02-15-2008 , 21:29   Re: Execution (Gears of War) 1.0 - 16/02/08
Reply With Quote #7

Quote:
Originally Posted by arkshine View Post
I don't understand... *_pcvar_* or *_cvar* do the same thing, except using pcvar is a lot better.
To expand on this, *_cvar_* has to search through every single cvar until it finds the one it is looking for. *_pcvar_* goes straight to the cvar it wants and doesn't have to search.
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 02-15-2008 , 21:35   Re: Execution (Gears of War) 1.0 - 16/02/08
Reply With Quote #8

You can read a more long explanation by Twilight Suzuka here : http://forums.alliedmods.net/showthr...371#post550371
__________________
Arkshine is offline
JoshGomez
Member
Join Date: Apr 2006
Location: Sweden
Old 02-16-2008 , 06:24   Re: Execution (Gears of War) 1.0 - 16/02/08
Reply With Quote #9

But if you update the pcvar the cvar won't change.

I have remove the engine & and cstrike module now, I can't get block jump to work.
Code:
public fm_cmd_start(id,uc_handle,seed) {     if((get_pcvar_num(cvar_execution) != 1) || (!is_user_alive(id)))     {         return FMRES_IGNORED;     }       new button = get_uc(uc_handle,UC_Buttons);         if(g_player_downed[id])     {         if(button & IN_ATTACK)         {             button &= ~IN_ATTACK;             set_uc(uc_handle,UC_Buttons,button);         }                 if(button & IN_ATTACK2)         {             button &= ~IN_ATTACK2;             set_uc(uc_handle,UC_Buttons,button);         }                 if(button & IN_JUMP)         {             button &= ~IN_JUMP;             set_uc(uc_handle,UC_Buttons,button);         }     }         if(button & IN_USE)     {         g_player_use[id] = true;     }     else if(button & ~IN_USE)     {         g_player_use[id] = false;     }         return FMRES_HANDLED; }

Last edited by JoshGomez; 02-16-2008 at 07:27.
JoshGomez is offline
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 02-16-2008 , 10:14   Re: Execution (Gears of War) 1.0 - 16/02/08
Reply With Quote #10

Quote:
Originally Posted by JoshGomez View Post
But if you update the pcvar the cvar won't change.
Wrong. If you update using a pcvar function, the cvar changes

PHP Code:
new amx_test register_cvar("amx_test""5");
set_pcvar_num(amx_test2); 
The above does the same thing as below, it is just the above is much quicker doing it.

PHP Code:
register_cvar("amx_test""5");
set_cvar_num("amx_test"2); 
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
Reply


Thread Tools
Display Modes

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 19:02.


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