Important information: this site is currently scheduled to go offline indefinitely by end of the year.

CABAL .EBM Can't Open 3D model

Post questions about game models here, or help out others!
godskin
veteran
Posts: 98
Joined: Thu Nov 05, 2015 2:45 pm
Has thanked: 11 times
Been thanked: 3 times

CABAL .EBM Can't Open 3D model

Post by godskin »

Some one know tihs ploblem or help

DeathKnight_boss.7z
http://www10.zippyshare.com/v/J0s7nWIz/file.html
godskin
veteran
Posts: 98
Joined: Thu Nov 05, 2015 2:45 pm
Has thanked: 11 times
Been thanked: 3 times

Re: CABAL .EBM Can't Open 3D model

Post by godskin »

bump
Acewell
VIP member
VIP member
Posts: 1330
Joined: Wed Nov 05, 2008 12:16 pm
Has thanked: 2710 times
Been thanked: 884 times

Re: CABAL .EBM Can't Open 3D model

Post by Acewell »

DeathKnight_boss.png
:D
search for FF FF FF FF and that will take you to where the models are
the byte after that is the mesh ID
the 2 bytes after that are the number of vertices
the 2 bytes after that you must multiply by 3 to get face count
2 bytes after that are padding and then the vertex block starts

have you tried the cabal scripts here?
viewtopic.php?p=91804#p91804
You do not have the required permissions to view the files attached to this post.
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4291
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1151 times
Been thanked: 2244 times

Re: CABAL .EBM Can't Open 3D model

Post by shakotay2 »

@godskin: use a hexeditor to look into that EBM, you'll find the strings 'DDS' and 'DXT1'

delete everything before 'DDS' and save the rest as as whatevername.dds

as simple as that:
DeathNight_Boss-EBM.jpg
(There's another two dds contained (DXT3) - but I'll leave that task to be solved by you. :) )

edit: upps, seems AceWell was active during my typing :D
You do not have the required permissions to view the files attached to this post.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
godskin
veteran
Posts: 98
Joined: Thu Nov 05, 2015 2:45 pm
Has thanked: 11 times
Been thanked: 3 times

Re: CABAL .EBM Can't Open 3D model

Post by godskin »

AceWell wrote:
DeathKnight_boss.png
:D
search for FF FF FF FF and that will take you to where the models are
the byte after that is the mesh ID
the 2 bytes after that are the number of vertices
the 2 bytes after that you must multiply by 3 to get face count
2 bytes after that are padding and then the vertex block starts

have you tried the cabal scripts here?
viewtopic.php?p=91804#p91804
thx but don't work
godskin
veteran
Posts: 98
Joined: Thu Nov 05, 2015 2:45 pm
Has thanked: 11 times
Been thanked: 3 times

Re: CABAL .EBM Can't Open 3D model

Post by godskin »

shakotay2 wrote:@godskin: use a hexeditor to look into that EBM, you'll find the strings 'DDS' and 'DXT1'

delete everything before 'DDS' and save the rest as as whatevername.dds

as simple as that:
DeathNight_Boss-EBM.jpg
(There's another two dds contained (DXT3) - but I'll leave that task to be solved by you. :) )

edit: upps, seems AceWell was active during my typing :D
this old ebm work on noesis mdf_mamuo.ebm
http://www117.zippyshare.com/v/FyYTyr9k/file.html

cabal korea have protection some .ebm file ??
godskin
veteran
Posts: 98
Joined: Thu Nov 05, 2015 2:45 pm
Has thanked: 11 times
Been thanked: 3 times

Re: CABAL .EBM Can't Open 3D model

Post by godskin »

godskin wrote:
shakotay2 wrote:@godskin: use a hexeditor to look into that EBM, you'll find the strings 'DDS' and 'DXT1'

delete everything before 'DDS' and save the rest as as whatevername.dds

as simple as that:
DeathNight_Boss-EBM.jpg
(There's another two dds contained (DXT3) - but I'll leave that task to be solved by you. :) )

edit: upps, seems AceWell was active during my typing :D
this old ebm work on noesis mdf_mamuo.ebm
http://www117.zippyshare.com/v/FyYTyr9k/file.html

cabal korea have protection some .ebm file ??
i need new .ebm can open in noesis only pls share how to fix

