Raised This Month: $32 Target: $400
 8% 

Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED


Post New Thread Reply   
 
Thread Tools Display Modes
rautamiekka
Veteran Member
Join Date: Jan 2009
Location: Finland
Old 08-14-2017 , 15:36   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #211

Quote:
Originally Posted by Ayman Khaled View Post
as i know it's not matter inside or not.
Re-creating the variable on every iteration ?
__________________
Links to posts I received Karma from:
Big thanks to all who gave Karma
rautamiekka is offline
Send a message via ICQ to rautamiekka Send a message via AIM to rautamiekka Send a message via MSN to rautamiekka Send a message via Yahoo to rautamiekka Send a message via Skype™ to rautamiekka
DevilBoy.eXe
Member
Join Date: Mar 2017
Location: Romania
Old 08-19-2017 , 05:40   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #212

Market have a bug that crash server with this error MSG_ONE AND MSG_UNRELIABLE fix it deroid
__________________

DevilBoy.eXe is offline
Send a message via Yahoo to DevilBoy.eXe Send a message via Skype™ to DevilBoy.eXe
RaZ_HU
Senior Member
Join Date: May 2015
Location: Hungary
Old 08-19-2017 , 16:45   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #213

I would recommend to use defines or const instead of cvars for SQL information, since it is sensitive data and I doubt that someone would like to switch to another SQL server/login during uptime.

You can separate M4A4 and M4A1S type M4 weapons by forcing the silencer on or off.
For example:
PHP Code:
// To plugin_init()
    
RegisterHam(Ham_Weapon_SecondaryAttack"weapon_m4a1" "CM4_SecondaryAttack_Pre" ,  0);


// To WeaponSkin(f) - aka weapon switching
    
if(wid == 22 && silencer[id] == false)
    {
        
cs_set_weapon_silen(iEnt0); // Removes silencer when switching to weapon
        
set_pdata_float(iEnt 47 9999.04); // Blocks attaching when switching to weapon
    
}
    else if(
wid == 22 && silencer[id] == true)
    {
        
cs_set_weapon_silen(iEnt10); // Attaches silencer when switching to weapon
        
return HAM_SUPERCEDE;
    }


