Maya nParticle only calculates friction/stickness between particles and rigid bodies, not friction is encountered between particles. My guess is the algorithm complexity is too high. Anyway there is two relative easy ways to fake the effect, according to my searching.
想要用一个一包糖粒堆在物体(对又是它..)上的片段,发现Maya的nParticle只计算粒子和Rigid body的摩擦力不计算粒子和粒子间的摩擦力(想来是算法复杂度太高了),所以不管怎么搞最终都会摊成大烧饼,并且还会不停的抽搐.. 查了下大概有两个相对简单的方法
1. hold particles with a invisible rigid body. 2. Use RealFlow, which seems to have much more handy control over particles
I’m not happy with either. 1 is lame. 2 too much trouble, have to get hang of another environment. If I must do scripting, I choose to learn mel.

So the algorithm is:
It’s unlikely to mess with friction as I guessed above. I tried to modify per particle mass to let them stuck in the space. Yea that works but they tend to be headbutted by other particles and flying around.. for science. Later I googled out it’s possible to control force field per particle, with attribute named “Field name”_”option name”. That is to say adding attribute “gravityField1_magnitude” to nParticle2 will grant you control over per particle gravity from the field.
On creation:
[php]
global int $freezeCap=5; //be completely frozen after the cap rounds
global int $gravityPP=500;
global float $dragPP=100;
global float $accelerationTrigger=15; //the speed parameter to trigger ‘I’m free again!", which leads to free droping.
global int $n[100000]; //how many times have the particle been locked
global int $preVel[100000]; //velocity of last frame
global int $locked[100000];
nParticleShape4.dragField1_magnitude=0;
nParticleShape4.gravityField1_magnitude=$gravityPP;
global int $init=1;
if($init==1) {
int $i;
for($i=0;$i<100000;$i++) {
$n[$i]=0;
$locked[$i]=0;
}
$init=0;
}
[/php]
Before dynamics:
[php]
int $id=nParticleShape4.particleId;
float $vel=abs(nParticleShape4.velocity);
//print("nParticleShape2.velocity "+$nParticleShape2.velocity+"\n");
if($vel>$preVel[$id]+$accelerationTrigger) {
$n[$id]=0;
nParticleShape4.dragField1_magnitude=0; //If it’s free again, unlock and erase record
}
else {
$freezeFact=$n[$id]/$freezeCap; //progress bar of locking
if($freezeFact>1)
$freezeFact=1;
$n[$id]+=1;
nParticleShape4.dragField1_magnitude=$freezeFact*$dragPP; //increase drag force depending on locking level
nParticleShape4.gravityField1_magnitude=$gravityPP*(1-$freezeFact)*(1-$freezeFact); //parabola is better according to experiment
nParticleShape4.velocity=<<0,0,0>>;
}
$preVel[$id]=nParticleShape4.velocity;
[/php]
The script is not bad to me.. adjustable parameters are handy. Time efficiency is acceptable (as a former ACMer, I can confirm this is O(n), can’t be better). 20 million particles * 100 frames cost my i7 half an hour. Not perfect but enough for bragging.
1. 弄个透明的动画的rigid body来把粒子圈起来。 2. 用RealFlow,我只用RealFlow模拟水,但是显然那它对粒子的控制比Maya厉害得多。
两个方法我都不高兴,1太不屌爆,2太麻烦,要做很多熟悉另一个环境的工作,且要写脚本,所以不如来学下mel。下了本书叫Maya Python — for Games and Film,翻了一百页发现Python在Maya上基本是庞大的workflow中工程师为了其他人方便写的maya程序,并且也要有mel基础,不是我要的。

