Author Topic: Meddling with meshes  (Read 6099 times)

0 Members and 1 Guest are viewing this topic.

Offline Littlemog

  • Pooper Scooper
  • *
  • Posts: 62
    • http://
Meddling with meshes
« on: August 02, 2006, 03:58:48 PM »
This may be a little ambitious, since I haven't even made a normal recoloured animal yet, but hey I can try :laughing:

I know the Kudu has a new (well, combined) mesh, so I started looking into the modelling aspect myself. Something simple, since I'm sure editing the rigging would be too ambitious (or impossible) so just adding a horn to the zebra to make it a unicorn. (only 4 extra polys, and immobile)

I've got access to 3ds Max, and managed to find an .nif importer for the thing. I've got the model in Max and added the horn. But this is where I'm stuck. I try to export the model as a .nif and get an error.

I understand this is a ZT2 forum, not an nif/3d modelling forum, but if anyone can help or give an alternative method then that would be really helpful.

(I've also made the critter so far using APE 2 with ES files (which is working when testing in game), but not the texturing yet. I imagine the texturing on the horn may be quite messy if it IS possible, since the existing .dds files for the zebra aren't made for a large protrusion from the forehead :blink: but it shouldn't be a HUGE deal if no-one minds a rather plain looking horn (as opposed to spiralled)

Edit: Bah, I don't know if this should be here or in the subforum... sorry guys if it's the wrong one!

That's fine. I moved it to Editing.
« Last Edit: August 02, 2006, 04:31:19 PM by csleesburg »

Offline Gibbon-Fanatic

  • ZA Designer
  • Marine Biologist
  • *
  • Posts: 1661
    • http://s12.invisionfree.com/zootoria/index.php?act=idx
Meddling with meshes
« Reply #1 on: August 03, 2006, 01:14:38 AM »
Could you please post some pics of the 'Mesh'

Offline Littlemog

  • Pooper Scooper
  • *
  • Posts: 62
    • http://
Meddling with meshes
« Reply #2 on: August 03, 2006, 03:42:32 AM »
Aha! Some progress. I've managed to export the file as a .nif.



Problem is it's not showing up in game. It's just the regular old zebra mesh, instead of this new mesh. (I realise the horn's a bit wonky, but I want to know it works before I start tweaking everything) It's also 8 extra polys, not 4.

There's 3 .nif's for the zebra aren't there? adult_F.nif, and young_F.nif, right? I've only done the adult nif so far (and renamed it, to unicorneuropean_adult_F.nif, unicorneuropean being its 'codename')

edit: Hold up, I'm editing the bfm files now, to see if they'll work!

edit2: From zebra model to... no model. Either it didn't like the size change in the file, or I've got a filename wrong somewhere. I've heard there's been similar problems with the Kudu young before they were fixed or something?

edit 3: gone through everything and renamed as seemed appropriate, but still nothing... the new nif size is smaller than the old one so I must be missing something... does anyone know about "vertex weights" at all? I'm searching on google and such at the moment.
« Last Edit: August 03, 2006, 04:28:33 AM by Littlemog »

Offline penguinman

  • Ridge on the Barrel of a Capstan
  • Gl?bal Moderator
  • Game Warden
  • *
  • Posts: 4622
  • Artifex!
    • Zoo Tycoon 2 Designing Centre
Meddling with meshes
« Reply #3 on: August 03, 2006, 07:20:51 AM »
Oh my!! That's pretty amazing... If you want, I can take a look at the coding and the bfm and such and see if there is a problem there. Having no model show up is acually a VERY common problem for people when coding so prehaps it is not related to the model change.

If this works, you could do some basic model changes for animals, like doing a bacterian out of the dromedary. I'll PM you my email if you like :)

Offline csleesburg

  • An Oldie But Goodie
  • Game Warden
  • *
  • Posts: 5422
Meddling with meshes
« Reply #4 on: August 03, 2006, 08:44:26 AM »
Now I realize this is a stupid question, but don't you have to keep the same number of letters as zebra in the .nif? Doesn't making the name longer make the .nif not work?

Offline Bonasus

  • Pooper Scooper
  • *
  • Posts: 45
Meddling with meshes
« Reply #5 on: August 03, 2006, 09:48:45 PM »
Asweme!:woot: please dont give up hope! think of all we could make with this!: : :) :

Offline Panda King

  • Marine Biologist
  • *
  • Posts: 1553
  • One flaming hot panda!
    • Panda-monium!
Meddling with meshes
« Reply #6 on: August 03, 2006, 09:53:54 PM »
SWEET! This is beyond awesome! Keep trying!

Offline Rosinas Cat

  • Feline Friend
  • Global Moderator
  • Game Warden
  • *
  • Posts: 3047
  • Cool Cat
Meddling with meshes
« Reply #7 on: August 03, 2006, 09:54:27 PM »
Quote from: penguinman

If this works, you could do some basic model changes for animals, like doing a bacterian out of the dromedary. I'll PM you my email if you like :)


Oh wow, I would love to see a bactrian camel! Not that I understand anything about editing etc. But good luck with it! : :) :

