SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help > Help Archive

 
 
Thread Tools Display Modes
Old 11/06/2011, 09:11 PM   #1
Donya
Gangsta
 
Join Date: Mar 2011
Posts: 735
Reputation: 33
Default "Slight homing", make a missile "Slightly!" home a vehicle.

alright, now i'm making something out of the ordinary, i want to make a missile "Slightly Home" (Slightly Follow) a vehicle. but if the vehicle goes out of range, it continues to go straight ahead.

now what i mean by slightly home is

[ame]http://www.youtube.com/watch?v=A_LrO-49vB4[/ame]

Look for the fire & homing missile, 0:14 for homing and 0:21 for fire

see the difference?

ok so, i already made a perfect homing missile. but now the question is? how to i make something slightly home instead of home fully
Donya is offline  
Old 11/06/2011, 09:18 PM   #2
Retardedwolf
High-roller
 
Retardedwolf's Avatar
 
Join Date: Jun 2009
Posts: 1,558
Reputation: 60
Default Re: "Slight homing", make a missile "Slightly!" home a vehicle.

Make a timer that runs on 1 second or so, then when a player shoots the missile, make the missile go straight to the vehicle's X, Y, Z and WAIT until the object hits the targeted X, Y, Z if the vehicle is still in the range make it move to the X, Y and Z again and repeat until the vehicle is in its explode range.
Retardedwolf is offline  
Old 11/06/2011, 09:37 PM   #3
Donya
Gangsta
 
Join Date: Mar 2011
Posts: 735
Reputation: 33
Default Re: "Slight homing", make a missile "Slightly!" home a vehicle.

that is homing, not slightly homing, hold up. i found a different twisted metal showing how a fire missile really works.

[ame]http://www.youtube.com/watch?v=_bRklv-c0LQ&feature=related[/ame]

1:01

see the ice cream truck guy actually shot the missile? it homed at it barely, but not fully. so the car was driving so fast, it didn't hit.
Donya is offline  
Old 11/06/2011, 10:17 PM   #4
Joe Staff
High-roller
 
Joe Staff's Avatar
 
Join Date: Aug 2007
Posts: 2,795
Reputation: 377
Default Re: "Slight homing", make a missile "Slightly!" home a vehicle.

that kind of action requires more than just a get/set position script. Something like that requires one base coordinate at which point it will only change velocity at a specific speed. What I'm saying its it's slightly more complicated than regular homing
__________________
Big bottom girls make this rockin' world go 'round.
Joe Staff is offline  
Old 11/06/2011, 10:20 PM   #5
Donya
Gangsta
 
Join Date: Mar 2011
Posts: 735
Reputation: 33
Default Re: "Slight homing", make a missile "Slightly!" home a vehicle.

Quote:
Originally Posted by SilentHuntR View Post
that kind of action requires more than just a get/set position script. Something like that requires one base coordinate at which point it will only change velocity at a specific speed. What I'm saying its it's slightly more complicated than regular homing
yes, i already started on it. for now im using a complicated random script, so when a fire missile is fired, if a vehicle is streamed in and the being aimed at, it will randomly home to that vehicle, as in it homes, then continues straight. etc randomly. that will have to do for now.
Donya is offline  
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
D:\Mis documentos\Server\gamemodes\lscnr.pwn(30602) : error 001: expected token: ",", but found ";" [M]xFire Help Archive 3 27/08/2010 08:11 PM
[SOLVED]warning 224: indeterminate array size in "sizeof" expression (symbol "") LarzI Help Archive 2 22/12/2009 05:32 AM
Admin script requires "ReturnUser", "strtok" and "IsNumeric" Rubennnnn Help Archive 1 02/12/2009 07:08 PM
"Bots", "AI", "NPCs"... Computer-controlled pedestrians and traffic! ssflsnoob General 2 23/11/2008 07:06 PM


All times are GMT. The time now is 05:52 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.