var/turf/block/B = new()
B.loc = locate(src.x,src.y,1)
And it says, "Cannot change constant var" What does that mean? What did I do wrong?
And if I make it new(src.loc) it work... what's the diff?
ID:148523
![]() Jan 11 2003, 1:36 pm
|
|
A turf can be created at a specific place (in a specific other turf), but it can't be moved. Only /atom/movable types can have their loc var changed once they're created. Thanks, that helped a alot... |
As Lummox JR stated below, you cannot move it, if it's parent type isn't atom/moveable. But you can do want you want this way, I believe:
<code> var/destination_x = src.x var/destination_y = src.y var/destination_z = 1 var/turf/block/B = new(destination_x,destination_y,destination_z) </code> Let me know if it works. ~>Volte |
A turf can be created at a specific place (in a specific other turf), but it can't be moved. Only /atom/movable types can have their loc var changed once they're created.
Lummox JR