WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 06-04-2015, 12:02 PM
MissingAFew MissingAFew is offline
Member
 
Join Date: Apr 2015
Posts: 15
Pausing the walkTo action

Right now I have something like:

Code:
Walk = vizact.walkTo(self.MoveToLocation, self.Speed, 300, turnInPlace=True)
yield viztask.addAction( self.Avatar.AvatarModel, Walk )
I would like to be able to have the avatar stop moving, then resume moving, under certain circumstances. However I cant figure out a good way to accomplish this. I've tried Walk.actionclass.finished() and Walk.actionclass.pause but they don't seem to work. Nothing in particular in the documentation seems to stand out as an easy way to do this, but I may have missed something or used it incorrectly. If anyone knows a good way to handle it, I'd love some feedback. I would prefer to avoid having to write my own movement class if possible, but I realize this may not be avoidable.
Reply With Quote
  #2  
Old 06-05-2015, 03:46 PM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
Take a look at this thread. The example code posted there may help you.
Reply With Quote
  #3  
Old 06-09-2015, 09:20 AM
MissingAFew MissingAFew is offline
Member
 
Join Date: Apr 2015
Posts: 15
Quote:
Originally Posted by Jeff View Post
Take a look at this thread. The example code posted there may help you.
Thank you Jeff, this looks like what I need. I appreciate the help you give around here.
Reply With Quote
  #4  
Old 06-11-2015, 11:39 AM
MissingAFew MissingAFew is offline
Member
 
Join Date: Apr 2015
Posts: 15
Quote:
Originally Posted by Jeff View Post
Take a look at this thread. The example code posted there may help you.
I could be wrong but this seems to be checking if the movement has ended. I want it to end abruptly, before it reaches the destination. The way I have it set up right now is that the task is scheduled using the viztask.schedule(). So I think I need to kill the task, and kill the schedule.

I'm gonna look through the documentation a little more, but if you know off hand how to do this it'd be a big help.
Reply With Quote
  #5  
Old 06-11-2015, 11:44 AM
MissingAFew MissingAFew is offline
Member
 
Join Date: Apr 2015
Posts: 15
Yeah, task.kill() doesn't actually stop the movement from occurring. Avatar continues to move, despite the task supposedly being killed.

Does this mean I have to manually move the avatar myself instead of using moveTo? Or is there a way to interrupt moveTo and stop the avatar before it reaches its destination?
Reply With Quote
  #6  
Old 06-11-2015, 11:56 AM
MissingAFew MissingAFew is offline
Member
 
Join Date: Apr 2015
Posts: 15
Nevermind! clearActions() from the thread you linked to works.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
vizact move action andreionutz Vizard 13 11-19-2014 02:54 AM
Creating Realistic Turns in Vizard using walkTo mikeb Vizard 1 02-28-2014 05:51 AM
avatar walkto interrupt Meneer_Aart Vizard 6 04-09-2013 02:41 PM
character pack and walkto ? digitaldarklord Vizard 1 09-30-2008 04:42 PM
How to make avatar's eyes to blink when speaking michelcm3 Vizard 12 01-15-2008 08:48 AM


All times are GMT -7. The time now is 04:02 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC