Modifié par Borden Haelven, 21 juin 2011 - 09:57 .
Perl script regquest. Two actually.
#26
Posté 21 juin 2011 - 09:53
#27
Posté 21 juin 2011 - 11:21
Sadly what Bannor is looking for is just a bit too complex to really be done there because of variable spacing. Hopefully virusman gets him sorted.
#28
Posté 29 juin 2011 - 04:09
Where you still needing a solution for this Bannor.
I am comming close to a solution for this via HLA.
hopefully I will have time to compleate it tonight after I get home from work.
#29
Posté 29 juin 2011 - 04:42
It is possible to do via my method, but nwscript isnt really made for this so its very tough to script it...
Sh
#30
Posté 29 juin 2011 - 05:18
Actually, having a script would still be useful, but I don't think nwscript can handle it ShaDoOow, I really appreciate you attempting it, but we found too many inconsistancies in the various mdls. IT seems that things can change easily, and are affected by access order/link order in the individual mdl file. So, if I were to open a tile, edit an object, it would change placement of the various options for the graphics bits, the alpha, luminosity, shininess etc... and put those lines in different locations. Likely, that could be changed, all at once, meaning just do a complete replacement of about 8-10 lines of text in the node, and make them all the same, but it just wasn't worth the effort for that.
Olias Stormcrow had a professional text editing apllication that allows for conditional testing, and replacement, he processed the tiles for me manually. His app, whatever it was, could not handle all of the tiles in question, but it did severely cut down on the ones that required manual intervention. This actually turned out to be a good report anyway, as it pointed out some other errors in those specific tiles which required different fixes anyway. Things that likely would have been missed.
Since I only have about 15-20 left to work on, I can handle these by hand now.
Thanks for the offers guys, it is appreciated, but no longer really necessary, although, someone might be able to use a script like that to make mass changes in other tilesets too.
IF you are still interested in attempting this, I can maybe help identify what lines are actually required for each instance, and just make it a quick search for node with bitmap, and replace everything between node and verts in the mdl. Everything after the vert can NOT be changed as it affects the uvw-mapping on the object, and is encoded somehow.
#31
Posté 29 juin 2011 - 07:28
#32
Posté 29 juin 2011 - 07:47
henesua wrote...
What text editor? And was it able to search for regular expressions (GREP)? I've got BBedit in os x but it would handy to see what is used on the windows side.
I don't know what the program actually is, but I was told that the single seat license cost is well over 10,000. So it is not likely something that can be found on the net.
It does a lot more than grep though, it allows batching, and sub-functions like any normal prgramming language. Olias claimed he was able to find the mdl's in the folder, search inside each one, find the nodes that had the proper bitmap assigned, then back process that entire node to find the specific Alpha line and make the necessary changes.
That is why I was originally requesting a perl script, because I know that can be done in a full programming language like perl.
#33
Posté 29 juin 2011 - 08:17
#34
Posté 29 juin 2011 - 09:27
[edit] Stupid question - but do any windows flavors have *nix style text editor apps ported to their command line? vi emacs or the like?
Modifié par henesua, 29 juin 2011 - 09:29 .
#35
Posté 29 juin 2011 - 09:33
#36
Posté 29 juin 2011 - 09:34
#37
Posté 29 juin 2011 - 09:37
#38
Posté 29 juin 2011 - 10:06
#39
Posté 04 juillet 2011 - 06:00
Bannor Bloodfist wrote...
Actually, having a script would still be useful, but I don't think nwscript can handle it ShaDoOow, I really appreciate you attempting it, but we found too many inconsistancies in the various mdls. IT seems that things can change easily, and are affected by access order/link order in the individual mdl file. So, if I were to open a tile, edit an object, it would change placement of the various options for the graphics bits, the alpha, luminosity, shininess etc... and put those lines in different locations....
IF you are still interested in attempting this, I can maybe help identify what lines are actually required for each instance, and just make it a quick search for node with bitmap, and replace everything between node and verts in the mdl. Everything after the vert can NOT be changed as it affects the uvw-mapping on the object, and is encoded somehow.
The system I am still working on writing has no problem with the placements of the KeyWords, As long as the Key Word is the first text on the line. It basicly searches for the KeyWord in this case 'bitmap', then checks to see if the text after it is the correct value. If the value is correct it then searches forward for the end of the node. Then back for the begining of the node. It then searches for the second Key and Value, once the second key if found it checks the value. if it does not match it replaces it.
The current problem that I have ran into is that not all nodes, that have a 'bitmap' key,, have an 'alpha' key. This raises the question. IF the bitmap is found with no alpha in the same node what should be done? Should a Alpha key be added? Would this hurt something that I do not know about?
I do not think it would. I guess the question would be where to add it. In some of the bioware tile sets I have noticed that the alpha key is after the verts with the bitmap key being before them. A verry broad assumption I have is that I could add the key anwhere into the node as long as it is after the bitmap key. Does that sound like a safe assumption to you?
#40
Posté 04 juillet 2011 - 07:31
The alpha line is not a required field, and only shows up on those tiles that have had some sort of adjustment made to the texture, either re-uvw mapping it, or changing one of the other various settings. By default, alpha is "assumed" to be 1.0 by the engine so if the line doesn't exist in the mdl, it just takes the assumed 1.0 state.
There are other lines similar to Alpha that likely could use the same sort of treatment, but I have not investigated them at this stage of things yet.
Code:
scale 1 render 1 shadow 0 beaming 0 inheritcolor 0 rotatetexture 1 alpha 0.8 transparencyhint 1 selfillumcolor 0 0 0 ambient 1 1 1 diffuse 1 1 1 specular 0 0 0 shininess 26 center 0 0 0 bitmap tctl0_water01endcode
I believe several of those are usefull, diffuse settings, shininess, ambient, selfillumcolor, abd inheritcolor all affect the way the texture is rendered. But I also believe that they tend to be defaulted to whatever Bioware originally used. Meaning they may not be required to get a texture to paint.
Modifié par Bannor Bloodfist, 04 juillet 2011 - 07:32 .





Retour en haut






