Hey people, and Spike, if you're reading this, sorry for the annoying questions.
I'm running into problems withe the checkclient(); builtin on a particular map. It has to do with the enemy AI, in which checkclient returns world when it should return the player entity. Even when I stand in front of the enemy, right next to them, they do not attack. Specifically filtering for the player with a find(); loop does not help either, client in FindTarget still yields world, which means the enemies still stand still. This only happens in my custom map, which is just a simple enclosed skybox with one info_player_start and one monster_army. All other Id1 maps work as expected.
With the find loop not working, this leads me to believe that the player almost doesn't exist(Which it certainly does, when I fire at the monster, he attacks and has the player set as the enemy). The map itself is compiled with q3map2 and made in netradiant, although I'm not sure how that could affect anything. To note, the map does work as expected in darkplaces, and the monster attacks, same progs and all. Anyone know what to do?
[FTEQW]checkclient(); bulitin returns player only sometimes
-
- Posts: 21
- Joined: Sun Apr 21, 2013 10:50 pm
Re: [FTEQW]checkclient(); bulitin returns player only someti
All I can figure is maybe the spawned world has a bug compiled into it that somehow factors into the equasion. I think that builtin looks for the FL_CLIENT flag, but I am not sure. So maybe if you built a map, and assigned the .flags field to have that bitflag present, it would cause this problem?
Re: [FTEQW]checkclient(); bulitin returns player only someti
I think its a problem with q2/q3 bsps and pvs.
checkclient only checks client slots (FL_CLIENT makes no difference). the more players you have, the longer it'll take for monsters to notice. players need health and not notarget.
edit: the current build on triptohell should fix this issue, hopefully.
checkclient only checks client slots (FL_CLIENT makes no difference). the more players you have, the longer it'll take for monsters to notice. players need health and not notarget.
edit: the current build on triptohell should fix this issue, hopefully.
Last edited by Spike on Fri May 23, 2014 3:00 am, edited 1 time in total.
-
- Posts: 21
- Joined: Sun Apr 21, 2013 10:50 pm
Re: [FTEQW]checkclient(); bulitin returns player only someti
I'm guessing that's what it is, since darkplaces loads the map and PVS seems to be working as intended.Spike wrote:I think its a problem with q2/q3 bsps and pvs.
I'm not sure if there could be a glitch that's causing self.flags to include FL_NOTARGET, is there some way I could see if it's set? I know how to use the QC debugger to check entities, it's just that I'm not sure what to make of it from there as far as the .flags field.
Re: [FTEQW]checkclient(); bulitin returns player only someti
give self.flags
if the second nibble from the right is 8,c,d,e,f, then notarget is set. either way its unlikely to be that - tried the new build?
if the second nibble from the right is 8,c,d,e,f, then notarget is set. either way its unlikely to be that - tried the new build?
-
- Posts: 21
- Joined: Sun Apr 21, 2013 10:50 pm
Re: [FTEQW]checkclient(); bulitin returns player only someti
Hey Spike, sorry I took a while to get back to this. I have revision 4669 working, PVS is functioning in q3 maps, but now the enemies are invisible. No idea why.
Re: [FTEQW]checkclient(); bulitin returns player only someti
iqm models invisible here too.jjsullivan5196 wrote:Hey Spike, sorry I took a while to get back to this. I have revision 4669 working, PVS is functioning in q3 maps, but now the enemies are invisible. No idea why.
Re: [FTEQW]checkclient(); bulitin returns player only someti
invisible iqms *should* be fixed in revision 4675. here's hoping something else doesn't break.
thanks go to gb who pointed me to a map that actully had the problem. hurrah.
thanks go to gb who pointed me to a map that actully had the problem. hurrah.