Bone Tree Editor- development thread : Version 1.1 released

Started by TheShyGuy, September 13, 2010, 11:57:53 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

ah...
KK...
hmm...

so you call the input file from a class function (I think) and then close the file

hmm...
not so sure how to do that in Py
your code is actually quite different as Py doesn't have binaryreader and binarywriter

Py loads a file as:

path = "input.mdl0"
input = open( path , 'rb' ) # r = read, rb = readbinary

or even simpler:

input = open( "input.mdl0" , 'rb' )

thing is...
that's not loading it to mem :/

[spoiler]Quote: Friedslick6
you have been through a lot of hassle. I've watched every topic you posted on this, and most of them seemed to disintegrate gradually.
But the coolest part was that you didn't stop working on it despite that.

Quote: Internet Explorer
you're doing more with your life right now than probably most other people around you. You're a valuable asset to the Smash community. So yeah, you should be proud.

quote: Greg
You do have a gift which I've seen many developers use to their advantage. You can become a great coder, and with all of those ideas I think you can really build something great.

December 15, 2010, 10:17:03 PM #121 Last Edit: December 15, 2010, 10:19:26 PM by theshyguy
i was going to go offtopic about how it actually works but i wont =p...

-are you reading it into a buffer? ex an array,list,another file...?Otherwise its reading the file into nothing(not keeping track of what is read)

ex: byte[] byteArray = br.readbytes(8 );

the string array will have the 8 bytes inside

if you don't then it  will basically just move the current position over 8 bytes



^ thats how it is in c#, hope it helps

eh... it's confusing...
but I see what you're doing:

list = [00 00 00 00 00 00 00 00 , 00 00 00 00 00 00 00 00 , ...]

the best way I can think of to do that would be:

filer = open('input.mdl0','rb')
list = []
a = 1
while a:
__r = filer.read(8)
__if r == '':
____a = 0
__else:
____list.append(r)

as you can see...
I'm really deep into reading from the file...
however...
I just had an idea on how to insert the file as a list...

list.append(filer.read(1).encode('hex'))

now the list will look something like:
list = [4D,44,4C,30,...] # [M,D,L,0,...]
now I can close the file and keep the data :D
while using the list indexes as bytes...
but I'll have to use an advance method of finding the bytes :/
(basic addition of multiplied numbers to give me the direct index)
and also...
list[ index : index+4 ] #32bit

you should get the rest and what not :P

heh...
this thread is getting off topic...
I should stop rambling XD

[spoiler]Quote: Friedslick6
you have been through a lot of hassle. I've watched every topic you posted on this, and most of them seemed to disintegrate gradually.
But the coolest part was that you didn't stop working on it despite that.

Quote: Internet Explorer
you're doing more with your life right now than probably most other people around you. You're a valuable asset to the Smash community. So yeah, you should be proud.

quote: Greg
You do have a gift which I've seen many developers use to their advantage. You can become a great coder, and with all of those ideas I think you can really build something great.

you should really try out c# lol...within a list you can load the whole thing into 1 index and search within that one index for offsets or specific text....

or just seek an offset within the file itself and read what you need at the time into a buffer...

lol...

C# I have to say is actually easier to read than C++
but it's confusing as all get out @_@

I wonder...
does C# have an interpreter as well as a compiler??
^that's why I like Py
I just don't know how to use the compiler XDD

I could do it your way (in py)...
I just don't know how to is all :P
same with buffers, classes, and for loops ;_;
I fail XD

[spoiler]Quote: Friedslick6
you have been through a lot of hassle. I've watched every topic you posted on this, and most of them seemed to disintegrate gradually.
But the coolest part was that you didn't stop working on it despite that.

Quote: Internet Explorer
you're doing more with your life right now than probably most other people around you. You're a valuable asset to the Smash community. So yeah, you should be proud.

quote: Greg
You do have a gift which I've seen many developers use to their advantage. You can become a great coder, and with all of those ideas I think you can really build something great.

lol i thought you were good at py...umm noob Q: what do you mean by interpreter? and yeh it has a compiler

Quote from: theshyguy on December 15, 2010, 11:57:29 PM
lol i thought you were good at py...umm noob Q: what do you mean by interpreter? and yeh it has a compiler

I did mention I'm not the best at Py :P
multiple times on multiple threads though... lol

Py uses an interpreter...
basically just type and go
(go as in run the program without compiling) <3 <3
can C# do that?? (run the scripts before compiling)

[spoiler]Quote: Friedslick6
you have been through a lot of hassle. I've watched every topic you posted on this, and most of them seemed to disintegrate gradually.
But the coolest part was that you didn't stop working on it despite that.

Quote: Internet Explorer
you're doing more with your life right now than probably most other people around you. You're a valuable asset to the Smash community. So yeah, you should be proud.

