Raised This Month: $ Target: $400
 0% 

WeaponS help


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
lordshiva
BANNED
Join Date: Aug 2009
Location: Heaven
Old 09-27-2009 , 03:31   WeaponS help
Reply With Quote #1

if players dont ve Nightvision than only give otherwise dont give bcaz message comes like u already have it

if(!cs_set_user_nvg(client, 1);)

than give

how to code it
lordshiva is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 09-27-2009 , 03:32   Re: WeaponS help
Reply With Quote #2

I don't understand you, where are you from ?
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
lordshiva
BANNED
Join Date: Aug 2009
Location: Heaven
Old 09-27-2009 , 03:41   Re: WeaponS help
Reply With Quote #3

when user spawn they get nightvision @ free of cost.....

whn they already ve it than dont give it...or else if they dont have than give it
lordshiva is offline
lordshiva
BANNED
Join Date: Aug 2009
Location: Heaven
Old 09-27-2009 , 04:28   Re: WeaponS help
Reply With Quote #4

fm_give_item(client, "ammo_338magnum" , "3" );

can someone correct this by giving 30 ammo in mag
lordshiva is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 09-27-2009 , 04:37   Re: WeaponS help
Reply With Quote #5

PHP Code:
/*    Formatright © 2009, ConnorMcLeod

    Free Nvg is free software;
    you can redistribute it and/or modify it under the terms of the
    GNU General Public License as published by the Free Software Foundation.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Free Nvg; if not, write to the
    Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.
*/

#include <amxmodx>
#include <cstrike>
#include <hamsandwich>

#define VERSION "0.0.1"

public plugin_init()
{
    
register_plugin("Free Nvg"VERSION"ConnorMcLeod")

    
RegisterHam(Ham_Spawn"player""Player_Spawn_Post"1)
}

public 
Player_Spawn_Postid )
{
    if( 
is_user_alive(id) && !cs_get_user_nvg(id) )
    {
        
cs_set_user_nvg(id
    }

Quote:
Originally Posted by lordshiva View Post
fm_give_item(client, "ammo_338magnum" , "3" );

can someone correct this by giving 30 ammo in mag
(#include <cstrike>)
cs_set_user_bpammo(id, CSW_AWP, 30)
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Old 09-27-2009, 05:08
humpty
This message has been deleted by humpty.
lordshiva
BANNED
Join Date: Aug 2009
Location: Heaven
Old 09-27-2009 , 05:10   Re: WeaponS help
Reply With Quote #6

yeah +karma for u ConnorMcLeod
ty

y item_nvg is not working instead wht i ve to use and also in cs_set_user_nvg(id) wht i ve to type instead of ID
lordshiva is offline
lordshiva
BANNED
Join Date: Aug 2009
Location: Heaven
Old 09-27-2009 , 16:27   Re: WeaponS help
Reply With Quote #7

did anyone know command for Nightvision

NOT THIS cs_set_user_nvg(id

and other like item_nvg
but its not working
lordshiva is offline
Old 09-28-2009, 03:32
lordshiva
This message has been deleted by lordshiva. Reason: clear cut
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 09-28-2009 , 10:17   Re: WeaponS help
Reply With Quote #8

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

public plugin_init() {
    
register_plugin("Weapons""0.1""Lordshiva");
    
    
RegisterHam(Ham_Spawn"player""FwdPlayerSpawn"1);
}

public 
FwdPlayerSpawn(client) {
    if( 
is_user_alive(client) ) {
        
strip_user_weapons(client)
        
        
give_item(client"weapon_awp");
        
give_item(client"weapon_deagle");
        
give_item(client"weapon_knife");
        
        
cs_set_user_bpammo(clientCSW_AWP 30)
        
cs_set_user_bpammo(clientCSW_DEAGLE35
        if( !
cs_get_user_nvg(client) ) {
            
cs_set_user_nvg(client1);   //....due to this it shows that YOU ALREADY HAVE IT
        
}
        
        if( 
cs_get_user_team(client) == CS_TEAM_CT ) {
            
cs_set_user_defuse(client100205 );
        }
    }

__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!

Last edited by Exolent[jNr]; 09-28-2009 at 11:45.
Exolent[jNr] is offline
lordshiva
BANNED
Join Date: Aug 2009
Location: Heaven
Old 09-28-2009 , 11:36   Re: WeaponS help
Reply With Quote #9

PHP Code:
switch( ( _:cs_get_user_team(client) ) )  LOOSE INDENTATION is CUMING
        

            case 
1: {} 
            case 
2: {cs_set_user_defuse(client100205 );} 
                
        } 
lordshiva is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 09-28-2009 , 11:45   Re: WeaponS help
Reply With Quote #10

It is now properly indented.
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
Old 09-28-2009, 14:42
lordshiva
This message has been deleted by lordshiva. Reason: bumping
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 22:32.


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