HOWEVER it is special cased in get/setplayer/sector to refer to the current player and sector (it is also special cased in get/setactor though this special casing shouldn't make any difference to behaviour). Specifically:
When used with get/setactor inside of actor code, THISACTOR refers to the actor you're manipulating.
When used with get/setplayer inside of actor code, THISACTOR refers to the nearest player.
When used with get/setsector inside of actor code, THISACTOR refers to the current actor's sector.
When used in a player event (as opposed to the special actor events like EVENT_GAME, EVENT_EGS, EVENT_SPAWN, et cetera), THISACTOR typically refers to the APLAYER sprite (or rather, it refers to whatever sprite has the sprite number contained in the value for the "i" member of the player struct).
When used in an actor event, such as the ones listed above, THISACTOR works as it does in actor code.