Announcement

Collapse
No announcement yet.

Staticmesh question

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Staticmesh question

    in the default properties of this code(from XEffects.u)
    i notice the thing that says StaticMesh=StaticMesh'GibBotHead'
    what is it referencing to and how would i add something like that?

    when i open the xeffects.u with WOTgreal or UTPT i can see the GibBotHead in there but how did they add it on to the package and how would i do it while compiling?

    //================================================== ==============================
    // GibBotHead.
    //================================================== ==============================

    class GibBotHead extends GibHead;

    defaultproperties
    {
    GibGroupClass=Class'xBotGibGroup'

    TrailClass=Class'BotSparks'

    HitSounds(0)=ProceduralSound'WeaponSounds.PGrenFlo or1.P1GrenFloor1'

    HitSounds(1)=ProceduralSound'WeaponSounds.PGrenFlo or1.P1GrenFloor1'

    DrawType=8

    StaticMesh=StaticMesh'GibBotHead'

    DrawScale=0.60

    Skins=

    CollisionRadius=5.00

    CollisionHeight=2.50

    }

    #2
    Look at the #exec calls in GibOrganic_rc.uc. That's how they embedded the meshes into the package.

    Comment


      #3
      Just be aware that you dont need a resource class to do this, you can import meshes, textures, sounds, or any other data type into a .u file. They just use the _rc idea from c++, most likely.

      Comment


        #4
        When compiling the compiler loads default resources, xweapons.u, xeffects.u, etc etc.

        Since the packages are open and available to the compiler it can reference to a class without having the package name, eg: StaticMesh = StaticMesh'GibBotHead' ; Since GibBotHead is a static mesh in xEffects.u you don't need to reference the class. But if you did not have xEffects.u loaded when compiling, you would get an error, ' could not find "GibBotHead" '.

        If you have a package that is not loaded when you compile, you need to add the #exec directive, like:

        #exec OBJ LOAD File="xEffects.u" // Which isn't needed btw.

        then you could refference to xEffects.u as stated in the default properties.

        Or as stated above, import your static meshes to the .U file.

        Comment


          #5
          oh ok, thanks so if its loaded in the parent class it doesn't need to be loaded again

          Comment

          Working...
          X