Merge branch 'develop' of github.com:thecodingmachine/workadventure

This commit is contained in:
_Bastler 2021-10-18 15:02:22 +02:00
commit a1338d40fb
4 changed files with 12 additions and 10 deletions

View File

@ -4,6 +4,7 @@
- Moving a discussion over a user will now add this user to the discussion - Moving a discussion over a user will now add this user to the discussion
- Being in a silent zone new forces mediaConstraints to false (#1508) - Being in a silent zone new forces mediaConstraints to false (#1508)
- Fixes for the emote menu (#1501) - Fixes for the emote menu (#1501)
- Fixing chat message attributed to wrong user (#1507 #1528)
## Version 1.5.0 ## Version 1.5.0
### Updates ### Updates

View File

@ -84,7 +84,7 @@ function createChatMessagesStore() {
addExternalMessage(authorId: number, text: string) { addExternalMessage(authorId: number, text: string) {
update((list) => { update((list) => {
const lastMessage = list[list.length - 1]; const lastMessage = list[list.length - 1];
if (lastMessage && lastMessage.type === ChatMessageTypes.text && lastMessage.text) { if (lastMessage && lastMessage.type === ChatMessageTypes.text && lastMessage.text && lastMessage?.author?.userId === authorId) {
lastMessage.text.push(text); lastMessage.text.push(text);
} else { } else {
list.push({ list.push({

View File

@ -40,6 +40,7 @@ WA.chat.onChatMessage((message => {
WA.room.onEnterZone('myTrigger', () => { WA.room.onEnterZone('myTrigger', () => {
WA.chat.sendChatMessage("Don't step on my carpet!", 'Poly Parrot'); WA.chat.sendChatMessage("Don't step on my carpet!", 'Poly Parrot');
WA.chat.sendChatMessage("Yeah, don't step on her carpet!", 'Peter Parrot');
}) })
WA.room.onLeaveZone('popupZone', () => { WA.room.onLeaveZone('popupZone', () => {

View File

@ -13,7 +13,7 @@
"width":10, "width":10,
"x":0, "x":0,
"y":0 "y":0
}, },
{ {
"data":[0, 0, 0, 0, 0, 0, 0, 0, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0, 23, 23, 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, 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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, "height":10,
@ -49,7 +49,7 @@
"width":10, "width":10,
"x":0, "x":0,
"y":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], "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, "height":10,
@ -61,7 +61,7 @@
"width":10, "width":10,
"x":0, "x":0,
"y":0 "y":0
}, },
{ {
"draworder":"topdown", "draworder":"topdown",
"id":3, "id":3,
@ -77,7 +77,7 @@
"width":104.442827410047, "width":104.442827410047,
"x":142.817125079855, "x":142.817125079855,
"y":147.448134926559 "y":147.448134926559
}, },
{ {
"height":132.434722966794, "height":132.434722966794,
"id":2, "id":2,
@ -88,7 +88,7 @@
"width":125.735549178518, "width":125.735549178518,
"x":13.649632619596, "x":13.649632619596,
"y":50.8502491249093 "y":50.8502491249093
}, },
{ {
"height":67, "height":67,
"id":3, "id":3,
@ -98,7 +98,7 @@
{ {
"fontfamily":"Sans Serif", "fontfamily":"Sans Serif",
"pixelsize":11, "pixelsize":11,
"text":"Test:\nWalk on top carpet\nResult:\nA message \"Don't step on my carpet\" is displayed", "text":"Test:\nWalk on top carpet\nResult:\nA message \"Don't step on my carpet\" is displayed from Poly Parrot and another message from Peter Parrot",
"wrap":true "wrap":true
}, },
"type":"", "type":"",
@ -106,7 +106,7 @@
"width":252.4375, "width":252.4375,
"x":2.78125, "x":2.78125,
"y":2.5 "y":2.5
}, },
{ {
"height":67, "height":67,
"id":4, "id":4,
@ -161,4 +161,4 @@
"type":"map", "type":"map",
"version":1.5, "version":1.5,
"width":10 "width":10
} }