script becoming forgotten after saving?

About advanced scenes, and the Thyme scripting language used in Algodoo.

script becoming forgotten after saving?

Postby royalblue » Sat Jan 16, 2010 10:21 pm

In this scene: http://www.algodoo.com/algobox/details.php?id=36424
an important script in the tires becomes lost every time you save or do any major changes to the tires. It basically has a clutch effect, where when the car is in neutral, the brake (connected to the "drivewheels") is turned off, then when you shift out of neutral, it turns the brake of the motor on, so that it transfers the motion from the "drivewheels" to the tires. Is there any other way I can script this to regain the same effect except it won't be forgotten or is there some way I can make it not forget the script every time?
royalblue
 
Posts: 14
Joined: Mon Aug 31, 2009 9:22 pm

Re: script becoming forgotten after saving?

Postby Kilinich » Sun Jan 17, 2010 12:36 am

same sh$t. sometimes deleting and creating object helps.
Dream of Algodoo as game development engine...
User avatar
Kilinich
[Best bug reporter 2010]
 
Posts: 2098
Joined: Mon Aug 31, 2009 8:27 pm
Location: South Russia

Re: script becoming forgotten after saving?

Postby standardtoaster » Sun Jan 17, 2010 12:38 am

What you can do to make it not forget the script all the time is a bit tedious.
  • Save your scene; in this case we will call it "test.phz"
  • Find test.phz and rename it to test.zip
  • Open test.txt with a text editor
  • Find all instances of things that were getting deleted and put := before the equal sign
I hope that I got this right. I have been working on and just finished my final midterm project and am very tired.
User avatar
standardtoaster
 
Posts: 606
Joined: Mon Aug 31, 2009 7:57 pm

Re: script becoming forgotten after saving?

Postby royalblue » Sun Jan 17, 2010 3:48 am

Ugh nothing is working! All of the other code stays just fine, whats wrong with that specific one?
royalblue
 
Posts: 14
Joined: Mon Aug 31, 2009 9:22 pm


Return to Thyme scripting

Who is online

Users browsing this forum: No registered users and 3 guests

cron