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

[L4D2] Shop [v4.5 | 20 March 2022]


Post New Thread Reply   
 
Thread Tools Display Modes
swiftswing1
Member
Join Date: Oct 2020
Old 10-24-2023 , 21:55   Re: [L4D2] Shop [v4.5 | 20 March 2022]
Reply With Quote #151

hi again. when i buy a melee weapon while on secondary slot, all is well. however, when i buy a melee weapon in any other slot (e.g. primary, grenade, medkit), it gives me the "failed to buy" error but i still get melee weapon. also no points are deducted from wallet. anyone else have this issue? thanks.

EDIT: i have found the problem. the shop seems to conflict with this plugin. if you turn off auto-switch on secondary pickup and buy a melee weapon, it will throw you the refund message but still give you the weapon. any possible way to fix this?

Last edited by swiftswing1; 10-25-2023 at 20:55.
swiftswing1 is offline
pan0s
Senior Member
Join Date: Nov 2017
Old 11-01-2023 , 22:58   Re: [L4D2] Shop [v4.5 | 20 March 2022]
Reply With Quote #152

Quote:
Originally Posted by swiftswing1 View Post
hi again. when i buy a melee weapon while on secondary slot, all is well. however, when i buy a melee weapon in any other slot (e.g. primary, grenade, medkit), it gives me the "failed to buy" error but i still get melee weapon. also no points are deducted from wallet. anyone else have this issue? thanks.

EDIT: i have found the problem. the shop seems to conflict with this plugin. if you turn off auto-switch on secondary pickup and buy a melee weapon, it will throw you the refund message but still give you the weapon. any possible way to fix this?
It is because some map may not have the melee, so there is a checking for buying melee.
PHP Code:
            else if(StrEqual(weaponName"weapon_melee"))
            {
                if (
StrContains(weaponNamemeleefalse) == -1)
                {
                       
char playerWeaponName[32];
                       
GetEntPropString(GetPlayerWeaponSlot(client1), Prop_Data"m_strMapSetScriptName"playerWeaponNamesizeof(playerWeaponName));
                    if(
StrEqual(playerWeaponNamemelee))
                    {
                        
isSucceed true;
                    }
                }
            } 
if you don't need the checking, just add
PHP Code:
bool BuyMelee(int client, const char[] meleeint price)
{
    if(!
g_bPointsOn) return false;
    if(
IsSurvivorDeadEx(clientmelee)) return false;

    
bool isSucceed false;
    if (
Checkout(clientmeleepricefalse))
    {

         
isSucceed true//add
         
CheatCommand(client"give"melee); 
__________________

Last edited by pan0s; 11-01-2023 at 23:01.
pan0s is offline
swiftswing1
Member
Join Date: Oct 2020
Old 11-04-2023 , 21:38   Re: [L4D2] Shop [v4.5 | 20 March 2022]
Reply With Quote #153

i'll check it out. thanks for replying.
swiftswing1 is offline
S.A.S
Member
Join Date: Jul 2023
Old 12-17-2023 , 12:27   Re: [L4D2] Shop [v4.5 | 20 March 2022]
Reply With Quote #154

Code:
SourceMod error session started
Exception reported: Client 7 is not in game
Blaming: l4d2_shop.smx
Call stack trace:
ThrowError
Line 700, \scripting\include\pan0s.inc::CPrintToChat
Line 1418, l4d2_shop.sp::KillClient
Line 2939, l4d2_shop.sp::HandleMenuSuicide
Error log file session closed.
S.A.S is offline
Misagi_Maxim
Junior Member
Join Date: Jul 2022
Old 12-29-2023 , 16:20   Re: [L4D2] Shop [v4.5 | 20 March 2022]
Reply With Quote #155

Quote:
Originally Posted by pan0s View Post
Translations:
Please "TR" translation.

Last edited by DarkDeviL; 12-30-2023 at 07:03. Reason: Adjusted full quote to fit the relation to the post.
Misagi_Maxim is offline
lawkmlaw
Junior Member
Join Date: Mar 2016
Old 04-24-2024 , 03:55   Re: [L4D2] Shop [v4.5 | 20 March 2022]
Reply With Quote #156

thanks for sharing









搬屋公司提供專業的搬家服務,涵蓋住宅和商業搬遷。我們的團隊精通安全高效的搬運技巧,保證您的財物安全 無憂。
lawkmlaw 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 07:16.


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