wc3campaigns
WC3C Homepage - www.wc3c.netUser Control Panel (Requires Log-In)Engage in discussions with other users and join contests in the WC3C forums!Read one of our many tutorials, ranging in difficulty from beginner to advanced!Show off your artistic talents in the WC3C Gallery!Download quality models, textures, spells (vJASS/JASS), systems, and scripts!Download maps that have passed through our rigorous approval process!

Go Back   Wc3C.net > Warcraft III Modding > Developer's Corner > Cinematics
User Name
Password
Register Rules Get Hosted! Chat Pastebin FAQ and Rules Members List Calendar



Reply
 
Thread Tools Search this Thread
Old 04-08-2006, 01:59 PM   #1
iNfraNe
PhD
 
iNfraNe's Avatar


Cinematics Moderator
 
Join Date: Dec 2003
Posts: 2,283

Submissions (7)

iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)

Approved Map: Mortar Ball

Send a message via MSN to iNfraNe
Default Cinematic general tricks

This "tutorial" illustrates alot of tricks cinematic makers can use to spice up their cinematic visually. I've collected alot of the older and newer tricks and placed them into 1 tutorial.

This tutorial currently holds:
  • Black Cinematic Borders
  • Basic Initialization Triggers
  • Lights (ambient light and omnilights)
  • Setting specific animations for units
  • Getting Model Data
  • Turning heads/torsos (Locking body part facing)
  • Timing

Black Cinematic Borders Thanks go to Hyarion

This requires no imported files. To make the borders black simply go to Advanced > Game Interface...
And change these things:
Table:
Value to be changed:Value to be given:
Image: Cinematic BorderUI\Widgets\EscMenu\Human\blank-background.blp
Image: Console BackgroundUI\Widgets\EscMenu\Human\blank-background.blp
Image: Game Menu BackgroundUI\Widgets\EscMenu\Human\blank-background.blp

Basic Initialization Triggers

I often see cinematics where the music is running trough the custom music played as a sound, simply because the maker didnt have music on and didnt notice. I also very often see a cinematic where there still are ambient sounds, which brings down the mood. Ambient sounds and music should both be triggered, not left to the game randomly.

This trigger will make the game start in a faded out cinematic mode with no sounds at all:
Trigger:
Example Init
Collapse Events
Map initialization
Conditions
Collapse Actions
Cinematic - Turn cinematic mode On for (All players)
Cinematic - Fade out over 0.00 seconds using texture Black Mask and color (0.00%, 0.00%, 0.00%) with 0.00% transparency
Sound - Stop music Immediately
Sound - Clear the music list
Sound - Stop music Immediately
Sound - Disable dawn and dusk sounds
Custom script: call StopSound(bj_nightAmbientSound, true, true)
Custom script: call StopSound(bj_dayAmbientSound, true, true)

The last 2 actions turn off the ambient sounds, be sure to copy them right, else you will get an error.

Lights (ambient light and omnilights)

An often overlooked feature warcraft brings are lights. Tho they seem not highly usable they are in fact quite usable.
Let's start with ambient lighting.
Ever noticed how the lighting goes a little blue when it gets to nighttime? That lighting is actually created by a model and it is changable by triggers!

The syntax is:
Collapse JASS:
call SetDayNightModels("TerrainLightModelHere","UnitLightModelHere")
Ofcourse, you should replace "TerrainLightModelHere" and "UnitLightModelHere" with paths to models. Simply giving them no, or a false path will lead to no light, so the screen will turn pitch black.
Collapse JASS:
call SetDayNightModels("","")
Does makes the terrain and units have no lighting at all.

To create a model, you should either get into some easy .mdl editing, or use any of these programs:
iNfraNe's Ambient Light Creator
ghEEd's LightModel Creator

Once you have created a model with any of these tools you should convert it to .mdx using this tool (or any other): Yobgul's Warcraft III File Converter
After this, import the file (as .mdx) and give it a name, for example my name will now be "Light.mdx".
If I want to use this model for lighting this is the syntax:
Collapse JASS:
call SetDayNightModels("Light.mdl","Light.mdl")
Notice .mdl, yes, you did import it as .mdx but wc3 converts it to .mdl again at mapinit and you should use .mdl as extention in the syntax.

Next you will think, why the **** would I want a pitch black surrounding? The answer is simple. You can now use omnilights to light the environment, like glowing torches. This will give a really nice effect, you can use ghEEd's program to create a lightmodel yourself.

Setting specific animations for units

