Important information: this site is currently scheduled to go offline indefinitely by end of the year.
[request] convert GRIN Engine .diesel models
-
- 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: [request] convert GRIN Engine .diesel models
The contents of this post was deleted because of possible forum rules violation.
- Tosyk
- double-veteran
- Posts: 1027
- Joined: Thu Oct 22, 2009 10:24 am
- Location: Russia, Siberia
- Has thanked: 269 times
- Been thanked: 154 times
- Contact:
Re: [request] convert GRIN Engine .diesel models
The contents of this post was deleted because of possible forum rules violation.
-
- mega-veteran
- Posts: 176
- Joined: Fri Jul 29, 2011 9:18 pm
- Has thanked: 54 times
- Been thanked: 46 times
Re: [request] convert GRIN Engine .diesel models
I just checked that in the files .bundle are not all models and textures (in the case of some games)
your work is genial Szkaradek123
thanks
your work is genial Szkaradek123
thanks
Re: [request] convert GRIN Engine .diesel models
Thanks for helping w/some old requests. Jsut because it's old doesent mean it's not useful or appreciated! Thanks!
-
- mega-veteran
- Posts: 176
- Joined: Fri Jul 29, 2011 9:18 pm
- Has thanked: 54 times
- Been thanked: 46 times
Re: [request] convert GRIN Engine .diesel models
dds format , with the specular maps in the diffuse map (alpha channel )dragbody wrote:The blender script by Szkaradek123 works great for these samples. How about the textures? What format do they come in?
- SoldierTODD
- beginner
- Posts: 35
- Joined: Fri Oct 24, 2014 10:15 pm
- Has thanked: 7 times
Re: [request] convert GRIN Engine .diesel models
I beg your pardon.Szkaradek123 wrote:Blender249 importer for Bionic models from samples:
-import geometry and uv
-open script in Blender249 text editorCode: Select all
#MARIUSZ SZKARADEK GLOGOW POLAND 2011-10-17 #BIONIC BLENDER249 IMPORTER(.DIESEL MODEL) #GEOMETRY+UV #PRESS ALT+P TO RUN SCRIPT AND SELECT DIESEL MODEL import bpy,struct,os import Blender from Blender import * from struct import * from Blender.Mathutils import * import math def find_0(): s='' while(True): litera = struct.unpack('c',plik.read(1))[0] if litera=='\x00': break else: s+=litera return s def word(long): s='' for j in range(0,long): lit = struct.unpack('c',plik.read(1))[0] if ord(lit)!=0: s+=lit if len(s)>100000: break return s def b(n): return struct.unpack(n*'b', plik.read(n)) def B(n): return struct.unpack(n*'B', plik.read(n)) def h(n): return struct.unpack(n*'h', plik.read(n*2)) def H(n): return struct.unpack(n*'H', plik.read(n*2)) def i(n): return struct.unpack(n*'i', plik.read(n*4)) def f(n): return struct.unpack(n*'f', plik.read(n*4)) def vertexuv(): mesh.vertexUV = 1 for m in range(len(mesh.verts)): mesh.verts[m].uvco = Vector(uvlist[m]) mesh.update() mesh.faceUV = 1 for fc in mesh.faces: fc.uv = [v.uvco for v in fc.verts];fc.smooth = 1 mesh.update() def drawmesh(name): global mesh mesh = bpy.data.meshes.new(name) mesh.verts.extend(vertexlist) mesh.faces.extend(faceslist,ignoreDups=True) if len(uvlist)!=0: vertexuv() scene = bpy.data.scenes.active obj = scene.objects.new(mesh,name) mesh.recalcNormals() Redraw() def parser(): global vertexlist,faceslist,uvlist print data = H(10);print data plik.seek(12) for m in range(data[4]): print '-'*20,m, var0 = i(2);print var0,plik.tell() seek = i(1)[0]#;print 'seek',seek back = plik.tell() if var0[0]==1012162716: print find_0() if var0[0]==268226816: print find_0() if var0[0]==2058384083: vertexlist = [] uvlist = [] num = i(1)[0];print 'num =',num var = i(1)[0];print 'var =',var if var == 5:i(10) elif var == 2:i(4) elif var == 4:i(8) elif var == 7:i(14) elif var == 8:i(16) elif var == 9:i(18) elif var == 10:i(21) else: print i(10) break for n in range(num): vertexlist.append(f(3)) for n in range(num): uvlist.append([f(1)[0],-f(1)[0]]) print plik.tell() #print f(10) if var0[0]==1280342547: faceslist = [] var = i(2);print var for n in range(var[1]/var[0]): faceslist.append(H(3)) drawmesh('model-'+str(m)) plik.seek(back) plik.seek(seek,1) def openfile(filename): global plik print sys.basename(filename) plik = open(filename,'rb') parser() Window.FileSelector(openfile)
This script can import an animation from the game Terminator Salvation?
P.S. Sorry for my English. I use a translator.