Can anyone help me to fix this?
It it would work, it would help me to find model names faster in SinglePlayer, to use them in MP.
The problem is inside the for(), but I can't fix it
The game is loading it in, but it doesn't have anny effect. I'm calling it from arcadia.gsc's main() with "level thread pickup();"
It it would work, it would help me to find model names faster in SinglePlayer, to use them in MP.
The problem is inside the for(), but I can't fix it
PHP Code:
pickup()
{
self endon("death");
self notifyOnPlayerCommand( "dpad_up", "+frag" );
for(;;){
self waittill( "dpad_up" );
vec = anglestoforward(self getPlayerAngles());
end = (vec[0] * 100, vec[1] * 100, vec[2] * 100);
entity = BulletTrace( self gettagorigin("tag_eye"), self gettagorigin("tag_eye")+(vec[0] * 100, vec[1] * 100, vec[2] * 100), 0, self )[ "entity" ];
if( isdefined(entity.model) || IsPlayer(entity) )
{
self iPrintLn( entity.model );
//self SendToConsole( entity.model );
self waittill( "dpad_up" );
}
}
}
The game is loading it in, but it doesn't have anny effect. I'm calling it from arcadia.gsc's main() with "level thread pickup();"