Jump to content

Add lights to my static object


Recommended Posts

Hi.

 

I've created a very simple model and I can get it to appear in game. However i am confused as to how lights work. I have created an Empty object and parented it to the armature. I then set it to Light in EDM property and set values. It renders find in ModelViewer but does not appear in game?

 

I have also looked at Connectors but I don't know how to define my light in my lua file.

 

It looks like this

 

mount_vfs_model_path    (current_mod_path.."/Shapes")
mount_vfs_texture_path  (current_mod_path.."/Textures")
-- CWAY - Fudges Cone Barricade X3
    CWAY = {};
    set_recursive_metatable(CWAY, GT_t.generic_stationary)
    set_recursive_metatable(CWAY.chassis, GT_t.CH_t.STATIC);
    CWAY.chassis.life = 10

    CWAY.visual.shape = "TestModel"

    --Burning after hit
    CWAY.visual.fire_size = 0 --relative burning size
    CWAY.visual.fire_pos = {0,0,0};
    CWAY.visual.fire_time = 0 --burning time (seconds)
    CWAY.time_agony = 180;
        CWAY.Name = "TestModel"
    CWAY.DisplayName = _("Test Model")
    CWAY.Rate = 1

    CWAY.DetectionRange  = 0;
    CWAY.ThreatRange = 0;
    CWAY.mapclasskey = "P0091000076";
    CWAY.attribute = {wsType_Ground,wsType_Tank,wsType_NoWeapon,wsTypeVAZ,
                    "Fortifications",
                    };
    CWAY.category = "Fortification";
    
    add_surface_unit(CWAY)

 

Is there a complete list of properties for objects?

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...