[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4787: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4789: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4790: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4791: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
InsideQC Forums • View topic - tutorbot and teamplay..

tutorbot and teamplay..

Discuss programming in the QuakeC language.

Moderator: InsideQC Admins

tutorbot and teamplay..

Postby drm_wayne » Thu Jul 25, 2013 10:39 am

User avatar
drm_wayne
 
Posts: 232
Joined: Sat Feb 11, 2012 5:47 pm

Re: tutorbot and teamplay..

Postby r00k » Thu Jul 25, 2013 4:13 pm

r00k
 
Posts: 1111
Joined: Sat Nov 13, 2004 10:39 pm

Re: tutorbot and teamplay..

Postby drm_wayne » Thu Jul 25, 2013 4:21 pm

thx i will take a look...
this is one of the things i still cant do lol...
I can code almost everything in qc i want, but when it comes to teamplay stuff im basicially stuck :(
User avatar
drm_wayne
 
Posts: 232
Joined: Sat Feb 11, 2012 5:47 pm

Re: tutorbot and teamplay..

Postby r00k » Thu Jul 25, 2013 4:32 pm

r00k
 
Posts: 1111
Joined: Sat Nov 13, 2004 10:39 pm

Re: tutorbot and teamplay..

Postby drm_wayne » Thu Jul 25, 2013 4:39 pm

User avatar
drm_wayne
 
Posts: 232
Joined: Sat Feb 11, 2012 5:47 pm

Re: tutorbot and teamplay..

Postby r00k » Thu Jul 25, 2013 6:16 pm

im not sure why u need to create a team of bots with only 1 human player?
if thats what u want u just need to create a loop 1 to maxteamsize - 1
spawn a bot entity and setmodel skin etc each iteration

im typing this on my phone so its kinda vague
r00k
 
Posts: 1111
Joined: Sat Nov 13, 2004 10:39 pm

Re: tutorbot and teamplay..

Postby ceriux » Thu Jul 25, 2013 6:17 pm

arent you only changing the color mapping of the bots? not the model ?
User avatar
ceriux
 
Posts: 2230
Joined: Sat Sep 06, 2008 3:30 pm
Location: Indiana, USA

Re: tutorbot and teamplay..

Postby drm_wayne » Fri Jul 26, 2013 12:35 pm

well the bots should at least work offline for singleplayer dm...
User avatar
drm_wayne
 
Posts: 232
Joined: Sat Feb 11, 2012 5:47 pm

Re: tutorbot and teamplay..

Postby frag.machine » Fri Jul 26, 2013 2:25 pm

I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
User avatar
frag.machine
 
Posts: 2120
Joined: Sat Nov 25, 2006 1:49 pm

Re: tutorbot and teamplay..

Postby r00k » Fri Jul 26, 2013 5:38 pm

setmodel wont precache you know
best to precache in world spawn i assumed he had those
ive forgotten the diff between setmodel, self.mdl = , and self.modelindex =.
i thought they all just changed the ents model but in different ways but same result.
r00k
 
Posts: 1111
Joined: Sat Nov 13, 2004 10:39 pm

Re: tutorbot and teamplay..

Postby Spike » Fri Jul 26, 2013 6:00 pm

setmodel looks up the name->modelindex
sets the modelindex to that lookup result
sets the model string to match.
sets the entity's mins+maxs (QW: only on a "*.bsp" model as non.bsp models are not loaded on the server)
relinks the entity (like setorigin) (including settting absmin, absmax, size, and checking which pvs leafs the entity is inside, as well as updating the physics kd tree thing, thus you will likely want to avoid calling it within touch functions).

.modelindex is used for bsp/bbox collisions, and is also used for networking. the check to see if the entity is actually potentially visible uses .model as an early-out clause however. clear either and the entity will not be drawn.

.mdl is merely a backup for .model, so that the entity can get the proper .model field again once a grabbed item respawns. that's its typical use. it means nothing to the engine.
.
Spike
 
Posts: 2914
Joined: Fri Nov 05, 2004 3:12 am
Location: UK

Re: tutorbot and teamplay..

Postby frag.machine » Fri Jul 26, 2013 11:53 pm

I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
User avatar
frag.machine
 
Posts: 2120
Joined: Sat Nov 25, 2006 1:49 pm

Re: tutorbot and teamplay..

Postby drm_wayne » Sat Jul 27, 2013 3:32 pm

User avatar
drm_wayne
 
Posts: 232
Joined: Sat Feb 11, 2012 5:47 pm

Re: tutorbot and teamplay..

Postby r00k » Sat Jul 27, 2013 9:41 pm

i dont reccomend that function for spawning bot entities
precache_model can only be called when the mod/map loads
r00k
 
Posts: 1111
Joined: Sat Nov 13, 2004 10:39 pm

Re: tutorbot and teamplay..

Postby frag.machine » Mon Jul 29, 2013 12:54 am

Right, that's why I suggest to precache in world.qc.
I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
User avatar
frag.machine
 
Posts: 2120
Joined: Sat Nov 25, 2006 1:49 pm

Next

Return to QuakeC Programming

Who is online

Users browsing this forum: No registered users and 3 guests