feat: add common social fireplace
This commit is contained in:
@@ -19,6 +19,16 @@ interface Chip {
|
||||
}
|
||||
|
||||
function makeTool(tool: string): Graphics {
|
||||
if (tool === 'log') {
|
||||
// бревно в руках — для подкинутого дрова у костра
|
||||
return new Graphics()
|
||||
.rect(-6, -3, 12, 5)
|
||||
.fill(0x7a5230)
|
||||
.circle(-6, -0.5, 2.2)
|
||||
.fill(0x9a7448)
|
||||
.circle(6, -0.5, 2.2)
|
||||
.fill(0x9a7448);
|
||||
}
|
||||
const g = new Graphics().rect(-1, -12, 2, 12).fill(HANDLE);
|
||||
if (tool === 'axe_rusty' || tool === 'axe_iron') {
|
||||
g.poly([-1, -12, 7, -12, 7, -7, -1, -8]).fill(tool === 'axe_iron' ? STEEL : RUSTY);
|
||||
@@ -68,7 +78,7 @@ export class AvatarView {
|
||||
const body = new Graphics().roundRect(-7, -18, 14, 13, 4).fill(av.color);
|
||||
const head = new Graphics().circle(0, -23, 6.5).fill(SKIN);
|
||||
this.toolHolder.position.set(6, -14);
|
||||
for (const tool of ['axe_rusty', 'axe_iron', 'pick_rusty', 'pick_iron', 'hammer', 'spoon', 'rod']) {
|
||||
for (const tool of ['axe_rusty', 'axe_iron', 'pick_rusty', 'pick_iron', 'hammer', 'spoon', 'rod', 'log']) {
|
||||
const g = makeTool(tool);
|
||||
g.visible = false;
|
||||
this.tools.set(tool, g);
|
||||
|
||||
Reference in New Issue
Block a user