PDA

View Full Version : Few questions about scripting...


civian
07-24-2007, 11:54 AM
Does anyone know how to...

- get the tomahawk missiles (the big white ones) crashing into some buildings?

- get the b3 bomber (the one from zhe zh movies, not the moab) started?

- get some jets started from the aircraft carrier?

- get the promotion of units disabled?

- get the thrash of units killed by gla disabled?

Would be nice if someone could help me, because i am still working on a nice mission for you... :-)

thx

Me Myself & Pi
07-24-2007, 01:44 PM
Well first of all, you need to be an adiquitly expirence scripter to do this. Do you know how to create & work scripts? I'll answer your questions in detail when I know how well you can script. But for for now, I will say this:

The stealth bomber that you see drops bombs, is accually an object, not a movie. even the clouds & the ground below is part of the object. I'll send you a map with the objects that you'll need for the things you need to know how to do, but you need to know how to opperate script to get these working.

I'm not sure what you're asking about "- get the promotion of units disabled?". Do you want the units to be buildable without having to choose the science? Or do you just want to get rid of the units completely?

With the cruise missles & air craft carrier, you'll need use scipts.

Now this senctence doesn't make sence at all "- get the thrash of units killed my igla disabled?" Can you retype it saying it correctly?

If you'd like to know how to access official maps, post a new thread & I'll tell you there.

civian
07-24-2007, 03:50 PM
Thanks for your answer.

Well first of all, you need to be an adiquitly expirence scripter to do this. Do you know how to create & work scripts?

Well i think i can call me an advanced map scripter. But there are still a lot of things to find out...
Here (http://www.file-upload.net/download-346158/mission-fallujah-preview.avi.html) you can download a movie map from me... I`ve uploadet it here a long time ago. Maybe you know it. I want to finish the mission now...


The stealth bomber that you see drops bombs, is accually an object, not a movie. even the clouds & the ground below is part of the object. I'll send you a map with the objects that you'll need for the things you need to know how to do, but you need to know how to opperate script to get these working.

I know about the special buildings like b3 - bomber or baikonur missile. Itīs no problem to place them on the map but i don`t know how to move them...


I'm not sure what you're asking about "- get the promotion of units disabled?".

I mean they shouldn`t get ranked if they did a good job, the yellow signs are disturbing during the movies...


Now this senctence doesn't make sence at all "- get the thrash of units killed my igla disabled?" Can you retype it saying it correctly?

I`m sorry for my english, but i`m from germany...
I mean the boxes which get spawned when a scorpion or a quad kills an enmy unit. They also look awfull in movies...


If you'd like to know how to access official maps, post a new thread & I'll tell you there.

I know how to get them... :-)

So there is also another question. The local player should be able to call for paradrop infantry every 5 minutes. I know that i have to give him the specific science...
But how can i script the part with the 5 minutes?


Thx a lot for your help...

Me Myself & Pi
07-24-2007, 08:02 PM
Somthing didn't work right with that movie. Window Media Player says it's just a song, no picture. But I heard some captions & some tanks moving. So I know that you know how to work scripts.

- get the tomahawk missiles (the big white ones) crashing into some buildings?

This will be pretty tough scripting. I just learned how to do this from the 5th USA Mission. Go through this little exersize:
1) Place the object "America\Vehicle\CINE_0U6_CruiseMissleAttack" Any where on the map. This object is where a cruise missle will come, you can ajust where you want the missle to come from by ajusting the angle.
2) Place a waypoint over it & call it anything you want, but remember it's name.
3) Create a new script & set a timer to expire in 2 seconds. (the amount of time it takes for the missle to hit the ground.)
4) Create a new script that has a condition waiting for the the timer to expire. In the action, selet "Unit\Spawn\Spawn -- unnamed unit on team at waypoint."
5) In that action, select the object "GLA\SYSTEM\CINE_CruiseMissleDetObject" this object makes the explotion as soon as it spawn. Select any any player except nuetral for the team. Selete the waypoint you created.
6) Test the map, a cuise missle should come from the sky & hit the ground & make an explotion.
Note: this expotion doesn't cause any damage, you have to deal damage to certian unit around where the cruise missle hit with an action. (I'm sure you know where it it.)
7) To have the cruise missles hit at different times, then use a script to spawn the "CINE_0U6_CruiseMissleAttack" & set a timer for 2 seconds for the missle explotion.
8) You can also use the "CINE_0U6_CruiseMissleFly" All it does is fly around, can move it through scripts. The USA mission used it to see the missle fly overhead.

- get the b3 bomber (the one from zhe zh movies, not the moab) started?


