XeNTaX Forum Index
Forum MultiEx Commander Tools Tools Home
It is currently Wed Dec 13, 2017 11:53 am

All times are UTC + 1 hour


Forum rules


Please click here to view the forum rules



Post new topic Reply to topic  [ 43 posts ]  Go to page Previous  1, 2, 3  Next
Author Message
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Wed Aug 30, 2017 9:54 am 
Offline
mega-veteran
mega-veteran

Joined: Sat Sep 24, 2011 7:06 pm
Posts: 177
Has thanked: 40 times
Have thanks: 18 times

I may have figured the vertex count but how they work this for both meshes is what's confusing me. 0x13A = 37,040. 37,040/16=2,315. That's the vertex count for the 2nd submesh, maybe they use this value for both meshes somehow. This seems to work with the other files provided too - the value after "VERTEX_ATTRIB_BLEND_INDEX".

You can make the ads go away by registering



Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Wed Aug 30, 2017 2:55 pm 
Offline
mega-veteran
mega-veteran

Joined: Sat Sep 24, 2011 7:06 pm
Posts: 177
Has thanked: 40 times
Have thanks: 18 times
Sorry for the double post (and for the red/orange background on the screenshots, that's how I like my Noesis layout lol) but:

Image
Image

The script works on every sample given but c_Daredevil_L1_skin_v2. It definitely needs tidying and refining, this was made just against testing one file, but it works with multiple instead. I'll look into making it work with others, and maybe look into bones/weights.

Edit - Reason why Daredevil's L1 skin doesn't work is because it has 3 meshes, I did manually checking with the first revision of the script so the script has been updated to fix that problem. I will get more/the rest of the models if I can and check to see if anything isn't working.

Code:
#sample class
from inc_noesis import *

def registerNoesisTypes():
   handle = noesis.register("Marvel's Avengers Academy", ".c3b")
   noesis.setHandlerTypeCheck(handle, c3bCheckType)
   noesis.setHandlerLoadModel(handle, c3bLoadModel)
   noesis.logPopup()
   return 1

def c3bCheckType(data):
   td = NoeBitStream(data)
   return 1

class c3bFile:
         
   def __init__(self, bs):
      self.texList   = []
      self.vtxList   = []
      self.matList   = []
      self.boneList  = []
      self.loadAll(bs)
      
   def loadAll(self, bs):
      self.readC3B(bs)
      
   def readC3B(self, bs):
      bs.seek(0xA, NOESEEK_ABS)
      namesizeA = bs.readUInt()
      matnameA = bs.readBytes(namesizeA).decode("ASCII")
      skip = bs.readBytes(8)
      namesizeB = bs.readUInt()
      matnameB = bs.readBytes(namesizeB).decode("ASCII")
      skip = bs.readBytes(248)
      vertex_count = bs.readUInt()
      vertBuff = bs.readBytes (vertex_count * 4)
      numSubmesh = bs.readUInt()
      for i in range(numSubmesh):
         namesizeC = bs.readUInt()
         meshname = bs.readBytes(namesizeC).decode("ASCII")
         face_count = bs.readUInt()
         faceBuff = bs.readBytes (face_count * 2)
         skip = bs.readBytes(24)
         vertex_stride = 64
         rapi.rpgBindPositionBufferOfs(vertBuff, noesis.RPGEODATA_FLOAT, 64, 0)
         rapi.rpgBindNormalBufferOfs(vertBuff, noesis.RPGEODATA_FLOAT, 64, 12)
         rapi.rpgBindUV1BufferOfs(vertBuff, noesis.RPGEODATA_FLOAT, 64, 24)
         rapi.rpgCommitTriangles(faceBuff, noesis.RPGEODATA_USHORT, face_count, noesis.RPGEO_TRIANGLE, 1)
         
   def loadMeshNames(self, bs):
      pass
      
def c3bLoadModel(data, mdlList):
   ctx = rapi.rpgCreateContext()
   c3b = c3bFile(NoeBitStream(data))
   try:
      mdl = rapi.rpgConstructModel()
   except:
      mdl = NoeModel()
   mdl.setModelMaterials(NoeModelMaterials(c3b.texList, c3b.matList))
   mdlList.append(mdl); mdl.setBones(c3b.boneList)   
   return 1


Last edited by TRDaz on Wed Aug 30, 2017 10:36 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Wed Aug 30, 2017 4:40 pm 
Offline
veteran

Joined: Tue Jan 26, 2016 2:26 pm
Posts: 115
Has thanked: 5 times
Have thanks: 6 times
Thanks a lot! I will test the script as soon as i will get access to my laptop.
Now i need to know how to download all game assets (if this a possible of course)
P.S Script for anims would be also good,i know what reverse anims it' hard,but it's only one thing what are left.


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Wed Aug 30, 2017 4:44 pm 
Offline
mega-veteran
mega-veteran

Joined: Sat Sep 24, 2011 7:06 pm
Posts: 177
Has thanked: 40 times
Have thanks: 18 times
Animations is definitely something I can't/won't do. I can possibly get bones and weights but animations are something I've never looked into.


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Thu Aug 31, 2017 6:10 am 
Offline
veteran

Joined: Tue Jan 26, 2016 2:26 pm
Posts: 115
Has thanked: 5 times
Have thanks: 6 times
Ok,and big thanks for the script
If any anyone can take a look here are animations in c3b format
https://www.sendspace.com/file/p2fgfe
Also,i'm wondering if this method can be used to get all assets from the game,without playing it.
viewtopic.php?f=29&t=16055


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Thu Aug 31, 2017 10:08 pm 
Offline
M-M-M-Monster veteran
M-M-M-Monster veteran
User avatar

Joined: Fri Apr 20, 2012 9:24 am
Posts: 2156
Location: Nexus, searching for Jim Kirk
Has thanked: 428 times
Have thanks: 1101 times
Rutabaga wrote:
,i know what reverse anims it' hard,but it's only one thing what are left.
no, it's not. You'll need the skeleton first before dealing with animations, without it doesn't make any sense for me.

Dealing with the skeleton of c_FoggyNelson_L1_skin_v1.c3b is just a waste of time&life, again. :cry:

There's 24 head bone names and 30+59 body bone names, where the latter contains head bone names, too, weird.
(The two body bones blocks share some names, too, so not to get nuts I restarted with the bone index 0.
It's not 113 bones because of these doubles.)
Head
0 "jt_head_bind" -1
1 "jt_l_brow_in_bind" 0
2 "jt_r_brow_in_bind" 0
3 "jt_l_brow_mid_bind" 0
4 "jt_l_brow_out_bind" 0
5 "jt_l_cheek_bind" 0
6 "jt_nose_bind" 0
7 "jt_nostrils_bind" 0
8 "jt_l_lip_bind" 0
9 "jt_lowerlip_bind" 0
10 "jt_jaw_bind" 0
11 "jt_upperlip_bind" 0
12 "jt_neck_bind" 0
13 "jt_chest_bind" 0
14 "jt_l_upperlid_bind" 0
15 "jt_l_lowerlid_bind" 0
16 "jt_r_brow_mid_bind" 0
17 "jt_r_brow_out_bind" 0
18 "jt_r_cheek_bind" 0
19 "jt_r_lip_bind" 0
20 "jt_r_upperlid_bind" 0
21 "jt_r_lowerlid_bind" 0
22 "jt_l_eye_bind" 0
23 "jt_r_eye_bind" 0

body, part1
0 *jt_chest_attach_bind* -1
1 *jt_midspine_bind* 0
2 *jt_hips_bind* 0
3 *jt_l_thumb_base_bind* 0
4 *jt_l_wrist_bind* 0
5 *jt_l_forearm_bind* 0
6 *jt_l_index_base_bind* 0
7 *jt_l_index_mid_bind* 0
8 *jt_l_middle_base_bind* 0
9 *jt_l_middle_mid_bind* 0
10 *jt_l_toes_bind* 0
11 *jt_l_ankle_bind* 0
12 *jt_l_knee_bind* 0

13 *jt_l_clavicle_bind* 0
14 *jt_l_upperarm_bind* 0
15 *jt_neck_temp_bind* 0
16 *jt_l_thigh_bind* 0
17 *jt_r_thigh_bind* 0
18 *jt_r_thumb_base_bind* 0
19 *jt_r_wrist_bind* 0
20 *jt_r_forearm_bind* 0
21 *jt_r_index_base_bind* 0
22 *jt_r_index_mid_bind* 0
23 *jt_r_middle_base_bind* 0
24 *jt_r_middle_mid_bind* 0
25 *jt_r_toes_bind* 0
26 *jt_r_ankle_bind* 0
27 *jt_r_knee_bind* 0

28 *jt_r_clavicle_bind* 0
29 *jt_r_upperarm_bind* 0

body, part2
partially added parent IDs manually
0 "jt_all_head_bind" -1
1 "jt_chest_bind" 0
2 "jt_neck_bind" 1
3 "jt_head_bind" 2
4 "jt_l_eye_bind" 1
5 "jt_l_upperlid_bind" 0
6 "jt_l_lowerlid_bind" 0
7 "jt_l_brow_in_bind" 0
8 "jt_l_brow_mid_bind" 0
9 "jt_l_brow_out_bind" 0
10 "jt_l_cheek_bind" 0
11 "jt_l_lip_bind" 0
12 "jt_upperlip_bind" 0
13 "jt_lowerlip_bind" 0
14 "jt_jaw_bind" 0
15 "jt_nostrils_bind" 0
16 "jt_nose_bind" 0
17 "jt_r_eye_bind" 0
18 "jt_r_upperlid_bind" 0
19 "jt_r_lowerlid_bind" 0
20 "jt_r_brow_in_bind" 0
21 "jt_r_brow_mid_bind" 0
22 "jt_r_brow_out_bind" 0
23 "jt_r_cheek_bind" 0
24 "jt_r_lip_bind" 0
25 "jt_all_bind" 0
26 "jt_hips_bind" 25
27 "jt_midspine_bind" 26
28 "jt_chest_attach_bind" 1
29 "jt_neck_temp_bind" 2
30 "jt_head_temp_bind" 3
31 "jt_l_clavicle_bind" 0
32 "jt_l_upperarm_bind" 31
33 "jt_l_forearm_bind" 32
34 "jt_l_wrist_bind" 33
35 "jt_l_thumb_base_bind" 34
36 "jt_l_index_base_bind" 34
37 "jt_l_index_mid_bind" 36
38 "jt_l_middle_base_bind" 34
39 "jt_l_middle_mid_bind" 38
40 "jt_r_clavicle_bind" 0
41 "jt_r_upperarm_bind" 40
42 "jt_r_forearm_bind" 41
43 "jt_r_wrist_bind" 42
44 "jt_r_thumb_base_bind" 43
45 "jt_r_index_base_bind" 43
46 "jt_r_index_mid_bind" 45
47 "jt_r_middle_base_bind" 43
48 "jt_r_middle_mid_bind" 47
49 "jt_l_thigh_bind" 26
50 "jt_l_knee_bind" 49
51 "jt_l_ankle_bind" 50
52 "jt_l_toes_bind" 51
53 "jt_r_thigh_bind" 26
54 "jt_r_knee_bind" 53
55 "jt_r_ankle_bind" 54
56 "jt_r_toes_bind" 55
57 "jt_shadow_bind" 0
58 "jt_prop_bind" 0

_________________
"you can't always get things served on a silver tray"
extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
Make_H2O-ForzaHor3-jm9.zip

"We are Microsoft. You will be assimilated. Resistance is Futile."


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Fri Sep 01, 2017 4:53 am 
Offline
veteran

Joined: Tue Jan 26, 2016 2:26 pm
Posts: 115
Has thanked: 5 times
Have thanks: 6 times
shakotay2 wrote:
You'll need the skeleton first before dealing with animations, without it doesn't make any sense for me.

Dealing with the skeleton of c_FoggyNelson_L1_skin_v1.c3b is just a waste of time&life, again. :cry:

Excuse me,because i didn't checked the script and i didn't know if script has bones support.


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Sat Sep 16, 2017 11:14 pm 
Offline
beginner

Joined: Mon Jul 23, 2012 2:02 am
Posts: 32
Has thanked: 1 time
Have thanks: 2 times
Hey TRDaz, you are awesome! <insert thumbs up here>

Note I've been using the basic set. Any standard models load as do any lodes. The only one that crashed for me thus far is Falcon and Weeny Cap. I'll update with more if you wish as I explore the event specific ones.


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Mon Sep 18, 2017 5:55 am 
Offline
veteran

Joined: Tue Jan 26, 2016 2:26 pm
Posts: 115
Has thanked: 5 times
Have thanks: 6 times
I agree with Alice,it's awesome to finally have script to extract models from this game.
Now bones are left :) i hope daz will add bones support soonly


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Mon Sep 18, 2017 5:15 pm 
Offline
mega-veteran
mega-veteran

Joined: Sat Sep 24, 2011 7:06 pm
Posts: 177
Has thanked: 40 times
Have thanks: 18 times
Would be nice to know which ones don't work and if you could, send them to me so I can check them (I have Falcon, I saw he doesn't work too, need to try and find a fix). Rutabaga sent me a couple from the Inhumans event and I saw that Lockjaw doesn't work with the current version of the script.