Ever wanted to make a unit play a specific animation, like "Stand - 2" but then found out the unit still played a random animation?
There is a way out. You should be using the animation native:
Collapse JASS:
native SetUnitAnimationByIndex takes unit whichUnit, integer whichAnimation returns nothing

First, you should store the unit you want to play the animation in a variable, like... tempUnit. In jass, this variable is then called udg_tempUnit (jass is case sensitive, note).

After this, extract the sequences list from the model, and check which number is the animation you want to play (look under the chapter "Getting Model Data" on how to do this). When u have found the animation number, simply input it in the call:
Collapse JASS:
call SetUnitAnimationByIndex(udg_tempUnit, 2)

There, u've let the unit play a specific animation.

Getting Model Data

Often you will want to get something from a model. Like:
  • Attachment points
  • Animation sequences
  • Texturepaths
  • etc
Not much people actually know how easy it is to get this data. I will start with attachment points.

Attachment Points

First, get Yobgul's Warcraft III File Converter to convert the model to .mdl (also, get Prophet's Warcraft III Viewer or something similar to extract your model from the mpq).

Once you have extracted and converted the model, simply open it with notepad. Now search the file for "Attachment". You will find something like this first:
Code:
Attachment "Head Ref" {
	ObjectId 13,
	Parent 1,
}
This is an attachment point, to attach a special effect to it in the editor choose "head" as point, always ignore the Ref. You will find all the attachment points the model has under eachother in this section.
Most common attachment points are:
  • Overhead (over the unit, does not follow animations)
  • Origin (under the unit, does not follow animations)
  • Head (does follow animations)
  • Chest
  • hand left (or right)
  • foot left (or right)
  • Weapon
But I suggest taking a look at the model when you want something else.

Animation Sequences

This is quite easy to find. You can use this to play a specific animation (as I talked about before). Go to the top of the model file and you will see something like
Code:
Sequences 12 {
	Anim "Stand" {
		Interval { 167, 1167 },
		MinimumExtent { -25.0869, -29.3512, 5.52004 },
		MaximumExtent { 35.6949, 29.3513, 18.8083 },
		BoundsRadius 36.2281,
	}
...
This list is in order, the first animation you see (stand in this case, and most cases), is index 0. The second animation you see is index 1 etc.

For other usefull things you can get from the model visit the .mdl editing section.

Turning heads/torsos (Locking body part facing)

It is possible to lock a unit's head OR torso by triggers. You can find the action under "Animation":
Trigger:
Animation - Lock (Last created unit)'s Head to face (Last created unit), offset by (0.00, 0.00, 90.00)
You need to change the units ofcourse. If you let 1 unit look at another his head or chest will follow this unit untill you reset the body part facing.
It is possible to lock the facing to the unit itself, making only the offset factor matter (this way you can make a unit always look in the same direction).

Timing

Most cinematics time their events with WAITS. Tho it might seem handy to use this at the time it is VERY inaccurate and will differ on each computer.
Even gametime waits dont work well. You have two options in this case:

Use a periodic timer to run events (this is hard, and therefore Anitarf has created a system based on this, with ALOT of good stuff in it, I suggest taking a look at it Cinematic System)

or use timers. This will make your cinematic have ALOT of different triggers but the increase in accurate timing is definately worth it. Another possibility is the use of the event "elapsed game time" which is also accurate.

Last words

I hope you found usefull stuff in this tricks tutorial. If you have questions about a certain subject, just make a new thread, dont ask in this one. If you have got more tricks to share please share here (i will add them to this list of tricks).
__________________
Ever so slightly active.
Table:
Past Projects:
The Spirit of Vengeance (Cinematic, Blizzard contest winner)
Elimination Tournament
Mortar Ball
iNfraNe is offline   Reply With Quote
Sponsored Links - Login to hide this ad!
Old 04-08-2006, 02:43 PM   #2
kaldoreielf
User
 
kaldoreielf's Avatar
 
Join Date: Mar 2006
Posts: 179

Submissions (2)

kaldoreielf has a little shameless behaviour in the past (-5)

Send a message via MSN to kaldoreielf
Default

Great! I think this should have been in the "--Submit a Tutorial--" section though...
__________________
My Warcraft Log - Please leave some comments!

Funny Warcraft Pictures Gallery Latest Picture: Up-close Blood Mage

Last edited by kaldoreielf : 04-08-2006 at 02:43 PM.
kaldoreielf is offline   Reply With Quote
Old 04-08-2006, 02:56 PM   #3
iNfraNe
PhD
 
iNfraNe's Avatar


Cinematics Moderator
 
Join Date: Dec 2003
Posts: 2,283

Submissions (7)

iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)

