|
Chairman Singer
Registered User
Join date: 27 Sep 2005
Posts: 4
|
09-20-2006 14:43
Hi folks. Recently decided to get more involved with building items. Having some good programing experience IRL I thought the scripting of said items would be fun too. And it is... I Recently used some of the basic (i.e. freebie) scripts to make a pistol. But in testing of the gun I saw two things I'd like to fix. (keep in mind with this basic "hello world" type project I am using physical bullets) 1) The aim of the thing was terrible. 2) The larger I made the bullets the straighter they flew. So my questions are: 1) In more advanced scripts are steps taken to improve the "aim" - or are most weapons in SL lousy?  2) If a physical object (in this case a bullet) is large and slow... shouldn't gravity pull it down faster than a small fast one? I think I'm going to have to wrap my head around this if I want to progress beyond the hello world gun. - so any insight is appreciated! Thanks!
|
|
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
|
09-20-2006 20:06
1.) Yeah, good luck. Heh. They might as well use integer values for position, direction, and velocity for as (in)accurate as SL is.
2.) Actually the size of the bullet SHOULDN'T matter except for air resistance (which isn't implemented in SL anyway). However, SL is very far from the mark of physical realism in just about all respects.
3.) The steps taken to, "improve aim," usually involve the actual projectile knowing its target and correcting its path as far as I can tell. Or using sensors entirely and not depending on trajectory at all. (Actually there are a few very small things you can do like offsetting the rez point of the bullet so its initial trajectory is right along the axis of the mouselook crosshairs, but you can only do so much that way and you have to correct differently based upon the vertical component of the direction, etc.)
|
|
ScriptScavenger Lei
Registered User
Join date: 3 Sep 2006
Posts: 14
|
targeting and mass vs muzzle speed
09-24-2006 07:42
1 usualy the better weapons have Heads Up Displays (HUD's) mostly for tracking purposes kills, deaths , round count , ect but in some cases they contain targeting scripts wich "aim" for you 2 as far as larger and slower the speed is set by the muzzle speed so larger bullets will have more momentum and wont fall as fast so the greater the mass the strighter it flys
in adition have u tried altering the material and shape to see how it affects flight path ? scripts can be placed in the bullet for different affects think theres a way to alter the physics so smaller rounds will have more mas and torq and do more dammage (or push harder ) you can even put a targeting script in the round if im not mistaken check where youre using the weapon to some battle areas have funny script restrictions
|
|
Vares Solvang
It's all Relative
Join date: 26 Jan 2005
Posts: 2,235
|
09-24-2006 08:38
I have wondered about this a bit in the past. I think that if you use llSetBuoyancy(1); then the bullet shouldn't drop at all. If you set it's boyancy to neutral it should just glide in a straight line until it hits something or you apply some kind of directional force, i.e. gravity won't have any effect on it. Might be worth playing with anyway, since you said you are using physical bullets. 
|
|
Chairman Singer
Registered User
Join date: 27 Sep 2005
Posts: 4
|
09-26-2006 17:25
Thanks folks. I found one freebie weapon that tried to "fix" the rez position of the bullet. I haven't had much luck with it yet. And bouncy is a neat idea.  It seems though that most "good" guns use non-physical bullets that acquire a target and "lock on" if you will. Cool stuff... lots to learn. No idea how exactly a non-physical bullet is supposed to do much good?  Thanks again!
|