I'm still trying with the bones, have never really worked with them in scripts before so it's a little harder for me, currently a bit busy in real life too so I don't have any estimate on when it will be finished.

Edit: I have Falcon and Lockjaw working now, send any more along that you find not working since I'd like to have most models working before posting this version if possible! I don't plan on supporting props/random other models YET since they probably would make the script too confusing, the game seems to like having different headers a lot, might check them out once the character models and bones are sorted.


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Tue Sep 19, 2017 1:59 pm 
Offline
beginner

Joined: Mon Jul 23, 2012 2:02 am
Posts: 32
Has thanked: 1 time
Have thanks: 2 times
I was wrong on Cap Weenie. He has the "d_" prefix. Falcon was the only for me. As there's a lot of files I'll list the ones that have worked so far. These are the static "c_" prefixed as well their lod's and alternate costumes. None of the animation files have worked for me. Some of the fx so far have though I only went through all of the "c_" files thus far and checked the caches from several different versions.

working: Ares, Abomb, Baron Zemo, Black Panther, Black Widow, Captain America, Chitauri, Drax, Enchantress, Gamora, Groot, Hank Pym, Hulk Weenie, Hydra, Holo-Loki, Iron Man, Leader, Loki, Madame Hydra, Ms.Marvel, Nebula, Nick Fury, Odin, Quake, Red Hulk, Rescue, Rocket Raccoon, Ronan, Scientist Supreme, Spider-woman, Star-Lord, Ultron, Vision, War Machine, Wasp, Yondu.