shakotay2 / Acwell
don't fixed
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4291
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1151 times
Been thanked: 2244 times

Re: CABAL .EBM Can't Open 3D model

Post by shakotay2 »

in function noepyCheckType(data) in fmt_CabalOnline_ebm.py add a further idstring:

Code: Select all

        if idstring not in [0x0003ED03, 0x0003EE03, 0x0003EF03, 0x0003F003, 0x0003F103]:
But you won't get too far - the script freezes Noesis then with DeathKnight_boss.EBM because finale00's script can't handle ebms of type 0x0003F103.

So if you want the textures you should try out my method.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
godskin
veteran
Posts: 98
Joined: Thu Nov 05, 2015 2:45 pm
Has thanked: 11 times
Been thanked: 3 times

Re: CABAL .EBM Can't Open 3D model

Post by godskin »

shakotay2 wrote:in function noepyCheckType(data) in fmt_CabalOnline_ebm.py add a further idstring:

Code: Select all

        if idstring not in [0x0003ED03, 0x0003EE03, 0x0003EF03, 0x0003F003, 0x0003F103]:
But you won't get too far - the script freezes Noesis then with DeathKnight_boss.EBM because finale00's script can't handle ebms of type 0x0003F103.

So if you want the textures you should try out my method.
i added u code
don't work bro
noesis freezy and not reponding after open Deatking

i do not need Texture
i need model + Skeletion + bone
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4291
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1151 times
Been thanked: 2244 times

Re: CABAL .EBM Can't Open 3D model

Post by shakotay2 »

godskin wrote:noesis freezy and not reponding after open Deatking
you don't read what other people write, do you?
Yes, it freezes - that's what I wrote.

Also WHY didn't you write that you don't need textures?
I really hate it when people waste my time.

This is the model:
DeathKnight_Boss.jpg
Try out hex2obj or let it be.
You do not have the required permissions to view the files attached to this post.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
godskin
veteran
Posts: 98
Joined: Thu Nov 05, 2015 2:45 pm
Has thanked: 11 times
Been thanked: 3 times

Re: CABAL .EBM Can't Open 3D model

Post by godskin »

shakotay2 wrote:
godskin wrote:noesis freezy and not reponding after open Deatking
you don't read what other people write, do you?
Yes, it freezes - that's what I wrote.

Also WHY didn't you write that you don't need textures?
I really hate it when people waste my time.

This is the model:
DeathKnight_Boss.jpg
Try out hex2obj or let it be.
Ok thank you Sorry
can share DeathKnight.obj
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4291
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1151 times
Been thanked: 2244 times

Re: CABAL .EBM Can't Open 3D model

Post by shakotay2 »

hex2obj can create obj files from models using H2O files.
In hex2obj:
File open (ebm file)
Open H2O
File SaveAs Mesh

Here's the H2O for the horse - save as txt file and rename it to DN_Horse.H2O for example:

0x236D81 23208
Vb1
32 24
0x209FA1 5743
020000
0x0 255
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
Szkaradek123
mega-veteran
mega-veteran
Posts: 292
Joined: Wed May 05, 2010 8:21 pm
Location: Poland Głogów
Has thanked: 21 times
Been thanked: 742 times

Re: CABAL .EBM Can't Open 3D model

Post by Szkaradek123 »

Noesis plugin new line: 160 -
self.inFile.readUShort()
You do not have the required permissions to view the files attached to this post.
godskin
veteran
Posts: 98
Joined: Thu Nov 05, 2015 2:45 pm
Has thanked: 11 times
Been thanked: 3 times

Re: CABAL .EBM Can't Open 3D model

Post by godskin »

Szkaradek123 wrote:Noesis plugin new line: 160 -
self.inFile.readUShort()
thx very much work !!

pls fix 010 Scrtip can't load new ebm

Code: Select all

//--------------------------------------##
// Game: CABAL Online
// File Format: EBM/ECH
// Description: Template for CABAL's model files
//--------------------------------------##
// Author: Yamachi
// Team: The Divinity Project
// Website: http://board.thedivinityproject.com
//--------------------------------------##

#include "Common_Cabal.bt"

//-Local-Variables----------------------

local string estType = "EBM";

local int tex_offsets[256], tex_lengths[256], dds_offsets[256];
local int index = 0;

//-Enumerations-------------------------

