You are not logged in.

  • "R A N T A N P L A N" started this thread

Posts: 378

Occupation: Management

wcf.user.option.userOption53: Ja

  • Send private message

1

Saturday, January 7th 2012, 10:28pm

Bot bug bei Nuclear Dawn?

Servus. Normalerweise sollten ja mit der Methode "fill" die Bots verschwinden wenn echte Spieler kommen, bei Nuclear Dawn klappt das leider nur bedingt, denn es bleiben irgendwie immer 2 Bots über und blockieren mir somit 2 Slots.

In meiner Server.cfg hab ich mir das so angelegt:

Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
14
// BOTS //

// Add a bot to the Consortium team
bot_add_ct 3

// Add a bot to the Empire team
bot_add_emp 3

// Number of bots
bot_quota 6

// [ normal | fill | match ] = If fill, the server will adjust bots to keep N players in the game, where N is bot_quota.
// If 'match', the server will maintain a 1:N ratio of humans to bots. If normal there will be N bots in the game. Where N is bot_quota.
bot_quota_mode fill


Problem dabei ist nun erstmal das es immer 8 Bots sind die dann auf dem Server sind und von diesen 8 Bots verschwinden am Ende wenn der Server voll ist immer nur 6, keine Ahnung woran das liegt. Hat jemand eine Idee? Die Bots bei ND sind halt noch im Beta-Stadium, kann deshalb auch noch ein Bug von denen sein.

This post has been edited 1 times, last edit by "R A N T A N P L A N" (Jan 7th 2012, 10:34pm)


MadMakz

Super Moderator

Posts: 1,878

Location: ~#

wcf.user.option.userOption53: Ja

  • Send private message

2

Sunday, January 8th 2012, 1:22am

mh, hatte ich bislang noch keine probleme mit, zumindest hat mir keiner was gesagt.

mal schnell was gebastelt,

Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#include <sourcemod>

#define PLUGIN_VERSION "1.0.0"

public Plugin:myinfo = 
{
	name = "Bot Quota Kick",
	author = "MadMakz",
	description = "Destroy Bots not respecting the Quota",
	version = PLUGIN_VERSION,
	url = "http://cgx24.com"
};

new Handle:cBotQuota;
new sBotQuota;

public OnPluginStart()
{
	CreateConVar("bqk_version", PLUGIN_VERSION, "Destroy Bots not respecting the Quota", FCVAR_PLUGIN|FCVAR_SPONLY|FCVAR_REPLICATED|FCVAR_NOTIFY);
	cBotQuota = FindConVar("bot_quota");
	
	
}

public OnClientPostAdminCheck()
{	
	if (cBotQuota != INVALID_HANDLE)
	{
		sBotQuota = GetConVarInt(cBotQuota);
		if (GetRealClientCount() >= sBotQuota)
		{
			ServerCommand("bot_kick");
		}
	}
}

stock GetRealClientCount(bool:inGameOnly = true)
{
	new clients = 0;
	for(new i = 1; i <= GetMaxClients(); i++)
	{
		if (((inGameOnly) ? IsClientInGame(i) : IsClientConnected(i)) && !IsFakeClient(i))
		{
			clients++;
		}
	}
	return clients;
}


das müsste alle verbleibenden bots kicken wenn die anzahl echter spieler = bot_quota sind
MadMakz has attached the following files:
  • bqk.sp (978 Byte - 100 times downloaded - latest: May 8th 2025, 1:39am)
  • bqk.smx (2.36 kB - 98 times downloaded - latest: Jun 15th 2025, 3:48pm)

This post has been edited 1 times, last edit by "MadMakz" (Jan 8th 2012, 6:22am)


Impact

Super Moderator

Posts: 1,276

wcf.user.option.userOption53: Nein

  • Send private message

3

Sunday, January 8th 2012, 11:11am

Warnung: Reiner Besserwisserpost

@RANTANPLAN
Wieso machst du bot_add_x, bot_quota fügt diese automatisch hinzu, zumindest bei CSS.

@MadMakz
GetMaxClients() sollte man durch MaxClients ersetzen, wenn man die ConVar hookt spart das eventuell auch etwas ressourcen.

MfG
Impact

  • "R A N T A N P L A N" started this thread

Posts: 378

Occupation: Management

wcf.user.option.userOption53: Ja

  • Send private message

4

Sunday, January 8th 2012, 12:01pm

Warnung: Reiner Besserwisserpost

@RANTANPLAN
Wieso machst du bot_add_x, bot_quota fügt diese automatisch hinzu, zumindest bei CSS.


Das scheint es gewesen zu sein, den jetzt werden nur noch 6 Bots ins Spiel geschickt. Ich hab das so allerdings auch bei TF2 laufen, dort funktioniert es. Hier hab ich jetzt nur bot_quota 6 und scheinbar läuft es so. Jetzt müssten ja eigentlich ab 6 Spielern alle Bots verschwinden, werde ich gleich sehen.

Trotzdem danke für das Plugin :D

MadMakz

Super Moderator

Posts: 1,878

Location: ~#

wcf.user.option.userOption53: Ja

  • Send private message

5

Sunday, January 8th 2012, 2:19pm

@Impact: copy/paste funktion :P

  • "R A N T A N P L A N" started this thread

Posts: 378

Occupation: Management

wcf.user.option.userOption53: Ja

  • Send private message

6

Sunday, January 8th 2012, 4:03pm

Du meinst Guttenbergen xD

Also danke Impact, das war der Fehler, nun verschwinden alle Bots bei 6 menschlichen Spielern, danke.

MadMakz

Super Moderator

Posts: 1,878

Location: ~#

wcf.user.option.userOption53: Ja

  • Send private message

7

Sunday, January 8th 2012, 7:01pm

was mich momentan richtig stört ist das wenn der server zur laufenden runde leer gespielt wird, die nuclear dawn uhr/timer asynchron zum timelimit wird.

daraus resultiert das im meisten fall z.b. end of map vote nicht mehr getriggert wird wenn nach einiger zeit wieder spieler in die gleiche map kommen.

ich habe schon ein workaround geschrieben aber das geht nicht weil mp_restartgame nicht funktioniert. jetzt überlege ich ob ich nicht einfach die ganze map neu lade oder direkt zur nächsten/random wechsel, könnte beim ersten client aber verwirrung stifften wenn er joint und gleich wieder einen "mapwechsel" screen kommt.

aus sicht eines admins ist ND leider noch ein echter horror.

This post has been edited 1 times, last edit by "MadMakz" (Jan 8th 2012, 7:07pm)


  • "R A N T A N P L A N" started this thread

Posts: 378

Occupation: Management

wcf.user.option.userOption53: Ja

  • Send private message

8

Sunday, January 8th 2012, 7:17pm

Also ich find dafür das es erst seit ein paar Monaten draussen ist läuft es schon sehr stabil, bis eben auf das kleine Problem mit dem hohen CPU Verbrauch im Vergleich zu CSS oder TF2.
Das mit dem Timelimit ist mir noch garnicht aufgefallen, meine Maps laufen sowieso alle 6 Stunden lang, bis dahin hat sich die Runde natürlich entschieden und einen End of Map Vote hab ich "noch" nicht.

Ich hoffe das in den nächsten Tagen mal wieder ein neues Update kommt, mit vielleicht neuen Maps :-D

Similar threads