Set sand origin when command is given

This commit is contained in:
2021-04-24 22:34:25 +00:00
parent a5642409d2
commit 4026b410f4
5 changed files with 14 additions and 6 deletions
+4
View File
@@ -268,6 +268,8 @@ class Commands:
self.g.job.state = self.g.job.gather_wood
reply = 'ok'
elif data == 'sand':
if not self.g.sand_origin or not self.g.chunks.check_loaded(self.g.sand_origin):
self.g.sand_origin = utils.pint(self.g.pos)
self.g.job.state = self.g.job.gather_sand
reply = 'ok'
@@ -288,6 +290,8 @@ class Commands:
self.g.job.state = self.g.job.farm_wood
reply = 'ok'
elif data == 'sand':
if not self.g.sand_origin or not self.g.chunks.check_loaded(self.g.sand_origin):
self.g.sand_origin = utils.pint(self.g.pos)
self.g.job.state = self.g.job.farm_sand
reply = 'ok'
elif data == 'wart':