I know c_trace instruction is used for that. The problem is that c_trace always returns positive number even if there are no obstacles between the player and the enemy, so how come I know if the enemy can see the player?
Re: Checking if the enemy can see the player?
[Re: Mark430SR]
#453799 08/14/1503:5508/14/1503:55
Don't use the distance but the if(trace_hit) ... variable (or the hit macro, manual: hit and c_trace obviously). Obviously you want to either c_ignore both player and enemy (or IGNORE_ME and IGNORE_PASSABLE and let's say set the player to passable immediately before the trace and reset the flag after).
"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual