No shadow (ASM tweak)

From FSDeveloper Wiki
Jump to: navigation, search



This article describes how you can remove the shadow from your scenery object created with MakeMDL. This can for example be useful if you have made a tree with a transparant texture and don't want the shadow to have the shape of the full polygon.

Below you find the code changes required when you are working with the Fs2002 gamepack. For the Fs2004 gamepack the changes are different, but these have not yet been added to this article.

Fs2002 gamepack

Find the piece of code that looks like the example below in your main ASM file (so not the one with the _0 in the name).

ADDOBJ OBJECT_0_SCALE
SHADOW_CALL OBJECT_0_SCALE
OBJECT_0_FAIL label BGLCODE

To remove the shadow all you need to do is to remove the comand called SHADOW_CALL. So after that your code will look like this:

ADDOBJ OBJECT_0_SCALE
OBJECT_0_FAIL label BGLCODE

Tip: Don't use this tweak for removing shadows from ground polygons, use the tweak instead that makes them real ground polygons.