总之,思路是:
想要计算摩擦力显然是不现实的,说过了。我先通过改质量的途径让粒子满足条件时失去质量以停在原地不受重力影响,停是能停住但是会被别的particle撞飞.. 非常科学。后来查到可以使用 <力场名>_<属性名> 的方式控制Per Particle的行为,即,给nParticle2添加名为gravityField1_magnitude的attribute程序就会使用它来控制它受到重力场1的magnitude。然后通过DragField让particle稳定。我在注释里详细说。
粒子生成时脚本:
[php]
global int $freezeCap=5; //be completely frozen after the cap rounds
global int $gravityPP=500;
global float $dragPP=100;
global float $accelerationTrigger=15; //the speed parameter to trigger ‘I’m free again!", which leads to free droping.
global int $n[100000]; //how many times have the particle been locked
global int $preVel[100000]; //velocity of last frame
global int $locked[100000];
nParticleShape4.dragField1_magnitude=0;
nParticleShape4.gravityField1_magnitude=$gravityPP;
global int $init=1;
if($init==1) {
int $i;
for($i=0;$i<100000;$i++) {
$n[$i]=0;
$locked[$i]=0;
}
$init=0;
}
[/php]
动态前的脚本:
[php]
int $id=nParticleShape4.particleId;
float $vel=abs(nParticleShape4.velocity);
//print("nParticleShape2.velocity "+$nParticleShape2.velocity+"\n");
if($vel>$preVel[$id]+$accelerationTrigger) {
$n[$id]=0;
nParticleShape4.dragField1_magnitude=0; //If it’s free again, unlock and erase record
}
else {
$freezeFact=$n[$id]/$freezeCap; //progress bar of locking
if($freezeFact>1)
$freezeFact=1;
$n[$id]+=1;
nParticleShape4.dragField1_magnitude=$freezeFact*$dragPP; //increase drag force depending on locking level
nParticleShape4.gravityField1_magnitude=$gravityPP*(1-$freezeFact)*(1-$freezeFact); //parabola is better according to experiment
nParticleShape4.velocity=<<0,0,0>>;
}
$preVel[$id]=nParticleShape4.velocity;
[/php]
个人感觉这个还不错,有很多参数可以控制,效率也还行(前ACMer表示这个就是O(n)..不能再低了),200万粒子100帧i7跑半个小时。显然不完美,蒙人没问题。
Świetny artykuł. Sporo przydatnych porad. Dzięki że dzielisz się wiedzą.
Będę zaglądać częściej.
Trafnie napisane – kwestia wystroju bywa trudna.
Przydatne podejście.
Bardzo przydatne. Szukałem takich informacji właśnie tego.
Dziękuję!
my webpage … Zlv426e.天堂.tw
When someone writes an piece of writing he/she keeps the image of a user in his/her brain that
how a user can understand it. So that’s why this post is outstdanding.
Thanks!
camisetadebarata.com se dedica a la fabricación y venta de camiseta tottenham 2026 desde hace más de una década.
Tejidos de alta calidad y precios bajos le proporcionan una
gran experiencia de compra online.
Veryy descriptive blog, I likerd thawt bit.
Willl there bbe a pazrt 2?
Heree iis myy blog; xxx2021.biz (Nichol)
Klasse Text. Reichlich konkrete Hinweise. Vielen Dank für diesen Inhalt.
Ich komme bestimmt wieder vorbei.
Genau – die Sache der Wohnungsgestaltung ist schwierig.
Gut, dass es jemand erklärt.
Wirklich nützlich. Ich war schon nach ähnlichen Tipps seit einiger Zeit gesucht.
Danke!
Take a look at my homepage; https://wiki.ithae.Net/index.php?Title=wie_man_auf_45_quadratmetern_modern_und_gemütlich_wohnt
you’re truly a just right webmaster. The web site loading velocity is
incredible. It kind of feels that you are doing any distinctive trick.
Furthermore, The contents are masterwork. you’ve done a magnificent process on this subject!
For hottest news you have to go to see web and on internet
I found this site as a most excellent web page for
newest updates.
I’vе been exploring the world of coin collесting for the ρast feᴡ weeks.
I found a lot of interеsting infoгmаtion here.
Mɑny articlеs about coin collecting feel outdated, bսt
this one was different.
Looking forward to reading more аrticles here.
Feeⅼ free to surf to my page: gold collectibles
Valuable information. Lucky me I discovered your website by chance, and
I am shocked why this twist of fate didn’t took place earlier!
I bookmarked it.
KUWIN là nền tảng cá cược trực tuyến vận hành
trên kiến trúc điện toán đám mây kết hợp mô hình bảo mật Zero-Trust, mang đến không
gian giải trí tối ưu độ trễ cho mọi hội viên. Hệ thống đồng bộ
hóa toàn diện các danh mục sản phẩm
chủ lực bao gồm Thể thao (cập nhật Odds theo thời gian thực), Casino trực tiếp với Dealer,
sảnh Game bài chiến thuật, cùng các dòng game cấu
trúc RNG như Nổ hũ và Bắn cá. Ngay sau quy trình đăng
ký và đăng nhập, luồng tài chính của người chơi được xử
lý khép kín qua cổng API thanh khoản tự động (nạp rút ngân hàng, ví điện tử) và được mã hóa bảo
vệ bởi giao thức SSL đa tầng. Để duy
trì trải nghiệm mượt mà và giải quyết triệt để
tình trạng link web KUWIN bị chặn do các đợt quét băng thông nhà mạng, người dùng được cung cấp
bộ giải pháp kỹ thuật dự phòng như tải app di động (iOS/Android) hoặc hướng dẫn cấu hình tải 1.1.1.1.
Mọi văn bản về quyền riêng tư, chính sách miễn trừ trách nhiệm cũng như cơ chế
cá cược có trách nhiệm đều được minh bạch hóa tại chuyên mục Câu hỏi thường gặp,
tạo nền tảng dữ liệu thực thể sạch giúp hệ thống đại lý KUWIN vận hành hiệu
quả và đạt điểm tin cậy tối ưu trước các thuật toán lõi của Google.
Great goods from you, man. I’ve understand your stuff previous to and you
are just extremely great. I actually like what you’ve acquired here, certainly like
what you’re stating and the way in which you say it. You make
it entertaining and you still care for to keep it smart. I can’t wait
to read much more from you. This is actually a great web site.
Прокси IPv6 с ротацией для майкрософт https://vpsnl.ru/ipv6-proksi/
It is perfect time to make some plans for the long
run and it’s time to be happy. I’ve learn this post and if I may
just I desire to suggest you few interesting issues or tips.
Perhaps you could write subsequent articles relating to this article.
I want to read more things approximately it!
Thanks in support of sharing such a pleasant opinion, paragraph is fastidious, thats why i have read it entirely
Naprawdę dobry wpis. Dużo praktycznych inspiracji.
Dzięki za ten materiał. Czekam na więcej.
Zgadzam się – sprawa wystroju potrafi być wymagająca.
Dobrze, że ktoś to wyjaśnia.
Bardzo przydatne. Szukałem takich informacji od dawna.
Dziękuję!
Here is my webpage … Lorenza
Thank you a bunch for sharing this with all of us you actually know what you’re talking about!
Bookmarked. Kindly also discuss with my web site =).
We can have a link alternate agreement between us
Hοw tо Pick the Ꭱight Mattress in Singapore – А No-Nonsense Practical Guide
Choosing а new mattress singapore is one оf thе biggest Singapore furniture investments mօst households ԝill make, yet it’s surprisingly easy to ɡet wrong.
The pressure іs real — yⲟu test foг seconds in thе furniture store, but
live ѡith thе result f᧐r years. Megafurniture’ѕ Somnuz mattresses give you a practical way to compare tһe most popular
mattress types ѕide by side in one furniture showroom.
Ꮋigh humidity, dust mites, and overnight air-conditioning սse all affect hօw a mattress singapore performs
oνer tіme. Bеcause Singapore stays humid ɑlmost aⅼl year, excellent breathability іs essential
fоr keeping a mattress singapore fresh. Ꭺ
largе numbеr of Singapore families deal ᴡith dust-mite reactions, еven if thеy һaven’t connected tһе dots to tһeir mattress.
The widespread ᥙse of aircon аt night can mаke certɑin foam types feel
firmer οr lesѕ comfortable tһan tһey did undeг bright
furniture showroom lights.
Мost mattress singapore options sold in Singapore fall іnto ᧐ne
of foᥙr main construction categories, ɑnd understanding tһe real differences helps yoս choose smarter.
Pocketed spring designs гemain popular Ьecause eɑch coil works on its own, reducing partner disturbance ᴡhile allowing air tto circulate freely.
Memory foam contours closely tо the body and excels
аt pressure relief, Ьut іt ϲan trap heat սnless specially engineered fߋr cooling.
Natural latex options feel lively аnd stay cooler while being moгe
resistant to dust mites tһan standard foam.Hybrid mattresses tгy to balance the support аnd breathability ߋf springs ᴡith the contouring comfort of foam or
latex.
Megafurniture’ѕ Somnuz collection conveniently represents tһe main construction types most local families ϲonsider.
Choosing tһe гight firmness level іs fɑr more personal than most mattress store shoppers expect.
Ѕide sleepers geneгally benefit fгom medium-soft to medium
firmness fоr proper spinal alignment. Вack sleepers tend
tο prefer medium tօ medium-firm fⲟr gooɗ lumbar support ѡithout flattening tһe natural curve.
Stomach sleepers ѕhould lean towаrԁ firmer options
to prevent tһe hips from sinking too fɑr.
Bedroom sizes in Singapore are often mοre compact tһan international standards assume, ѕo
gеtting the гight mattress size іs more іmportant tһan simply upgrading t᧐ king.
Cover fabric choice matters mor іn Singapore than moѕt buyers initially tһink.
Bamboo covers սsed іn some Somnuz models provide superior breathability аnd
һelp reduce musty build-up ovеr time. Water-repellent covers protect aɡainst spills, sweat, ɑnd humidity ingress
— еspecially ᥙseful for families with children or pets.
Ꮋere’s how the Somnuz mattresses ⅼine ᥙp with real household requirements іn Singapore.
Fоr vаlue-conscious buyers, tһe Somnuz Comfy
delivers goօd independent coil support at an accessible рrice point.
The Somnuz Comforto adԁs bamboo fabric and latex for those who prioritise breathability аnd natural dust-mite resistance.
Households tһаt need spill and humidity protection usuaⅼly lan toward the Somnuz Comfort Night model.
Тhe top-tier Somnuz Roman Supreme delivers premium support аnd
luxury feel for buyers ѡilling to invest in the higһest comfort level.
Ƭhe traditional ninety-second showroom test most people dо is almost useless for mаking ɑ gօod decision. Ꭲo get useful feedback,
spend at ⅼeast tеn minutes օn each model in the exact position youu normally sleep іn. Megafurniture’s flagship furniture store ɑt
134 Joo Seng Road and the Giant Tampines outlet both display the full Somnuz range in realistic bedroom settings, mаking extended testing mսch
easier.
Ꮇake ѕure the retailer ϲan deliver on үouг exact timeline, еspecially іf уou’refurnishing ɑ
new HDB oг condo. Asҝ about old mattress removal and study thе warranty details Ƅefore yߋu sign.
A quality mattress singapore ѕhould comfortably last 8–10 ʏears in Singapore conditions ѡhen chosen аnd maintained properly.
Ignoring еarly warning signs usually meɑns you end uр sleeping
on а worn-out mattress fɑr lοnger than you sһould.
Whethеr you prefer tօ shop іn person at tһeir showrooms ߋr online, Megafurniture
maкes choosing tһe rigһt mattress store option simple аnd transparent.
Here is my website Water Repellent Sofa
I’m really enjoying the design and layout of your blog. It’s a very easy
on the eyes which makes it much more enjoyable for me to come here and visit more often. Did you
hire out a developer to create your theme? Exceptional work!
I like the valuable information you provide in your articles.
I’ll bookmark your weblog and check again here frequently.
I am quite sure I’ll learn many new stuff right
here! Best of luck for the next!
If you desire to obtain a great deal from this article then you have to apply these
methods to your won weblog.
I am regular reader, how are you everybody? This piece of writing posted at this web site is
in fact good.
hi!,I love your writing so much! percentage we
keep up a correspondence extra about your post on AOL?
I require a specialist on this space to solve my problem.
May be that is you! Having a look ahead to see you.
I like what you guys are up too. Such clever work and exposure!
Keep up the terrific works guys I’ve included you guys to my own blogroll.
I like it when people come together and share views.
Great blog, continue the good work!
What i don’t realize is in fact how you’re no longer actually much more neatly-appreciated than you
might be right now. You are so intelligent. You recognize therefore considerably
when it comes to this matter, made me in my view believe it from a lot of varied angles.
Its like women and men don’t seem to be fascinated until it is one thing to do with Lady
gaga! Your individual stuffs excellent. At all times handle it
up!
Howdy just wanted to give you a quick heads up.
The words in your content seem to be running off the screen in Ie.
I’m not sure if this is a format issue or something to do with browser
compatibility but I figured I’d post to let you know.
The design and style look great though! Hope you get the issue resolved soon. Cheers
Great beat ! I wish to apprentice while you amend your web site, how could
i subscribe for a blog site? The account aided me a acceptable
deal. I had been a little bit acquainted of this your broadcast offered bright clear concept
I am really loving the theme/design of your web site. Do you ever run into
any web browser compatibility problems? A number
of my blog visitors have complained about my website
not working correctly in Explorer but looks great in Chrome.
Do you have any advice to help fix this issue?
Hilfreicher Inhalt. Reichlich nützliche Inspirationen. Super
für diesen Inhalt. Ich empfehle die Seite gerne weiter.
Du hast recht – die Frage der Möbelauswahl wird oft schwierig.
Danke für die klare Erklärung.
Echt praxisnah. Ich habe schon nach ähnlichen Tipps genau danach gesucht.
Danke!
my page Andy
I every time used to study piece of writing in news papers but now as I am a user of web therefore from now
I am using net for articles, thanks to web.
Wartościowy artykuł. Mnóstwo przydatnych wskazówek.
Super że dzielisz się wiedzą. Będę zaglądać częściej.
Zgadzam się – kwestia wystroju bywa wymagająca.
Przydatne podejście.
Bardzo przydatne. Szukałam takich informacji już jakiś czas.
Dziękuję!
Feel free to surf to my web page; Links.Gtanet.COM.Br
I pay a visit every day a few blogs and information sites to read posts, but this webpage
gives quality based content.
This inspired me to make a donation.
Grüße euch, ich bin beim Stöbern hier gelandet und ich muss zugeben, dass man hier echt was mitnimmt. Ich renoviere seit kurzem mein Haus und ich suche nach Inspiration. Liebe Grüße in die Runde.
Wertvoller Beitrag. Ich kann aus eigener Erfahrung sagen, dass die richtige Farbgebung die Basis von allem ist. Gut Ding will Weile haben.
My web site :: https://Cheater.fun/user/LesSik9887935/
アダルト フィギュア 無 修正wish to be hidden,but that aughtshould be hidden from it,
so I thought I would have a littlejoke at the familyI would tease the fatherly heart of FedoseyNikolaitch.”As soon as he took my letter and opened it,アジア えろ
Usually I do not learn article on blogs, however I would like to say that this
write-up very compelled me to try and do so! Your writing taste has been surprised me.
Thanks, very great post.
Hello! This is my 1st comment here so I just wanted to give a quick shout out
and tell you I truly enjoy reading your blog posts. Can you suggest any other blogs/websites/forums that deal with the same subjects?
Thank you so much!
Dzień dobry, trafiłem tu przypadkiem i chcę powiedzieć, że jest tu sporo wartościowych treści. Sam od jakiegoś czasu zmieniam wystrój i każda wskazówka jest na wagę złota. Pozdrawiam serdecznie.
Wartościowy wątek. Moim zdaniem dobór mebli ma ogromne znaczenie. Lepiej raz a dobrze.
Here is my web blog … https://freakapedia.com/index.php/Minimalizm_w_praktyce:_jak_urz%C4%85dzi%C4%87_wn%C4%99trze,_kt%C3%B3re_oddycha
Hi there! I know this is kind of off-topic but I had to ask.
Does managing a well-established website like yours require a massive
amount work? I am brand new to operating a blog but
I do write in my journal daily. I’d like to start a
blog so I can easily share my experience and feelings online.
Please let me know if you have any kind of ideas or tips
for brand new aspiring bloggers. Thankyou!
We recognize the value of your time, which is why we have incorporated
a Turbo Mode feature into Easy Videos Downloader.
It’s appropriate time to make some plans for the future and it is time to be happy.
I’ve read this post and if I could I want to suggest you some interesting things
or suggestions. Perhaps you could write next articles referring to this
article. I desire to read even more things about
it!
Nice share! Ulasan ini sangat relevan bagi saya yang suka mencari situs dengan modal kecil
namun terpercaya. Saya sangat puas bermain di **1131GG** karena mereka adalah **Bandar Slot Dana 5 Ribu** yang benar-benar memberikan **Layanan Cepat**.
Kelebihan lainnya adalah **Deposit Tanpa Biaya Tambahan**, jadi saldo kita tetap utuh.
Terima kasih sudah berbagi! Kunjungi 1131GG Sekarang
You really make it appear so easy with your presentation however I to find this
matter to be really one thing which I think I might never understand.
It seems too complicated and extremely wide for me. I am taking a look forward
on your subsequent publish, I will attempt to get the grasp of it!
This is really interesting, You’re a very skilled blogger.
I’ve joined your rss feed and look forward to seeking more of your excellent post.
Also, I’ve shared your website in my social networks!
bookmarked!!, I like your website!
This is a very informative post about online casinos and betting
platforms. I especially liked how it explains the importance of choosing a licensed
site before signing up.
Many players often ask where they can find reliable gaming
platforms with fair odds and smooth payouts. From what I’ve
seen, checking platforms like vn22vip helps users compare features, bonuses, and overall experience.
Thanks for sharing these insights — they’re helpful for both beginners and experienced bettors.
Woah! Sono davvero innamorato dal template/tema di
questo sito web. Semplice, eppure efficace. Spesso è difficile ottenere quel “perfetto equilibrio”
tra usabilità e aspetto visivo. Devo dire che hai fatto un lavoro grande.
Anche, il blog si carica super veloce per me su Chrome. Superbo blog —
stessa vibe che provo leggendo di Crazy Time!
Nice share! Ulasan ini sangat relevan dengan perkembangan industri hiburan saat
ini. Memang sulit mencari platform yang stabil, namun **1131GG** berhasil membuktikannya melalui integrasi **Slot Online**,
**Live Casino**, dan **Sports Entertainment** dalam satu tempat.
Sangat menginspirasi bagi pengembang platform digital lainnya!
Kunjungi 1131GG Official
Link exchange is nothing else however it is simply placing
the other person’s weblog link on your page at appropriate place and other
person will also do same in favor of you.