xmoonproductions.org
https://www.xmoonproductions.org/

Animation help
https://www.xmoonproductions.org/viewtopic.php?f=27&t=4330
Page 1 of 4

Author:  pavar [ Fri Jan 01, 2016 11:39 pm ]
Post subject:  Animation help

So I created an animation of Saiko bending over and I scripted it to Jiggle for test's sake. I added the waypoint sitass_wp1 so on "jiggle" Saiko goes to the wp and then bend over. My problem is that no matter what I try, she keeps turning before bending over. The idea is to have her bend over the table, not showing her twat to it. Any help would be appreciated.
Here is the specific piece of code:
Code:
[START1]
  {
    // Jiggle
      loc.sp.pose_type = TEST;
      loc.sp.pose_id   = 0;
     loc.sp.waypoint  = "sitass_wp1";
     loc.sp.exact     = 0;
     loc.sp.par       = 0.5;
    SetPose(loc.sp);
   
    state.dyn.me.do.pose.sp     = loc.sp; 
      state.dyn.me.do.pose.state2 = START2;
      state.dyn.me.do.pose.fstate2 = FINISH;
    state.dyn.me.do.state2      = POSE_WAIT;
  }

Author:  Eskarn [ Sat Jan 02, 2016 1:53 am ]
Post subject:  Re: Animation help

There's a few ways to get them to move to where you want


you can add front or back to each way point

front will make them face the way point and back will face away from the way point

either like
loc.sp.waypoint = "sitass_wp1+back;

or like this
loc.sp.waypoint = "sitass_wp1";
loc.sp.waypoint += "+back";


you can have the npc face the player/npc as well using

loc.sp.waypoint = "#MAIN+front";
loc.sp.waypoint = "#MAIN+back";
loc.sp.waypoint = "#MONICA+back";
loc.sp.waypoint = "#MONICA+front";
loc.sp.waypoint = "#SAIKO+back";
loc.sp.waypoint = "#SAIKO+front";

Hope this helps

Author:  pavar [ Sat Jan 02, 2016 2:31 am ]
Post subject:  Re: Animation help

Thanks, I tried but I wrongly used back:sitass_wp .
Btw, your animation tutorial rocks, especially for those that have nver used Maya.

Author:  pavar [ Sat Jan 02, 2016 11:18 am ]
Post subject:  Re: Animation help

Hmm, the waypoint is too far from the table to be useful, I will have to figure out how to add a custom one.

Author:  Eskarn [ Sat Jan 02, 2016 2:04 pm ]
Post subject:  Re: Animation help

To add new waypoints you would need the source dungeon which i believe we do not have

You could add in a new table using pos xyz if there is a waypoint close enough
Or use an object as a waypoint(i think its possible but iv never tried)

I'll have a look tomorrow to see how it can be done

Author:  pavar [ Sat Jan 02, 2016 8:50 pm ]
Post subject:  Re: Animation help

I managed to get an object waypoint in the scene (DUNGEON1:TABLEBEND), unfortunately the NPC ignores it. Oh well, back to the drawing board. I migh have to add an extra table with an object wp for it to work, but not to be able to add new wp limit my options. I was thinking to have her bend over facing the wall, but I will have the same issue there :( For my third idea, having Saiko and Monica kiss, that will not be an issue since I can point an npc to the other. I guess I will start working on that one
Xpadmin, any suggestions?

Since we are able to add an object waypoint, e.g.
Code:
  waypoint_objecti TABLEBEND
{
pos = (1.2,0.0,0.0);
rot = (0.0,90.0,0.0);
}


is there a similar way to add a regular wp?

Author:  Eskarn [ Sun Jan 03, 2016 12:22 am ]
Post subject:  Re: Animation help

Holy shit you can add waypoints THIS CHANGES EVERYTHING

Code:
    waypoint_objecti TABLEBEND
{
pos = (-2,0.0,0.0);
rot = (0.0,90.0,0.0);
}


Code:
loc.sp.pose_type = STAND;
loc.sp.pose_id   = 0;
loc.sp.waypoint  = "DUNGEON1:TABLEBEND";


Just make sure its not to close to the table otherwise she will not be able to get to it

Author:  pavar [ Sun Jan 03, 2016 1:43 am ]
Post subject:  Re: Animation help

Yeah, I added it to dungeon1.dat in init/stories/dungeon/scenes

Here is part of the code for Jiggle

Code:
loc.sp.pose_type = TEST;
      loc.sp.pose_id   = 0;
    loc.sp.waypoint  = "DUNGEON1:TABLEBEND";
     loc.sp.exact     = 2;
     loc.sp.par       = 0.5;
    SetPose(loc.sp);


unfortunately, she does not recognize the waypoint and skip to the action in situ

Author:  Eskarn [ Sun Jan 03, 2016 7:48 am ]
Post subject:  Re: Animation help

You need to get her to walk to the spot first like this example
Code:
[START1]
{
loc.sp.pose_type = STAND;
      loc.sp.pose_id   = 0;
    loc.sp.waypoint  = "DUNGEON1:TABLEBEND";
    SetPose(loc.sp);
      do_set_timer(1);
state.dyn.me.do.state2 = START2;
}

[START2]
{
    loc.ts = GetTs(); 
[loc.ts < state.dyn.me.do.ts] return;
[state.dyn.me.pose.result == NONE] return;

loc.sp.pose_type = TEST;
      loc.sp.pose_id   = 0;
    SetPose(loc.sp);
}

Author:  pavar [ Sun Jan 03, 2016 12:49 pm ]
Post subject:  Re: Animation help

Thanks, I will try it in the evening and let you know

Page 1 of 4 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/