Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds

Members Online

»
0 Active | 53 Guests
Online:

LATEST FORUM THREADS

»
CoD: Battle Royale
CoD+UO Map + Mod Releases
Damaged .pk3's
CoD Mapping
heli to attack ai
CoD4 SP Mapping

Forums

»

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Call of Duty 2
Category: CoD2 MP Mapping
CoD 2 mapping and level design.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword, playername
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked
Page
Next Page
subscribe
Author Topic: Vertex number out of sync - ERROR
serthy
General Member
Since: Sep 8, 2010
Posts: 482
Last: Jun 28, 2013
[view latest posts]
Level 5
Im a fan of MODSonair
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 10:08 am
Hey
i tried to compile a model in the assetmanager, and i got this Error:
Quote:
.XMODEL_EXPORT(954):Vertex number out of sync


i reduced the vertexes from over 16.000 to 4.000, 2.000 and now 954 but still the same error
what did i do wrong? it was a simple castle-tower btw..
Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 11:46 am
this error occurs if vert numbers are skipped or doubled in the vertex segment of an xmodel_export file, e.g.:

Code:
VERT 6
OFFSET -1.000000, -1.000000, 1.000000
BONES 1
BONE 0 1.000000

VERT 8
OFFSET -1.000000, 1.000000, 1.000000
BONES 1
BONE 0 1.000000


VERT 7 is missing, perhaps happened 'cause you deleted a vertex in Blender/Maya and it did not update the subsequent indices.

As for Blender, i'll change my BlenderCoD code to not use the given indices but count myself:

file.write("VERT %i\n" % (v.index+v_count))

Will post a hotfix in an hour
Share |
serthy
General Member
Since: Sep 8, 2010
Posts: 482
Last: Jun 28, 2013
[view latest posts]
Level 5
Im a fan of MODSonair
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 12:33 pm
cool thanks again [thumbs_up]
Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 02:23 pm
http://code.google.com/p/blender-cod/issues/detail?id=4

Well, i can fix your error easily, but there's another problem with the enumeration. Vertices, which aren't used by a face aren't taken into account when total number of verts is calculated. Need to find a way to get around this...
Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 04:29 pm
Update:
Dowload Blender-CoD Addon v0.3.2 (alpha 3)

- Issue #4 fixed - Vertex number out of sync error / Vert enumeration.
If there are vertices in a mesh, which aren't used by any face, they won't be written to the output file. Now taken into account for vertex count. Enumeration of vertices now done via script and not taken from Blender data, as gaps / duplicates in indices occured.

- Issue #2 fixed - Error on export if using "Pose animation".
The pose to model sequence feature now disables Armature export to prevent this error. Fixed, unless anyone needs Pose animation with Armature.

Should handle problematic meshes properly now.
Share |
serthy
General Member
Since: Sep 8, 2010
Posts: 482
Last: Jun 28, 2013
[view latest posts]
Level 5
Im a fan of MODSonair
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 06:27 pm
Okay, this works now [cool]

but it gives me this error instead:
Quote:
.XMODEL_EXPORT(6097):Vertex index out of range
i reduced my model to around 250 vertexes, can you tell me what is the issue? [confused]
Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 08:36 pm
hm interesting...

looks like bad verts cause more than out of sync error. this is probably in the faces section, not vertices

can you post line 6097 and some sorrounding lines so i can see whats going on?
And please post the NUMVERTS count too! (or just send me the entire file)
Share |
serthy
General Member
Since: Sep 8, 2010
Posts: 482
Last: Jun 28, 2013
[view latest posts]
Level 5
Im a fan of MODSonair
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 08:45 pm
this one has ~700 verts but its the same model

edited on Jan. 25, 2012 03:32 pm by serthy
Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 09:01 pm
i think i know why... faces are made up of 3 vertices each, a face references 3 vertices by their index numbers. As the script drops invalid verts and calculates its own indices, the faces link to the wrong verts, and in some cases to not even existing verts. Thats causing the error.

Well, i'm not sure yet how to solve this. I'll see if a remapping would work...

In the meanwhile you should check your model for bad vertices (not linked to a face), or edges (two connected verts, but not parts of a face). There has to be a reason why my script considers some verts as invalid.
Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 MP Mapping
Posted: Wednesday, Jan. 25, 2012 10:04 pm
ok, tested your blender file and got the same error.
NUMVERTS is 1055 and there's a reference to VERT 1055 (which doesn't exist, 1055 verts = VERT 0 to 1054)

But i was able to solve it: Went to Edit-mode, selected everything, Mesh > Vertices > Remove doubles

It removed 4 verts and error vanished.
_____________________________________

Converting 1 assets, reason: 'asset out of date'
Converting 'test_tower' (xmodel 1 of 1)...
Converting xmodel 'C:\Program Files (x86)\Activision\Call of Duty 4 - Modern Warfare\model_export/test_tower.XMODEL_EXPORT'...
*** 10 degenerate tris discarded ***

Surface summary:
mtl_books (8 tris, 16 verts, 16 unique verts)
mtl_books (844 tris, 1425 verts, 759 unique verts)
mtl_books (5 tris, 9 verts, 9 unique verts)
mtl_books (1006 tris, 1622 verts, 809 unique verts)

Conversion done. Hit key to continue.
_____________________________________

10 degenerated triangles were removed, dunno what's up with them but at least it converts and i hope there aren't any holes in model somewhere.



Looks quite good, i just replaced your materials with a random one.
Share |
Restricted Access Topic is Locked
Page
Next Page
subscribe
MODSonline.com Forums : Call of Duty 2 : CoD2 MP Mapping

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»