quote: Greg
You do have a gift which I've seen many developers use to their advantage. You can become a great coder, and with all of those ideas I think you can really build something great.

December 16, 2010, 12:57:21 AM #127 Last Edit: December 16, 2010, 01:18:26 AM by theshyguy
lol i took that as your good but not great....not know how to create loops etc is...more like "im a beginner at py" lol =p

no..it has to compile(build) before running...but it has a check thing that checks if the code has any errors.   Theres a debugger...which is obvious as to what it does.  

edit:....ugh lol trying to get the treeview to scroll to...blah..blah...it doesn't work for some unknown reason....blah..blah going to just make the drag n drop stuff then attempt it again...blah .balh

well for loops is one of the basics yes...
but that's the only one holding me back...

I know what they do...
just not how to use them :/

Tkinter is my next downfall
if I could grasp the concept of that,
I would be able to progg GUI's in a snap
also...
why Tk and not Wx or PyCd
Tk comes with the distribution...
the others dont :/

[spoiler]Quote: Friedslick6
you have been through a lot of hassle. I've watched every topic you posted on this, and most of them seemed to disintegrate gradually.
But the coolest part was that you didn't stop working on it despite that.

Quote: Internet Explorer
you're doing more with your life right now than probably most other people around you. You're a valuable asset to the Smash community. So yeah, you should be proud.

quote: Greg
You do have a gift which I've seen many developers use to their advantage. You can become a great coder, and with all of those ideas I think you can really build something great.

drag and drop works fine...trying to dnd and add the bone right after the dest node...but it keeps adding it at (didn't look at pattern) places(under the right parent tho)...making it a childnode of the dest bone is already done

Quote from: theshyguy on December 16, 2010, 02:09:58 PM
drag and drop works fine...trying to dnd and add the bone right after the dest node...but it keeps adding it at (didn't look at pattern) places(under the right parent tho)...making it a childnode of the dest bone is already done

hmm...
so you're saying you're having trouble getting it to do this:
[-] <- main bone
[-] <- added bone

because it keeps doing:
[-] <- main bone
+ [-] <- added bone

am I correct on that?? :/

[spoiler]Quote: Friedslick6
you have been through a lot of hassle. I've watched every topic you posted on this, and most of them seemed to disintegrate gradually.
But the coolest part was that you didn't stop working on it despite that.

Quote: Internet Explorer
you're doing more with your life right now than probably most other people around you. You're a valuable asset to the Smash community. So yeah, you should be proud.

quote: Greg
You do have a gift which I've seen many developers use to their advantage. You can become a great coder, and with all of those ideas I think you can really build something great.

no it ends up
[-] added bone
[-] main bone

but it doesnt always go on top...but neither does it become a child randomly...but that was before...

through lots of recurssive ive fixed it but i got one more glitch to fix lol...which ill do in a sec....

ah...

I see what you mean...
that's odd lol
heh...
looks like you've pretty much got things covered as well :P
can't wait to see when it's finished :D

oh and btw, I also understand what the nodes are...
the nodes are the transform indexes used by the Objects (Polygons)
it's basically an ID so the transforms get matched up correctly...
I'm still not understanding the node data though :/
(it's not always '00 00 00 00' or 'FF FF FF FF')

[spoiler]Quote: Friedslick6
you have been through a lot of hassle. I've watched every topic you posted on this, and most of them seemed to disintegrate gradually.
But the coolest part was that you didn't stop working on it despite that.

Quote: Internet Explorer
you're doing more with your life right now than probably most other people around you. You're a valuable asset to the Smash community. So yeah, you should be proud.

quote: Greg
You do have a gift which I've seen many developers use to their advantage. You can become a great coder, and with all of those ideas I think you can really build something great.

you mean the bone nodeIDs (lol used to think it was nodeLd-> doesnt even makes sense lol...) are ids that decide which polygon(through its nodeID) it (the polygon) attaches to?

Sorry but you are not allowed to view spoiler contents.


also the node mix has something to do with i think certain \vertex points....if you wanna know a bit more just ask cuz i dun feel like typing it if you might know

December 16, 2010, 08:13:50 PM #134 Last Edit: December 16, 2010, 08:15:01 PM by Tcll
ah...
no...
the definition and node stuff confuses me big time :P

so yea... IDK

EDIT:
lol...
you seem to me of more help to me around the bone areas XD

[spoiler]Quote: Friedslick6
you have been through a lot of hassle. I've watched every topic you posted on this, and most of them seemed to disintegrate gradually.
But the coolest part was that you didn't stop working on it despite that.

Quote: Internet Explorer
you're doing more with your life right now than probably most other people around you. You're a valuable asset to the Smash community. So yeah, you should be proud.

quote: Greg
You do have a gift which I've seen many developers use to their advantage. You can become a great coder, and with all of those ideas I think you can really build something great.