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

unlimited weapons~HELP! cs1.6


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
f1kUsSs
Junior Member
Join Date: Aug 2010
Old 08-20-2010 , 13:03   unlimited weapons~HELP! cs1.6
Reply With Quote #1

Hi guys, my english is bad, so i will be short

I need a plugin that allows me to, when the weapon on the floor (as fy_snow)
it can not "wear out" when players run over and pick up weapons, say 1000 times, to stay for the other players
means that it can not wear

My friend Lucky made this :


PHP Code:
#include <amxmodx> 
#include <cstrike> 
#include <fun> 

public plugin_init() 

    
register_plugin("Nov Plugin""1.0""Lucky"
     
    
register_event("WeapPickup""weaponpickup""be"


public 
weaponpickup(id

    new 
weaponid read_data(1
     
    if(
weaponid != CSW_C4
    { 
        new 
weaponname[64
        
get_weaponname(weaponidweaponname63
         
        
give_item(idweaponname
         
        return 
PLUGIN_HANDLED 
    

    return 
PLUGIN_CONTINUE 

but i have just five or six weapon on the same meat

Thanks!
f1kUsSs is offline
Old 08-20-2010, 19:19
f1kUsSs
This message has been deleted by YamiKaitou. Reason: bump
Old 08-21-2010, 07:56
f1kUsSs
This message has been deleted by f1kUsSs. Reason: sorry :]
platzpatrone
Veteran Member
Join Date: Apr 2007
Location: Germany
Old 08-21-2010 , 08:21   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #2

Quote:
Originally Posted by f1kUsSs View Post
bump?
read the rules on this forums:

dont bump until 2 weeks are passed.


u postet yesterday ur request
and today u postet again, this is too short
and not allowed here ;)
platzpatrone is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-21-2010 , 13:10   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #3

HE-Grenades now supported and all primary weapons are given with full backpack ammo. Now using engine instead of hamsandwich.
PHP Code:
#include <amxmodx>
#include <fakemeta>
#include <cstrike>
#include <engine>
#include <fun>

new const Version[] = "0.2";

//Set g_iMaxPickups to the max number of weapon pickups per player, per weapon, per round.
//Example: Set to 3, a player can only pickup a new AK47 3 times in a round. He can still pickup 
//a dropped AK47 as much as he wants. This prevents the map from getting flooded with weapons 
//if players decide to spam.
const g_iMaxPickups 3;

new 
g_iWeaponPickups33 ][ 31 ];
new 
g_iMaxPlayers;

const 
g_PrimaryWeapons = ( ( << CSW_SCOUT ) | 
             ( 
<< CSW_XM1014 ) | 
             ( 
<< CSW_MAC10 ) |
             ( 
<< CSW_AUG ) |
             ( 
<< CSW_UMP45 ) |
             ( 
<< CSW_SG550 ) |
             ( 
<< CSW_GALIL ) |
             ( 
<< CSW_FAMAS ) |
             ( 
<< CSW_AWP ) |
             ( 
<< CSW_MP5NAVY ) |
             ( 
<< CSW_M249 ) |
             ( 
<< CSW_M3 ) |
             ( 
<< CSW_M4A1 ) |
             ( 
<< CSW_TMP ) | 
             ( 
<< CSW_G3SG1 ) |
             ( 
<< CSW_SG552 ) |
             ( 
<< CSW_AK47 ) |
             ( 
<< CSW_P90 ) );
        
new const 
g_szPrimaryWeapons31 ][] = 
{
    
"",
    
"",
    
"",
    
"weapon_scout",   
    
"weapon_hegrenade",
    
"weapon_xm1014",
    
"",
    
"weapon_mac10",
    
"weapon_aug",
    
"",
    
"",
    
"",
    
"weapon_ump45",
    
"weapon_sg550",
    
"weapon_galil",
    
"weapon_famas",
    
"",
    
"",
    
"weapon_awp",
    
"weapon_mp5navy",
    
"weapon_m249",
    
"weapon_m3",
    
"weapon_m4a1",
    
"weapon_tmp",
    
"weapon_g3sg1",
    
"",
    
"",
    
"weapon_sg552",
    
"weapon_ak47",
    
"",
    
"weapon_p90"
};

new const 
g_iBackPackAmmo[] = 
{
    
0,  
    
52,
    
0,
    
90,
    
1,
    
32,
    
0,
    
100,
    
90,
    
0,
    
120,
    
100,
    
100,
    
90,
    
90,
    
90,
    
100,
    
120,
    
30,
    
120,
    
200,
    
32,
    
90,
    
120,
    
90,
    
2,
    
35,
    
90,
    
90,
    
0,
    
100
};

const 
Offset_PrimaryWeapon 116;
const 
Extra_Offset 5;

#define IsPlayer(%1)    (1<=%1<=g_iMaxPlayers)
#define HasPrimary(%1) (get_pdata_int(%1,Offset_PrimaryWeapon,Extra_Offset))
 
public plugin_init() 
{
    
register_plugin"Unlimited Armoury" Version "bugsy" );
    
    
g_iMaxPlayers get_maxplayers();
    
    
register_logevent"fw_RoundStart" "1=Round_Start" );
    
    
register_touch"armoury_entity""player""fw_TouchWeapon" );
}

public 
fw_RoundStart()
{
    for ( new 
id id <= g_iMaxPlayers id++ )
        
arraysetg_iWeaponPickupsid ] , sizeofg_iWeaponPickups[] ) );
}

