|
|
@@ -198,15 +198,18 @@ export const destroy = () => {
|
|
|
|
|
|
// 为了兼容性而添加的方法导出
|
|
|
export function addText(d, e) {
|
|
|
+ if (!model) return;
|
|
|
if (modelContextList[0]) modelContextList[0].context?.addText(d);
|
|
|
if (modelContextList[1]) modelContextList[1].context?.addText(e);
|
|
|
if (modelContextList[2]) modelContextList[2].context?.addText(d);
|
|
|
}
|
|
|
export function addCssText() {
|
|
|
+ if (!model) return;
|
|
|
if (modelContextList[0] && modelContextList[0].context && modelContextList[0].context['addCssText']) modelContextList[0].context['addCssText']();
|
|
|
if (modelContextList[2] && modelContextList[2].context && modelContextList[2].context['addCssText']) modelContextList[2].context['addCssText']();
|
|
|
}
|
|
|
export function playSmoke(d) {
|
|
|
+ if (!model) return;
|
|
|
for (let i = 0; i < modelContextList.length; i++) {
|
|
|
const item = modelContextList[i];
|
|
|
if (item.context && item.context.playSmoke) item.context.playSmoke(d);
|