/*
These are simple defaults for your project.
*/
#include <kaiochao\shapes\shapes.dm>
world
fps = 25 // 25 frames per second
icon_size = 32 // 32x32 icon size by default
view = 6 // show up to 6 tiles outward from center (13x13 view)
turf
icon = 'shapes.dmi'
icon_state = "rect"
// Make objects move 8 pixels per tick when walking
mob
step_size = 8
appearance_flags = KEEP_TOGETHER
icon = 'shapes.dmi'
icon_state = "rect"
color = rgb(255,0,0)
Login()
. = ..()
//icon_state is not being inherited! (KEEP_TOGETHER doesn't matter)
var/image/i = image('shapes.dmi',src,layer=FLOAT_LAYER)
i.color = rgb(0,255,255)
world << i
//Uncomment for animate.
/*
var/matrix/m = new()
i.icon_state = "arrow"
var/matrix/n = new()
n.Scale(2)
animate(i, transform = n, time = 10, loop = -1)
animate(src, transform = null, time = 10, loop = -1)
m.Turn(120)
animate(transform = m, time = 10)
m.Turn(120)
animate(transform = m, time = 10)
*/
obj
step_size = 8
Problem description:
I'm not sure whether these are bugs or not, so I'm posting here. I'm using version 511.1364, and these are my issues:
1. images' icon_state, no matter whether KEEP_TOGETHER is on or off, does not change with the loc even if icon_state is set to null. Easy workaround: Change all icon_states at once, make a proc or define to do so.
2. images don't animate with their loc if KEEP_TOGETHER is on. Easy workaround: Take KEEP_TOGETHER off or set KEEP_APART on the images.
Are these bugs or intended behavior? I'm fine with using the workarounds for now (I currently have them implemented), even if they aren't ideal.