Search found 14 matches

by Panos
Thu Jun 14, 2007 9:57 am
Forum: Beginners Help
Topic: FollowSplineAnimator - startTime
Replies: 1
Views: 219

FollowSplineAnimator - startTime

Hi!

I want to make a model follow a spline when a key is striken.I can use FollowsplineAnimator but what should I use as startTime Parameter?
by Panos
Wed Jun 13, 2007 12:45 pm
Forum: Beginners Help
Topic: Moving a camera forward
Replies: 4
Views: 565

Perhaps you could use an animator assigned to the camera... :roll:
by Panos
Wed Jun 13, 2007 10:05 am
Forum: Beginners Help
Topic: Cube question
Replies: 2
Views: 244

There is setScale...I hadn't noticed that in docs... :oops: :oops:

Sorry for this silly topic... :oops: :oops: :oops:
by Panos
Wed Jun 13, 2007 8:56 am
Forum: Beginners Help
Topic: Cube question
Replies: 2
Views: 244

Cube question

Hi guys!

In my project,I use models following splines.

I want to draw small cubes in each spot of their path but the CubeSceneNode add a big cube.

Can it become smaller?

Thanks
by Panos
Tue May 15, 2007 7:48 am
Forum: Beginners Help
Topic: MD2 help...
Replies: 0
Views: 178

MD2 help...

Hi guys,I have some problems with md2 models...

i)When I load them by casting to IAnimatedMeshMD2(with getMesh) I am always getting a castexception... :roll: ...why is it happening?
ii)Is there any way to find with Irrlicht the frameloop for each animation?
iii)I am trying to convert sydney to .x ...
by Panos
Sat Jan 27, 2007 3:18 pm
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

Finally I found a solution that works!!!

Here is my code in java:(anms my md2 and n a cude used for the rotation of anms)

vector3df cur = anms.getPosition();
vector3df targ=n.getPosition();
vector3df dir =targ.subtractOperator(cur).normalize();
vector3df rotation = dir.getHorizontalAngle ...
by Panos
Wed Jan 24, 2007 3:16 pm
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

MasterBaker I tried your method but sth goes wrong:

ISceneNode n = smgr.addEmptySceneNode();
n.addAnimator(smgr.createFollowSplineAnimator(0,vecciv,0.2f,0.2f));
ICameraSceneNode tmp = smgr.addCameraSceneNode(null);

IAnimatedMeshSceneNode anms = smgr.addAnimatedMeshSceneNode(smgr.getMesh ...
by Panos
Sat Jan 20, 2007 8:16 pm
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

Well the faceTarget doesn't work correctly for me with this simple spline

Code: Select all

		vec2.push_front(new vector3df(0, 0,200));
		vec2.push_front(new vector3df(-200, 0,0));
		vec2.push_front(new vector3df(0, 0,-200));
		vec2.push_front(new vector3df(200, 0,0));
I am trying to fix it.
by Panos
Fri Jan 19, 2007 3:41 pm
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

I will try both solutions to see which one works better...then I will post the results... :wink:
by Panos
Thu Jan 18, 2007 9:30 pm
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

So I can create an invisible object-attach to it the same spline animator as Sydney and then use this

void faceTarget(irr::core::vector3df targetPos) {
core::vector3df nodePos = targetPos - myNode->getPosition();
myRotation.Y = atan(nodePos.Z/nodePos.X) * (180.0f / irr::core::PI);
if ...
by Panos
Thu Jan 18, 2007 11:57 am
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

Everything seems to work fine but I have one more problem.

I want Sydney face the direction she moves.How can it be done?Using a rotation animator???

Thanks again zeno60
by Panos
Wed Jan 17, 2007 11:06 pm
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

Sort of, but the b.getDistanceFrom(a) <= 1.0f will have to be updated with each device loop.

Not used Jirr so i'm not sure how that works, but you should have a main loop with your begin() and end() etc. Put:

if(b.getDistanceFrom(a)<= 1.0f)
anms.removeAnimator(anim);

Within this loop somewhere ...
by Panos
Wed Jan 17, 2007 8:36 pm
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

So let's say that anim is my ISceneNodeAnimator and anms my IAnimatedMeshSceneNode.

I use this but obviously it's wrong.

vector3df a = new vector3df(40,0,100);
anim=smgr.createFollowSplineAnimator(0,vec,0.3f,0.5f);
anms.addAnimator(anim);
anim.drop();
vector3df b = anms.getPosition();
if(b ...
by Panos
Wed Jan 17, 2007 6:05 pm
Forum: Beginners Help
Topic: FollowSplineAnimator
Replies: 15
Views: 1264

FollowSplineAnimator

Hi guys!!!

I am new with Irrlicht(I use jirr) and I have a problem with FollowSplineSimulator.

I give the pts tha Sydney must go and the animator works fine but when Sydney reaches the end of my path goes back again and again.

What can I do???

Thanks