1) You'll need three objects, "Civilian\Structure\CINE_B301,CINE_B302, & CINE_B303". Name the first two object any thing you want.
2) Postion the camera at the jet of the "CINE_B301" & use the action "Unit\CommandButton\Use commandbutton ability.", select the name you named of the B301. Then select one of the two command buttons (I don't think it matters which one.) & the jet should start moving. (I don't know why they're the command button names as used to launch the rocket.) I think the camera will start following it autmaticly after that.
3) Set a timer for the time it takes to get to the other side of the clouds & after that, move the camera some where else (In the mission, the camera moved to the chinooks.)
4) Now move the camera to the B302 & tell it to use to its command ability & you'll see the bombs fall out.
5) Now move the camera to the place where you want the bombs to fall & spawn the B303 (That object it the 6 bombs) at a pretty high distance spawn it there. (Gives them time to fall.)
6) That should to it!

- get some jets started from the aircraft carrier?

Just use one of the four actions here "Unit\CommandButton\..." in a script. It's really easy to do. (After you select the name of the air craft carrier, which you need to name, the command buttons will show up in the drop down list of "Ability:"

- get the promotion of units disabled?

You know how to use INI files right? Here's what I use for my INI files:

Object Lazr_AmericaTankCrusader
IsTrainable = No
End

Just change the "Lazr_AmericaTankCrusader" to whatever unit you want. The names of each units are in the object list in the world builder.

- get the thrash of units killed by gla disabled?

Now I know what you mean! This is how you spell "trash". Well, what I do is set the wathing player to a china or USA faction because those armies can't see it. Go ahead & study the shell map & see how they do it. (The map that plays in the back on the menu screen.)

So there is also another question. The local player should be able to call for paradrop infantry every 5 minutes. I know that i have to give him the specific science...
But how can i script the part with the 5 minutes?

You'll have to use an INI file to modify the time. Assuming you know how to work them & how to create a simple map INI file, then create it from the "SpecialPower.ini" file in the "INIZH.big" file. Just use the "Find" program & to find "Para"

chaoscontrol512
07-25-2007, 01:43 AM
- get the promotion of units disabled?
Another thing you can do for this is to use the script "Remove Draw-Icon UI". This will remove the veterancy chevrons, but it won't stop them from gaining experiance.

civian
07-25-2007, 01:47 PM
Hey guys...

thanks a lot for your extensive answers !

I will now try to get the stuff working in the wb...

After that, i will report everything as soon as i can...:)Another thing you can do for this is to use the script "Remove Draw-Icon UI". This will remove the veterancy chevrons, but it won't stop them from gaining experiance.

Hey, this one works fine :-)

Two hours later: Ok, I am finished for today...

For now I can say, the shellmap works, the missile attack works and the Remove Draw-Icon UI works...

Thats really good for one evening...

But the aircraftcarrier still doesnt start any jet, although i tell it to use the commandbutton...

civian
07-30-2007, 12:49 PM
I have another question about the tomahawk attack...

Is their any way to settle the direction from wich they attack...

Look at the map "falludscha cutscene". I need to change the direction in the lat camera move...

Me Myself & Pi
07-30-2007, 09:42 PM
Yes, it is possible. I accually just said it in my last post.

1) Place the object "America\Vehicle\CINE_0U6_CruiseMissleAttack" Any where on the map. This object is where a cruise missle will come, you can ajust where you want the missle to come from by ajusting the angle.

civian
07-31-2007, 06:51 AM
Yes, it is possible. I accually just said it in my last post.

No I cant do it that way because the missiles should attack a city during the third camera view of a cutscene...
So I will have to spawn them, otherwise they will attack after two seconds in the intro movie...

Me Myself & Pi
08-01-2007, 07:52 AM
You can spawn stuff at angles. But then you also need to know the x, y, & z cordinates. To find this info, first click on the Lock Angle button in the world builder. It's just to the right of the mouse button. Now place waypoints where you want the missles to come, you'll see at the right, in the waypoint window, the x & y cordinates. They'll be in the 100s place, (Lock angle does that. If you didn't check Lock Angle before placing the waypoint, then it would be some number with a lot of decimal numbers.) Now move you mouse to the waypoint, you'll see at the bottum of the world builder world builder, the hight it's in. (This hight is different then the hight you choose when you molded your map terrain. It's precisly 5/8 of that hight. So if it's at 80ft, then you'll see 50 ft.) Now go to script (leaving the waypoint window up.) & choose the action. "Spawn a named unit on team with oriontaion." Put there the x & y cordinates you see in the waypoint window, & put the hight you saw at the bottum of the world builder window. Now you can choose it's angle!

chaoscontrol512
08-01-2007, 03:21 PM
Don't forget to leave Z at zero. This will spawn the object on the terrain, not suspended in the air or buried in the ground.