ATTENTION

This FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices.


flexsim.com

Go Back   FlexSim Community Forum > FlexSim Software > Q&A
FAQ Downloads Calendar Search Mark Forums Read

Q&A Using Flexsim and building models

Reply
 
Thread Tools Display Modes
  #1  
Old 05-06-2016
Thomas Wyssenbach
Guest
 
Posts: n/a
Downloads: 3
Uploads: 0
Question Activate/deactivate Components in Animations during Runtime

Hello all
I am trying to add some visually animated components to a TE as flow item and would like to de/activate them during a simulation run.
In fact, there will be male & female TE as flow items with each carrying either backbacks, trolleys, handbags, etc. or a combination of them. During runtime, the TE as flow items will get rid of them and will walk without - or a different combination. All that, I would like to define in run time.

So far, I have tried several paths: The one, that presently make most sense to me is adding the additional visuals as "components" in the "Animations and Components" tab. It would now be ideal, if I could de/activate the components individually in runtime by flexscript - similar to what I can do that by clicking on the "eye" symbol in the GUI.

Any hints, how I can access this parameter (or any other parameter with the same effect) of the "TE as flow item" by flexscript? Going through the Model tree did not lead to a success yet.

Thank you very much for your support

rgs Tom
Reply With Quote
  #2  
Old 05-06-2016
Phil BoBo's Avatar
Phil BoBo Phil BoBo is offline
Flexsim Development
 
Join Date: Jan 2008
Posts: 756
Downloads: 109
Uploads: 18
Thanks: 385
Thanked 1,483 Times in 525 Posts
Rep Power: 1166
Phil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond repute
Default

You can reference component objects using the node() command, and you can hide objects using the switch_hideshape() command:

Code:
treenode component = node("/ComponentName", drawsurrogate(object));
switch_hideshape(component, 1);
Attached is a model that shows how you can hide components of a task executer flowitem.

The FlexScript code that hides the components is in the OnEntry trigger of the Queue.

Attached Thumbnails
Click image for larger version

Name:	hide_animation_components2.png
Views:	742
Size:	92.6 KB
ID:	3259  
Attached Files
File Type: fsm HideAnimationComponents.fsm (18.1 KB, 445 views)
Reply With Quote
The Following 4 Users Say Thank You to Phil BoBo For This Useful Post:
arunkrmahadeva (05-06-2016), Jing Chen (05-06-2016), Sebastian Hemmann (05-08-2016), Thomas Wyssenbach (05-07-2016)
  #3  
Old 05-07-2016
Thomas Wyssenbach
Guest
 
Posts: n/a
Downloads: 3
Uploads: 0
Default

Perfect - thanks, works great. Exactly what I was looking for.
Reply With Quote
Reply

Tags
animation

Thread Tools
Display Modes

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
Bone Animations Phil BoBo Tips and Tricks 0 01-29-2016 02:55 PM
To obtain distances travelled by components sravan kumar Q&A 0 01-07-2015 02:28 AM
Modifying the arrival schedule of the Source Object at runtime Vadim Fooks Q&A 2 01-22-2013 11:52 PM
Calling COM Components from within Flexsim Samuel Jack Q&A 6 05-12-2011 09:36 AM


All times are GMT -6. The time now is 03:55 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.
Copyright 1993-2018 FlexSim Software Products, Inc.