优化座驾特效入场标题
This commit is contained in:
@@ -482,10 +482,15 @@ export function bindChatEvents() {
|
||||
const target = e.detail?.target_username;
|
||||
const operator = e.detail?.operator;
|
||||
const myName = window.chatContext?.username;
|
||||
const effectOptions = {
|
||||
effect_title: e.detail?.effect_title,
|
||||
ride_name: e.detail?.ride_name,
|
||||
operator,
|
||||
};
|
||||
|
||||
if (type && typeof EffectManager !== "undefined") {
|
||||
if (!target || target === myName || operator === myName) {
|
||||
EffectManager.play(type);
|
||||
EffectManager.play(type, effectOptions);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -81,7 +81,7 @@ function playEntryEffect(initialState) {
|
||||
}
|
||||
|
||||
window.setTimeout(() => {
|
||||
window.EffectManager?.play?.(initialState.entryEffect);
|
||||
window.EffectManager?.play?.(initialState.entryEffect, initialState.entryEffectOptions || {});
|
||||
}, 1000);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user