mirror of
https://github.com/ineedbots/iw5_bot_warfare.git
synced 2025-09-07 13:17:26 +00:00
Move files
This commit is contained in:
73
raw/scripts/bots_test.gsc
Normal file
73
raw/scripts/bots_test.gsc
Normal file
@@ -0,0 +1,73 @@
|
||||
#include maps\mp\_utility;
|
||||
#include maps\mp\gametypes\_hud_util;
|
||||
#include common_scripts\utility;
|
||||
#include maps\mp\bots\_bot_utility;
|
||||
|
||||
init()
|
||||
{
|
||||
setDvarIfUninitialized( "bots_test", true );
|
||||
|
||||
if (!getDvarInt("bots_test"))
|
||||
return;
|
||||
|
||||
level thread onConnected();
|
||||
level thread onframe();
|
||||
}
|
||||
|
||||
onframe()
|
||||
{
|
||||
for(;;)
|
||||
{
|
||||
wait 0.05;
|
||||
|
||||
if(getDvarInt("developer")) print("time:" + getTime() + " child0:" + getVarUsage(0) + " child1:" + getVarUsage(1) + " notifycount:" + getVarUsage(2));
|
||||
}
|
||||
}
|
||||
|
||||
onConnected()
|
||||
{
|
||||
for (;;)
|
||||
{
|
||||
level waittill("connected", player);
|
||||
|
||||
player thread test();
|
||||
player thread onSpawn();
|
||||
}
|
||||
}
|
||||
|
||||
onSpawn()
|
||||
{
|
||||
self endon("disconnect");
|
||||
|
||||
for (;;)
|
||||
{
|
||||
self waittill("spawned_player");
|
||||
|
||||
self thread spawned();
|
||||
}
|
||||
}
|
||||
|
||||
spawned()
|
||||
{
|
||||
self endon("disconnect");
|
||||
self endon("death");
|
||||
|
||||
wait 0.5;
|
||||
}
|
||||
|
||||
test()
|
||||
{
|
||||
self endon("disconnect");
|
||||
|
||||
for (;;)
|
||||
{
|
||||
wait 0.05;
|
||||
|
||||
if (self is_bot())
|
||||
{
|
||||
}
|
||||
else
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user