question

Wang Z2 avatar image
0 Likes"
Wang Z2 asked Joerg Vogel edited

code to set Elevator size

Hi.

In my model,I use code to create Elevator and set its size.But the size won't change until I click on the Elevator with the mouse.

Is this probably due to the slow refresh rate? How to solve this problem?

Thanks.Below is my code, my model ischangeelevatorsize.fsm

Object newConveyor = createinstance(node("/?Elevator", library()), model());
newConveyor.setSize(1,0.8,0.15);
FlexSim 18.2.3
codeelevatorcreateinstancesize
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

·
Joerg Vogel avatar image
2 Likes"
Joerg Vogel answered Joerg Vogel edited

The elevator is a composed or assembled object, like the crane or the transporter. You find in the library nodefunctions that are there to do or accomplish the resizing of such objects:

Object newConveyor = createinstance(node("/?Elevator", library()), model());
newConveyor.setSize(1,0.8,0.15);
treenode scalelift = library().find("taskexecuters/Elevator>behaviour/eventfunctions/scalecomponents");
nodefunction(scalelift,newConveyor);
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.