keeperfx
keeperfx copied to clipboard
rewrite Get human controlled creature target
selects what target is hit when hitting in posession
also refactored some eye_height related stuff
hmm pseudo code says pos, but I've seen cases where pseudo code is simply wrong so I tried num but makes no difference, also found and fixed another mistake but still always returns 0
hmm pseudo code says pos, but I've seen cases where pseudo code is simply wrong so I tried num but makes no difference, also found and fixed another mistake but still always returns 0
Well, MapSubtlCoord is a subtile number, which is num. Have you tried using MapCoord and val?
also checked val yes, but since it has the >256 check under it it's clearly not val
also checked val yes, but since it has the >256 check under it it's clearly not val
That looks like a subtile number to me.
yeah I believe it's num as well, but it's not the only bug I guess
if you wanne have a go at it feel free to commit to this branch
I can't figure out why this doesn't work either :(. I do know, however, that the for (i = thing_get(get_mapwho_thing_index(mapblk)); !thing_is_invalid(i); i = thing_get(i->next_on_mapblk)) always returns an invalid thing, so I'm guessing it's looking at the wrong co-ordinates.
Edit: I tried resetting the x co-ordinate after the x loop, but it still doesn't work.
It seems to be working now, touch wood; I made a few silly errors in my code.