// Code that keeps M4s act as they should (silenced or not)
public CM4_SecondaryAttack_PreiM4 )
{
    new 
id get_pdata_cbase(iM4414);
    if(
silencer[id] == false// For M4A4
    
{
        
cs_set_weapon_silen(iM400); // Keeps silencer off
        
set_pdata_float(iM4 47 9999.04); // Prevents attaching the silencer
        
return HAM_SUPERCEDE;
    }
    else if(
silencer[id] == true// For M4A1S
    
{
        
cs_set_weapon_silen(iM410); // Keeps silencer on
        
return HAM_SUPERCEDE;
    }

    return 
HAM_IGNORED;

Futhermore it would be clearer to store rank data like this than separated:
PHP Code:
new const Ranks[][] =
{
    { 
"Silver I"},
    { 
"Silver II"25 },
    { 
"Silver III"100 },
    { 
"Silver IV"250 },
    { 
"Silver Elite"750 },
    { 
"Silver Elite Master"1000 },
    { 
"Gold Nova I"1500 },
    { 
"Gold Nova II"2250 },
    { 
"Gold Nova III"3000 },
    { 
"Gold Nova Master"3900 },
    { 
"Master Guardian I"4900 },
    { 
"Master Guardian II"5900 },
    { 
"Master Guardian Elite"7000 },
    { 
"Distinguished Master Guardian"8500 },
    { 
"Legendary Eagle"10000 },
    { 
"Legendary Eagle Master"15000 },
    { 
"Supreme Master First Class"22000 },
    { 
"The Global Elite"30000 },
    { 
""40000 }
}; 
BTW, you can remove the empty rank with 0 kills since it is pointless if the Silver1 has the same value.


If I am wrong in something just tell me, since I am not an AMXX expert
RaZ_HU is offline
rautamiekka
Veteran Member
Join Date: Jan 2009
Location: Finland
Old 08-20-2017 , 06:02   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #214

Quote:
Originally Posted by RaZ_HU View Post
[..]
PHP Code:
// To WeaponSkin(f) - aka weapon switching
    
if(wid == 22 && silencer[id] == false)
    {
        
cs_set_weapon_silen(iEnt0); // Removes silencer when switching to weapon
        
set_pdata_float(iEnt 47 9999.04); // Blocks attaching when switching to weapon
    
}
    else if(
wid == 22 && silencer[id] == true)
    {
        
cs_set_weapon_silen(iEnt10); // Attaches silencer when switching to weapon
        
return HAM_SUPERCEDE;
    } 
[..]
->
PHP Code:
// To WeaponSkin(f) - aka weapon switching
    
if(wid == 22)
    {
        if(
silencer[id] == false)
        {
            
cs_set_weapon_silen(iEnt0); // Removes silencer when switching to weapon
            
set_pdata_float(iEnt 47 9999.04); // Blocks attaching when switching to weapon
        
}
        else if(
silencer[id] == true)
        {
            
cs_set_weapon_silen(iEnt10); // Attaches silencer when switching to weapon
            
return HAM_SUPERCEDE;
        }
    } 
to avoid unnecessarily checking the same thing multiple times.

The
PHP Code:
== false 
and
PHP Code:
== true 
parts probly can be omitted, no idea with my C++.
__________________
Links to posts I received Karma from:
Big thanks to all who gave Karma
rautamiekka is offline
Send a message via ICQ to rautamiekka Send a message via AIM to rautamiekka Send a message via MSN to rautamiekka Send a message via Yahoo to rautamiekka Send a message via Skype™ to rautamiekka
DevilBoy.eXe
Member
Join Date: Mar 2017
Location: Romania
Old 08-20-2017 , 11:23   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #215

Quote:
Originally Posted by RaZ_HU View Post
I would recommend to use defines or const instead of cvars for SQL information, since it is sensitive data and I doubt that someone would like to switch to another SQL server/login during uptime.

You can separate M4A4 and M4A1S type M4 weapons by forcing the silencer on or off.
For example:
PHP Code:
// To plugin_init()
    
RegisterHam(Ham_Weapon_SecondaryAttack"weapon_m4a1" "CM4_SecondaryAttack_Pre" ,  0);


// To WeaponSkin(f) - aka weapon switching
    
if(wid == 22 && silencer[id] == false)
    {
        
cs_set_weapon_silen(iEnt0); // Removes silencer when switching to weapon
        
set_pdata_float(iEnt 47 9999.04); // Blocks attaching when switching to weapon
    
}
    else if(
wid == 22 && silencer[id] == true)
    {
        
cs_set_weapon_silen(iEnt10); // Attaches silencer when switching to weapon
        
return HAM_SUPERCEDE;
    }


// Code that keeps M4s act as they should (silenced or not)
public CM4_SecondaryAttack_PreiM4 )
{
    new 
id get_pdata_cbase(iM4414);
    if(
silencer[id] == false// For M4A4
    
{
        
cs_set_weapon_silen(iM400); // Keeps silencer off
        
set_pdata_float(iM4 47 9999.04); // Prevents attaching the silencer
        
return HAM_SUPERCEDE;
    }
    else if(
silencer[id] == true// For M4A1S
    
{
        
cs_set_weapon_silen(iM410); // Keeps silencer on
        
return HAM_SUPERCEDE;
    }

    return 
HAM_IGNORED;

Futhermore it would be clearer to store rank data like this than separated:
PHP Code:
new const Ranks[][] =
{
    { 
"Silver I"},
    { 
"Silver II"25 },
    { 
"Silver III"100 },
    { 
"Silver IV"250 },
    { 
"Silver Elite"750 },
    { 
"Silver Elite Master"1000 },
    { 
"Gold Nova I"1500 },
    { 
"Gold Nova II"2250 },
    { 
"Gold Nova III"3000 },
    { 
"Gold Nova Master"3900 },
    { 
"Master Guardian I"4900 },
    { 
"Master Guardian II"5900 },
    { 
"Master Guardian Elite"7000 },
    { 
"Distinguished Master Guardian"8500 },
    { 
"Legendary Eagle"10000 },
    { 
"Legendary Eagle Master"15000 },
    { 
"Supreme Master First Class"22000 },
    { 
"The Global Elite"30000 },
    { 
""40000 }
}; 
BTW, you can remove the empty rank with 0 kills since it is pointless if the Silver1 has the same value.


If I am wrong in something just tell me, since I am not an AMXX expert
Do you know how to make player be able to equip multiple primary and secondary skins? like m4a1 skin and awp skin and ak47 skin in same time?
__________________

DevilBoy.eXe is offline
Send a message via Yahoo to DevilBoy.eXe Send a message via Skype™ to DevilBoy.eXe
LUMiNEO
Junior Member
Join Date: Aug 2017
Old 08-20-2017 , 11:53   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #216

Is it possable to add more than 4 skin?
LUMiNEO is offline
shady101
Member
Join Date: Nov 2014
Location: USA
Old 08-23-2017 , 13:27   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #217

Quote:
Originally Posted by RaZ_HU View Post
I would recommend to use defines or const instead of cvars for SQL information, since it is sensitive data and I doubt that someone would like to switch to another SQL server/login during uptime.

You can separate M4A4 and M4A1S type M4 weapons by forcing the silencer on or off.
For example:
PHP Code:
// To plugin_init()
    
RegisterHam(Ham_Weapon_SecondaryAttack"weapon_m4a1" "CM4_SecondaryAttack_Pre" ,  0);


// To WeaponSkin(f) - aka weapon switching
    
if(wid == 22 && silencer[id] == false)
    {
        
cs_set_weapon_silen(iEnt0); // Removes silencer when switching to weapon
        
set_pdata_float(iEnt 47 9999.04); // Blocks attaching when switching to weapon
    
}
    else if(
wid == 22 && silencer[id] == true)
    {
        
cs_set_weapon_silen(iEnt10); // Attaches silencer when switching to weapon
        
return HAM_SUPERCEDE;
    }


// Code that keeps M4s act as they should (silenced or not)
public CM4_SecondaryAttack_PreiM4 )
{
    new 
id get_pdata_cbase(iM4414);
    if(
silencer[id] == false// For M4A4
    
{
        
cs_set_weapon_silen(iM400); // Keeps silencer off
        
set_pdata_float(iM4 47 9999.04); // Prevents attaching the silencer
        
return HAM_SUPERCEDE;
    }
    else if(
silencer[id] == true// For M4A1S
    
{
        
cs_set_weapon_silen(iM410); // Keeps silencer on
        
return HAM_SUPERCEDE;
    }

    return 
HAM_IGNORED;

Futhermore it would be clearer to store rank data like this than separated:
PHP Code:
new const Ranks[][] =
{
    { 
"Silver I"},
    { 
"Silver II"25 },
    { 
"Silver III"100 },
    { 
"Silver IV"250 },
    { 
"Silver Elite"750 },
    { 
"Silver Elite Master"1000 },
    { 
"Gold Nova I"1500 },
    { 
"Gold Nova II"2250 },
    { 
"Gold Nova III"3000 },
    { 
"Gold Nova Master"3900 },
    { 
"Master Guardian I"4900 },
    { 
"Master Guardian II"5900 },
    { 
"Master Guardian Elite"7000 },
    { 
"Distinguished Master Guardian"8500 },
    { 
"Legendary Eagle"10000 },
    { 
"Legendary Eagle Master"15000 },
    { 
"Supreme Master First Class"22000 },
    { 
"The Global Elite"30000 },
    { 
""40000 }
}; 
BTW, you can remove the empty rank with 0 kills since it is pointless if the Silver1 has the same value.


If I am wrong in something just tell me, since I am not an AMXX expert
would you happen to know anyway to fix the market? Whenever i try putting a key up, it just exits out of the menu and doesn't let me put anything on the market and/or when i cancel one of my items i think.
And possibly make chosen skins stay, no matter how many different types of weapons they are? I believe they don't save.
Is anyone able and willing to do this?

Last edited by shady101; 08-23-2017 at 13:29.
shady101 is offline
frienzko
New Member
Join Date: Sep 2017
Old 09-03-2017 , 15:10   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #218

login and password not entered when entering password
do not write a social media account that I can reach you
frienzko is offline
Ayman Khaled
Senior Member
Join Date: Mar 2017
Location: Palestine
Old 09-03-2017 , 16:50   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #219

do you have a sql db ?
__________________
Ayman Khaled is offline
frienzko
New Member
Join Date: Sep 2017
Old 09-06-2017 , 14:00   Re: Global Offensive Mod 2.15 Beta [LAST UPDATE: 08. 13] *BUG FIXED
Reply With Quote #220

no how do i get
frienzko 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 13:57.


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