Hi all, started a diary last night which I plan to update a few times a week depending on my progress.
Comments and ideas very welcome.
Just got the script engine (F'Tang) to a usable state and added a free plain tool and a free cube tool, both working fine and UV mapped too using an easy function. So that screenie shows the very first primitive created with vanmesh
. Gonna have to add a clause that stops inverted polygons being created - not sure how yet, maybe make a function that inverts specified polygons, add it to the script subroutine if I can - but I'll need it anyway for manually fixing interior polygons.
The scripts seem to run quite quickly considering the amount of optimization I haven't done yet, plus the heavy use of Left$, Right$, and Mid$ will be slowing things down, hopefully that'll get fixed soon or I may look into a text handling plugin. In real terms, when creating a plain, it's smooth as silk - a little jerky with the cube because it's updating a lot of verts, but at least the mouse control is spot on to make up for it. There are still a lot of issues with condition handling, but all the math is in place, just adding more functions as I need them for the scripts and scratching my head as to the best way to detect the difference between '>' and '>=', I need a better way of splitting the condition up.
One neat side effect of my lack of error trapping, is that I can vary the amount of variables passed to an internal function, just have to check them inside the function to see if they're used. A typical example might be a select all function, I can use the same function to simply select all the verts, or I can pass upto 32 variables and use it to single out and select verts according to set criteria. Coding script parsers is a pain, actually evaluating formulaes and swapping out variables is straightforward enough, the pain starts with condition checking. I'm thinking of a neat way to add For...Next loops, but I might have to brutalise that in favour of something easier to handle, don't want to have to manually set the control variable before a for...next - it'll just lead to bugs. The formula parse is quite lazy, it'll let me increment variables by simply putting '[VAR]+1', so I might leave for...next for next time
.
The GUI is stable right now, adding proper dialogue functions should be a big step forward because I can then program the rest of the tools, don't see the point in coding a fileselector twice, so I'm holding out for my scripted dialogues to handle that. Currently the dialogue handling is hard coded, that needs scripting but the memory footprint is already in place to hold the setup data, and the functions I have already are pretty general - should get the rest of the dialog controls done relatively quickly. Scripting the dialogues will be a breeze, for example I have it set so I can pass a control command to a dialogue control that is returned when the control has been clicked on - most of the handling will be done using a common variable holding the returned data. Not quite VB's 'On Click' style of handling, but it'll do for a scripting engine. The dialogues will work a bit like the old Excel dialogue boxes, just a grid of data really, so I should probably make a dialogue design tool - if I have time I'd actually prefer to make a proper IDE for F'Tang, but I reckon I'll manage for a while without it. It's so much damn work making a script system that I don't plan on repeating it, F'Tang will be expanded on in the future for different projects, I plan to include a level engine with vanmesh and a game orientated incarnation of F'Tang will be part of that.
This week...
Gonna continue debugging that parser and start on a polyline subroutine, once I have polylines in I can extrude and start doing some real testing. I've been dragging my heels on finishing the GUI in case I had to change it a great deal, but everything seems fine for now so I'll do more work on that, that green blob at the right of the screenie has been mocking me for some time, I should really get it working soon. The other priority is more dialogue functions, and a fileselector script.
Note that the screenshot has been cropped and shows the script subroutine for creating plains, added later with PSP to give an idea of the script functionality.
Screenie will be added shortly...
Van-B
The nature of Monkey was irrepressible!.