Mob status
#28
Skeleton diagnosis:
The Skeleton is immobile because the mobs' pathfinding will stop when mobs reach their final destination. The function which determines if the mob reached the final destination is cMonster::ReachedFinalDestination, and that function simply returns whether the target in range or not. For melee units, Target in range <=> Reached final destination. But for ranged units, that is not the case. The target may be in range regardless of whether or not the final destination was reached. This causes the skeleton to wrongly believe it reached the final destination, this is why it is immobile.

One easy fix is checking the line of sight inside ReachedFinalDest, but that's sphagetti, and I feel parts the TickPathfinding function is also sphagetti. As a quick fix, I'll make ReachedFinalDestination compare distance to some small constant, and not to the actual mob attack range. On the longer run, I'll rewrite some of cMonster's pathfinding code and clean it.
Reply
Thanks given by: Jammet


Messages In This Thread
Mob status - by LogicParrot - 05-01-2015, 04:54 PM
RE: AI Reborn - by tonibm19 - 05-01-2015, 07:30 PM
Breeding todo'ed - by LogicParrot - 05-01-2015, 07:32 PM
RE: AI Reborn - by Seadragon91 - 05-01-2015, 08:28 PM
RE: AI Reborn - by worktycho - 05-01-2015, 09:16 PM
Merged - by LogicParrot - 05-01-2015, 10:34 PM
RE: Mob status - by Jammet - 05-07-2015, 02:27 AM
RE: Mob status - by LogicParrot - 05-08-2015, 10:58 PM
RE: Mob status - by NiLSPACE - 05-07-2015, 05:52 AM
RE: Mob status - by Jammet - 05-08-2015, 11:03 PM
RE: Mob status - by sphinxc0re - 05-09-2015, 01:32 AM
RE: Mob status - by LogicParrot - 05-25-2015, 03:08 AM
RE: Mob status - by Jammet - 05-25-2015, 06:42 PM
RE: Mob status - by Jammet - 05-27-2015, 03:44 AM
RE: Mob status - by LogicParrot - 05-27-2015, 05:33 PM
RE: Mob status - by Jammet - 05-27-2015, 08:11 PM
Reproduce? - by LogicParrot - 05-27-2015, 11:47 PM
RE: Mob status - by Jammet - 05-27-2015, 11:50 PM
RE: Mob status - by LogicParrot - 05-27-2015, 11:55 PM
RE: Mob status - by Jammet - 05-27-2015, 11:57 PM
RE: Mob status - by LogicParrot - 05-28-2015, 12:42 AM
RE: Mob status - by Jammet - 05-28-2015, 01:37 AM
RE: Mob status - by LogicParrot - 05-28-2015, 04:58 PM
RE: Mob status - by Jammet - 05-28-2015, 05:25 PM
RE: Mob status - by LogicParrot - 05-28-2015, 05:53 PM
RE: Mob status - by bearbin - 05-28-2015, 05:59 PM
RE: Mob status - by LogicParrot - 05-28-2015, 06:00 PM
Skeleton diagnosis - by LogicParrot - 05-28-2015, 10:51 PM
RE: Mob status - by xoft - 05-29-2015, 12:58 AM
RE: Mob status - by worktycho - 05-29-2015, 01:37 AM
RE: Mob status - by LogicParrot - 05-29-2015, 02:03 AM
RE: Mob status - by worktycho - 05-29-2015, 02:26 AM
RE: Mob status - by LogicParrot - 05-29-2015, 02:28 AM
RE: Mob status - by LogicParrot - 05-29-2015, 02:47 AM
RE: Mob status - by worktycho - 05-29-2015, 03:00 AM
RE: Mob status - by jan64 - 05-29-2015, 04:53 AM
RE: Mob status - by LogicParrot - 05-29-2015, 05:21 AM
RE: Mob status - by Jammet - 05-29-2015, 05:35 AM
RE: Mob status - by LogicParrot - 05-29-2015, 05:43 AM
RE: Mob status - by xoft - 05-29-2015, 06:18 AM
RE: Mob status - by LogicParrot - 05-29-2015, 07:26 AM
RE: Mob status - by xoft - 05-29-2015, 04:34 PM
Dijkstra considerations - by LogicParrot - 05-29-2015, 06:37 PM
RE: Mob status - by LogicParrot - 05-29-2015, 06:49 PM
RE: Mob status - by xoft - 05-29-2015, 07:42 PM
RE: Mob status - by LogicParrot - 05-29-2015, 07:51 PM
RE: Mob status - by Jammet - 05-29-2015, 07:52 PM
RE: Mob status - by LogicParrot - 05-29-2015, 08:03 PM
RE: Mob status - by ReonBalisty - 05-30-2015, 05:27 AM
RE: Mob status - by LogicParrot - 05-30-2015, 08:17 AM
RE: Mob status - by LogicParrot - 05-30-2015, 08:44 PM
RE: Mob status - by Jammet - 05-30-2015, 08:58 PM
RE: Mob status - by warmist - 06-16-2015, 03:13 AM
Breeding implemented - by LogicParrot - 11-30-2015, 05:05 PM
RE: Mob status - by Jammet - 12-07-2015, 10:36 PM
RE: Mob status - by LogicParrot - 01-12-2016, 07:11 PM
RE: Mob status - by LogicParrot - 01-12-2016, 10:49 PM
Spawn distance - by LogicParrot - 01-13-2016, 12:55 AM
RE: Mob status - by Jammet - 01-13-2016, 01:49 AM
RE: Mob status - by xoft - 01-13-2016, 03:02 AM
Ball of Mud - by LogicParrot - 01-15-2016, 11:44 PM
RE: Mob status - by xoft - 01-16-2016, 12:13 AM
RE: Mob status - by LogicParrot - 01-16-2016, 03:37 AM
RE: Mob status - by xoft - 01-16-2016, 06:59 AM
RE: Mob status - by LogicParrot - 01-17-2016, 12:14 AM
Smart dogs and spiders - by LogicParrot - 01-23-2016, 05:31 AM
RE: Mob status - by Jammet - 01-23-2016, 11:02 AM
RE: Mob status - by warmist - 03-04-2016, 07:24 PM
RE: Mob status - by LogicParrot - 03-28-2016, 10:29 PM
RE: Mob status - by Jammet - 03-28-2016, 10:30 PM
RE: Mob status - by LogicParrot - 03-28-2016, 10:31 PM
RE: Mob status - by LogicParrot - 04-15-2016, 04:25 AM
RE: Mob status - by hangyas - 09-11-2016, 07:25 AM
RE: Mob status - by LogicParrot - 09-11-2016, 05:56 PM
RE: Mob status - by LogicParrot - 08-05-2017, 10:00 PM



Users browsing this thread: 3 Guest(s)