View unanswered posts | View active topics It is currently Thu Dec 26, 2024 5:58 pm



Reply to topic  [ 4 posts ] 
 Help with SetWhichMOToNotHit? 
Author Message
User avatar

Joined: Fri Feb 16, 2007 8:43 pm
Posts: 1695
Location: AH SHIT FUCK AUGH
Reply with quote
Post Help with SetWhichMOToNotHit?
Hey guys, this may be a dumb question, but ♥♥♥♥ that. Basically, i can't figure out how to use SetWhichMOToNotHit. My current and obviously wrong version looks like this:
Code:
function Create(self)
   self:SetWhichMOToNotHit("Main Thruster Blast Ball 1",-1);
...

The console does provide some obscure feedback, but i can't make sense of it whatsoever. Just for good measure, here's the Wiki page:

http://www.datarealms.com/wiki/index.ph ... MOToNotHit

What am i doing wrong, and what should i do to make it right?


Tue Aug 18, 2009 9:02 pm
Profile WWW
REAL AMERICAN HERO
User avatar

Joined: Sat Jan 27, 2007 10:25 pm
Posts: 5655
Reply with quote
Post Re: Help with SetWhichMOToNotHit?
SetWhichMOToNotHit requires a pointer, not a string.

Basically, do this:

for particle in MovableMan.Particles do
if particle.PresetName == "Main Thruster Blast Ball 1" then
self:SetWhichMOToNotHit(particle,-1);
end
end

That'll make yourself not hit the particles, by the way, not the other way around, but it'll work just as well.

Also, your limbs, attachables, and head will still collide.


Tue Aug 18, 2009 9:06 pm
Profile
User avatar

Joined: Fri Oct 17, 2008 9:46 pm
Posts: 5212
Location: The Grills Locker.
Reply with quote
Post Re: Help with SetWhichMOToNotHit?
SetWhichMOToNotHit, like many Lua functions, doesn't work with pure presetnames. You have to make a pointer for that object, such as in:
for thing in MovableMan.Particles do
if thing.PresetName == "Main Thruster Blast Ball" then
self:SetWhichMOToNotHit(thing,-1);
end
end

EDIT: heck, ninja'd!


Tue Aug 18, 2009 9:08 pm
Profile WWW
User avatar

Joined: Fri Feb 16, 2007 8:43 pm
Posts: 1695
Location: AH SHIT FUCK AUGH
Reply with quote
Post Re: Help with SetWhichMOToNotHit?
Ah, ok, thanks. I got around the problem of the particles hitting the limbs by making the particles ignore the actor, instead of the actor ignoring the particles.

Problem solved. :)


Tue Aug 18, 2009 9:20 pm
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 4 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.091s | 13 Queries | GZIP : Off ]