Offline Simba

  • Zookeeper
  • *
  • Posts: 409
Meddling with meshes
« Reply #8 on: August 04, 2006, 03:41:40 AM »
Hey even I have 3ds max and the nif importer,exporter thing.I opened the E.wolf nif file to make it a better Andrewsarchus because the normal E.wolf doesnt look good! I finished it completely then I exported it, put it in the game and tried it, it doesnt work!
Then I opened 3ds max again and imported it there was no model??!!? STRANGE!!!And what version of 3dsmax are you using and where did you download the nif plugin???????
« Last Edit: August 05, 2006, 04:36:08 AM by Simba »

Offline Littlemog

  • Pooper Scooper
  • *
  • Posts: 62
    • http://
Meddling with meshes
« Reply #9 on: August 07, 2006, 03:13:34 AM »
Sorry for the delay guys!

I'll try sending the file to you, penguinman (I'm using hotmail and it's over 1MB but hopefully it'll work)

I've had a go at renaming them to smaller things (the same letters as "zebracommon" and "zebra" for the files that need it, so unicorneuro and unico) and going into the coding to rename references to those files, though I may have missed a few and that would cause an error.

For the nif importer and max, you need to select the entire thing and "save selected" but it often turns out an "unknown error" message when you extract it (possibly because the nif contains other info as well as the model, like the rigging) Instead I've used a third program to extract the part of the .nif that is the model (high detail only so far though, so once it is in game it might only work with certain detail levels), opening that part in 3ds max, editing it, and importing it again.

But after importing the new model, the size of the .nif is smaller (from 160 to 148, despite having slightly more polygons), so I have a worry that on export/import something is being lost. The program comes up with a message about vertex weights data, which is beyond my understanding I'm afraid, though it's likely to do with the skinning somehow?

Offline wasabipeas

  • Zookeeper
  • *
  • Posts: 221
    • http://wasabipeas.deviantart.com/
Meddling with meshes
« Reply #10 on: August 07, 2006, 04:34:08 AM »
this sooooo awesome this could change your way making animals!!!!FOR ME TO Download

Offline Littlemog

  • Pooper Scooper
  • *
  • Posts: 62
    • http://
Meddling with meshes
« Reply #11 on: August 08, 2006, 01:49:26 AM »
There may be some problems on the unicorn front.

