Ok well I went back a step and tested something simpler. Again, I am gettign a constant empty poitner error.
New code:
Code:
var vec_dist_var=0;
var player_vector[3];
var vec_varx=0;
action vec_check
{
while(1);
{
vec_varx=vec_dist(my.x,player.x);
wait(1);
if(vec_varx<=100)
{
ent_remove(me);
return;
}
wait(1);
}
}
action vec_dist_test
{
while(1)
{
player_vector.x=player.x;
player_vector.y=player.y;
player_vector.z=player.z;
wait(1);
vec_dist_var=vec_length(player_vector);
wait(1);
IF(vec_dist_var>=100)
{
ent_remove(me);
return;
}
wait(1);
}
}
The top action is the new action while the bottom action is the original problem to this thread.