Raised This Month: $ Target: $400
 0% 

Crowbar and pistol after respawn


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
BFK_GoNER
Junior Member
Join Date: Feb 2009
Location: Holland
Old 02-17-2009 , 02:25   Crowbar and pistol after respawn
Reply With Quote #1

Hi everybody,

1) I'm trying to code an instant player respawn plugin but I'm running into weird problems already. After intensive web/forum-searching I decided to use the spawn() function, however I noticed strange things - the player always leaves behind a crowbar and a 9mm pistol after respawning:

Screenshot

Is there any explanation to this? How can I avoid spawning extra weapon entities?

2) The second part of my code slays all players and respawns them instantly. The problem is that my server often crashes with "ED_Alloc: no free edicts" error, especially when there is a lot of people playing. Any idea on how to fix this?

Thanks a lot!
BFK_GoNER is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 02-17-2009 , 03:28   Re: Crowbar and pistol after respawn
Reply With Quote #2

1) If you play HLDM I'm remember you respawn immediately. oO

2) Too many entities created at once. Don't know what are the plugins installed but you can change the max allowed. Add -num_edicts 2047 in your command line of your server.
Arkshine is offline
BFK_GoNER
Junior Member
Join Date: Feb 2009
Location: Holland
Old 02-17-2009 , 03:35   Re: Crowbar and pistol after respawn
Reply With Quote #3

1) Well, not really. Unless a player hits the mouse button he can be in "ghost" state for as long as he wants. By the way, any idea how to disable it?

2) Awesome, I'll try that
BFK_GoNER is offline
BFK_GoNER
Junior Member
Join Date: Feb 2009
Location: Holland
Old 02-17-2009 , 06:45   Re: Crowbar and pistol after respawn
Reply With Quote #4

2) Did not work. Setting the key in liblist.gam gave this:

Host_Error: Couldn't get DLL API from .\valve\addons\metamod\dlls\metamod.dll -num_edicts 2047! Screen

Adding the key to the console did not help at all, the game crashed after 20 minutes. Is there a way to get rid of the garbage entities, like the ones that are not used anymore?
BFK_GoNER is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 02-17-2009 , 07:12   Re: Crowbar and pistol after respawn
Reply With Quote #5

How do you start your server ?
Arkshine is offline
BFK_GoNER
Junior Member
Join Date: Feb 2009
Location: Holland
Old 02-17-2009 , 10:31   Re: Crowbar and pistol after respawn
Reply With Quote #6

-- inside the .bat file: --

start hlds -console +map crossfire +maxplayers 32 -num_edicts 2047
BFK_GoNER is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 02-17-2009 , 11:01   Re: Crowbar and pistol after respawn
Reply With Quote #7

Try to up the value more.
Arkshine is offline
BFK_GoNER
Junior Member
Join Date: Feb 2009
Location: Holland
Old 02-17-2009 , 12:17   Re: Crowbar and pistol after respawn
Reply With Quote #8

Whatever I do with the value the maximum number of entities stays the same: 1365 (when there are 32 player slots).

I get this value with global_get() command. Maybe I'm doing something wrong?
BFK_GoNER is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 02-17-2009 , 12:39   Re: Crowbar and pistol after respawn
Reply With Quote #9

Yep, something wrong. The switch name is right.

Should not be : start hlds "-console +map crossfire +maxplayers 32 -num_edicts 2047" ?

Make sure to stop and restart your server.
Arkshine is offline
BFK_GoNER
Junior Member
Join Date: Feb 2009
Location: Holland
Old 02-18-2009 , 05:48   Re: Crowbar and pistol after respawn
Reply With Quote #10

Yeah I did tried that too. Still no effect.
I was thinking since metamod throws the error maybe it's metamod-related or game mod-related. I wish I could test it on cstrike server but I can't.
Any other ideas?
BFK_GoNER 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 17:03.


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