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

Solved [L4D2] How to remove melee weapons at the start of the map and safe room


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
caphao1101
Member
Join Date: Aug 2023
Old 04-11-2024 , 11:24   [L4D2] How to remove melee weapons at the start of the map and safe room
Reply With Quote #1

As the title says, can anyone help me remove the melee weapons at the beginning of the map and in the safe room? Specific example: Dead Center map (c1m1) in the game you will see Fireaxe & Crowbar there and I want to delete them. I hope everyone will help me
Thank everyone <3

Last edited by caphao1101; 04-15-2024 at 10:18.
caphao1101 is offline
Silvers
SourceMod Plugin Approver
Join Date: Aug 2010
Location: SpaceX
Old 04-11-2024 , 18:22   Re: [L4D2] How to remove melee weapons at the start of the map and safe room
Reply With Quote #2

Quote:
Originally Posted by little_froy View Post
try
You should add pos[2] += 5.0 or 10.0 before calling the natives because the updated natives L4D_IsPositionIn* in Left4DHooks require line of sight to the nearest NavArea which on certain maps are blocked by a table etc.

You also need to reset entity to -1 before doing the next while loop in plugin start.

Maybe RemoveEntity is safer to use in these instances.
__________________
Silvers is offline
caphao1101
Member
Join Date: Aug 2023
Old 04-12-2024 , 09:32   Re: [L4D2] How to remove melee weapons at the start of the map and safe room
Reply With Quote #3

Quote:
Originally Posted by little_froy View Post
try
Thank you very much little_froy, it works fine on my server
caphao1101 is offline
caphao1101
Member
Join Date: Aug 2023
Old 04-12-2024 , 09:36   Re: [L4D2] How to remove melee weapons at the start of the map and safe room
Reply With Quote #4

Quote:
Originally Posted by Silvers View Post
You should add pos[2] += 5.0 or 10.0 before calling the natives because the updated natives L4D_IsPositionIn* in Left4DHooks require line of sight to the nearest NavArea which on certain maps are blocked by a table etc.

You also need to reset entity to -1 before doing the next while loop in plugin start.

Maybe RemoveEntity is safer to use in these instances.
I don't know what you mentioned but it works fine in my server
caphao1101 is offline
little_froy
Senior Member
Join Date: May 2021
Old 04-12-2024 , 14:29   Re: [L4D2] How to remove melee weapons at the start of the map and safe room
Reply With Quote #5

Quote:
Originally Posted by caphao1101 View Post
Thank you very much little_froy, it works fine on my server
found bug, pickuped melee will disappear after map tratransition, this should fix.

-prevent possible error in late load.
Attached Files
File Type: sp Get Plugin or Get Source (no_saferoom_melee.sp - 31 views - 4.0 KB)

Last edited by little_froy; 04-13-2024 at 18:01.
little_froy is offline
bj88ninjja
New Member
Join Date: Mar 2024
Old 04-13-2024 , 09:44   https://bj88.ninja/
Reply With Quote #6

BJ88 – Địa Điểm Cá Cược Hấp Dẫn Nhất Châu Á 2024
BJ88 chắc chắn đă không c̣n là một cái tên quá xa lạ đối với những anh em có yêu thích bộ môn giải trí trực tuyến. Nhà cái được xem là một trong những thánh địa cá cược hàng đầu hiện nay khi luôn cập nhật và nâng cấp toàn bộ sản phẩm cũng như mang đến cho anh em những phút giây cá cược hấp dẫn. Những thông tin trong bài viết này sẽ cung cấp thêm cho anh em cái nh́n rơ nét hơn về thương hiệu của chúng tôi.
bj88ninjja is offline
caphao1101
Member
Join Date: Aug 2023
Old 04-13-2024 , 11:35   Re: [L4D2] How to remove melee weapons at the start of the map and safe room
Reply With Quote #7

Quote:
Originally Posted by little_froy View Post
found bug, pickuped melee will disappear after map tratransition, this should fix.
Thx bro, i will try
caphao1101 is offline
caphao1101
Member
Join Date: Aug 2023
Old 04-19-2024 , 10:44   Re: [L4D2] How to remove melee weapons at the start of the map and safe room
Reply With Quote #8

Quote:
Originally Posted by little_froy View Post
found bug, pickuped melee will disappear after map tratransition, this should fix.

-prevent possible error in late load.
I tried it and it crashes my plugin and autoexec can you fix it...even though it doesn't say in the log file
caphao1101 is offline
appvipo
New Member
Join Date: Apr 2024
Location: 248 Green Village Rd, Ma
Old 04-22-2024 , 18:15   Re: [L4D2] How to remove melee weapons at the start of the map and safe room
Reply With Quote #9

great
appvipo 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 13:31.


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