Browse Search Popular Register Upload Rules User list Login:
Search:
Basic Scripting

Image:
screenshot of the scene

Author: pastrana20

Group: Default

Filesize: 20.22 kB

Date added: 2014-05-29

Rating: 5

Downloads: 370

Views: 298

Comments: 11

Ratings: 1

Times favored: 0

Made with: Algodoo v2.1.0

Tags:

Scene tag

Put objects on the rectangle to increase the speed of the vehicle. Click the rectangle
to decrease the speed. I know when you are clicking it the edit menu wil occasionally pop up. But that is just a minor issue. Im just testing some things out.

PLEASE PLEASE PLEASE Comment, and rate. it will show me how I am doing. Thank you:D -pastrana2000

----------------------------------------------
-------------------------------------------------------------
---------------------

UPDATE: This works now:D
UPDATE: 6/8/14 added moveable objects. Also the edit menu doesn't pop up anymoe when you click the rectangle. Also added stationary speedometer. Also made car faster.
Last edited at 2014/06/08 23:40:58 by pastrana20
Please log in to rate this scene
edit
Similar scenes
Title: ALGOODO SCRIPTING GUIDE (ENG)
Rating: 4.5
Filesize: 384.84 kB
Downloads: 488
Comments: 6
Ratings: 2
Date added: 2014/04/26 23:11:38
Made with: Algodoo v2.1.0
Rating: rated 4.5
download
Title: a vehicle going the other
Rating: 5
Filesize: 14.96 kB
Downloads: 256
Comments: 0
Ratings: 1
Date added: 2010/09/27 14:53:05
Made with: Algodoo before v1.8.5
Rating: rated 5
download
Title: Rail Gun
Rating: 5.25
Filesize: 23.05 kB
Downloads: 635
Comments: 1
Ratings: 2
Date added: 2011/01/24 22:04:25
Made with: Algodoo before v1.8.5
Rating: rated 5.3
download
Title: Vehicle sensing edges and walls
Rating: 5.625
Filesize: 11.09 kB
Downloads: 284
Comments: 1
Ratings: 2
Date added: 2010/09/27 14:54:14
Made with: Algodoo before v1.8.5
Rating: rated 5.6
download
Title: Simple Rocket
Rating: 5
Filesize: 4.6 kB
Downloads: 1046
Comments: 0
Ratings: 1
Date added: 2021/07/26 22:12:44
Made with: Algodoo v2.1.0
Rating: rated 5
download
Title: "Smash" Prototype
Rating: 5
Filesize: 8.97 kB
Downloads: 306
Comments: 4
Ratings: 1
Date added: 2016/12/26 13:57:02
Made with: Algodoo v2.1.0
Rating: rated 5
download
Um.... There are problems with this scene. First of all, the speed of the vehicle is controlled with arrow keys, and not with the variable. Secondly, the variable "scene.variable1" has not been defined. And third, you need to name the variable "scene.my.variable1" if you want to save it along with the scene. You define a variable by initially entering it into the console or into the text box in the upper-left of any geometry. Here is the syntax to define a variable: scene.my.variable1 := 0

The colon is only for a check to make sure that the variable was not previously defined. If it was, then you would see an error message printed in the console.

Also, you should TEST your scenes before uploading them! If you had tested this one, then you would have noticed right away that it does not work as expected.

Hope this helps...
I have tested this and it still works for me:/ maybe its just local.
Nvm i see the problems. Thank you very much. I am coming out with a new game i am making be sure to test if for me:D
Fixed it.
Yes, it works now.

Helpful hint: Add this script to "update' in any box or circle in the scene (only ONE place), and it will prevent the script menu from showing up when clicking on things: app.gui.playmode = sim.running
Thank you I did it:)
Well, if you did it, then it's not working. I looked all through the scene and I cannot find app.gui.playmode = sim.running so you must not have added that script.

Edit: OH, WAIT.... You made the change at the same time I was writing this comment!!! BUT you put the script in the wrong place! It must go in "update" not in onCLick!
Last edited at 2014/06/08 23:26:36 by Xray
Oh wow. DERP. Really totally messed that up.
Ok I did it now:P
I als turned up the car torque and friction on the wheels, so it goes faster.
NOW it works correctly! HOORAY! :lol: