mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-14 12:34:05 +09:00
circular (octagon actually) propagation of light
Former-commit-id: 1e67a3284ea298a0d8f27309d9d8ca800a8525c8 Former-commit-id: a5067df80d1053ceec6d78b6fda6cf0afa3c286c
This commit is contained in:
@@ -266,6 +266,8 @@ constructor() : BasicGameState() {
|
||||
}
|
||||
|
||||
private fun changePossession(refid: Int) {
|
||||
// TODO prevent possessing other player on multiplayer
|
||||
|
||||
if (!hasActor(refid)) {
|
||||
throw IllegalArgumentException("No such actor in actorContainer: $refid")
|
||||
}
|
||||
@@ -309,12 +311,19 @@ constructor() : BasicGameState() {
|
||||
/////////////////
|
||||
// --> Change of blend mode <-- introduced by ActorWithBody //
|
||||
actorContainer.forEach { actor ->
|
||||
if (actor is ActorWithBody && actor.inScreen() && actor !is Player) {
|
||||
if (actor is ActorWithBody && actor.inScreen() && actor !is Player && !actor.drawTopmost) {
|
||||
actor.drawBody(gc, worldDrawFrameBuffer.graphics)
|
||||
}
|
||||
}
|
||||
// --> Change of blend mode <-- introduced by ActorWithBody //
|
||||
player.drawBody(gc, worldDrawFrameBuffer.graphics)
|
||||
// --> Change of blend mode <-- introduced by ActorWithBody //
|
||||
actorContainer.forEach { actor ->
|
||||
if (actor is ActorWithBody && actor.inScreen() && actor !is Player && actor.drawTopmost) {
|
||||
actor.drawBody(gc, worldDrawFrameBuffer.graphics)
|
||||
}
|
||||
}
|
||||
// --> Change of blend mode <-- introduced by ActorWithBody //
|
||||
|
||||
|
||||
/////////////////////////////
|
||||
|
||||
Reference in New Issue
Block a user