Old School
I have decided to make an old school game, in Macromedia Flash. The game is similar to Ant Attack but much more artistic and with a much more interesting plot and many more capabilities. […]
I have decided to make an old school game, in Macromedia Flash. The game is similar to Ant Attack but much more artistic and with a much more interesting plot and many more capabilities. […]
I think Ant is great, except when it comes to logical thinking. The classpath and path and pathelement and path-like structures lack even the most elementary logic and are used chaotically according to a non-strict non-structured uneven set of principles. I think this is a huge minus for the XML building script which otherwise looks quite good and plain and logical.
To be more specific, I wonder why can path elements reside ousite of tasks as well as within classpath elements, but not under other path elements? The answer is easy: because the idiotic author considered it to be an expression of his lack on intelligence in that fried brain of his. That’s why!!!
I must say that this is a very simple post for the beginners. My knowledge about sorting is far more scary, and I do not intend to put it into this blog right now ;-)
A good discussion about this topic is worth much more than even a full article, but I think I can just put here the very essence of the story, I repeat, for newbies. Ever since computers and ever since math, the concept of sorting was introduced and defined. OK. As far as a small programmer should be concerned, there are two types of sorting involved:
1. Sorting by one field
2. Sorting by n fields
For the first one there are so many methods, one faster than the other and alltogether slower than what would be ideal. It’s the second method that raised issues: How can one sort a list of objects, when all these objects must be sorted by several criteria (sg. criterion) and they provide fields for each?
A simple approach would seem to be to sort them for each criterion, that is to sort them several times. But no, you can’t because you would scramble the previous sorting this way. You must assign costs to the elements based on the criterion’s importance and combine the costs for each criterion in a n-dimensional valid cost that would hierarchize the list according to the desired way. Then sort with method 1, by a field, where the field is the cost. Simple, he?
If you are interested about sorting in Java, a good article I found here:
http://www.javaworld.com/javaworld/jw-12-2002/jw-1227-sort.html
A nice visual comparsion of various sorting methods would be this:
http://cg.scs.carleton.ca/~morin/misc/sortalg/
Please note, I am not sure for how long these links are going to work… If they become dead, please let me know by commenting… Hopefuly they should work for at least a few years (or should I hope months).
This is a technical note about FlagStone Flash Generation Library. After reviewing several such libraries, I rather use FlagStone to generate SWF content from Java. There you go, you can find them there: http://www.flagstonesoftware.com/. There are some improvements that could be well added to it, such as not only a twip based addressing but also a pixel based coordinate system. Many concepts or techniques could be better wrapped or documented. There are some minor bugs I found with font embedding and lack for latest ActionScript 2 (they only support AS1). Except these, I find it ideal and a great library to work with, very well documented (at least compared to the rest) and support is great. I just asked a question on the forum and the very same day I got the answer. I must say "WOW". This is opensource software by the way. You may use it, write your own librar with it or even add improvements to it (with the author’s permission, of course). I am working on a huge project involving this library, and soon I shall post many more things about it here.