Jump to content


Photo

changing an objects texture using map ini


  • Please log in to reply
33 replies to this topic

#21 njm1983

njm1983

    title available

  • Project Team
  • 2,867 posts
  • Location:Orangevale, California USA

Posted 23 February 2013 - 05:50 AM

Well there is the clue... it was your paths of the dead, now that you mention it.

#22 MattTheLegoman

MattTheLegoman

    LEGO Knight of Minas Ithil

  • T3A Staff
  • 3,669 posts
  • Location:Tomorrow, when the War began
  • Projects:Mapping this Middle-earth
  •  Mapper
  • Division:BFME
  • Job:T3A Staff

Posted 23 February 2013 - 06:26 AM

:rolleyes:
Golly gosh. ;p I did not understand things like I do now. It would have been either the minor edit EA Paths (cloud was there from EA), or my City of the Dead (in which I changed the textures for RJ-Cam and they showed pink in game, just like our rocks, same reason)
:) Well, the next step would be to ask if one can have a mod with just textures, maps and an asset, so we can test this seperately to SEE and merge later.

Remember that all worlds draw to an end and that noble death is a treasure which no one is too poor to buy. - C.S. Lewis

There will come a time when you believe everything is finished. That will be the beginning. - Louis L'Amour

What will matter then will be people. If relationships will matter most then, shouldn't they matter most now? - Max Lucado


#23 Bofur

Bofur

    The Bolicious One

  • Hosted
  • 1,766 posts
  • Location:England
  • Projects:Age of the Firstborn
  •  The Bolicious T3A Team Chamber Member

Posted 23 February 2013 - 07:48 AM

Yep.


left64_by_obsidianlake-d5ruayp.pngAotF.pngright64_by_obsidianlake-d5ruf44.png


#24 Fudge

Fudge

    title available

  • Project Team
  • 531 posts
  • Location:Devon, England
  • Projects:Luckily AotR Mapping

Posted 09 April 2013 - 05:15 PM

Hey could somebody maybe point me in the right direction with a little problem?

I'm trying to change the textures of all the rocks on a map so that they are more moss covered, now I've found a texture in the games default Asset.dat that would be appropriate (prfngrnrock.dds) but it doesn't seem to work and when I fiddle around the object disappears entirely.
.
Here's what I've got in the map.ini


;------------------------------------------------------------------------------
Object DarkRockGrey05
ReplaceModule ModuleTag_01
Draw = W3DScriptedModelDraw ModuleTag_01_NEW
StaticModelLODMode = yes
RandomTexture = prfngrnrock.tga 0 roh01.tga
OkToChangeModelColor = Yes
DefaultModelConditionState
Model = PRDarkGrey05
End       
End
End
End

Edited by Fudge, 09 April 2013 - 05:16 PM.


#25 Bofur

Bofur

    The Bolicious One

  • Hosted
  • 1,766 posts
  • Location:England
  • Projects:Age of the Firstborn
  •  The Bolicious T3A Team Chamber Member

Posted 09 April 2013 - 05:20 PM

Just a guess, wouldn't it be just Texture and nor RandomTexture...?

left64_by_obsidianlake-d5ruayp.pngAotF.pngright64_by_obsidianlake-d5ruf44.png


#26 Fudge

Fudge

    title available

  • Project Team
  • 531 posts
  • Location:Devon, England
  • Projects:Luckily AotR Mapping

Posted 09 April 2013 - 05:51 PM

I've tried that before and I get an error message.



#27 njm1983

njm1983

    title available

  • Project Team
  • 2,867 posts
  • Location:Orangevale, California USA

Posted 09 April 2013 - 11:03 PM

Sorry I didnt see this sooner.

 

Here is the code from MTL map ini for weathertop

 

 

Object IronHillsRockyOutcropping02
    ReplaceModule ModuleTag_01
        Draw = W3DScriptedModelDraw ModuleTag_01_irontoas
            StaticModelLODMode = yes
            RandomTexture = prascliff01.tga 0 pironhillsoutcrop02.tga
            OkToChangeModelColor = Yes
            DefaultModelConditionState
                Model = PIronHillsOut02
            End       
        End    
    End
End
 


#28 MattTheLegoman

MattTheLegoman

    LEGO Knight of Minas Ithil

  • T3A Staff
  • 3,669 posts
  • Location:Tomorrow, when the War began
  • Projects:Mapping this Middle-earth
  •  Mapper
  • Division:BFME
  • Job:T3A Staff

Posted 10 April 2013 - 03:43 AM

I don't know if this will work - tell me of course if it does.

 

The information I used to make this came from data\ini\object\nature\naturerocks.ini

and art\compiledtextures\pr

