Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

scripting simple (or not?) vehicle-like movement

Shadowwing Tigerpaw
Registered User
Join date: 9 Dec 2008
Posts: 2
08-26-2009 22:15
Hello, I've been trying to find out how I can program a object, like a chair or something, so that it will start moving when I press the button, and stop moving when I let it go, like when your avatar is walking, only moreso.
I've looked at the wiki, in the script library forum, and in a number of places in-world, but I haven't found anywhere that has what I'm looking for. In fact, I haven't really found anywhere that gives a whole lot of help with vehicles(which might explain why many of the free ones I've picked up aren't really worth much, lol). So, I've decided to just try asking someone, and this looked like the best place for it.

Specifically, I'm looking for a way to make it:
-Start moving at a specified speed when I press the button, without having to slowly speed up to it.
-Continue moving while I hold the button down. No jumping a certain distance each time I press the button.
-Stop when I release the button, rather than a gradual loss of speed.
-Turn the same whether I'm moving or not.
-Also work for up and down and strafing.
-And stay in one spot when I'm not pressing anything, which means no falling due to gravity or something.
And while it might be simpler to just get a script for that from someone, I would honestly prefer to be able to understand it, partly in case I want to use it again, partly in case I need to adjust something, partly in case I lose the original, but mainly because I like understanding things, especially if they're useful. :)

If you can help me with this at all, I greatly appreciate it, if you can't, I hope the answer to this helps you too.
Though I tried to make this as straightforward as I could, if any of it is confusing, just tell me and I will see if I can explain it.
Also, if any part of this in any way offends you, I do apologize, as it is not intended to.
Thanks in advance!
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
08-27-2009 00:29
you want to look at control and the vehicle functions
https://wiki.secondlife.com/wiki/Category:LSL_Controls
https://wiki.secondlife.com/wiki/Category:LSL_Vehicle

also you may want to check out Jopsy Pendragon's new "Vehicle Laboratory" inworld
_____________________
|
| . "Cat-Like Typing Detected"
| . This post may contain errors in logic, spelling, and
| . grammar known to the SL populace to cause confusion
|
| - Please Use PHP tags when posting scripts/code, Thanks.
| - Can't See PHP or URL Tags Correctly? Check Out This Link...
| -
Shadowwing Tigerpaw
Registered User
Join date: 9 Dec 2008
Posts: 2
08-27-2009 10:47
Yeah, I've been by the vehicle lab, but the part about movement hasn't been built yet, It currently gets as far as controlling sit, camera, and taking the controls, none of which I've got any real problem with.
And, no offense, but the wiki is just no help at all. Yes, it gives you all the commands and variables, and says what they do. but that's it, it doesn't explain what anything means. Like "VEHICLE_ANGULAR_DEFLECTION_TIMESCALE = exponential timescale for the vehicle to achieve full angular deflection" but it doesn't say anything about what angular deflection is, or why it's needed, or anything.
Which is, honestly, why I came here, where I could talk with real people, who could discuss and explain what all the relevant fiddlybits really are, why they're there, and how i can get them to do what i want.
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
08-27-2009 19:06
angular deflection = turning/banking
timescale = how long it takes to do that
exponential = softer at the beginning, increasingly sharper as it's applied (and truthfully that wording is just for technical accuracy, the important words were the other two)
_____________________
|
| . "Cat-Like Typing Detected"
| . This post may contain errors in logic, spelling, and
| . grammar known to the SL populace to cause confusion
|
| - Please Use PHP tags when posting scripts/code, Thanks.
| - Can't See PHP or URL Tags Correctly? Check Out This Link...
| -