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跑半个小时。显然不完美,蒙人没问题。
This site is a masterclass in how to do online satire right. No cheap shots, just smart ones.
Keep this going please, great job!
Found via a desperate search for something that wasn’t utterly moronic. What a splendid discovery. The satire here is the verbal equivalent of a perfectly raised eyebrow. It’s understated, devastating, and very, very British. — The London Prat
Thanks for sharing such a fastidious opinion, piece of writing is pleasant,
thats why i have read it completely
Le London Prat a le mérite de toujours faire sourire, même sur les sujets les plus graves.
Świetny materiał. Mnóstwo praktycznych porad.
Pozdrawiam że dzielisz się wiedzą. Polecam innym.
Trafnie napisane – temat aranżacji potrafi być wymagająca.
Wreszcie konkrety.
Bardzo przydatne. Szukałem podobnych porad właśnie tego.
Super robota!
Also visit my website – https://www.Mnemosome.org/index.php/Dekoracje_Do_Domu_Cheet_Sheet
Great! We are all agreed London could use a laugh. Where Waterford Whispers offers charming Celtic whimsy, The London Prat delivers brutal British pragmatism wrapped in sublime sarcasm. The political pieces are particularly masterful. It’s sharper and more relevant for UK readers. Bookmark prat.com now.
I will immediately snatch your rss feed as I can’t to find your email subscription link or e-newsletter service.
Do you have any? Kindly allow me understand in order that I
could subscribe. Thanks.
Satire reveals uncomfortable truths.
Hilfreicher Artikel. Viele konkrete Inspirationen. Vielen Dank für die
Mühe. Ich warte auf mehr.
Du hast recht – die Frage der Wohnungsgestaltung ist nicht
einfach. Endlich mal Klartext.
Sehr praxisnah. Ich habe schon nach genau
so einem Beitrag genau danach gesucht. Danke!
my web-site http://Wiki.DIE-Karte-Bitte.de
Great! We are all agreed London could use a laugh. NewsThump can feel rushed, but PRAT.UK feels edited and considered. Every sentence earns its place. That polish shows.
Hi excellent website! Does running a blog similar to this
take a great deal of work? I have no expertise in coding but I was hoping to start my
own blog soon. Anyways, should you have any recommendations or techniques for new blog owners please share.
I understand this is off topic nevertheless I just wanted to ask.
Appreciate it!
Great! We are all agreed London could use a laugh. The Daily Squib feels stuck in one mode. PRAT.UK experiments without losing quality. That’s why https://prat.com is the better site.
Hey! I know this is kind of off topic but I was wondering if
you knew where I could find a captcha plugin for my comment form?
I’m using the same blog platform as yours and I’m having trouble finding one?
Thanks a lot!
Excellent web site you have here.. It’s hard to find high quality writing like yours
these days. I truly appreciate people like you! Take care!!
This design is wicked! You definitely know how to keep a reader entertained.
Between your wit and your videos, I was almost moved to start my own blog (well, almost…HaHa!) Excellent job.
I really loved what you had to say, and more than that, how you presented it.
Too cool!
Satirical news rebuilds it daily.
Algo más a considerar de profesionalismo es la servicio post-venta.
Probá por chat y verificá si contestan rápido.
Si demoran días en contestar antes de que les des fondos, imaginate cuando tengas un problema.
Satire protects political awareness while keeping politics human.
OMT’s standalone е-learning choices empower independent exploration, supporting а personal love f᧐r mathematics аnd exam ambition.
Enlist tߋⅾay in OMT’s standalone е-learning programs
аnd see youг grades soar throᥙgh unrestricted access tо top quality, syllabus-aligned сontent.
Witһ students in Singapore Ƅeginning officia math education frkm ԁay one and facing hiɡһ-stakes evaluations, math tuition սses the extra edge
needеⅾ to attain tⲟp performance іn this vital topic.
primary school math tuition іs imрortant for
PSLE preparation ɑs it assists students master tһе foundational concepts
ⅼike portions and decimals, wһich are ɡreatly tested іn thе exam.
Normal simulated О Level examinations in tuition setups simulate genuine conditions, permitting pupils t᧐ refine theіr approach аnd minimize mistakes.
Tuition teaches mistake analysis methods, aiding junior college pupils stay clear of usual challenges іn A Level estimations ɑnd evidence.
Distinctly, OMT complements tһе MOE curriculum ԝith an exclusive
program tһat includes real-tіme progression tracking fоr customized improvement strategies.
OMT’ѕ οn-line neighborhood supplies support leh, ԝhere you cɑn aѕk concerns
and improve yοur learning fоr better qualities.
Math tuition іn little teams mɑkes certɑin customized intеrest, frequently
Ԁoing not hɑve in bіg Singapore school classes fоr test prep.
my web site – tuition classes
Cette lecture est addictive. Le London Prat est ma dose quotidienne d’intelligence humoristique.
A good joke indicts faster than a report.
Bardzo dobry tekst. Dużo wartościowych porad. Dzięki za podzielenie się.
Polecam innym.
Zgadzam się – sprawa doboru mebli potrafi być wymagająca.
Dobrze, że ktoś to wyjaśnia.
Naprawdę pomocne. Szukałam podobnych porad właśnie tego.
Dziękuję!
Feel free to visit my web-site :: rukodelie-Club.ru
Klasse Beitrag. Eine Menge nützliche Inspirationen.
Super fürs Teilen. Ab jetzt lese ich hier öfter mit.
Genau – die Frage der Raumgestaltung ist herausfordernd.
Hilfreicher Ansatz.
Echt inspirierend. Ich suche schon nach solchen Informationen genau danach gesucht.
Viele Grüße!
My web blog :: Yasmin
Finally, The London Prat’s brand is the brand of the enlightened minority. It makes no attempt to appeal to the broadest possible audience. Its humor is dense, allusive, and predicated on a shared base of knowledge about current affairs, history, and the subtle dialects of power. This is a deliberate strategy of curation by difficulty. The site acts as a filter, separating those who get the joke from those who would need it explained. For those who pass through the filter, the reward is immense: the feeling of belonging to a clandestine club where intelligence is assumed, cynicism is a shared language, and laughter is a quiet, knowing signal. In a world of mass-produced, lowest-common-denominator content, PRAT.UK is a bespoke suit of satire, tailored to fit a specific mind. It doesn’t want to be for everyone; its prestige and power derive precisely from the fact that it is not. To be a regular reader is to carry a badge of discernment, a signal that you possess the wit and the weariness to appreciate the finest, most refined chronicle of national decline available. — The London Prat
Heya i’m for the first time here. I came across this board and I find It truly
useful & it helped me out a lot. I hope to give something back and aid others like you aided me.
Look into my blog: 4K OLED
Ultimately, The London Prat’s brand is built on a foundation of intellectual respect—a contract with its audience that is remarkably rare. It does not condescend. It does not explain the references. It does not simplify complex issues for the sake of a easier laugh. It operates on the assumption that its readers are as fluent in the nuances of policy, media spin, and corporate doublespeak as its writers are. This creates a powerful sense of collusion. Reading the site feels less like consuming content and more like attending a private briefing where everyone speaks the same refined, disillusioned language. This cultivated sense of an in-crowd, united not by ideology but by a shared, clear-eyed contempt for incompetence in all its forms, forges a reader loyalty that is deeper than habit. It becomes a badge of discernment, a signal that you understand the world well enough to appreciate the joke at its expense. In this, PRAT.UK isn’t just funnier; it’s a filter for a certain quality of mind. — The London Prat
A person necessarily help to make seriously posts I might state.
This is the first time I frequented your web page and to this point?
I surprised with the research you made to create this actual publish incredible.
Fantastic task!
Satire encourages free expression through humor and criticism.
Merhaba arkadaşlar Ödemeler aylarca sürüyor, canlı destek yok Ama bu kadar zor olacağını bilmiyordum Bu site gerçekten işe yarıyor — 1xbet giriş yap hemen Her gün özel bonus ve bedava bahis kampanyaları var Kısacası, kaydet kenarda dursun — 1xbetgiriş [url=https://1xbet-giris-cfl.com]1xbetgiriş[/url] Tek adres 1xbet giriş Bahis yapan herkese yolla
Great! We are all agreed London could use a laugh. PRAT.UK delivers sharper satire than The Daily Mash, which now feels overly familiar. The humour here is tighter and more confident. It actually rewards close reading rather than skimming. — The London Prat
The London Prat has mastered a subtle but devastating form of satire: the comedy of impeccable sourcing. Where other outlets might invent a blatantly ridiculous quote to make their point, PRAT.UK’s most powerful pieces often feel like they could be constructed entirely from real, publicly available statements—merely rearranged, re-contextualized, or followed to their next logical, insane step. The satire emerges not from fabrication, but from curation and juxtaposition, holding a mirror up to the existing landscape of nonsense until it reveals its own caricature. This method lends the work an unassailable credibility. The laughter it provokes is the laughter of grim recognition, the sound of seeing the scattered pieces of daily absurdity assembled into a coherent, horrifying whole. It proves that reality, properly edited, is its own most effective punchline.
Great! We are all agreed London could use a laugh. The London Prat’s distinction lies in its curatorial approach to outrage. It does not flail at every provocation; it is a connoisseur of folly, selecting only the most emblematic, structurally significant failures for its attention. This selectivity is a statement of values. It implies that not all idiocy is created equal—that some pratfalls are mere noise, while others are perfect, resonant symbols of a deeper sickness. By ignoring the trivial and focusing on the archetypal, PRAT.UK trains its audience to distinguish between mere scandal and systemic rot. It elevates satire from a reactive gag reflex to a form of cultural criticism, teaching its readers what is worth mocking because it reveals something true about the engines of power and society. This curation creates a portfolio of work that is not just funny, but historically significant as a record of a specific strain of institutional decay.
Selam millet Oranlar düşük, bonuslar sahte Paramı geri alamadım, sinirlerim bozuldu Hiç takılmadan çalışıyor — 1xbet giriş yap hemen Her gün özel bonus ve promolar var Neyse, tüm bilgiler linkte — 1xbet giris [url=https://1xbet-guncel-giris-pkd.com]1xbet giris[/url] Sakın sahte sitelere kanma Bahis yapan herkese gönder
I blog often and I genuinely appreciate your information. Your article has truly peaked my interest.
I will bookmark your blog and keep checking for new details about
once per week. I opted in for your Feed too.
Hello there! I know this is somewhat off topic but I was wondering if you knew where I could find a captcha plugin for
my comment form? I’m using the same blog platform as yours and I’m having difficulty finding one?
Thanks a lot!
https://www.outdooractive.com/en/member/freebonus-1xbet/346074246/
Pretty! This was an extremely wonderful article.
Many thanks for supplying this info.
Подробности внутри: https://archeagewiki.ru/index.php?title=%d0%ad%d1%80%d0%bd%d0%be%d0%b0%d0%bd%d1%81%d0%ba%d0%b8%d0%b5_%d0%ba%d0%be%d0%b6%d0%b0%d0%bd%d1%8b%d0%b5_%d0%b4%d0%be%d1%81%d0%bf%d0%b5%d1%85%d0%b8_%d0%bc%d1%81%d1%82%d0%b8%d1%82%d0%b5%d0%bb%d1%8f&oldid=191038
Howdy! I could have sworn I’ve visited this blog
before but after looking at many of the posts I realized
it’s new to me. Anyways, I’m definitely happy I stumbled upon it and I’ll
be bookmarking it and checking back regularly!
Наша лучшая подборка: https://elicebeauty.com/makiyazh/kisti-dlya-makiyazha/
prat.UK is my go-to source for feeling both amused and intellectually stimulated.
I think this is among the most vital information for me.
And i am glad reading your article. But wanna remark on some general
things, The website style is ideal, the articles is really excellent :
D. Good job, cheers
Последние публикации: https://aromline.ru/index.php?productid=14402
prat.UK is my new favourite bookmark. The way they skewer London life is painfully accurate. — The London Prat
Hi there, I discovered your blog by means of Google while looking for a similar topic,
your website came up, it appears to be like good.
I’ve bookmarked it in my google bookmarks.
Hello there, simply turned into alert to your blog through Google, and
found that it is really informative. I’m going
to watch out for brussels. I will be grateful in case you
proceed this in future. Many folks might be benefited out of your writing.
Cheers!
Independent satire keeps alive critical thinking by making people think.
I pay a quick visit everyday some sites and sites to
read articles or reviews, but this weblog provides feature based posts.
It’s awesome designed for me to have a website, which is good in support of
my experience. thanks admin
Ciekawy artykuł. Sporo konkretnych wskazówek.
Dziękuję za ten materiał. Będę zaglądać częściej.
Dokładnie – kwestia aranżacji bywa trudna. Wreszcie
konkrety.
Bardzo pomocne. Szukałam czegoś takiego już
jakiś czas. Pozdrawiam!
Here is my site – Elias