Posted by: Kvantovy - Saturday, January 7, 2017 5:26:07 AM
Hello! I took up modding Generals a few days ago. My current goal is to replace original Crusader model and texture with my own tank. At first I made a simple model with simple textures to test my workflow, and it worked ingame: http://i.imgur.com/GFatHrB.jpg After that I made a more serious model, but when I tried to test it ingame, the texture was not loading. Apart from that, the tank work as intended, it moves, shoots etc. http://i.imgur.com/wrkvbh2.jpg The UV coordinates are there, when I check them in gmax: http://i.imgur.com/qJwd3L4.png I place .W3D files in \Command and Conquer Generals Zero Hour\Art\W3D\avleopard.W3D \Command and Conquer Generals Zero Hour\Art\W3D\avleopard_D.W3D and .dds texture in \Command and Conquer Generals Zero Hour\Art\Textures\avleopard.dds Can someone help? Here are the files I used at the last try: (gmax, source .png texture, .dds texture and exported .w3d) http://www.filedropper.com/abramsfiles BTW: Is there a free image to .DDS converter that works well on Win10 and makes files readable by ZH? Right now a friend with Photoshop helped me, but I would like to have the option to convert the images by myself.

Posted by: acidbrain - Saturday, January 7, 2017 6:44:28 AM
Well looked at it in gmax/renx and the right texture shows up so i think you have a problem with the location/format of the texture, did you put it in the Art/Textures folder in the gameroot?, your new texture in the download is .png, if you also put this texture format in the game it doesnt work. [quote=Kvantovy;142576] I would like to have the option to convert the images by myself.[/quote] You can use paint.net, it is free software, you can load and save TGA and DDS files with this program, you can find it [url=http://www.getpaint.net/index.html][color=blue]Here[/color][/url].

Posted by: Kvantovy - Saturday, January 7, 2017 7:25:54 AM
Thanks for the response, paint.net looks just like the thing I was looking for. As for the model, I made a set of files and put them all in what I think is the correct directory: https://scr.hu/mmJOp1 But the tank is still pink. Can you test the files I posted in the first post on your copy of ZH? Maybe it has something to do with my Origin version of the game.

Posted by: acidbrain - Saturday, January 7, 2017 8:14:35 AM
Ok, i put it in a mod and it looks fine to me... [img=https://s29.postimg.cc/tavb3fy07/tank.png]tank[/img] I dont use origin btw, i have tfd

Posted by: klingondragon - Saturday, January 7, 2017 10:31:10 AM
I can test with origin if you want. I'll Post as soon as I've tested it. UPDATE: Using just the dds and w3d in that archive with my version of ZH: [img]http://klingondragon.dynu.com/img/cnclabs/forum/Tank.png[/img] I think I may need the other files for it to work.

Posted by: Kvantovy - Saturday, January 7, 2017 12:09:27 PM
Thanks for joining the tests klingondragon. So it would seem that the problem lies in Origin version of the game? It would be kinda sad if the models I can create were to be incompatible with current official version of the game :/ Anyways, I tried putting the files into .big file and putting the art folder inside Data/English, but neither of that helped. Interestingly, when I use only my .dds, with no new model, the original crusader appears and it actually has that new .dds displayed over it. It's like the game do not want to combine the texture (which works with the old crusader) with the model (which works, but is pink). https://scr.hu/vmVRgW [quote=klingondragon;142584] I think I may need the other files for it to work.[/quote] What other files do you require? In the first post there are also .gmax file which I used to make a .w3d and source .png texture.

Posted by: klingondragon - Saturday, January 7, 2017 12:14:25 PM
I don't have gmax. You showed a picture of your file structure which had a .tga and .png image that were not in the archive. You also listed the file avleopard_D.W3D which was not in the archive. I seriously doubt it's origin that's the problem.

Posted by: acidbrain - Saturday, January 7, 2017 12:16:59 PM
Give the new model an original name and try again...

Posted by: klingondragon - Saturday, January 7, 2017 12:19:14 PM
That requires loads more modding than should be needed. For now we should make sure it's not the art that's the problem before we mess around with ini.

Posted by: acidbrain - Saturday, January 7, 2017 12:24:18 PM
[quote=klingondragon;142598]That requires loads more modding than should be needed. For now we should make sure it's not the art that's the problem before we mess around with ini.[/quote] He has the gmax model so it would be a case of loading the model into gmax and exporting it with a new name, doesnt sound like a lot of work to me...

Posted by: klingondragon - Saturday, January 7, 2017 12:29:44 PM
But replacing all the models in the object's ini code would take some time. (for every faction) Plus, this mod should be compatible with mods which change what the tank does as this mod only changes it's model and texture.

Posted by: Kvantovy - Saturday, January 7, 2017 12:37:20 PM
@acidbrain I was thinking about adding that as a new unit, but I haven't got to that stage of modding yet :D @klingondragon Yes, sorry, I haven't mentioned that all image files were derived from the .png and the _D model is identical to the first one. Here are all of them for clarity: http://www.filedropper.com/allabramsassets

Posted by: klingondragon - Saturday, January 7, 2017 12:49:25 PM
FOUND THE PROBLEM (I think) I had a look at the files in W3DZH.big and TexturesZH.big. The files say crusader not leopard. Probably an origin thing, as the games were remade for windows 7. I'll rename the files and check if that works. Post again once I've tested.

Posted by: acidbrain - Saturday, January 7, 2017 12:53:09 PM
Here is the same tank with a new name... Btw, the muzzleflash is missing, important detail...:P [ATTACH]1988[/Attach]

Posted by: acidbrain - Saturday, January 7, 2017 12:56:48 PM
And an imprtant sidenote is to not give your model name more then 14 characters...

Posted by: klingondragon - Saturday, January 7, 2017 12:58:53 PM
Renaming didn't work. (I should have realised they had the right names as the tank was pink)

Posted by: acidbrain - Saturday, January 7, 2017 1:00:04 PM
Well it works fine in The First Decade so it's an origin problem for sure...

Posted by: klingondragon - Saturday, January 7, 2017 1:02:44 PM
Specifically the texture. Are the dimensions of the dds and tga the same as the original?

Posted by: Kvantovy - Saturday, January 7, 2017 1:02:46 PM
[quote=acidbrain;142606] Btw, the muzzleflash is missing, important detail...:P[/quote] I think Killakanz tank setup tutorial overlooked that, I was learning from it. I dont know how to add the tank as a completely new unit (where to change and add stuff in other files). I will try to add it as e.g. Battlemaster, once I find its filenames.

Posted by: klingondragon - Saturday, January 7, 2017 1:07:00 PM
NVBtMstrNG.W3D

Posted by: klingondragon - Saturday, January 7, 2017 1:14:29 PM
Since acidbrain got it to work, May I have that copy of the files to check if that works? (You may have packaged them differently and that may be the problem.

Posted by: Kvantovy - Saturday, January 7, 2017 1:24:42 PM
[quote]NVBtMstrNG.W3D[/quote] In my ChinaVehicle.ini it's without the "NG". It came out totally invisible when built oO

Posted by: klingondragon - Saturday, January 7, 2017 1:27:43 PM
I checked the file name in W3DZH.big I thought they were the same as the inis (save for the '.w3d' file extension).

Posted by: Kvantovy - Saturday, January 7, 2017 1:45:40 PM
GUYS! IT WORKS! But I'm not fully sure why :D https://scr.hu/MeXqL2 Ok, I'm not exacly sure, but thats what happened: I renamed stuff to battlemaster name klingondragon posted, and battlemaster was built looking like in vanilla ZH. I then renamed stuff to the name I posted above, and it was build completely invisible. I then renamed stuff to avleopard again, and it came out invisible for USA too. I then deleted all added files to import clear copies, and I forgot to change the names of textures to avleopard (they were called zbajerowane.png when I was modeling the tank in Blender and probably when I was testing textures in gmax too). And it works :D So, the name of the texture file is determined by what? By the name of the texture we put on the model in gmax?

Posted by: klingondragon - Saturday, January 7, 2017 1:51:45 PM
Obviously. gmax's W3D has got an entry in it which says (In human): 'Go to Art/Textures/ and find the file called 'texture name here' and apply that to this model'. (I don't use the program but how is it going to guess what texture you use, It must use the filename you provide. In the future I would suggest putting your texture in the correct directory before applying it to the model) Not related to the installation stuff, but: That block of colour (for factioncolor) is a bit unsightly. I would like it if the faction colour were less a block and more part of the design of the tank. (work it into the bodywork more). Just a suggestion for the future.

Posted by: acidbrain - Saturday, January 7, 2017 1:52:24 PM
[quote=Kvantovy;142621] So, the name of the texture file is determined by what? By the name of the texture we put on the model in gmax?[/quote] Yip, the texture you apply to the model has to be in the gameroot otherwise you get a pink panther...:P In gmax/renx you can go to Modify/Modifier List/Unwrap UVW/Edit/Pick texture(right upper corner)/Applied(radiobuttons)..There you can see what texture is applied to the selected object. You can alo check which textures are applied in File/Summary info, here you see a list with all the objects from the model and the applied textures...

Posted by: Kvantovy - Saturday, January 7, 2017 2:11:56 PM
Welp, that's another important thing to remember :D I wonder, though, why it worked anyway on acidbrain ZH. Did you reexport it from gmax? Anyway, thank you both very much, for your help! The HOUSECOLOR was added only to check if it works, I had no clue where to put it. The Tank itself (the textures) comes from strategy/simulation game Hostile Waters (2001), one of my favourite games of all time. I wanted to recreate it in ZH. In HW it appears only as an enemy vehicle (and in one mission as an ally, when that faction is helping you), but you cannot control it yourself. But now I can! Whole army of them in fact! :D

Posted by: klingondragon - Saturday, January 7, 2017 2:15:57 PM
May I suggest putting the faction colour around the rim of the turret (as a broken line (I feel a solid line wouldn't look right))

Posted by: acidbrain - Saturday, January 7, 2017 2:22:08 PM
[quote=Kvantovy;142626]Welp, that's another important thing to remember :D I wonder, though, why it worked anyway on acidbrain ZH. Did you reexport it from gmax? [/quote] At first i took your original files, i only made a tga file from your png file, later i exported it again for a new model name and that worked too.

Posted by: acidbrain - Saturday, January 7, 2017 7:21:04 PM
Hey Kvantovy, added a muzzleflash for ya... [img=https://s27.postimg.cc/hgkj6rzw3/muzzleflash_w3d.png]stuff[/img] Here are the settings for gmax/renx in case you need them... [img=https://s29.postimg.cc/v8i341non/muzzle_flash_settings.jpg]more stuff[/img] I attached a rar with the W3D model and the gmax file so you can also check out or change the settings on the model... Greetz...[sunglasses] [ATTACH]1990[/Attach]

Posted by: klingondragon - Saturday, January 7, 2017 7:47:37 PM
It did that fine for me when it was pink. It didn't need anything adding.

Posted by: acidbrain - Saturday, January 7, 2017 9:00:30 PM
[quote=klingondragon;142638]It did that fine for me when it was pink. It didn't need anything adding.[/quote] This is the tank that was uploaded, no muzzleflash as you can see, so tell me how can this model ever show a muzzleflash in game? [img=https://s24.postimg.cc/flwp99sdx/original_w3d.png]original tank[/img] Here is the model i renamed with added muzzleflash... [img=https://s24.postimg.cc/ojy3iqudx/muzzleflash_2_w3d.png]modded tank with muzzleflash[/img] Check out the upper model, there is a helper called [color=red]TurretMS[/color] at the end of the barrel, now look at the code->WeaponFireFXBone = PRIMARY [color=red]TurretMS[/color] Now look at the bottom model, that muzzleflash is called [color=red]TurretFX[/color], now look at the code-> WeaponMuzzleFlash = PRIMARY [color=red]TurretFX[/color]... See it now, two seperate things create the flash, an additive texture and FX which contains several particle systems... Now take a look at the weapon from the crusader tank->Weapon = PRIMARY [color=red]CrusaderTankGun[/color]. Now take a look at the [color=red]CrusaderTankGun[/color] in Weapon.ini->FireFX = [color=red]WeaponFX_GenericTankGunNoTracer[/color]. Now take a look at the WeaponFX in FXList.ini: [code=plain] FXList WeaponFX_GenericTankGunNoTracer ViewShake Type = NORMAL End LightPulse Color = R:255 G:255 B:128 Radius = 15 IncreaseTime = 0 DecreaseTime = 500 End ParticleSystem Name = TankMuzzleFlashSmoke OrientToObject = Yes End ParticleSystem Name = TankMuzzleFlashFlame OrientToObject = Yes End ParticleSystem Name = TankMuzzleFlare OrientToObject = Yes End ParticleSystem Name = TankMuzzleWave OrientToObject = Yes CreateAtGroundHeight = Yes End End [/code] You only saw the WeaponFX klingon, not the muzzleflash... Maybe im wrong, install gmax/renx and check it out yourself...[sunglasses] [quote=some dude] It's quite hard to ride a bike when you have only seen it happen and didnt ride it yourself, you can talk about it but the experience just isnt there and the best teacher in life is experience...[wink][/quote] Greetz

Posted by: klingondragon - Saturday, January 7, 2017 11:42:13 PM
Just look at the screenshot. There was a flash when it fired.

Posted by: acidbrain - Sunday, January 8, 2017 3:50:17 AM
[quote=klingondragon;142645]Just look at the screenshot. There was a flash when it fired.[/quote] I explained it to you in detail klingon, there was a flash but not the flash that was supposed to be there, just look at your screenshot and then at mine... The model had no muzzleflash so it is just impossible to have a muzzleflash in game, your model had weaponfx but no muzzleflash... Just look at the code: WeaponFireFXBone = PRIMARY [color=red]TurretMS[/color] WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY [color=red]TurretFX[/color] WeaponLaunchBone = PRIMARY TurretMS [quote=klingondragon;142595]I don't have gmax.[/quote] So basicly you are trying to say that you are right while you dont have the tools to check it out yourself, you are speaking to a experienced modeler here while you never made a model in your life yourself klingon, im really not in the mood to spend more time on this since it is very very hard to try to teach you something, you know it all... Here are some detailed screenshots from gmax/renx [b]TURRETMS for FX and weaponlaunch[/b] [img=https://s24.postimg.cc/ebs1f16f9/TURRETMS01.png]TURRETMS01[/img] [b]TURRETFX for the muzzleflash[/b] [img=https://s30.postimg.cc/i3q5uuatt/TURRETFX01.png]TURRETFX01[/img] When you place a crusader tank and the new tank in worldbuilder you see this: [img=https://s24.postimg.cc/yr0loj73p/crusaders.png]Stuff[/img] When i place a crusader tank and the new tank in worldbuilder i see this: [img=https://s29.postimg.cc/8hawafxyv/crusaders2.png]Stuff[/img] End of discussion... [quote=The Dictionary] [size=7]stubborn[/size] [stuhb-ern] adjective 1. unreasonably obstinate; obstinately unmoving: a stubborn child. 2. fixed or set in purpose or opinion; resolute: a stubborn opponent of foreign aid. 3. obstinately maintained, as a course of action: a stubborn resistance. 4. difficult to manage or suppress: a stubborn horse; a stubborn pain. 5. hard, tough, or stiff, as stone or wood; difficult to shape or work. [/quote] Im trying klingon, omg im trying but you are making it so hard, so hard... Greetz

Posted by: Kvantovy - Sunday, January 8, 2017 9:05:09 AM
Ok, thx for the additional information. I replicated the effect, though at first I had problems with black background appearing in game. [img=http://i.imgur.com/8KVWPKR.png]Tank with muzzleflash[/img]

Posted by: acidbrain - Sunday, January 8, 2017 9:19:58 AM
It is important that you export the helpers and muzzleflash with the right settings, you individualy set the settings and at the end you select all the objects and export. [b]Helpers[/b] [img=https://s24.postimg.cc/cnzvkc8lx/helpers.png]helpers[/img] [b]MuzzleFlash[/b] [img=https://s30.postimg.cc/inj9jzk9d/turretfx.png]turretfx[/img]

Posted by: acidbrain - Sunday, January 8, 2017 10:23:13 AM
Checked out your tank a bit more and found something that can be done better, the SMOKE01 helper is linked to the chassis, it should be linked to the turret. I also added 2 threadfx helpers and put the threadfx helpers at the right place, added an extra SMOKE helper so you can use some extra particlesystems and such. Added a FIREPOINT helper on the turret so you can attach a gattlingcannon to the turret, just for fun... Played around with the model a bit and give it an OverlordTankDraw module... [img=https://s24.postimg.cc/6lk5xfyid/tankstuff.png]stuff[/img] I attached a gattling, you can attach anything you want... I attached the W3D and the gmax files so you can check them out... [ATTACH]1991[/Attach]