public 
fw_TouchWeaponiEnt id )
{    
    static 
szModel25 ] , iWeaponIndex iIsPrimary;
        
    
peviEnt pev_model szModel charsmaxszModel ) );
    
formatexszModel strlenszModel ) - "weapon_%s" szModel] );
    
    
iWeaponIndex GetWeaponIndexszModel );
    
iIsPrimary = ( ( << iWeaponIndex ) & g_PrimaryWeapons );
    
    if ( ( ( !
iIsPrimary && !cs_get_user_bpammoid iWeaponIndex ) ) || ( iIsPrimary && !HasPrimaryid ) ) ) && ( g_iWeaponPickupsid ][ iWeaponIndex ]++ < g_iMaxPickups )  )
    {
        
give_itemid g_szPrimaryWeaponsiWeaponIndex ] );    
        
cs_set_user_bpammoid iWeaponIndex g_iBackPackAmmoiWeaponIndex ] );
    }

    return 
PLUGIN_HANDLED;
}

GetWeaponIndex( const szWeaponName[] )
{
    static 
i;
    
    for ( 
sizeofg_szPrimaryWeapons ) ; i++ )
        if ( 
equalszWeaponName g_szPrimaryWeapons] , 10 ) )
            return 
i;
            
    return 
0;

__________________

Last edited by Bugsy; 08-23-2010 at 21:01.
Bugsy is offline
f1kUsSs
Junior Member
Join Date: Aug 2010
Old 08-21-2010 , 13:59   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #4

Quote:
Originally Posted by Bugsy View Post
PHP Code:
#include <amxmodx>
#include <cstrike>
#include <fun>
#include <fakemeta>
#include <hamsandwich>

new const Version[] = "0.1";

//Set g_iMaxPickups to the max number of weapon pickups per player, per weapon, per round.
//Example: Set to 3, a player can only pickup a new AK47 3 times in a round. He can still pickup 
//a dropped AK47 as much as he wants. This prevents the map from getting flooded with weapons 
//if players decide to spam.

const g_iMaxPickups 3;

new 
g_iWeaponPickups33 ][ 31 ];
new 
g_iMaxPlayers;

