Merge pull request #230 from thecodingmachine/customize-characters2
png files + customizeScene that enables the player to create his own character
@ -177,7 +177,7 @@ export class IoSocketController {
|
|||||||
//add function to refresh position user in real time.
|
//add function to refresh position user in real time.
|
||||||
//this.refreshUserPosition(Client);
|
//this.refreshUserPosition(Client);
|
||||||
|
|
||||||
const messageUserJoined = new MessageUserJoined(Client.userId, Client.name, Client.character, Client.position);
|
const messageUserJoined = new MessageUserJoined(Client.userId, Client.name, Client.characterLayers, Client.position);
|
||||||
|
|
||||||
socket.to(roomId).emit(SockerIoEvent.JOIN_ROOM, messageUserJoined);
|
socket.to(roomId).emit(SockerIoEvent.JOIN_ROOM, messageUserJoined);
|
||||||
|
|
||||||
@ -188,7 +188,7 @@ export class IoSocketController {
|
|||||||
console.warn('Something went wrong. The World contains a user "'+user.id+"' but this user does not exist in the sockets list!");
|
console.warn('Something went wrong. The World contains a user "'+user.id+"' but this user does not exist in the sockets list!");
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
return new MessageUserPosition(user.id, player.name, player.character, player.position);
|
return new MessageUserPosition(user.id, player.name, player.characterLayers, player.position);
|
||||||
}).filter((item: MessageUserPosition|null) => item !== null);
|
}).filter((item: MessageUserPosition|null) => item !== null);
|
||||||
answerFn(listOfUsers);
|
answerFn(listOfUsers);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
@ -278,7 +278,7 @@ export class IoSocketController {
|
|||||||
}
|
}
|
||||||
const Client = (socket as ExSocketInterface);
|
const Client = (socket as ExSocketInterface);
|
||||||
Client.name = playerDetails.name;
|
Client.name = playerDetails.name;
|
||||||
Client.character = playerDetails.character;
|
Client.characterLayers = playerDetails.characterLayers;
|
||||||
answerFn(Client.userId);
|
answerFn(Client.userId);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -9,6 +9,6 @@ export interface ExSocketInterface extends Socket, Identificable {
|
|||||||
webRtcRoomId: string;
|
webRtcRoomId: string;
|
||||||
userId: string;
|
userId: string;
|
||||||
name: string;
|
name: string;
|
||||||
character: string;
|
characterLayers: string[];
|
||||||
position: PointInterface;
|
position: PointInterface;
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import {PointInterface} from "_Model/Websocket/PointInterface";
|
import {PointInterface} from "_Model/Websocket/PointInterface";
|
||||||
|
|
||||||
export class MessageUserJoined {
|
export class MessageUserJoined {
|
||||||
constructor(public userId: string, public name: string, public character: string, public position: PointInterface) {
|
constructor(public userId: string, public name: string, public characterLayers: string[], public position: PointInterface) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -6,6 +6,6 @@ export class Point implements PointInterface{
|
|||||||
}
|
}
|
||||||
|
|
||||||
export class MessageUserPosition {
|
export class MessageUserPosition {
|
||||||
constructor(public userId: string, public name: string, public character: string, public position: PointInterface) {
|
constructor(public userId: string, public name: string, public characterLayers: string[], public position: PointInterface) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -3,6 +3,6 @@ import * as tg from "generic-type-guard";
|
|||||||
export const isSetPlayerDetailsMessage =
|
export const isSetPlayerDetailsMessage =
|
||||||
new tg.IsInterface().withProperties({
|
new tg.IsInterface().withProperties({
|
||||||
name: tg.isString,
|
name: tg.isString,
|
||||||
character: tg.isString
|
characterLayers: tg.isArray(tg.isString)
|
||||||
}).get();
|
}).get();
|
||||||
export type SetPlayerDetailsMessage = tg.GuardedType<typeof isSetPlayerDetailsMessage>;
|
export type SetPlayerDetailsMessage = tg.GuardedType<typeof isSetPlayerDetailsMessage>;
|
||||||
|
BIN
front/dist/resources/customisation/character_accessories/character_accessories1.png
vendored
Normal file
After Width: | Height: | Size: 293 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories10.png
vendored
Normal file
After Width: | Height: | Size: 517 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories11.png
vendored
Normal file
After Width: | Height: | Size: 517 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories12.png
vendored
Normal file
After Width: | Height: | Size: 524 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories13.png
vendored
Normal file
After Width: | Height: | Size: 505 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories14.png
vendored
Normal file
After Width: | Height: | Size: 525 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories15.png
vendored
Normal file
After Width: | Height: | Size: 517 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories16.png
vendored
Normal file
After Width: | Height: | Size: 743 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories17.png
vendored
Normal file
After Width: | Height: | Size: 798 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories18.png
vendored
Normal file
After Width: | Height: | Size: 754 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories19.png
vendored
Normal file
After Width: | Height: | Size: 814 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories2.png
vendored
Normal file
After Width: | Height: | Size: 452 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories20.png
vendored
Normal file
After Width: | Height: | Size: 810 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories21.png
vendored
Normal file
After Width: | Height: | Size: 827 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories22.png
vendored
Normal file
After Width: | Height: | Size: 451 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories23.png
vendored
Normal file
After Width: | Height: | Size: 451 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories24.png
vendored
Normal file
After Width: | Height: | Size: 451 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories25.png
vendored
Normal file
After Width: | Height: | Size: 451 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories26.png
vendored
Normal file
After Width: | Height: | Size: 281 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories27.png
vendored
Normal file
After Width: | Height: | Size: 276 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories28.png
vendored
Normal file
After Width: | Height: | Size: 368 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories29.png
vendored
Normal file
After Width: | Height: | Size: 332 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories3.png
vendored
Normal file
After Width: | Height: | Size: 450 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories30.png
vendored
Normal file
After Width: | Height: | Size: 324 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories31.png
vendored
Normal file
After Width: | Height: | Size: 349 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories32.png
vendored
Normal file
After Width: | Height: | Size: 347 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories4.png
vendored
Normal file
After Width: | Height: | Size: 486 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories5.png
vendored
Normal file
After Width: | Height: | Size: 390 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories6.png
vendored
Normal file
After Width: | Height: | Size: 495 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories7.png
vendored
Normal file
After Width: | Height: | Size: 389 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories8.png
vendored
Normal file
After Width: | Height: | Size: 516 B |
BIN
front/dist/resources/customisation/character_accessories/character_accessories9.png
vendored
Normal file
After Width: | Height: | Size: 505 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes0.png
vendored
Normal file
After Width: | Height: | Size: 454 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes1.png
vendored
Normal file
After Width: | Height: | Size: 454 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes10.png
vendored
Normal file
After Width: | Height: | Size: 1000 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes11.png
vendored
Normal file
After Width: | Height: | Size: 1011 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes12.png
vendored
Normal file
After Width: | Height: | Size: 965 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes13.png
vendored
Normal file
After Width: | Height: | Size: 965 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes14.png
vendored
Normal file
After Width: | Height: | Size: 910 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes15.png
vendored
Normal file
After Width: | Height: | Size: 980 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes16.png
vendored
Normal file
After Width: | Height: | Size: 938 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes17.png
vendored
Normal file
After Width: | Height: | Size: 961 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes18.png
vendored
Normal file
After Width: | Height: | Size: 977 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes19.png
vendored
Normal file
After Width: | Height: | Size: 977 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes2.png
vendored
Normal file
After Width: | Height: | Size: 388 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes20.png
vendored
Normal file
After Width: | Height: | Size: 977 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes21.png
vendored
Normal file
After Width: | Height: | Size: 2.0 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes22.png
vendored
Normal file
After Width: | Height: | Size: 2.0 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes23.png
vendored
Normal file
After Width: | Height: | Size: 2.0 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes24.png
vendored
Normal file
After Width: | Height: | Size: 3.3 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes25.png
vendored
Normal file
After Width: | Height: | Size: 4.0 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes26.png
vendored
Normal file
After Width: | Height: | Size: 3.8 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes27.png
vendored
Normal file
After Width: | Height: | Size: 3.8 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes28.png
vendored
Normal file
After Width: | Height: | Size: 4.5 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes29.png
vendored
Normal file
After Width: | Height: | Size: 4.3 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes3.png
vendored
Normal file
After Width: | Height: | Size: 388 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes30.png
vendored
Normal file
After Width: | Height: | Size: 3.8 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes31.png
vendored
Normal file
After Width: | Height: | Size: 3.5 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes32.png
vendored
Normal file
After Width: | Height: | Size: 3.4 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes33.png
vendored
Normal file
After Width: | Height: | Size: 3.9 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes34.png
vendored
Normal file
After Width: | Height: | Size: 4.5 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes35.png
vendored
Normal file
After Width: | Height: | Size: 3.8 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes36.png
vendored
Normal file
After Width: | Height: | Size: 4.1 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes37.png
vendored
Normal file
After Width: | Height: | Size: 3.9 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes38.png
vendored
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes39.png
vendored
Normal file
After Width: | Height: | Size: 3.0 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes4.png
vendored
Normal file
After Width: | Height: | Size: 354 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes40.png
vendored
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes41.png
vendored
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes42.png
vendored
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes43.png
vendored
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes44.png
vendored
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes45.png
vendored
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes46.png
vendored
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes47.png
vendored
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes48.png
vendored
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes49.png
vendored
Normal file
After Width: | Height: | Size: 922 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes5.png
vendored
Normal file
After Width: | Height: | Size: 356 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes50.png
vendored
Normal file
After Width: | Height: | Size: 955 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes51.png
vendored
Normal file
After Width: | Height: | Size: 972 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes52.png
vendored
Normal file
After Width: | Height: | Size: 866 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes53.png
vendored
Normal file
After Width: | Height: | Size: 877 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes54.png
vendored
Normal file
After Width: | Height: | Size: 905 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes55.png
vendored
Normal file
After Width: | Height: | Size: 388 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes56.png
vendored
Normal file
After Width: | Height: | Size: 465 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes57.png
vendored
Normal file
After Width: | Height: | Size: 465 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes58.png
vendored
Normal file
After Width: | Height: | Size: 550 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes59.png
vendored
Normal file
After Width: | Height: | Size: 550 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes6.png
vendored
Normal file
After Width: | Height: | Size: 469 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes60.png
vendored
Normal file
After Width: | Height: | Size: 457 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes61.png
vendored
Normal file
After Width: | Height: | Size: 457 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes62.png
vendored
Normal file
After Width: | Height: | Size: 4.8 KiB |
BIN
front/dist/resources/customisation/character_clothes/character_clothes63.png
vendored
Normal file
After Width: | Height: | Size: 529 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes64.png
vendored
Normal file
After Width: | Height: | Size: 529 B |
BIN
front/dist/resources/customisation/character_clothes/character_clothes65.png
vendored
Normal file
After Width: | Height: | Size: 3.4 KiB |