Approved Map: Mortar Ball

Send a message via MSN to iNfraNe
Default

its not really a tutorial, more like general tips/tricks, so I dont think so.
__________________
Ever so slightly active.
Table:
Past Projects:
The Spirit of Vengeance (Cinematic, Blizzard contest winner)
Elimination Tournament
Mortar Ball
iNfraNe is offline   Reply With Quote
Old 04-08-2006, 03:46 PM   #4
Whitehorn
SPOON!
 
Whitehorn's Avatar


Respected User
 
Join Date: Sep 1983
Posts: 4,900

Submissions (114)

Whitehorn is a name known to all (510)Whitehorn is a name known to all (510)Whitehorn is a name known to all (510)Whitehorn is a name known to all (510)Whitehorn is a name known to all (510)

Default

Well my 'tips' topics got relocated there too :(. This is a tutorial AFAIK.
__________________
My Wargame

Be excellent to each other.
Whitehorn is offline   Reply With Quote
Old 04-08-2006, 06:12 PM   #5
Rao Dao Zao
www.raodaozao.net
 
Rao Dao Zao's Avatar


MDL & Resource Moderator
 
Join Date: Aug 2003
Posts: 2,511

Submissions (27)

Rao Dao Zao has a brilliant future (822)Rao Dao Zao has a brilliant future (822)Rao Dao Zao has a brilliant future (822)Rao Dao Zao has a brilliant future (822)Rao Dao Zao has a brilliant future (822)Rao Dao Zao has a brilliant future (822)Rao Dao Zao has a brilliant future (822)

Approved Map: When the Freedom Slips Away

Send a message via MSN to Rao Dao Zao
Default

That thing about the lighting models... I love you for it. You are a genius.
__________________
Rao Dao Zao is offline   Reply With Quote
Old 05-28-2006, 04:40 AM   #6
Pheonix-IV
I want you inside me...
 
Pheonix-IV's Avatar
 
Join Date: Oct 2002
Posts: 4,006

Submissions (17)

Pheonix-IV is a jewel in the rough (212)Pheonix-IV is a jewel in the rough (212)Pheonix-IV is a jewel in the rough (212)Pheonix-IV is a jewel in the rough (212)

Default

The light thing is awesome, but is it possible to change ONLY the Night ambient light or ONLY the day ambient light? Also, does anyone know what the default models are and where to find them?
__________________

Last edited by Pheonix-IV : 05-28-2006 at 04:42 AM.
Pheonix-IV is offline   Reply With Quote
Old 05-28-2006, 09:44 AM   #7
iNfraNe
PhD
 
iNfraNe's Avatar


Cinematics Moderator
 
Join Date: Dec 2003
Posts: 2,283

Submissions (7)

iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)

Approved Map: Mortar Ball

Send a message via MSN to iNfraNe
Default

Quote:
Originally Posted by Pheonix-IV
The light thing is awesome, but is it possible to change ONLY the Night ambient light or ONLY the day ambient light? Also, does anyone know what the default models are and where to find them?
The day night stuff is made with animations, it is changable, but the programs dont support it.

The normal models can be found in: Environment\DNC\
Each tileset has its own model.
__________________
Ever so slightly active.
Table:
Past Projects:
The Spirit of Vengeance (Cinematic, Blizzard contest winner)
Elimination Tournament
Mortar Ball
iNfraNe is offline   Reply With Quote
Old 05-28-2006, 10:02 PM   #8
Waldbaer
Dragonblood Creator
 
Waldbaer's Avatar
 
Join Date: Nov 2003
Posts: 73

Submissions (3)

Waldbaer will become famous soon enough (37)Waldbaer will become famous soon enough (37)

Default

This is really useful. I found some useful things that were new to me, too, although I think I'm a quiet experienced cinematic maker.
I think it's very nice of you Infrane, that you are so open with your technical secrets of cinematic-making and present them to anybody who wants to know something about them!
That's not the case with everybody if I think about this thing called map-protection...
__________________

Last edited by Waldbaer : 05-28-2006 at 10:03 PM.
Waldbaer is offline   Reply With Quote
Old 05-29-2006, 07:29 AM   #9
Pheonix-IV
I want you inside me...
 
Pheonix-IV's Avatar
 
Join Date: Oct 2002
Posts: 4,006

Submissions (17)