new const 
g_szPrimaryWeapons31 ][] = 
{
    
"",
    
"",
    
"",
    
"weapon_scout",   
    
"",
    
"weapon_xm1014",
    
"",
    
"weapon_mac10",
    
"weapon_aug",
    
"",
    
"",
    
"",
    
"weapon_ump45",
    
"weapon_sg550",
    
"weapon_galil",
    
"weapon_famas",
    
"",
    
"",
    
"weapon_awp",
    
"weapon_mp5navy",
    
"weapon_m249",
    
"weapon_m3",
    
"weapon_m4a1",
    
"weapon_tmp",
    
"weapon_g3sg1",
    
"",
    
"",
    
"weapon_sg552",
    
"weapon_ak47",
    
"",
    
"weapon_p90"
};

const 
Offset_PrimaryWeapon 116;
const 
Extra_Offset 5;

#define IsPlayer(%1)    (1<=%1<=g_iMaxPlayers)
#define HasPrimary(%1) (get_pdata_int(%1,Offset_PrimaryWeapon,Extra_Offset))
 
public plugin_init() 
{
    
register_plugin"Unlimited Armoury" Version "bugsy" );
    
    
g_iMaxPlayers get_maxplayers();
    
    
register_logevent"fw_RoundStart" "1=Round_Start" );
    
    
RegisterHamHam_Touch "armoury_entity" "fw_TouchWeapon" );
}

public 
fw_RoundStart()
{
    for ( new 
id id <= g_iMaxPlayers id++ )
        
arraysetg_iWeaponPickupsid ] , sizeofg_iWeaponPickups[] ) );
}

public 
fw_TouchWeaponiEnt id )
{    
    if ( !
IsPlayerid ) || !pev_validiEnt ) )
        return 
HAM_IGNORED;

    static 
szModel25 ] , iWeaponIndex;
        
    if ( !
HasPrimaryid ) )
    {       
        
peviEnt pev_model szModel charsmaxszModel ) );
        
formatszModel strlenszModel ) - "weapon_%s" szModel] );
        
        
iWeaponIndex GetWeaponIndexszModel );
        
        if ( 
g_iWeaponPickupsid ][ iWeaponIndex ]++ < g_iMaxPickups )
            
give_itemid g_szPrimaryWeaponsiWeaponIndex ] );
    }
        
    return 
HAM_SUPERCEDE;
}

GetWeaponIndex( const szWeaponName[] )
{
    static 
i;
    
    for ( 
sizeofg_szPrimaryWeapons ) ; i++ )
        if ( 
equalszWeaponName g_szPrimaryWeapons] , 10 ) )
            return 
i;
            
    return 
0;

this have some bugs..when i dropp 5 or 6 times i can't pick up again that weapon...
f1kUsSs is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-21-2010 , 14:27   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #5

Its not a bug and after 3 times you cannot pick it up anymore; this was done purposely. I assume you cannot read english?

If you want unlimited, do this:

const g_iMaxPickups = 99999;
__________________

Last edited by Bugsy; 08-21-2010 at 14:29.
Bugsy is offline
f1kUsSs
Junior Member
Join Date: Aug 2010
Old 08-21-2010 , 20:28   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #6

yes :] it's work..but can you add unlimited HE ?
i can't pick up he ..pls :]
f1kUsSs is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-21-2010 , 20:34   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #7

Yes I can add nades. I coded the plugin using fy_iceworld and forgot that fy_snow has nades.
__________________
Bugsy is offline
f1kUsSs
Junior Member
Join Date: Aug 2010
Old 08-22-2010 , 05:29   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #8

no xD i need this plugin for surf_ski_2 :]]
which is the code for HE ? :*
f1kUsSs is offline
f1kUsSs
Junior Member
Join Date: Aug 2010
Old 08-22-2010 , 08:49   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #9

sorry for double post :]
every weapon have only 30 / 0 bullets
how can i made 30 / 90 ? pls AND ADD unlimited HE and give me a code ..
THANKS!
f1kUsSs is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-22-2010 , 09:24   Re: unlimited weapons~HELP! cs1.6
Reply With Quote #10

I am away for the weekend, I won't be able to do it until tonight or tomorrow. Be patient.
__________________
Bugsy is offline
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 15:00.


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