So i'm working on testing out an idea. I've got other things working more or less the way I want them, but there's something i'm building up to a piece at a time.
Right here, I want to project onto the screen the POV of another object. In this instance a pigcop with a palette of 200. I'm sure this will come off as a bit amusing to some of you, but i'm honestly stumped.
gamevar ptemp 0 2
gamevar ptemp2 0 2
// ('squadmate') Camera
onevent EVENT_DISPLAYREST
{
getactor[THISACTOR].picnum ptemp
ifvare ptemp PIGCOP
getactor[THISACTOR].pal ptemp2
ifvare ptemp2 200
getactor[THISACTOR].x x
getactor[THISACTOR].y y
getactor[THISACTOR].z z
getactor[THISACTOR].ang ang
// getactor[THISACTOR].horiz horiz
// getactor[THISACTOR].horizoff temp
// addvarvar horiz temp
updatesectorz x y z sect
showviewunbiased x y z ang horiz sect 16 41 56 69
}
endevent
Obviously, this is not working. Oh, It does project a view onto the screen, but it's behind the player.
I'm almost certain I need to call the pig stuff in an EVENT_LOADACTOR and then reference it into the EVENT_DISPLAYREST stuff. I was trying that before and it either wasn't showing up, or was just showing a view from the player's feet.
Note, I commented out a few lines that weren't working (for obvious reasons, they reference a camera setup for a player position.)
So, can someone point me in the right direction?