Pheonix-IV is a jewel in the rough (212)Pheonix-IV is a jewel in the rough (212)Pheonix-IV is a jewel in the rough (212)Pheonix-IV is a jewel in the rough (212)

Default

Notice that he waited until after he won the cinematic contest to tell us this stuff :P

Anyway, cheers, now i can just alter the base one in MDL to make night combat a reality! Woo!
__________________
Pheonix-IV is offline   Reply With Quote
Old 01-01-2007, 09:16 PM   #10
Ammorth
I blink, therefore I am.
 
Ammorth's Avatar
 
Join Date: Sep 2006
Posts: 1,812

Submissions (10)

Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)

Default

I noticed the links for the Light model creators have perished... Can someone please post it somewhere else, or refer me to a place where I can get either of them?

Edit: Don't feel like posting again.

Merci Beacoup!
__________________

Last edited by Ammorth : 01-01-2007 at 10:49 PM.
Ammorth is offline   Reply With Quote
Old 01-01-2007, 10:00 PM   #11
iNfraNe
PhD
 
iNfraNe's Avatar


Cinematics Moderator
 
Join Date: Dec 2003
Posts: 2,283

Submissions (7)

iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)

Approved Map: Mortar Ball

Send a message via MSN to iNfraNe
Default

Quote:
Originally Posted by Ammorth
I noticed the links for the Light model creators have perished... Can someone please post it somewhere else, or refer me to a place where I can get either of them?
Sorry for that, my server has crashed so the site has been down for some time.
Here they are.
Attached Files
File Type: rar War3 Light Creator.rar (35.0 KB, 93 views)
File Type: rar LightModelCreator.rar (5.5 KB, 102 views)
__________________
Ever so slightly active.
Table:
Past Projects:
The Spirit of Vengeance (Cinematic, Blizzard contest winner)
Elimination Tournament
Mortar Ball
iNfraNe is offline   Reply With Quote
Old 07-16-2007, 12:48 AM   #12
player_72985
Optimus Spine
 
player_72985's Avatar
 
Join Date: Mar 2004
Posts: 413

Submissions (2)

player_72985 has a spectacular aura about (82)player_72985 has a spectacular aura about (82)player_72985 has a spectacular aura about (82)

Send a message via AIM to player_72985 Send a message via MSN to player_72985 Send a message via Yahoo to player_72985
Default

I know this is a 1+year post, however Infrane, the LightModelCreator is not working, and the error "Component 'comdlg32.ocx' or one of its dependencies not correctly registered: a file is missing or invalid" - any ideas on fixes?
__________________
The Return. Unknown Date.

Hidden information:
I've seen the end of time, an oblivion so vast the voids themselves are lost in its shadow. But it is not our end, for I saw your end. ~The Return
Shipwrecked - 100%
Azrael's Tale - Canceled
The Return - Canceled
Blizzard Contest Entry: Waves of Blood - 100%
3rd Place in the Battle.net Contest
player_72985 is offline   Reply With Quote
Old 04-08-2008, 04:35 AM   #13
Drazalon
User
 
Join Date: Jun 2007
Posts: 17

Drazalon has little to show at this moment (0)

Default

hmmm. the jass specific animation is surprisingly simple. ill try this out. if all goes well..
Drazalon is offline   Reply With Quote
Old 08-18-2008, 02:51 PM   #14
iNfraNe
PhD
 
iNfraNe's Avatar


Cinematics Moderator
 
Join Date: Dec 2003
Posts: 2,283

Submissions (7)

iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)iNfraNe is just really nice (266)

Approved Map: Mortar Ball

Send a message via MSN to iNfraNe
Default

Quote:
Originally Posted by player_72985
I know this is a 1+year post, however Infrane, the LightModelCreator is not working, and the error "Component 'comdlg32.ocx' or one of its dependencies not correctly registered: a file is missing or invalid" - any ideas on fixes?
As the filedescription says, get frameworks.
__________________
Ever so slightly active.
Table:
Past Projects:
The Spirit of Vengeance (Cinematic, Blizzard contest winner)
Elimination Tournament
Mortar Ball
iNfraNe is offline   Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

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


All times are GMT. The time now is 04:31 AM.


Affiliates
The Hubb The JASS Vault Clan WEnW Campaign Creations Clan CBS GamesModding Flixreel Videos

Powered by vBulletin (Copyright ©2000 - 2018, Jelsoft Enterprises Ltd).
Hosted by www.OICcam.com
IT Support and Services provided by Executive IT Services