typedef enum <uint32> {
    MATERIAL         = 0x41470201,
    MESH             = 0x41470202,
    ARMATURE         = 0x41470203,
    ANIMATION        = 0x41470204,
    INFLUENCE        = 0x41470205,
} CID;      // Chunk ID's

typedef enum <int32> {
    MULTIPLY                = 0x04,
    GRAIN_MERGE             = 0x08,
    HARD_LIGHT              = 0x09,
    MULTIPLY__INVERT_PARENT = 0x0A,
    ODD_FLICKER_EFFECT      = 0x0E,
    BELOW                   = 0x10,
    SCREEN                  = 0x12,
    SOME_PURE_WHITE_THING   = 0x13,
    CHROME                  = 0x18,
} RenderFlag;    // 2nd layer render flag

//-Structures---------------------------

typedef struct {
	uint magic <format=hex>;
	ushort unkus;
	byte model_flag <format=hex>;
    byte alpha_threshold;
    ushort unkus;
	Vector3 bound_min;          // Bounding box lower vertex
	Vector3 bound_max;          // Bounding box upper vertex
	uint scale_percentage;      // Scale of model (default = 100%)
	CID chunk_id <format=hex>;  // ID for the next chunk
} Header;

typedef struct {
    float r, g, b, a;
} RGBA <read=RGBARead, write=RGBAWrite>;

typedef struct {
    RGBA r <hidden=true>;
    ParseRGBA(r);
    RGBA ambient;

    RGBA r <hidden=true>;
    ParseRGBA(r);
    RGBA diffuse;

	RGBA r <hidden=true>;
    ParseRGBA(r);
    RGBA specular;

    RGBA r <hidden=true>;
    ParseRGBA(r);
    RGBA emissive;
    SetBackColor(cNone);

	float power;
} MatProps;     // Material properties

typedef struct {
    ubyte unkba[9];
    int material_index <read=MaterialIndexReadI>;
    Bool is_faceted;
    Vector2 speed;
    RenderFlag render_flags;
} Layer;

typedef struct {
	Text id;
    tex_lengths[index] = id.length;
    tex_offsets[index] = FTell() - id.length;
	uint size;
    dds_offsets[index] = FTell();
	ubyte data[size];
    index++;
} IndexedTexture;

typedef struct {
    MatProps material_properties;
    IndexedTexture texture;
    Layer layer;
} Material;

typedef struct {
    uint count;
    if (count != 0) {
        uint vertex_index[count];
        float weight[count]; }
} InfluenceBone;

typedef struct {
    InfluenceBone influence_for_bone[skeleton.count] <optimize=false>;
} Influence;

typedef struct {
    Text id;
    Matrix world_matrix;
    Matrix local_matrix;
    int root_bone_id;   // Bone to attach mesh to.  Causes entire mesh to "stick" to that bone, moving when it does.
    ubyte material_index <read=MaterialIndexRead>;
    ushort vertex_count;
    ushort face_count;
    Vertex vertices[vertex_count];
    Face faces[face_count];

    /*CID chunk_id;   // INFLUENCE
    if (chunk_id == INFLUENCE) {
        ushort influence_count;
        if (influence_count != 0)
            Influence influences[influence_count] <optimize=false>; }
    else {FSeek(FTell() - 4) ; }*/
    
    // Hopefully this works for all models.  It should do.
    if (vertex_count > 0) {
        CID chunk_id;
        ushort influence_count;
        if (influence_count != 0)
            Influence influences[influence_count] <optimize=false>; }
} Mesh;

typedef struct {
    Text id;
    int parent_bone_index;
    Matrix bone_space_matrix;
    Matrix parent_bone_space_matrix;
} Bone <read=BoneRead>;

typedef struct {
    Text id;
    uint translation_count;
    Translation translations[translation_count] <optimize=false>;
    uint rotation_count;
    Rotation rotations[rotation_count] <optimize=false>;
} Transformation <read=TransformationRead>;

typedef struct {
    Text id;
    ushort count;
    Transformation transformations[count] <optimize=false>;
} Animation <read=AnimationRead>;

typedef struct {
    ushort count;
    local ushort tex_name_lengths[count];
    local short i = 0;
	Material materials[count] <optimize=false>;
    CID chunk_id <format=hex>;
} MT <read=CommentMT>;

