Merge branch 'develop' of github.com:thecodingmachine/workadventure
This commit is contained in:
commit
f25cb6a3ba
@ -1,7 +1,7 @@
|
||||
<script lang="typescript">
|
||||
import MenuIcon from "./Menu/MenuIcon.svelte";
|
||||
import {menuIconVisiblilityStore, menuVisiblilityStore} from "../Stores/MenuStore";
|
||||
import {emoteMenuVisiblilityStore} from "../Stores/EmoteStore";
|
||||
import {emoteMenuStore} from "../Stores/EmoteStore";
|
||||
import {enableCameraSceneVisibilityStore} from "../Stores/MediaStore";
|
||||
import CameraControls from "./CameraControls.svelte";
|
||||
import MyCamera from "./MyCamera.svelte";
|
||||
@ -113,7 +113,7 @@
|
||||
<Menu></Menu>
|
||||
</div>
|
||||
{/if}
|
||||
{#if $emoteMenuVisiblilityStore}
|
||||
{#if $emoteMenuStore}
|
||||
<div>
|
||||
<EmoteMenu></EmoteMenu>
|
||||
</div>
|
||||
|
@ -21,6 +21,8 @@
|
||||
emojisPerRow: isMobile() ? 6 : 8,
|
||||
autoFocusSearch: false
|
||||
});
|
||||
//the timeout is here to prevent the menu from flashing
|
||||
setTimeout(() => picker.showPicker(emojiContainer), 100);
|
||||
|
||||
picker.on("emoji", (selection) => {
|
||||
emoteStore.set(selection.emoji);
|
||||
@ -30,13 +32,6 @@
|
||||
emoteMenuStore.closeEmoteMenu();
|
||||
});
|
||||
|
||||
unsubscriber = emoteMenuStore.subscribe((isEmoteMenuVisible) => {
|
||||
if (isEmoteMenuVisible && !picker.isPickerVisible()) {
|
||||
picker.showPicker(emojiContainer);
|
||||
} else {
|
||||
picker.hidePicker();
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
function onKeyDown(e: KeyboardEvent) {
|
||||
|
@ -64,7 +64,7 @@ export abstract class Character extends Container {
|
||||
this.invisible = false;
|
||||
})
|
||||
.catch(() => {
|
||||
return lazyLoadPlayerCharacterTextures(scene.load, ["color_22", "eyes_23"]).then((textures) => {
|
||||
return lazyLoadPlayerCharacterTextures(scene.load, [ "color_22", "eyes_23" ]).then((textures) => {
|
||||
this.addTextures(textures, frame);
|
||||
this.invisible = false;
|
||||
});
|
||||
|
@ -9,7 +9,6 @@ import { get } from "svelte/store";
|
||||
import { requestedCameraState, requestedMicrophoneState } from "../../Stores/MediaStore";
|
||||
import { helpCameraSettingsVisibleStore } from "../../Stores/HelpCameraSettingsStore";
|
||||
import { menuIconVisiblilityStore } from "../../Stores/MenuStore";
|
||||
import { emoteMenuVisiblilityStore } from "../../Stores/EmoteStore";
|
||||
|
||||
/**
|
||||
* This class should be responsible for any scene starting/stopping
|
||||
@ -112,7 +111,6 @@ export class GameManager {
|
||||
public gameSceneIsCreated(scene: GameScene) {
|
||||
this.currentGameSceneName = scene.scene.key;
|
||||
menuIconVisiblilityStore.set(true);
|
||||
emoteMenuVisiblilityStore.set(true);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -125,7 +123,6 @@ export class GameManager {
|
||||
gameScene.cleanupClosingScene();
|
||||
gameScene.createSuccessorGameScene(false, false);
|
||||
menuIconVisiblilityStore.set(false);
|
||||
emoteMenuVisiblilityStore.set(false);
|
||||
if (!this.scenePlugin.get(targetSceneName)) {
|
||||
this.scenePlugin.add(targetSceneName, sceneClass, false);
|
||||
}
|
||||
@ -139,7 +136,6 @@ export class GameManager {
|
||||
if (this.currentGameSceneName) {
|
||||
this.scenePlugin.start(this.currentGameSceneName);
|
||||
menuIconVisiblilityStore.set(true);
|
||||
emoteMenuVisiblilityStore.set(true);
|
||||
} else {
|
||||
this.scenePlugin.run(fallbackSceneName);
|
||||
}
|
||||
|
@ -14,6 +14,5 @@ function createEmoteMenuStore() {
|
||||
};
|
||||
}
|
||||
|
||||
export const emoteMenuVisiblilityStore = writable(false);
|
||||
export const emoteStore = writable<string | null>(null);
|
||||
export const emoteMenuStore = createEmoteMenuStore();
|
||||
|
82
maps/tests/emoji.json
Normal file
82
maps/tests/emoji.json
Normal file
@ -0,0 +1,82 @@
|
||||
{ "compressionlevel":-1,
|
||||
"height":10,
|
||||
"infinite":false,
|
||||
"layers":[
|
||||
{
|
||||
"data":[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1],
|
||||
"height":10,
|
||||
"id":1,
|
||||
"name":"floor",
|
||||
"opacity":1,
|
||||
"type":"tilelayer",
|
||||
"visible":true,
|
||||
"width":10,
|
||||
"x":0,
|
||||
"y":0
|
||||
},
|
||||
{
|
||||
"data":[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
|
||||
"height":10,
|
||||
"id":2,
|
||||
"name":"start",
|
||||
"opacity":1,
|
||||
"type":"tilelayer",
|
||||
"visible":true,
|
||||
"width":10,
|
||||
"x":0,
|
||||
"y":0
|
||||
},
|
||||
{
|
||||
"draworder":"topdown",
|
||||
"id":3,
|
||||
"name":"floorLayer",
|
||||
"objects":[
|
||||
{
|
||||
"height":308.584234177831,
|
||||
"id":1,
|
||||
"name":"",
|
||||
"rotation":0,
|
||||
"text":
|
||||
{
|
||||
"fontfamily":"Sans Serif",
|
||||
"pixelsize":13,
|
||||
"text":"Test:\nClick on tne WOKA name\n\nResult:\nThe tab with all emoji should be displayed\n\nTest:\nChoose on emoji and click on it\n\nResult:\nEmoji will be play at the top of your WOKA",
|
||||
"wrap":true
|
||||
},
|
||||
"type":"",
|
||||
"visible":true,
|
||||
"width":315.4375,
|
||||
"x":1.74700399641053,
|
||||
"y":1.43404009627554
|
||||
}],
|
||||
"opacity":1,
|
||||
"type":"objectgroup",
|
||||
"visible":true,
|
||||
"x":0,
|
||||
"y":0
|
||||
}],
|
||||
"nextlayerid":7,
|
||||
"nextobjectid":2,
|
||||
"orientation":"orthogonal",
|
||||
"renderorder":"right-down",
|
||||
"tiledversion":"1.7.2",
|
||||
"tileheight":32,
|
||||
"tilesets":[
|
||||
{
|
||||
"columns":11,
|
||||
"firstgid":1,
|
||||
"image":"tileset1.png",
|
||||
"imageheight":352,
|
||||
"imagewidth":352,
|
||||
"margin":0,
|
||||
"name":"tileset1",
|
||||
"spacing":0,
|
||||
"tilecount":121,
|
||||
"tileheight":32,
|
||||
"tilewidth":32
|
||||
}],
|
||||
"tilewidth":32,
|
||||
"type":"map",
|
||||
"version":"1.6",
|
||||
"width":10
|
||||
}
|
@ -79,6 +79,14 @@
|
||||
<a href="#" class="testLink" data-testmap="jitsi_custom_url.json" target="_blank">Testing Jitsi + silent layer</a>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<input type="radio" name="test-emoji"> Success <input type="radio" name="test-emoji"> Failure <input type="radio" name="test-emoji" checked> Pending
|
||||
</td>
|
||||
<td>
|
||||
<a href="#" class="testLink" data-testmap="emoji.json" target="_blank">Testing Emoji</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h2>Iframe API</h2>
|
||||
<table class="table">
|
||||
|
Loading…
Reference in New Issue
Block a user