I mean, there are problems already, but something as 'extreme' (I'll explain in a minute) as a unicorn might be impossible.

After some research it seems the number of vertices (corners) an animal model has may have to remain the same. Which means - thinner/fatter animals, lumpy or smooth, but adding things (like a horn) may be impossible. Apparently the vertices are linked to the rigging/bones and so changing them causes problems. That also means that extreme movement of these vertices will go haywire and possibly crash if the game attempts to deform them by movement or growth (And as cool as it'd be, no-one wants a crashy critter)

The zebra's forehead does come to a central point - but between the eyes and that point there's no split, which would make its entire forehead a horn, rather than just part of it, if I can't split these faces to make a forehead/horn break.

There's also a case of mysterious lost data when exporting the meshes. Even if I export the mesh, then import it without changing, there's 12kb reduction of the .nif filesize. So something's going missing, but I don't know what.

Offline Budgielover101

  • Gl?bal Moderator
  • Marine Biologist
  • *
  • Posts: 2011
Meddling with meshes
« Reply #12 on: August 08, 2006, 01:53:48 AM »
oh thats too bad : :( : if only it would work. but good try!  It was a great idea! :woot: :original:

Offline Littlemog

  • Pooper Scooper
  • *
  • Posts: 62
    • http://
Meddling with meshes
« Reply #13 on: August 09, 2006, 01:22:33 AM »
I don't think it's impossible (editing at all, not the unicorn idea), just... a lot more difficult :laughing: This thing's brought out my stubborn streak and I refuse to be defeated, even if it means making some compromises.

Unless it does turn out to be completely impossible. Then more the fool I am for spending the time on it, but y'know =P

If it's a case where the number of vertices has to be the same then it might be a case of a unicorn with a very mobile and flat forehead if the zebra's brows move at all, because they could be tweaked around a bit.

I just need to find the vertex weight data (as I suspect that's being lost) and somehow preserve it while changing the mesh, ie copying the mesh data into the nif by notepad or something.

Offline Budgielover101

  • Gl?bal Moderator
  • Marine Biologist
  • *
  • Posts: 2011
Meddling with meshes
« Reply #14 on: August 09, 2006, 01:29:43 AM »
Well hopefully it won't be completley impossible, think of the possibilities if it isn't! :original: if someone gets it to work well and gets good at it, we will have a lot more how we say - interesting animals! :laughing:
Good luck with it!

Offline Littlemog

  • Pooper Scooper
  • *
  • Posts: 62
    • http://
Meddling with meshes
« Reply #15 on: August 11, 2006, 06:41:12 AM »
HOHMYGODITWORKED!

IT WORKS! AH! AH! AAAAAAAH!

http://img75.imageshack.us/img75/6703/aaaaaahunicornwq9.jpg

:woot:

Now as you've probably noticed there's a gap around the horn - this is because instead of importing a model straight from Blender or 3DSMax, I've had to put them side by side and copy the location of the verices (In XYZ space). The model I made in blender lost a few vertices when exporting, so some of it was guesswork... including that. As far as I can tell it's only 2 points that are misplaced - causing the lovely seethrough holes in the unicorns' heads =P

This, I will fix. The program I'm using to edit the numbers (rather than a drag-the-point-where-I-want-it interface) doesn't highlight selected vertices - hence it's all guesswork, and very time consuming @_@ (I also need to texture the things, and make the young models, then test to make sure it's not crashing things in general and the ear rig doesn't distort the horn, as well as get the rest of the coding (eg zoopedia) finished up)

The .nif is exactly the same size it started off as (as I suspected when you have to limit your .dds codenames) and everything except the model is the same. The number of vertices (corners) that an animal has must remain the same.

There may well be a shorter way around it, but I haven't figured it out yet =P I know there must be an easier method, and darnit I WILL find it!

But before that I must eat, as I have been working on this evil model since morning and it's now past lunch.

NEEDFOODNOW! *zoom*

Edit: This is the hi-res model only. The game has about 3 meshes for different display levels and the highest one has the most polygons and is therefore much more flexible to edit (the distortion of the head on the lower models would be insane. I tried it. The ears detach. And can't be moved or they'll distort rediculously when the game tries to have the unicorn flick its ears.)

So I'm afraid once this does become a download, it'll be for people who's comps can manage high detail - sorry.

[modnotice=penguinman]Please post links to such large images :)[/modnotice]
« Last Edit: August 12, 2006, 08:42:04 AM by penguinman »

Offline penguinman

  • Ridge on the Barrel of a Capstan
  • Gl?bal Moderator
  • Game Warden
  • *
  • Posts: 4622
  • Artifex!
    • Zoo Tycoon 2 Designing Centre
Meddling with meshes
« Reply #16 on: August 11, 2006, 07:20:13 AM »
Wow that's amazing... This opens up many new possibilities!!! Congrats!

Offline bcln

  • Pooper Scooper
  • *
  • Posts: 16
Meddling with meshes
« Reply #17 on: August 11, 2006, 07:38:46 AM »
some one should make a wooly mammoth

[modnotice=penguinman]Please do not post requests here, they belong in wishlist and we don't want to barrage Littlemog with requests.[/modnotice]
« Last Edit: August 11, 2006, 07:51:39 AM by penguinman »

Offline Budgielover101

  • Gl?bal Moderator
  • Marine Biologist
  • *
  • Posts: 2011
Meddling with meshes
« Reply #18 on: August 11, 2006, 03:41:12 PM »
That is so awesome! well done!!! :hifive:
Good luck with getting the hole fixed XD

Offline Bonasus

  • Pooper Scooper
  • *
  • Posts: 45
Meddling with meshes
« Reply #19 on: August 11, 2006, 05:48:41 PM »
wahoo! awseme:woot:  i ant beleive my eyes:surprise: ! this is so cool keep up the good work and i hope you get the hole thingy fixed!: :) :

Offline Panda King

  • Marine Biologist
  • *
  • Posts: 1553
  • One flaming hot panda!
    • Panda-monium!
Meddling with meshes
« Reply #20 on: August 11, 2006, 05:55:55 PM »
SO... Coool! NEAT! I really hope this works!

Offline TurtleStork

  • Zookeeper
  • *
  • Posts: 328
Meddling with meshes
« Reply #21 on: August 11, 2006, 06:10:18 PM »
But, can i say, please don't leave like xtrat did after she made the ambient frog into an animal.

Offline GoneWild

  • Senior Zookeeper
  • *
  • Posts: 572
Meddling with meshes
« Reply #22 on: August 11, 2006, 07:29:13 PM »
OMG this is amazing! So you can fix the gap in the face and make it a working model?  Awesome.

Offline germanwolf

  • Gl?bal Moderator
  • Marine Biologist
  • *
  • Posts: 1611
  • Captian Jack is back
Meddling with meshes
« Reply #23 on: August 11, 2006, 07:35:31 PM »
I must say, it looks splendid. Off of this model, we can make many other ones!:bounce:  I hope you can fix the gap in the head.

Offline Koala Komander

  • ZA Designer
  • Scientist
  • *
  • Posts: 1035
    • Zoomania
Meddling with meshes
« Reply #24 on: August 11, 2006, 07:36:22 PM »
it looks amazing! *HUGS!* best thing ever. (8sings unicorn song*)