Hack and Slash A.I. difficulty

Hey there everyone =)

Okay, I’ve been using blender for a good while, moreso BGE than rendering, but I on my current project, I’ve hit a snag. my Orcs won’t track my humans. (It’s not everyday you get to pull a sentance like that out of the bag o.O)

Anyway, the idea is to have an orc (enemy) track a human, and atack it. I’ve got the collisions, health and damage stuff set up perfectly, it’s just the fact that the Orcs won’t target the humans! I tried using a Edit Object: Track To “Human” (The bounding box) actuator, but seen as the characters are all spawned onto the map from another level, it causes the Orc to track to the humans object center on the 2nd layer (Where the human is spawned from). I’m using the bounding box idea (The invisible ones, with collisions, to help BGE speed) with the aesthetics(The models/animations) parented inside the the bounding box. The weapons set their parent as the characters ‘hand’ (an Empty with IPO animation, which is parented to the bounding box, again) every couple of frames aswell, seen as there is a bug that the objects won’t stay parented unless they’re updated (Could be wrong, maybe it updates the parents position, and then doesn’t relay to the child or something? not sure. Python isn’t my brains friend.) Anyway, I’ve spent the past 3 days searching these forums for the Predator Prey script, and I have found no working links, no in house tuts, and no blend files. I’ve searched the internet aswell, and nothing.

I’m also using 2.47 =)

If anyone can help, please do so =(!

What I really need, is something along the lines of a “Track to property” script.

Thanks in advance, Dan.

could you post the blend?


/looks around pathetically

…I don’t know where to upload it? Lol. I feel pathetic. I have no webspace, and I don’t use forums unless I’m really bloody stuck lmao! It doesn’t look like much (I haven’t even modeled the characters bodies yet) it’s basically a bunch of Extended Cubes with properties and logic bricks.

I’ll upload something when I figure out how? o.O

i use filefront to uplaod

The blenderartists forums lets you attach blend files. Just hit manage attachments, and choose the file.

You could do it with complicated math, OR putting an empty at the hit position of a ray

Okay, so I know what I need anyway, the ‘Predator prey’ script.

However, I moved onto a different project. I’ll post some screens or something up if I get a chance to find somewhere to host them o.O