a few others I got so far are the dj table, the ant and the anthill. Will list more when I get through them. Thank you again though and massive props for this.


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Tue Sep 19, 2017 8:38 pm 
Offline
mega-veteran
mega-veteran

Joined: Sat Sep 24, 2011 7:06 pm
Posts: 177
Has thanked: 40 times
Have thanks: 18 times
No idea what the "d_" prefix represents, I have Cosmo The Dog with a name like that, and a flower bed item, no idea what they have in common unless they are just items you can place down. I've only looked at the "c_" files and those are the ones I focus on since they are the main characters, most other things probably won't work, animations definitely not.

Looks like a lot are working though which is great, I can look into other things once the "c_" files are sorted but those are my focus right now, along with the bones.


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Wed Sep 20, 2017 5:29 am 
Offline
veteran

Joined: Tue Jan 26, 2016 2:26 pm
Posts: 115
Has thanked: 5 times
Have thanks: 6 times
TRDaz wrote:
No idea what the "d_" prefix represents, I have Cosmo The Dog with a name like that, and a flower bed item, no idea what they have in common unless they are just items you can place down. I've only looked at the "c_" files and those are the ones I focus on since they are the main characters, most other things probably won't work, animations definitely not.

Looks like a lot are working though which is great, I can look into other things once the "c_" files are sorted but those are my focus right now, along with the bones.

