Comments (6)
先将想修改属性的组件保存到一个变量中,随后在回调事件中修改即可。看下面这两个小栗子,按下qwer上面的1234键看效果。
https://codepen.io/OriIIusion/pen/zYbEPpp
https://codepen.io/OriIIusion/pen/VwRMrxg
from orillusion.
先将想修改属性的组件保存到一个变量中,随后在回调事件中修改即可。看下面这两个小栗子,按下qwer上面的1234键看效果。 https://codepen.io/OriIIusion/pen/zYbEPpp https://codepen.io/OriIIusion/pen/VwRMrxg
蟹蟹~ 很感谢。
但我根据栗子用法尝试修改ParticleOverLifeScaleModule模块粒子的初始和结束时大小却修改不到。比如我是这样
this.OverLifeScaleModule = simulator.addModule(ParticleOverLifeScaleModule);
this.OverLifeScaleModule = [
new Vector4(0.1, 0.1,0.1),
new Vector4(0.1,0.1,0.1)
];
然后在事件中进行回调
this.OverLifeScaleModule = [
new Vector4(10, 10,10),
new Vector4(1,1, 1)
];
没有修改成功,是我的写法有问题吗?
from orillusion.
你可以先看看控制台有没有报错。
OverLifeScaleModule是一个模块,你想修改的那个大小,应该是下面这样写。
overLifeScaleModule.scaleSegments = [new Vector4(1, 1, 1), new Vector4(3, 3, 3)];
粗心了哦
from orillusion.
你可以先看看控制台有没有报错。 OverLifeScaleModule是一个模块,你想修改的那个大小,应该是下面这样写。 overLifeScaleModule.scaleSegments = [new Vector4(1, 1, 1), new Vector4(3, 3, 3)]; 粗心了哦
啊啊啊啊啊啊啊~~~好了~~ (^3^) (^3^) (^3^)
from orillusion.
想再追问下,修改发射器半径时。似乎会导致粒子重置发射,缺少了变大变小时的过渡效果,这个会尝试更新吗
from orillusion.
不清楚哎,我也是新手
from orillusion.
Related Issues (20)
- [BUG]: Uncaught (in promise) TypeError: Failed to execute 'requestDevice' on 'GPUAdapter': Unsupported feature: bgra8unorm-storage HOT 2
- [BUG]: dev分支,物理模块不能用了 HOT 1
- [FR]: 怎么修改粒子发射器的角度呢?
- [BUG]: FlyCameraController在初始化后setCamera不生效 HOT 2
- 添加的 wordpanel 如何在其他地方从场景中进行销毁 HOT 1
- [BUG]: 这里的代码似乎有问题 HOT 1
- [BUG]: 加载GLTF模型,模型显示错误 HOT 1
- [BUG]: 鼠标右键点击事件无效 HOT 1
- [BUG]: 设置PCF阴影,报错
- [BUG]: 加载obj文件失败
- [FR]: 给assets库添加了四个字体
- [BUG]: Blend首次打开页面不生效 HOT 1
- [BUG]: 控制台发出警告 HOT 2
- [FR]: 请问现在orillusion在绘制场景时,支持的模型文件最大是多少?单场景中模型的面数最大是多少? HOT 4
- [BUG]: The LoaderFunctions.OnUrl doesn't seem to be called HOT 3
- [FR]: 海量渲染WASM 申请内存时间太长 HOT 5
- [BUG]: 设置拾取模式为pixel后,添加bloompost报错 HOT 3
- [BUG]: 景深会影响2DUI HOT 1
- [BUG]: SSR,Fog会影响2DUI HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from orillusion.