types-nora-api 0.0.150 → 0.0.152
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/classes.d.ts +106 -44
- package/dist/classes.js +30 -14
- package/package.json +1 -1
package/dist/classes.d.ts
CHANGED
|
@@ -754,22 +754,32 @@ type TelemetrySnapshot = {
|
|
|
754
754
|
lastEvents: TelemetryEventLog[];
|
|
755
755
|
serverTime: number;
|
|
756
756
|
};
|
|
757
|
-
type EventoTipo = '
|
|
758
|
-
type
|
|
759
|
-
tipo:
|
|
757
|
+
type EventoTipo = 'envia' | 'emite' | 'envia-e-recebe';
|
|
758
|
+
type EventoEnvia<P = any> = {
|
|
759
|
+
tipo: 'envia';
|
|
760
|
+
payload: P;
|
|
761
|
+
response?: never;
|
|
762
|
+
};
|
|
763
|
+
type EventoEmite<P = any, R = any> = {
|
|
764
|
+
tipo: 'emite';
|
|
765
|
+
payload: P;
|
|
766
|
+
response: R;
|
|
767
|
+
};
|
|
768
|
+
type EventoEnviaERecebe<P = any, R = any> = {
|
|
769
|
+
tipo: 'envia-e-recebe';
|
|
760
770
|
payload: P;
|
|
761
|
-
} & (T extends 'recebe-envia' ? {
|
|
762
771
|
response: R;
|
|
763
|
-
}
|
|
764
|
-
type
|
|
765
|
-
type GatewayDef = Record<string,
|
|
766
|
-
|
|
767
|
-
|
|
772
|
+
};
|
|
773
|
+
type EventoSchema = EventoEnvia<any> | EventoEmite<any, any> | EventoEnviaERecebe<any, any>;
|
|
774
|
+
type GatewayDef = Record<string, EventoSchema>;
|
|
775
|
+
declare function createGateway<T extends {
|
|
776
|
+
[K in keyof T]: EventoSchema;
|
|
777
|
+
}>(def: T): T;
|
|
768
778
|
declare namespace EventosWebSocket {
|
|
769
779
|
const gateways: {
|
|
770
780
|
readonly Chat: {
|
|
771
781
|
testeChat1: {
|
|
772
|
-
tipo: "recebe
|
|
782
|
+
tipo: "envia-e-recebe";
|
|
773
783
|
payload: {
|
|
774
784
|
mensagem: string;
|
|
775
785
|
};
|
|
@@ -778,7 +788,7 @@ declare namespace EventosWebSocket {
|
|
|
778
788
|
};
|
|
779
789
|
};
|
|
780
790
|
testeDuplicado: {
|
|
781
|
-
tipo: "recebe
|
|
791
|
+
tipo: "envia-e-recebe";
|
|
782
792
|
payload: {};
|
|
783
793
|
response: {
|
|
784
794
|
msg: string;
|
|
@@ -787,7 +797,7 @@ declare namespace EventosWebSocket {
|
|
|
787
797
|
};
|
|
788
798
|
readonly GameEngine: {
|
|
789
799
|
testeGameEngine1: {
|
|
790
|
-
tipo: "recebe
|
|
800
|
+
tipo: "envia-e-recebe";
|
|
791
801
|
payload: {
|
|
792
802
|
teste1: string;
|
|
793
803
|
};
|
|
@@ -796,14 +806,8 @@ declare namespace EventosWebSocket {
|
|
|
796
806
|
msg: string;
|
|
797
807
|
};
|
|
798
808
|
};
|
|
799
|
-
testeGameEngine2: {
|
|
800
|
-
tipo: "recebe";
|
|
801
|
-
payload: {
|
|
802
|
-
teste2: number;
|
|
803
|
-
};
|
|
804
|
-
};
|
|
805
809
|
testeDuplicado: {
|
|
806
|
-
tipo: "recebe
|
|
810
|
+
tipo: "envia-e-recebe";
|
|
807
811
|
payload: {};
|
|
808
812
|
response: {
|
|
809
813
|
msg: string;
|
|
@@ -812,7 +816,29 @@ declare namespace EventosWebSocket {
|
|
|
812
816
|
};
|
|
813
817
|
readonly UsuariosConectados: {
|
|
814
818
|
obtemUsuariosConectados: {
|
|
815
|
-
tipo: "
|
|
819
|
+
tipo: "emite";
|
|
820
|
+
payload: {};
|
|
821
|
+
response: {
|
|
822
|
+
msg: string;
|
|
823
|
+
};
|
|
824
|
+
};
|
|
825
|
+
};
|
|
826
|
+
readonly Teste: {
|
|
827
|
+
mudaTexto: {
|
|
828
|
+
tipo: "envia";
|
|
829
|
+
payload: {
|
|
830
|
+
novoTexto: string;
|
|
831
|
+
};
|
|
832
|
+
};
|
|
833
|
+
enviaPraQuemPediu: {
|
|
834
|
+
tipo: "emite";
|
|
835
|
+
payload: {};
|
|
836
|
+
response: {
|
|
837
|
+
msg: string;
|
|
838
|
+
};
|
|
839
|
+
};
|
|
840
|
+
enviaPraTodoMundo: {
|
|
841
|
+
tipo: "emite";
|
|
816
842
|
payload: {};
|
|
817
843
|
response: {
|
|
818
844
|
msg: string;
|
|
@@ -821,6 +847,10 @@ declare namespace EventosWebSocket {
|
|
|
821
847
|
};
|
|
822
848
|
};
|
|
823
849
|
}
|
|
850
|
+
type EventosEmiteMap = typeof Eventos_Emite;
|
|
851
|
+
type EventoEmiteAny = {
|
|
852
|
+
[G in keyof EventosEmiteMap]: EventosEmiteMap[G]['eventos'][keyof EventosEmiteMap[G]['eventos']];
|
|
853
|
+
}[keyof EventosEmiteMap];
|
|
824
854
|
type SOCKET_AcessoUsuario = {
|
|
825
855
|
usuario: UsuarioDto;
|
|
826
856
|
paginaAtual?: PaginaObjeto | null;
|
|
@@ -986,28 +1016,42 @@ declare function criarEventosFiltrados<Tipo extends EventoTipoLiteral>(tipo: Tip
|
|
|
986
1016
|
readonly fullName: `${Extract<G, string>}:${Extract<E, string>}`;
|
|
987
1017
|
}; };
|
|
988
1018
|
}; };
|
|
989
|
-
declare const
|
|
1019
|
+
declare const Eventos_Envia: {
|
|
990
1020
|
readonly Chat: {
|
|
991
1021
|
eventos: {};
|
|
992
1022
|
};
|
|
993
1023
|
readonly GameEngine: {
|
|
1024
|
+
eventos: {};
|
|
1025
|
+
};
|
|
1026
|
+
readonly UsuariosConectados: {
|
|
1027
|
+
eventos: {};
|
|
1028
|
+
};
|
|
1029
|
+
readonly Teste: {
|
|
994
1030
|
eventos: {
|
|
995
|
-
|
|
996
|
-
tipo: "
|
|
1031
|
+
mudaTexto: {
|
|
1032
|
+
tipo: "envia";
|
|
997
1033
|
payload: {
|
|
998
|
-
|
|
1034
|
+
novoTexto: string;
|
|
999
1035
|
};
|
|
1000
1036
|
} & {
|
|
1001
|
-
readonly nome: "
|
|
1002
|
-
readonly gateway: "
|
|
1003
|
-
readonly fullName: "
|
|
1037
|
+
readonly nome: "mudaTexto";
|
|
1038
|
+
readonly gateway: "Teste";
|
|
1039
|
+
readonly fullName: "Teste:mudaTexto";
|
|
1004
1040
|
};
|
|
1005
1041
|
};
|
|
1006
1042
|
};
|
|
1043
|
+
};
|
|
1044
|
+
declare const Eventos_Emite: {
|
|
1045
|
+
readonly Chat: {
|
|
1046
|
+
eventos: {};
|
|
1047
|
+
};
|
|
1048
|
+
readonly GameEngine: {
|
|
1049
|
+
eventos: {};
|
|
1050
|
+
};
|
|
1007
1051
|
readonly UsuariosConectados: {
|
|
1008
1052
|
eventos: {
|
|
1009
1053
|
obtemUsuariosConectados: {
|
|
1010
|
-
tipo: "
|
|
1054
|
+
tipo: "emite";
|
|
1011
1055
|
payload: {};
|
|
1012
1056
|
response: {
|
|
1013
1057
|
msg: string;
|
|
@@ -1019,23 +1063,38 @@ declare const Eventos_Recebe: {
|
|
|
1019
1063
|
};
|
|
1020
1064
|
};
|
|
1021
1065
|
};
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1066
|
+
readonly Teste: {
|
|
1067
|
+
eventos: {
|
|
1068
|
+
enviaPraQuemPediu: {
|
|
1069
|
+
tipo: "emite";
|
|
1070
|
+
payload: {};
|
|
1071
|
+
response: {
|
|
1072
|
+
msg: string;
|
|
1073
|
+
};
|
|
1074
|
+
} & {
|
|
1075
|
+
readonly nome: "enviaPraQuemPediu";
|
|
1076
|
+
readonly gateway: "Teste";
|
|
1077
|
+
readonly fullName: "Teste:enviaPraQuemPediu";
|
|
1078
|
+
};
|
|
1079
|
+
enviaPraTodoMundo: {
|
|
1080
|
+
tipo: "emite";
|
|
1081
|
+
payload: {};
|
|
1082
|
+
response: {
|
|
1083
|
+
msg: string;
|
|
1084
|
+
};
|
|
1085
|
+
} & {
|
|
1086
|
+
readonly nome: "enviaPraTodoMundo";
|
|
1087
|
+
readonly gateway: "Teste";
|
|
1088
|
+
readonly fullName: "Teste:enviaPraTodoMundo";
|
|
1089
|
+
};
|
|
1090
|
+
};
|
|
1032
1091
|
};
|
|
1033
1092
|
};
|
|
1034
|
-
declare const
|
|
1093
|
+
declare const Eventos_EnviaERecebe: {
|
|
1035
1094
|
readonly Chat: {
|
|
1036
1095
|
eventos: {
|
|
1037
1096
|
testeChat1: {
|
|
1038
|
-
tipo: "recebe
|
|
1097
|
+
tipo: "envia-e-recebe";
|
|
1039
1098
|
payload: {
|
|
1040
1099
|
mensagem: string;
|
|
1041
1100
|
};
|
|
@@ -1048,7 +1107,7 @@ declare const Eventos_RecebeEnvia: {
|
|
|
1048
1107
|
readonly fullName: "Chat:testeChat1";
|
|
1049
1108
|
};
|
|
1050
1109
|
testeDuplicado: {
|
|
1051
|
-
tipo: "recebe
|
|
1110
|
+
tipo: "envia-e-recebe";
|
|
1052
1111
|
payload: {};
|
|
1053
1112
|
response: {
|
|
1054
1113
|
msg: string;
|
|
@@ -1063,7 +1122,7 @@ declare const Eventos_RecebeEnvia: {
|
|
|
1063
1122
|
readonly GameEngine: {
|
|
1064
1123
|
eventos: {
|
|
1065
1124
|
testeGameEngine1: {
|
|
1066
|
-
tipo: "recebe
|
|
1125
|
+
tipo: "envia-e-recebe";
|
|
1067
1126
|
payload: {
|
|
1068
1127
|
teste1: string;
|
|
1069
1128
|
};
|
|
@@ -1077,7 +1136,7 @@ declare const Eventos_RecebeEnvia: {
|
|
|
1077
1136
|
readonly fullName: "GameEngine:testeGameEngine1";
|
|
1078
1137
|
};
|
|
1079
1138
|
testeDuplicado: {
|
|
1080
|
-
tipo: "recebe
|
|
1139
|
+
tipo: "envia-e-recebe";
|
|
1081
1140
|
payload: {};
|
|
1082
1141
|
response: {
|
|
1083
1142
|
msg: string;
|
|
@@ -1092,10 +1151,13 @@ declare const Eventos_RecebeEnvia: {
|
|
|
1092
1151
|
readonly UsuariosConectados: {
|
|
1093
1152
|
eventos: {};
|
|
1094
1153
|
};
|
|
1154
|
+
readonly Teste: {
|
|
1155
|
+
eventos: {};
|
|
1156
|
+
};
|
|
1095
1157
|
};
|
|
1096
1158
|
type SOCKET_UsuarioExistente = {
|
|
1097
1159
|
id: number;
|
|
1098
1160
|
username: string;
|
|
1099
1161
|
avatar: string;
|
|
1100
1162
|
};
|
|
1101
|
-
export { IArcoAventura, ArcoAventuraDto, IAventura, AventuraDto, IConviteGrupoAventuraPersonagem, ConviteGrupoAventuraPersonagemDto, IGrupoAventura, GrupoAventuraDto, IGrupoAventuraPersonagem, GrupoAventuraPersonagemDto, IRespostaConvite, RespostaConviteDto, IVariavelAmbiente, VariavelAmbienteDto, IConquista, ConquistaDto, ITipoConquista, TipoConquistaDto, IDetalheSessaoAventura, DetalheSessaoAventuraDto, IDetalheSessaoCanonica, DetalheSessaoCanonicaDto, CapituloSessaoCanonica, IDetalheSessaoNaoCanonica, DetalheSessaoNaoCanonicaDto, IDetalheSessaoUnica, DetalheSessaoUnicaDto, IParticipanteSessaoUnica, ParticipanteSessaoUnicaDto, ICoeficienteGanhoEstatisticaClasse, CoeficienteGanhoEstatisticaClasseDto, IGanhoNivelClasse, GanhoNivelClasseDto, DadosDoTipoGanho, DadosGanho_Atributos, DadosGanho_Pericias, DadosGanho_Estatisticas, DadosGanho_Classes, DadosGanho_ValorMaximoAtributo, DadosGanho_PontosHabilidadesEspeciais, DadosGanho_PontosHabilidadesParanormais, DadosGanho_PontosHabilidadeElemental, IGanhoRelativoCoeficienteAtributo, GanhoRelativoCoeficienteAtributoDto, ITipoGanhoNivel, TipoGanhoNivelDto, IGeracao, GeracaoDto, IImagem, ImagemDto, ITipoImagem, TipoImagemDto, IAlcance, AlcanceDto, IAtributo, AtributoDto, ICategoriaRitual, CategoriaRitualDto, ICirculoRitual, CirculoRitualDto, IClasse, ClasseDto, IDuracao, DuracaoDto, IElemento, ElementoDto, IEstatisticaDanificavel, EstatisticaDanificavelDto, IExecucao, ExecucaoDto, IFormatoAlcance, FormatoAlcanceDto, ILinhaEfeito, LinhaEfeitoDto, INivel, NivelDto, INivelComponente, NivelComponenteDto, INivelProficiencia, NivelProficienciaDto, INivelRitual, NivelRitualDto, IPatentePericia, PatentePericiaDto, IPericia, PericiaDto, IProficiencia, ProficienciaDto, ITipoAlvo, TipoAlvoDto, ITipoCategoria, TipoCategoriaDto, ITipoDano, TipoDanoDto, ITipoEfeito, TipoEfeitoDto, ITipoItem, TipoItemDto, ITipoProficiencia, TipoProficienciaDto, ILink, LinkDto, ITipoLink, TipoLinkDto, IDificuldadeSessao, DificuldadeSessaoDto, IEstiloSessaoMestrada, EstiloSessaoMestradaDto, ITipoSessao, TipoSessaoDto, IPerfilAdmin, PerfilAdminDto, IPerfilJogador, PerfilJogadorDto, IPerfilMestre, PerfilMestreDto, IFichaPersonagem, FichaPersonagemDto, ObjetoFicha, DetalheEvolucao, DetalhesExtras, FichaDeJogo, AtributoFicha, PericiaFicha, EstatisticaDanificavelFicha, DetalheFicha, RegistroPericiaLivre, IInformacaoPersonagem, InformacaoPersonagemDto, IPersonagem, PersonagemDto, IResumoPersonagemAventura, ResumoPersonagemAventuraDto, ITipoPersonagem, TipoPersonagemDto, IDetalheRascunhoAventura, DetalheRascunhoAventuraDto, IDetalheRascunhoSessaoUnica, DetalheRascunhoSessaoUnicaDto, IDetalheRascunhoSessaoUnicaCanonica, DetalheRascunhoSessaoUnicaCanonicaDto, IRascunho, RascunhoDto, IEstudo, EstudoDto, IRegistroSessao, RegistroSessaoDto, ISessao, SessaoDto, AuthSession, ICustomizacaoUsuario, CustomizacaoUsuarioDto, IDisponibilidadeUsuario, DisponibilidadeUsuarioDto, ListaDisponibilidadesUsuario, DisponibilidadesDDS, JanelaDisponibilidade, IUsuario, UsuarioDto, PAGINAS, PaginaChave, PaginaObjeto, TelemetryConnectionInfo, TelemetryEventLog, TelemetrySnapshot, EventoTipo,
|
|
1163
|
+
export { IArcoAventura, ArcoAventuraDto, IAventura, AventuraDto, IConviteGrupoAventuraPersonagem, ConviteGrupoAventuraPersonagemDto, IGrupoAventura, GrupoAventuraDto, IGrupoAventuraPersonagem, GrupoAventuraPersonagemDto, IRespostaConvite, RespostaConviteDto, IVariavelAmbiente, VariavelAmbienteDto, IConquista, ConquistaDto, ITipoConquista, TipoConquistaDto, IDetalheSessaoAventura, DetalheSessaoAventuraDto, IDetalheSessaoCanonica, DetalheSessaoCanonicaDto, CapituloSessaoCanonica, IDetalheSessaoNaoCanonica, DetalheSessaoNaoCanonicaDto, IDetalheSessaoUnica, DetalheSessaoUnicaDto, IParticipanteSessaoUnica, ParticipanteSessaoUnicaDto, ICoeficienteGanhoEstatisticaClasse, CoeficienteGanhoEstatisticaClasseDto, IGanhoNivelClasse, GanhoNivelClasseDto, DadosDoTipoGanho, DadosGanho_Atributos, DadosGanho_Pericias, DadosGanho_Estatisticas, DadosGanho_Classes, DadosGanho_ValorMaximoAtributo, DadosGanho_PontosHabilidadesEspeciais, DadosGanho_PontosHabilidadesParanormais, DadosGanho_PontosHabilidadeElemental, IGanhoRelativoCoeficienteAtributo, GanhoRelativoCoeficienteAtributoDto, ITipoGanhoNivel, TipoGanhoNivelDto, IGeracao, GeracaoDto, IImagem, ImagemDto, ITipoImagem, TipoImagemDto, IAlcance, AlcanceDto, IAtributo, AtributoDto, ICategoriaRitual, CategoriaRitualDto, ICirculoRitual, CirculoRitualDto, IClasse, ClasseDto, IDuracao, DuracaoDto, IElemento, ElementoDto, IEstatisticaDanificavel, EstatisticaDanificavelDto, IExecucao, ExecucaoDto, IFormatoAlcance, FormatoAlcanceDto, ILinhaEfeito, LinhaEfeitoDto, INivel, NivelDto, INivelComponente, NivelComponenteDto, INivelProficiencia, NivelProficienciaDto, INivelRitual, NivelRitualDto, IPatentePericia, PatentePericiaDto, IPericia, PericiaDto, IProficiencia, ProficienciaDto, ITipoAlvo, TipoAlvoDto, ITipoCategoria, TipoCategoriaDto, ITipoDano, TipoDanoDto, ITipoEfeito, TipoEfeitoDto, ITipoItem, TipoItemDto, ITipoProficiencia, TipoProficienciaDto, ILink, LinkDto, ITipoLink, TipoLinkDto, IDificuldadeSessao, DificuldadeSessaoDto, IEstiloSessaoMestrada, EstiloSessaoMestradaDto, ITipoSessao, TipoSessaoDto, IPerfilAdmin, PerfilAdminDto, IPerfilJogador, PerfilJogadorDto, IPerfilMestre, PerfilMestreDto, IFichaPersonagem, FichaPersonagemDto, ObjetoFicha, DetalheEvolucao, DetalhesExtras, FichaDeJogo, AtributoFicha, PericiaFicha, EstatisticaDanificavelFicha, DetalheFicha, RegistroPericiaLivre, IInformacaoPersonagem, InformacaoPersonagemDto, IPersonagem, PersonagemDto, IResumoPersonagemAventura, ResumoPersonagemAventuraDto, ITipoPersonagem, TipoPersonagemDto, IDetalheRascunhoAventura, DetalheRascunhoAventuraDto, IDetalheRascunhoSessaoUnica, DetalheRascunhoSessaoUnicaDto, IDetalheRascunhoSessaoUnicaCanonica, DetalheRascunhoSessaoUnicaCanonicaDto, IRascunho, RascunhoDto, IEstudo, EstudoDto, IRegistroSessao, RegistroSessaoDto, ISessao, SessaoDto, AuthSession, ICustomizacaoUsuario, CustomizacaoUsuarioDto, IDisponibilidadeUsuario, DisponibilidadeUsuarioDto, ListaDisponibilidadesUsuario, DisponibilidadesDDS, JanelaDisponibilidade, IUsuario, UsuarioDto, PAGINAS, PaginaChave, PaginaObjeto, TelemetryConnectionInfo, TelemetryEventLog, TelemetrySnapshot, EventoTipo, EventoEnvia, EventoEmite, EventoEnviaERecebe, EventoSchema, GatewayDef, createGateway, EventosWebSocket, EventosEmiteMap, EventoEmiteAny, SOCKET_AcessoUsuario, PaletaCores, EstruturaPaginaDefinicao, ConteudoItem, DefinicaoElemento, ListaItem, AventuraEstado, EstadoPendenciaPersonagem, EstadoPendenciaAdministrativaPersonagem, EstadoOcupacaoPersonagem, EstadoSessao, DiaDaSemana, obtemDiaDaSemanaPorExtensoPorDDS, NumeroHora24, NumeroMomento, MomentoFormatado24, MomentoFormatado, CargoExibicaoUsuario, CargosUsuario, ObjetoAutenticacao, ObjetoCache, ObjetoPendeciaPersonagem, TipoVariavelAmbiente, ObjetoEvolucaoCompleto, ObjetoEvolucao, ObjetoGanhosEvolucao, GanhoEstatistica, FormatoMomento, DetalheUtilizacaoRascunho, EstiloSessao, Gateways, EventoTipoLiteral, FiltraEventosPorTipo, criarEventosFiltrados, Eventos_Envia, Eventos_Emite, Eventos_EnviaERecebe, SOCKET_UsuarioExistente };
|
package/dist/classes.js
CHANGED
|
@@ -74,46 +74,62 @@ const PAGINAS = {
|
|
|
74
74
|
nome: 'Página de Mestre',
|
|
75
75
|
},
|
|
76
76
|
};
|
|
77
|
-
function createGateway(
|
|
77
|
+
function createGateway(def) { return def; }
|
|
78
78
|
//
|
|
79
79
|
var EventosWebSocket;
|
|
80
80
|
(function (EventosWebSocket) {
|
|
81
81
|
const Chat = createGateway({
|
|
82
82
|
testeChat1: {
|
|
83
|
-
tipo: 'recebe
|
|
83
|
+
tipo: 'envia-e-recebe',
|
|
84
84
|
payload: { mensagem: '' },
|
|
85
85
|
response: { entregue: true },
|
|
86
86
|
},
|
|
87
87
|
testeDuplicado: {
|
|
88
|
-
tipo: 'recebe
|
|
88
|
+
tipo: 'envia-e-recebe',
|
|
89
89
|
payload: {},
|
|
90
90
|
response: { msg: '' },
|
|
91
91
|
},
|
|
92
92
|
});
|
|
93
93
|
const GameEngine = createGateway({
|
|
94
94
|
testeGameEngine1: {
|
|
95
|
-
tipo: 'recebe
|
|
95
|
+
tipo: 'envia-e-recebe',
|
|
96
96
|
payload: { teste1: '' },
|
|
97
97
|
response: { ok: true, msg: '' },
|
|
98
98
|
},
|
|
99
|
-
testeGameEngine2: {
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
},
|
|
99
|
+
// testeGameEngine2: {
|
|
100
|
+
// tipo: 'emite',
|
|
101
|
+
// payload: { teste2: 0 },
|
|
102
|
+
// },
|
|
103
103
|
testeDuplicado: {
|
|
104
|
-
tipo: 'recebe
|
|
104
|
+
tipo: 'envia-e-recebe',
|
|
105
105
|
payload: {},
|
|
106
106
|
response: { msg: '' },
|
|
107
107
|
},
|
|
108
108
|
});
|
|
109
109
|
const UsuariosConectados = createGateway({
|
|
110
110
|
obtemUsuariosConectados: {
|
|
111
|
-
tipo: '
|
|
111
|
+
tipo: 'emite',
|
|
112
|
+
payload: {},
|
|
113
|
+
response: { msg: '' },
|
|
114
|
+
},
|
|
115
|
+
});
|
|
116
|
+
const Teste = createGateway({
|
|
117
|
+
mudaTexto: {
|
|
118
|
+
tipo: 'envia',
|
|
119
|
+
payload: { novoTexto: '' },
|
|
120
|
+
},
|
|
121
|
+
enviaPraQuemPediu: {
|
|
122
|
+
tipo: 'emite',
|
|
123
|
+
payload: {},
|
|
124
|
+
response: { msg: '' },
|
|
125
|
+
},
|
|
126
|
+
enviaPraTodoMundo: {
|
|
127
|
+
tipo: 'emite',
|
|
112
128
|
payload: {},
|
|
113
129
|
response: { msg: '' },
|
|
114
130
|
},
|
|
115
131
|
});
|
|
116
|
-
EventosWebSocket.gateways = { Chat, GameEngine, UsuariosConectados };
|
|
132
|
+
EventosWebSocket.gateways = { Chat, GameEngine, UsuariosConectados, Teste };
|
|
117
133
|
})(EventosWebSocket || (EventosWebSocket = {}));
|
|
118
134
|
// @tipoCompartilhadoFront
|
|
119
135
|
var AventuraEstado;
|
|
@@ -219,7 +235,7 @@ function criarEventosFiltrados(tipo) {
|
|
|
219
235
|
}
|
|
220
236
|
return result;
|
|
221
237
|
}
|
|
222
|
-
const Eventos_Recebe = criarEventosFiltrados('recebe');
|
|
223
238
|
const Eventos_Envia = criarEventosFiltrados('envia');
|
|
224
|
-
const
|
|
225
|
-
|
|
239
|
+
const Eventos_Emite = criarEventosFiltrados('emite');
|
|
240
|
+
const Eventos_EnviaERecebe = criarEventosFiltrados('envia-e-recebe');
|
|
241
|
+
export { AuthSession, PAGINAS, createGateway, EventosWebSocket, AventuraEstado, EstadoPendenciaPersonagem, EstadoPendenciaAdministrativaPersonagem, EstadoOcupacaoPersonagem, EstadoSessao, DiaDaSemana, obtemDiaDaSemanaPorExtensoPorDDS, CargoExibicaoUsuario, FormatoMomento, EstiloSessao, criarEventosFiltrados, Eventos_Envia, Eventos_Emite, Eventos_EnviaERecebe };
|