_d is a dialouge,i think (probably dialouge only character)
SickAlice wrote:
Some of the fx so far have though I only went through all of the "c_" files thus far and checked the caches from several different versions.

These caches has a lot of character files? If yes,can you share me some caches or tell me the where you are downloaded them?
Thanks.


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Fri Sep 22, 2017 6:30 am 
Offline
veteran

Joined: Tue Jan 26, 2016 2:26 pm
Posts: 115
Has thanked: 5 times
Have thanks: 6 times
Sorry for double post.
I've uploaded more c3b samples,i hope they can help.
https://www.sendspace.com/file/1uxoo5

Also,here are files with no extension,can they contain info about event chars or something like that?
https://www.sendspace.com/file/7e53kr


Top
 Profile  
 
 Post subject: Re: Avengers Academy .ccz .c3b
PostPosted: Fri Sep 22, 2017 8:05 am 
Offline
mega-veteran
mega-veteran

Joined: Sat Sep 24, 2011 7:06 pm
Posts: 177
Has thanked: 40 times
Have thanks: 18 times
Thanks for the model files, looks like the Falcon model in there doesn't work with the updated version I have for the other Falcon model, which is weird. Everything else does though, I'll check that out later when I have time.

Those unknown files don't seem to be related to models so I don't think they are useful.



Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 43 posts ]  Go to page Previous  1, 2, 3  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group