typedef struct {
    ushort count;
    Mesh meshes[count] <optimize=false>;
    CID chunk_id <format=hex>;
} GE <read=CommentGE>;

typedef struct {
    ushort count;
    if (count != 0)
        Bone bones[count] <optimize=false>;
    CID chunk_id <format=hex>;
} SK <read=CommentSK>;

typedef struct {
    ushort count;
    if (count != 0)
        Animation animations[count] <optimize=false>;
} AN <read=CommentAN>;

typedef struct {
    local int i;

    for (i = 0; i < 210; i++)
    {
        Colour c <hidden=true>;
        ParseColour(c);
        Colour glow_colour;

        SetBackColor(cNone);
        SetForeColor(cNone);
    }
} GL;

//-Main---------------------------------

FSeek(0);

Header model_header <read=CommentHDR>;

local CID chunk_id = model_header.chunk_id;
local ushort x = 0;

while (x < 4) {
    if (chunk_id == MATERIAL) {
        MT materials_and_textures;
        chunk_id = materials_and_textures.chunk_id;
        x++;
    }
    else if (chunk_id == MESH) {
        GE geometry;
        chunk_id = geometry.chunk_id;
        x++;
    }
    else if (chunk_id == ARMATURE) {
        SK skeleton;
        chunk_id = skeleton.chunk_id;
        x++;
    }
    else if (chunk_id == ANIMATION) {
        AN animations;
        x++;
    }
    else { x = 4; }
}

if (FileSize() - FTell() > 4)
    GL glows;

//-Functions----------------------------

void ParseRGBA(RGBA &r) {
    FSeek(FTell() - 16);
    local float blue = (r.b * 255.0f);
    local float green = (r.g * 255.0f);
    local float red = (r.r * 255.0f);
    local int bc = (int)blue * 0x10000 + (int)green * 0x100 + (int)red;
    SetBackColor(bc);
}

//-Chunk-Descriptors--------------------

string CommentHDR(Header &voi) {
    return ("Unknown values, model flag, bounding box, and following chunk ID.");
}

string CommentMT(MT &voi) {
    return ("Materials and textures.");
}

string CommentGE(GE &voi) {
    return ("Meshes.");
}

string CommentSK(SK &voi) {
    return ("Bones.");
}

string CommentAN(AN &voi) {
    return ("Animation sequences.");
}

//-English------------------------------

string MaterialIndexRead(ubyte i) {
    string name = ReadString(tex_offsets[i]);
    name = SubStr(name, 0, tex_lengths[i]);
    string s;
    SPrintf(s, "%i ( %s )", i, name);
    return s;
}

string MaterialIndexReadI(int i) {
    string name;
    if (i == -1)
        name = "NULL";
    else {
        name = ReadString(tex_offsets[i]);
        name = SubStr(name, 0, tex_lengths[i]); }
    string s;
    SPrintf(s, "%i ( %s )", i, name);
    return s;
}

string AnimationRead(Animation &a) {
    return (a.id.text);
}

string TransformationRead(Transformation &t) {
    string s;
    SPrintf(s, "%s: %s", "Bones", t.id.text);
    return s;
}

string RGBARead(RGBA &r) {
    string s;
    SPrintf(s, "(%f %f %f %f)", r.r, r.g, r.b, r.a);
    return s;
}
void RGBAWrite(RGBA &r, string s ) {
    SScanf(s, "(%f %f %f %f)", r.r, r.g, r.b, r.a);
}

string BoneRead(Bone &b) {
    string s;
    SPrintf(s, "%s", b.id.text);
    return s;
}
Szkaradek123
mega-veteran
mega-veteran
Posts: 292
Joined: Wed May 05, 2010 8:21 pm
Location: Poland Głogów
Has thanked: 21 times
Been thanked: 742 times

Re: CABAL .EBM Can't Open 3D model

Post by Szkaradek123 »

Hi godskin
I see your purpose here is only testing scripts. Nice.

What is this ? From which software is it from ? And how it use ?

//--------------------------------------##
// Game: CABAL Online
// File Format: EBM/ECH
// Description: Template for CABAL's model files
//--------------------------------------##
// Author: Yamachi
// Team: The Divinity Project
// Website: http://board.thedivinityproject.com
//--------------------------------------##
Post Reply