mirror of
https://github.com/solero/houdini.git
synced 2024-11-25 23:17:24 +00:00
Implement penguin class add_coins
method
This commit is contained in:
parent
174cda73c3
commit
4703c9f789
@ -218,6 +218,13 @@ class Penguin(Spheniscidae, penguin.Penguin):
|
|||||||
|
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
async def add_coins(self, coins, stay=False):
|
||||||
|
if stay:
|
||||||
|
await self.join_room(self.room)
|
||||||
|
await self.update(coins=self.coins + coins).apply()
|
||||||
|
await self.send_xt('zo', self.coins, '', 0, 0, 0)
|
||||||
|
return self.coins
|
||||||
|
|
||||||
async def set_color(self, item):
|
async def set_color(self, item):
|
||||||
await self.update(color=item.id).apply()
|
await self.update(color=item.id).apply()
|
||||||
await self.room.send_xt('upc', self.id, item.id)
|
await self.room.send_xt('upc', self.id, item.id)
|
||||||
|
Loading…
Reference in New Issue
Block a user