Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds

Members Online

»
0 Active | 3 Guests
Online:

LATEST FORUM THREADS

»
warfare
CoD4 Map + Mod Releases
Voting menu on maps
CoD+UO General
Hauling 911
CoDBO3 General

Forums

»

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Call of Duty 4
Category: CoD4 SP Mapping
CoD 4 mapping and level design for single player.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword, playername, novemberdobby
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked
Page
Previous Page
subscribe
Author Topic: How to get a chopper of jet to fly over head?
sam_fisher3000
General Member
Since: Apr 18, 2007
Posts: 816
Last: Jul 16, 2016
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD4 SP Mapping
Posted: Monday, Dec. 13, 2010 10:55 pm
I can help u on that. Give me sometime and I will give u the codes. I have it but I need sometime to sorted out and I need to know that u are willing to accept it.
Share |
Blade_MacTavish
General Member
Since: Jun 7, 2009
Posts: 438
Last: Jul 8, 2012
[view latest posts]
Level 5
Im a fan of MODSonair
Category: CoD4 SP Mapping
Posted: Monday, Dec. 13, 2010 11:04 pm
Sure.
Share |
sam_fisher3000
General Member
Since: Apr 18, 2007
Posts: 816
Last: Jul 16, 2016
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD4 SP Mapping
Posted: Monday, Dec. 13, 2010 11:45 pm
Now, getting the helicopter to shoot isn't too hard. I don't know why you want to use it on friendlies. It would be considered friendly fire but if that's what you want, then you got it. I guess your saying an enemy helicopter. I dont usually script for enemies so it's a habit of wondering why you want this. It's the same for the enemies, or I should say vise versa. However, what I did was, I used a script_origin as the target. I put it near the enemy, or the friendlies in your case. I don't remember clearly, but you can use it on the actors, but to me, I had some errors as in the actors are undefined. I don't have time to test it now, since I don't have time, but you can experiment with it. For now, just use the script_origin or script_struct if you prefer.

Ok, I assume you got the basic done. Now, make sure that on one of the script_struct that you want your helicopter to stop at, make sure you give it a targetname.

Then, name your script_origin that is the target and place it by the enemies. Don't worry, the weapon that the heli uses will hit the enemy.

Now, that's it in radiant, pretty much, you can also go ahead a give a targetname for the enemies or friendlies. Now the script.

Code:

cobrashoothere = getent("cobrashoothere","targetname"); //the target

cobraattack = getstruct("shoot_here","script_noteworthy"); //your script_struct that you want the heli to stop at. 
cobraattack waittill( "trigger", helicop ); /waittill the heli reaches that script_struct. helicop is what I named my helicopter, use what you have named.

helicop vehicle_detachfrompath(); // detach it from the path so it can stop and shoot


wait 0.75; //give it some time

helicop thread fire_missile( "mi28_seeker", 10, cobrashoothere, 3 ); // now this is from the _helicopter_globals gsc file. Check out the file for more helicopter actions.

//mi28_seeker is the weapon name, you can find out other weapons in the gsc file. 10, if I can remember is how many times or how many bullets you want it fire. Cobrashoothere is the target. 3 would be the delay between shots. It tells you what all the variables/functions are in the gsc file. 

then when you are done, use another wait if you like to get it in order. Sometimes, it might not response properly.

wait 5;

helicop vehicle_resumepathvehicle(); // continue flying.


Now, you can use
Code:

helicop thread mgon(); //this uses the machine gun. If I can remember machine gun is the only one that you don't need to script. It fires by itself at any enemy it sees. You can just add this without all those codes, if you just want the machine gun. 


Make sure you have all the other scripts ready. Like spawning the vehicles, activating the triggers. Remember to use a wait before you spawn the helicopter or any vehicles for that matter.


If you need more help and requires the whole script for this scene, I will be more than glad to share it. This scene was in the part 3 playtest, the one where Colonel Markens dies. I know I did not release the source file but it would be a good idea to see what actually happens. And ask away if you need anything.


Enjoy!



edited on Dec. 13, 2010 06:46 pm by sam_fisher3000

Make sure you add this at the top

#include maps\_helicopter_globals;

with all the other stuff.



edited on Dec. 13, 2010 06:47 pm by sam_fisher3000

edited on Dec. 13, 2010 06:48 pm by sam_fisher3000


credit goes to voidsource who helped me on this.

edited on Dec. 13, 2010 06:49 pm by sam_fisher3000


isn't too hard, sorry typo. It isn't too hard.
Share |
sam_fisher3000
General Member
Since: Apr 18, 2007
Posts: 816
Last: Jul 16, 2016
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD4 SP Mapping
Posted: Tuesday, Dec. 14, 2010 09:30 pm
So, Blade_MacTavish, have you gotten it to work and getting the hang of it?
Share |
Blade_MacTavish
General Member
Since: Jun 7, 2009
Posts: 438
Last: Jul 8, 2012
[view latest posts]
Level 5
Im a fan of MODSonair
Category: CoD4 SP Mapping
Posted: Saturday, Dec. 18, 2010 03:52 pm
I'm hopeless at this.[banghead]

Okay, here, how about this...

-Get the choppers you sent me earlier to fly away upon target.

-Get a chopper to come pick you up.
Share |
sam_fisher3000
General Member
Since: Apr 18, 2007
Posts: 816
Last: Jul 16, 2016
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD4 SP Mapping
Posted: Saturday, Dec. 18, 2010 03:58 pm
Blade_MacTavish writes...
Quote:
I'm hopeless at this.[banghead]

Okay, here, how about this...

-Get the choppers you sent me earlier to fly away upon target.

-Get a chopper to come pick you up.


It's not that hard. Did you even follow my tutorial?

What do you mean by "Get me the choppers you sent me earilier to fly away upon target."

Get me the choppers?

Getting a chopper to pick you up isn't hard as well. You do need a chinook or the seaknight though. You just need to make it land.

Code:


heli = getent("heli","targetname");

lz_spot = getstruct( "unload_team", "script_noteworthy" );

lz_spot waittill( "trigger", heli );

heli vehicle_detachfrompath();

heli vehicle_land();

heli notify( "unload" );
	
heli waittill( "unloaded" );

activate_after_unload = getent("activate_after_unload","script_noteworthy");
activate_after_unload activate_trigger();

wait 2;

heli vehicle_resumepathvehicle();

}





edited on Dec. 18, 2010 10:58 am by sam_fisher3000


When it lands, get in the chinook and you need to link to the seat. Find out the tag and link to it.

You don't need to unload btw.

edited on Dec. 18, 2010 11:00 am by sam_fisher3000
Share |
Blade_MacTavish
General Member
Since: Jun 7, 2009
Posts: 438
Last: Jul 8, 2012
[view latest posts]
Level 5
Im a fan of MODSonair
Category: CoD4 SP Mapping
Posted: Monday, Jan. 3, 2011 03:11 am
So if don't need it to unload, what do I remove from the script so it just lands and I can go in?
Share |
sam_fisher3000
General Member
Since: Apr 18, 2007
Posts: 816
Last: Jul 16, 2016
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD4 SP Mapping
Posted: Monday, Jan. 3, 2011 04:01 am
Blade_MacTavish writes...
Quote:
So if don't need it to unload, what do I remove from the script so it just lands and I can go in?


Remove the heli notify unload and the wait till unload. These are the unload functions, just remove them. I don't have time right now to make a tutorial on this, perhaps later this year. Hope this helps.
Share |
Restricted Access Topic is Locked
Page
Previous Page
subscribe
MODSonline.com Forums : Call of Duty 4 : CoD4 SP Mapping

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»