jerimo
1037 posts
|
Topic: Game Programming /
getters and setters in other languages
Well in C++ you can make functions to get and set, you can also make pointers to the info, though that means you need to put a dereference to use the data, you could also simply over ride the operator= (or any other operator really) and go through the list of things you could use it for, I guess that could count as a an easy setter/getter you jsut need to write it out once what you need it to do, and not have to deal with it again
|
|
|
jerimo
1037 posts
|
Topic: The Arts /
How can I sell my pixel art online?
16x art means a total of 256 pixels, a dollar a piece means that each pixel is worth a little under half a cent, which quite frankly it is not, full sprite sheets could maybe be worth five dollars if you have full anims done, not a dollar per frame per 16x square
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Deeper Topic (part 4): Examples and advanced techniques
I thought it was quite clear without mention but if you use the keyboard or something other than the timer itself, whilr the timer is not ready it will stop all events of the required types to be deleted, following the component behavior and using the event system itself. True it could be a subclass but then you’d need to make one for each component you made if they haveny special things that are done. With this the component can modify te timer at any poun, and they can bth comunicate to each other if need be, special pickups and the such
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Deeper Topic (part 4): Examples and advanced techniques
You could potentially use a var that counts how many of each components exists in the game, or even your entity could asign the int to the part so that you could if need be ask for a reference to the different parts by asking the entity for its number.
But personally i would make it so that you could easily make a factory of these objects; Each weapon can have a “cooldown” component attached to it. When the weapon fires, or is first created, it would send the amount of time needed to the cooldown, which would request the trigger word of the weapon, after the timer was over it would trigger the event of that weapon.
Components are an interesting way of doing things, but as the image to explain this style goes, its like building with legos, nothing stops you from connecting bricks to things other than the first brick!
If in each component you have a “trigger_word” field, you could use the said timer on virtualy any component that was made
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Deeper Topic (part 3): Events to the rescue!
I don;t know about FD specifically, but normaly IDEs hav an option o folders to look into that are not part of the basic folder tree of your project. IF worse comes to worse and there isn’t just locate where the basic classes that are included with the IDE are and put it all there
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
XNA Team Development
Could you not use a system along the lines of this that way you could easily integrate each of their ‘modules’ into the program, and it would be easily useable for other projects?
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Deeper Topic (part 3): Events to the rescue!
I was debating when to start ‘porting’ all my code to this way of doing things, seeing Ace’s excitement I’ll be starting the second I have time to program lol
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Collision detection fail
Ah, yes tested each way three times, fair enough.
I have ran ten tests using the proposed method using floating points, just to see if t would ever happen, there has nto been a single value that was not perfect, in a million calculations; THey may not happen only in flash, but I don’t seem to be getting any
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Collision detection fail
State a case where it gives a decimal number using the proposed method, and we shall see then?
As for your “output values in the comments” You output one value and yet show three values, unless you are using the three ints you declared, i, t, and x, at which point it also doesn’t make sense, as x should be the same in all instances as you are doing the same thing. So which is it?
I may be reading the code wrong, AS3 is not my language; I abide to C++
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
How Do You Pronounce...
you-int
S-W-F
S-W-C
fla(as in flash)
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Collision detection fail
Originally posted by RTL_Shadow:
(200 – 200 % 32) / 32
why not int(x/tileWidth)
Because this way you get an integer value rather than a floating point and don’t have to deal with decimals; The modulo will give you the extra you need to shave off the original number to get a perfect division of the second argument, so when you do divide you get a simple answer, and need no more becasue you only want to know which tile you are on, not the exact section of the tile, as that would be pointless
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
How Do You Pronounce...
Originally posted by RTL_Shadow:
Car, var, Jason, E C M A Script.
How do you guys pronounce these:
HaXe (hex)
Instantiate (In-stan-tee-ate)
Exactly like ^
h•A(pronounce the letter)•x
in•stan(like the name)•she•ate
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Deeper Topic (part 3): Events to the rescue!
@RTL_Shadow – Using C++ not AS2 ;)
@Drakim – Well yeah, I was just wondering if you had found a way to do it within the components; With a normal way, it makes sense though
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Deeper Topic (part 3): Events to the rescue!
Just a small question here, as to collisions in such a system, How in the world; Normally you go down the list of all things you need to check for collision, and the such, and you make sure to check each possibility only once, in such a system though I seem to not wrap my mind around the fact that without keeping a list of all objects it was checked against it would make every possible check twice, once for both of the objects? ((Objects used very wildly in this context I know, but for simplicity I went along with it))
On a side note, while answering, stay in pseudo code if you are to make some, as AS3 code takes me twice as long to work from, considering I do not use the said language, thanks
Edit: Considering Solsund’s post; I would get lost in rewriting every piece of code again and again; reworking the hierarchy, it becomes annoying quite fast, i must agree!
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Deeper Topic (part 2): Composition over inheritance
Firstly, you should truly make a blog about this, many of us would read it.
Secondly, great points are made, and you explain the concept in an easy to use format, which can be easily ported to other languages.
Thirdly, thank you; I am now realizing how bad my design decisions have been, so I must thank you for the learning experience, I shall be trying this out quite soon! ((PS: I also rather despise the fact, as I now must restart most of my code, but still a good idea to do it now!))
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Reviewing under rated games
Originally posted by GameBuilder15:
Originally posted by Danishdragon:
Another suggestion: …. don’t be as boring as me!
Video presentation I made for an exam:
https://www.youtube.com/watch?v=LHgb0Dk5RB8
also… if you want to cringe, just watch my programming presentations haha >_<
That video was fascinating. I’m not kidding. I didn’t think it was boring.
That wasn’t boring it fit with the informatory tone of the presentation. If you were doing a presentation on unicorns to 8 year olds then yep boring, but apart from it works!
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Java?
WHen I loaded up the game my firewall asked to load and play the java applet form another site, so yes it’s an iframe
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Google Code Jam 2013
Alright, thanks! It’s just to try my hand anyways lol.
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Google Code Jam 2013
I’m not legally allowed to enter, even less win, and because in my province (Quebec) contests are illegal if they do not specifically register with the special ministry here, and no contest can pass if they have any chance, no matter how small of closing down the contest without having a winner, for any reason.
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Google Code Jam 2013
But still a good thing to try anyways!
Do they publically give the questions, or do you need to e in the comp to get them? I’d like to try even though I’m not legally allowed to enter
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
Google Code Jam 2013
I would have attempted if my province was not listed on the black list…
Gotta love Quebec’s reglementation…
|
|
|
jerimo
1037 posts
|
Topic: Collaborations /
Who'd Like to Work
And just what are YOU bringing into the said team?
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
save an object forever [AS2]
Not an AS3 programer, but if you don;t want an object to be loaded the next time, just don’t load it? Check before loading it to see if it should be loaded and voila?
|
|
|
jerimo
1037 posts
|
Topic: Game Programming /
General tips for designing a turn based strategy game
Since this is posted in programming not in the clearly labelled Game Design forum, maybe they meant class design? IDK, just pointing it out that it’s a possibility
|
|
|
jerimo
1037 posts
|
Topic: Game Design /
Tower Defense Themes
Originally posted by Drakim:
200 hours at minimum wage is 1450 dollars. That pathfinding better be pretty amazing.
As for the theme, I think Ace_Blue’s suggestions are pretty nifty. Or do you mean more “gameplay elements” than an actual theme?
Your minimum wage sure is low! Here it would be around $2050
|