posted March 09, 2004 05:45 PM
Well, I see nothing here, don't know why, and I'm doing a programmin' project for Tread Marks. I got tired of trying to organize my entities and time stamping them and updating stuff from sites for servers: Hence this program. It should, at its core:
- Help mod authors write up mods, add authorship, allow peeps to keep the mods up to date, and other miscellaneous MOD stuff.
- Allow others to modify it so entegrity/masterclient/tankbuilder/etc. can all be glued into one stable program that overall can control TM mod development.
- Encourage others to submit mods on mods and on the regular Treadmarks scheme
- Have lots of funny easter eggs with graphics only a bored person could create.
- Be a launch pad from which I can start a SUPER DUPER python plugin for blender that allows Tread MArks players to make tanks on the fly with entities and UV files and LWO's all exported by clicking on one button.
So, why post this here?
I guess I'd like any help passerby programmers might have. Also, I'd like to encorage others that programming is only a couple of links away from being a reality of you're interested. I also would like anyone here with guts enough to stand up to a would-be cookie dough maniac and criticize his method. Don't like python and have a constructive answer? I'm ALL ears. I'll do it if I can't find a decent rebuttal. Why not? Also, I'd like to do this in the spirit of Suemas, who I dearly wish I could have met. I know there isn't a great demand for this, but I'm a passionate guy about computers (a.k.a. geek or nerd or /-\4X0/2) and I just find this titillating in some weird way enough that I'd even use that word for it. I enjoy programming, and it's awesome to spread the word. So, without further ado, here's what I've done so far (no screenies till I find somewhere to post them ... AND find permission as well!):
I found Boa and have since fallen in love with it. It's an IDE for python, and it works well with me. Why didn't I choose C++, C#, perl, or anyting else? Python works, it's free, it's powerful, and it works on linux! (ahhhh, c|457 31337!i!i!i)
After programming a decent gui with anchors, I set about getting down how the thing is gonna work:
---Check changes in addons and update grand list of mods
---If no mods list, make one
----For manipulating list files, everything will be a form of XML.
-----List files will have a basic DTD
#(is that right? It's supposed to be the instructions which tell the XML parser how to check and interpret the XML file)#
-----List files will contain dates according to how the modder wants
------Either one can go by how the file system gives the dates, or go by which files are changed in the list and give those files the current system date stamp
-----List files will have the website defined in which files can be ascertained as well as what format they'll be under
------Files can be accessed as ZIP,GZIP(cause that seems natural for a nix compat language to do),individual files, <insert more here>
-----List files will also contain entity names, authorship, and type. This keeps the program from checking the entities itself.
----Upon importing a list, the program checks for identical names
I'll finish more of this as I need to.
Okay... I'll be editing this a ton anyway... I have a lot of links I want to post, but my cable modem as decided it can ONLY access the TM forum... gonna see if posting works (which, if it does: I officially HATE cable for the dirty rotten filthy evil persnickety no-good lousy flea-bitten fat-headed stinking low-down double-crossing <blankity blank blank>s they are!)
Okay, I'd like to keep my comments that are above and just continue my post... cable officially is evil until someone defends it here... then perhaps i'll change my mind. Well, back to the program.
I still have had no comments, but this is an obscure post, and I like the security of not being known. To those would be readers, I'd like it if you wait a week or so before notifying others of this post just to see who's actually actively looking around the forum and actually interested in this. But you don't have too... really I wouldn't be upset at all if you told me you'd done such a thing. Now to business.
For the links I have found much joy in, CHECK THESE OUT:
-This is where I've found the 1337 stuff. everything that follows I've found there.
-This is THE thing to do blender crud with when you wanna make kick butt plug-ins. Oh yes... my tank constructor is practically a reality now that I have this *writhes in joy*
-A nice set of plug-ins, but one is esp. important to me which follows:
-Da' 1337 xml file exporter for python. Yes, just look at the hits that the site reports. Wow... people must like this.
-And das XML parse engine. I think it'll do the job.
Well, I gotta get these things plugged into my project.
OH: Big ups to da Marines. I am joining tomorrow. Feel great about it. I give ful permission to speel support/criticism on this subject as well. let's cut the rug on Programming as well, though, if we can.
Yet another edit. I've found some nice file handling scripts also from the vaults of parnassus. Here they are:
Well, I hate windows today [March 5th, 2004]
It took me a FILTHY ROTTEN TWO DAG-BLASTED HOURS to get this simple print directories script working in python... don't you even dare say it's python's fault.
The thing is under 15 lines of code... which is what's so demoralizing. If only winblows didn't have do a few of these name differences and not be cap sensitive and how it doesn't order it's dirs and.... and..... ohhhhh, okay... I'll stop.
i've got things REALLY coming together now. Beta should be out by Monday. That is if everything else (car emissions/registration, and other misc. life struggles) works out smoothly. Have fun! I'm playing TM then FFX. W00000t.
Darn, biggie update. (March 9th, 2004) I mean BIG. I have so far made the file scanner, and right now working on getting my proggy to detect references to other files (be they ent or bmp or something else).
Wow, this is one heck of an arduous task. I think I should have something that can load a set of references... but I'll have to see if I have time to release a beta. Keep fingers crossed. Actually, wait, I hate superstition. Pray instead, . If all goes well, I could have the thing at least reading dirs (actually this is harder than loading zips and all... amazing huh?) and spouting XML. Prolly be able to read it as well (W00t). Pray again. Do as many times as it takes to fill up the rest of the day. Thanks.
Want some clippets? Ask me to add them... I can! I'll find ways... program python parsers to do it for me, even.
Wait, have a clippet, why not?
entDefinitions = [['projectile','projectile'],['firesoundent'],['explokill'],
resDefinitions = [['mesh','lwo'],['secmesh','lwo'],['texture','bmp'],['sound','wav'],['altsound','wav'],
subFile,resFile = 
"""THIS SUC|<S. I have to make sure things aren't comments, assume entity refs
come more often then resources, and I also have to wack at what the entity name
is and it's directory. If the directory is not valid, are we gonna be nice?
FRIGGIN NO! Eat yah heart out, Mr. Modder... put stuff where it BELONGS! PFFFFT!!!"""
for i in textlines(self.entDir):
if i != '#':
found = 0
definitionLength = i.find('=')
for j in entDefinitions:
if definitionLength == len(j):
if i[ definitionLength - 1)] == j:
#ICKY! Need to optimize if things get slow!!! Try searching for / from the end back and stop loop when you're done
entNameStart = 0
commenting = i.find('#',definitionLength)
for k in range(3):
entNameStart = i.find('/',entNameStart)
if entNameStart > commenting:
end = commenting
end = entNameStart
subFile += [[location + i[definitionLength:end],i[end:commenting] + '.ent',j]]
found = 1
if not found:
for j in resDefinitions:
if definitionLength == len(j):
if i[ definitionLength - 1)] == j:
resFile += [[location + + '.'+ j,j]]
found = 1
Note, this thing is NOT done. I know the entdefinitions aren't complete and all, but I'll fix that soon enough. This is only a fraction of what I've done so far today. gimme a couple hours and I'll post how today ended. Perhaps with a beta. I mean it. It'll take all of 30 minutes to write the xml and zip stuff. It's the parsing of mods and directory searches that bite. Wait... I take that back... I'll have to get the gui to work with it then... that might take a bit longer because I have no clue how to get most of it working... but I might have a hope. Once again, those who want the python source, just tell me... err... umm... and I'll need an e-mail addy. Dunno where to post this that's hassle free (every second is a second I could be programming! I love doing this, you know?).
Criticize criticize critize. Enquire or inquire, or query or quwherey... howver you cn spl as a prgmr/mdr.
Confession time [a few hours later, people]: I gave up... I had to play TM. I will finish the beta by then of the week (mainly because schoolwork is not going to allow much more work until Saturday... if at all). Sorry all. But no worries *puts cape on melon cracker* here's super target at our service. (He doesn't read this stuff anyways, right? So he won't know I typed that)
Well, here's the rules of engagement as planned. If I go to my g-parents and bake pies and get high off cookie dough and play soldat in a sugar-coated stupor:
1. Get the entity parser done (I've hit a bad spot because I decided to make the entity class do all the hard work, so I'm having trouble rewriting the code. I feel it's far more proper than putting code everywhere... I hate doing that!)
2. Get XML export/import finished
3. Get GUI working and add super secr3t evil animation.
The idea is I work at these stages... by next week, I stop on whichever I am at, and release all the code to some place safe (I'll hack GA's computer and force him to set up an ftp server and send him pictures of roadkill in the mail if the server dies).
If I end up staying here (the appartment) and don't go to my grandparents... in other words I end up not sleeping friday or staturday night because my programminf station is right here.... then I will probably be able to go beyond the GUI to these steps:
4. post screenies and get the list editor and entity quick editor (It just makes a table of variables and they're values for some to edit quickly or make a python script to hack up a set of entities quickly)
5. Get all the zip file, gzip file, and internet access stuff............ working.........
6. Get the latter -=[WORKING]=-
8. Heaven forbid I get this far... so it's number 8. (besides, I don't want seven to eat nine *har har*).
I'll assume all bets are off and dive neck deep into interfacing this with my tank creator for blender. PLEASE check out my link for SPE that's above, if you doubt I could do it. Considering the power behind SPE, if I don't do it I'd be a fool *random guy runs in from Blazing Saddles and yell's "The FOO.... The Dude's going to do it!"*
Well, that sums it up. That is ALL subject to change. I atleast have my plans. I'll be editing the above feature lists and functionality soon... so keep your eyes peeled. I'll try to post a reply to state what's been updated. I like keeping it all in one post up here still so people who are new to this get all the development and can look at discussion separately. Ta Ta!
The best part of programming is set backs. As if I even need to post this, I'm sure any of your programmers out there foresaw this update.
Sailor... I'll send you a pick some time by Wed IF nothing like this happens again!
Well, on to the goodies, eh?
1) see that code snippet up above. I botched it bad. I took many many shortcuts that are time consuming since they grunt a lot of stuff. Some stuff is very hacky, as well, right now. What is above was an ideal situation that will never happen unless you, the modder, can change all the entities for me. In fact, I've now got probably the best botched job (how's that for an oxy-moron?) in my programming career on the next virtual desktop (even though that career is very short, ). Well... here's what must make Entegrity so crazy good, and why I'm probably not releasing a beta (I could, but you'd all be screaming at me because the klunky thing wouldn't do zips yet, and is slow to read dirs because of file handling struggles. Thank you, M$. You make life easier. *cough*). Chiefly, the dependency checker has a hard time. Sometimes you give the entity a dir, as in smoke/<blah> or explo/<blah>. Other times the same explo or smoke entity is just placed there and assumed to be found. I know TM can do it, and I can do it as well. But dang, it takes longer to work around that when you're just learning python.
*Gumbles as TM Server Spy lists another person joining DDM and laundry timer goes off*
2) The code above has not only been very hacky since I got lazy. I am now at a big crossroads. If I just link entities blindly to weapons and tanks and so on... you hit a major problem. What to do when you get multiple tanks and weapons referring to the same explo file or projectile, you have some issues. You waste time loading files that you already have and you risk writing files to zips and what not rather... ummm... redundantly. Any suggestions on fixing these inefficiency problems?
3) This is what killed the beta: The file searcher. It's why I love M$ right now. I was hoping they'd have made some way for someone to use all the search utilities that are available in folders in a command line. If so, I'd have been able to search quick quick and use the within file search to eliminate chaffe. Anyone have any solutions to this? Today, my thing broke because someone put a projectile (tankGunD.ent) into the main ent folder for one of my addon dirs. When I had the thing search for related files, it somehow got tripped up on this, and I still cannot figure it out (I put so many 'print' statements in the thing that it took 15 minutes for the file search to complete). When I try to directly search (just open up the file containing the function and make a direct call to it without using any class structures or other crud), it doesn't do it. And yet the same call from a class structure will cause the problem... and not a single other search does it, it seems. It's an obscure bug that sucked up 2 hours today of 'print' insanity, as the debugger refused to use breakpoints when I started in the main class file... grrr grrrr.... or in the function file. Anyone want to play with a python function? I assure you, it requires NO special libraries.
I have more to say, but this sums up the past 6 hours of time I put into programing. Believe me, that's generous... considering my workload of classes. And it's not even hard stuff... just tons of busy work. If anyone is interested, I'm doing a literature project that's supposed to be about my life up to today. If you like the insane garbage I vent out upon the forums enough, I'll send you as much as you like. For those wanting screenies, just post a request. I'll get hooked up with sailor when I have a GOOD shot that represents what the beta will do for you. I'll explain the gui when it can be posted. Thanks sailor. You're a great guy.
Ta ta... I'm working on La Tarea now. (I'll code later on if possible, but it's unlikely... )
Cap'n Dudy's Log: Dude-date 03302004 AD
Well, It's doomed. As the last of the bugz was traced an killed, the damage was already done. I ran my code with a sample, and no errors came up. All was clean and quiet... too quiet. In fact, the whole thing halted for 15 minutes just to get the list of entities that one weapon is dependent on. Crap. Double crap. Quintuple Dog doo-doo crap! In fact, a whole GA pant-load of crap (knowing ants that have pants, an ant's pant's chance to grant great gross gobs I can't stand to rant for what an ant's pants grants in antics).
The class structures I made simply do too much. They take so much control of themselves that I can't tell them when they've tried to copy an entity or reinvent the *ahem* turret and so on. Sooooooo... I'm going to go through, salvage as much as I can, and make the program take more control of them. Mainly, I had classes fetch a list of entities with each search they made for matches to their entity references. That's now far too suicidal... and I couldn't have known so well as with this 500 MHz computer . To solve the issue, I'll try to implement code tomorrow to assume each entity is going to be used, and let it build an entity reference structure afterwords... sound good? Either that, or I make a list of entities that already have their types fetched, so as a weapon or racetank or insignia or other major entity needs to fetch an entity, it first checks to see if the entity is already loaded, and if not, finds a type match in the entity list AND deletes the entities it gathers up as they are assimilated by the scripts. I think that one will still allow too much control but I'll see what I can do. Either way, I'll have fun trying to find a way to keep all the entities within easy reach (as in I can quickly grab a list of available entities that have been assimilated and check to see who is missing on the fly). Wish me cookie dough!
And the pickles frolicked with the waffles, joyously
[This message has been edited by Dudymas (edited March 30, 2004).]