ChildObject DarkRockGrey05 GenericRockVendor
    ReplaceModule ModuleTag_01
        Draw = W3DScriptedModelDraw ModuleTag_01_darkgreytofan
            StaticModelLODMode = yes
            RandomTexture = prfngrnrock.tga 0 prgrey.tga
            OkToChangeModelColor = Yes
            DefaultModelConditionState
                Model = PRDarkGrey05
            End
        End
    End
End

ModuleTag_01_darkgreytofan you can change this if you like.


Remember that all worlds draw to an end and that noble death is a treasure which no one is too poor to buy. - C.S. Lewis

There will come a time when you believe everything is finished. That will be the beginning. - Louis L'Amour

What will matter then will be people. If relationships will matter most then, shouldn't they matter most now? - Max Lucado


#29 Fudge

Fudge

    title available

  • Project Team
  • 531 posts
  • Location:Devon, England
  • Projects:Luckily AotR Mapping

Posted 10 April 2013 - 10:00 AM

Thanks Matt but unfortunately the rock still has the same texture.



#30 Ridder Geel

Ridder Geel

    Master Yelloh

  • T3A Staff
  • 10,852 posts
  • Location:The Netherlands (AKA: Holland)
  • Projects:RC Mod + SEE + RTS Engine
  •  The Dangerous T3A Team Chamber Member
  • Division:BFME
  • Job:T3A Staff

Posted 10 April 2013 - 04:55 PM

I don't believe you need to mention the childobject part in map.ini, but i could be wrong... I tend not to work in the map.ini's :p

 

Object DarkRockGrey05
    ReplaceModule ModuleTag_01
        Draw = W3DScriptedModelDraw ModuleTag_01_darkgreytofan
            StaticModelLODMode = yes
            RandomTexture = prfngrnrock.tga 0 prgrey.tga
            OkToChangeModelColor = Yes
            DefaultModelConditionState
                Model = PRDarkGrey05
            End
        End
    End
End

That should work if that is indeed the texture you want applied to the model... first is the one it changes to, second is the original texture :p (unless im mixing those two up again -.-')


Ridder Geel

#31 Fudge

Fudge

    title available

  • Project Team
  • 531 posts
  • Location:Devon, England
  • Projects:Luckily AotR Mapping

Posted 10 April 2013 - 06:34 PM

Nope that doesn't work, why is it whenever I try and do something with ini it's always rather complicated.



#32 njm1983

njm1983

    title available

  • Project Team
  • 2,867 posts
  • Location:Orangevale, California USA

Posted 10 April 2013 - 09:43 PM

Thats why I ask others to solve it for me. Then just give me the code. Though I feel like a douche afterward. Lol

#33 Glorfindel23

Glorfindel23
  • Project Team
  • 157 posts
  • Projects:Glorfindel23's Submod + MapsPack and The Horse Lords

Posted 27 February 2016 - 11:36 AM

How can I change the texture of a units in the game ?

 

My code doesn't work I dont know please help me  :

 

 

Object LindonElvenWarrior

ReplaceModule ModuleTag_01
Draw = W3DHordeModelDraw ModuleTag_01Test
StaticModelLODMode  = yes
RandomTexture  = eugaladh_bow.tga  0 cubows.tga
OkToChangeModelColor  =  Yes 
DefaultModelConditionState 
   Model = rugaladrim_skn
   Skeleton = RUElfWar_SKL
End        
End 
   KindOf = PRELOAD SELECTABLE CAN_CAST_REFLECTIONS INFANTRY SCORE THROWN_OBJECT PATH_THROUGH_EACH_OTHER ARCHER ATTACK_NEEDS_LINE_OF_SIGHT GRAB_AND_DROP
    Scale = 0.91
    Geometry = CYLINDER
    GeometryMajorRadius = 8.0
    GeometryMinorRadius = 8.0
    GeometryHeight = 19.2
    GeometryIsSmall = Yes
    Shadow = SHADOW_DECAL
    ShadowSizeX = 14;
    ShadowSizeY = 14;
    ShadowTexture = ShadowI;
End
 
End
 

Edited by Glorfindel23, 27 February 2016 - 11:37 AM.

                                                                                                                                        mini_175165Glorfindel23Cover.jpg

 

31062.png

 

 


#34 Bofur

Bofur

    The Bolicious One

  • Hosted
  • 1,766 posts
  • Location:England
  • Projects:Age of the Firstborn
  •  The Bolicious T3A Team Chamber Member

Posted 27 February 2016 - 02:39 PM

Won't work, as in it comes up with the original texture? What's the name of the original texture? This code should work, assuming the original texture was cubows.tga, and the new one is eugaladh_bow.tga... You may have them the wrong way around?


left64_by_obsidianlake-d5ruayp.pngAotF.pngright64_by_obsidianlake-d5ruf44.png





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users