[1:39:03 PM] <smoth2> jk
[1:39:24 PM] <smoth2> what is your opinion on me trying to attach models to units
[1:39:36 PM] <smoth2> I was thinking that you do polies for stuff like lups
[1:39:46 PM] <smoth2> so maybe it won't be too expensive?
[1:46:37 PM] <[LCC]jK> attach models to units?
[1:50:47 PM] <smoth2> yeah
[1:51:01 PM] <smoth2> like say I want to use a different model for the barrel on a tank
[1:51:31 PM] <smoth2> and attach said model to the tank barrel object of the tank(which would be an empty object)
[1:53:44 PM] <smoth2> say like the guns on the top left
[1:53:44 PM] <smoth2>
http://img820.imageshack.us/img820/7091/armor1.gif
[1:54:10 PM] <smoth2> I have an empty object on the arm where the gun will go
[1:54:19 PM] <smoth2> and want to attach the weapon model
[1:54:53 PM] <smoth2> I would only move the gun by moving the point it is attached to
[1:55:00 PM] <smoth2> thoughts?
[1:57:17 PM] <smoth2> fucking weblobby
[1:58:10 PM] <[LCC]jK> you could just replace the dlist
[1:58:46 PM] <smoth2> even if it is a model using a different texture?
[1:58:54 PM] <[LCC]jK> the other barrels still need to be features or units to access their dlist, but you don't need to really create an unit
[1:59:17 PM] <[LCC]jK> even then you could swap the texture with dlists
[1:59:38 PM] <smoth2> what if it is a different texture than the modeling I am attaching?
[1:59:52 PM] <[LCC]jK>
http://springrts.com/wiki/Lua_UnitRendering
[2:00:04 PM] The time is now 2:00:04 PM
[2:00:31 PM] <[LCC]jK> Spring.UnitRendering.SetMaterialDisplayLists -> swap the texture in those 2 dlists (they get called before and after the piece)
[2:00:49 PM] <smoth2> oh so the attched piece can use a different source than the parent?
[2:00:56 PM] <[LCC]jK> and replace the dlist of the piece with Spring.UnitRendering.SetPieceList
[2:01:03 PM] <[LCC]jK> yup
[2:01:09 PM] <smoth2> how do I attach the model piece to another model?
[2:01:21 PM] <smoth2> oh
[2:01:26 PM] <smoth2> I grab the piece from one unit
[2:01:31 PM] <smoth2> and attach to another?
[2:03:51 PM] <[LCC]jK> yup
[2:04:10 PM] <[LCC]jK> but it seems you need to create an unit with the new model once ...
[2:04:32 PM] <smoth2> so I need to have a rack of guns somewhere on the map lol?
[2:06:36 PM] <smoth2> so if my gunrack dies?
[2:06:43 PM] <[LCC]jK> nah you just need it for an infinitesimal period
[2:06:52 PM] <[LCC]jK> to create the dlist
[2:06:56 PM] <smoth2> ah
[2:07:01 PM] <[LCC]jK> after that you can destroy the unit again