• What are you working on? v19
    6,590 replies, posted
[QUOTE=DrLuke;31307429]I don't see a color difference?[/QUOTE] The one in my app is blue'er and the picture viewer one is less blue and a little red. You can check it with an editor. It might just be subtle on your monitor.
[QUOTE=DrLuke;31307429]I don't see a color difference?[/QUOTE] One's blue and one's purple for me :dance:
Until someone has an OP, I won't close this thread.
[QUOTE=Overv;31307617]Until someone has an OP, I won't close this thread.[/QUOTE] Close it in ehh 5 days, 6 hours, 8 minutes and 10 seconds. Then we will know what to put in the thread!
How good is this resource? [url]http://openglbook.com/[/url]
[IMG]http://dl.dropbox.com/u/3077939/AOEII2/0.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/1.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/2.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/3.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/4.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/5.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/6.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/7.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/8.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/9.png[/IMG] I'm working on extracting and converting the AOEII assets. I need to load the palette files to get the colours, and work out a way of storing the player specific colour data in a PNG. It might need to be a separate image and applied in a shader.
Maybe its the compression in windows photoviewer ?
[QUOTE=ColdFusionV2;31308040]Maybe its the compression in windows photoviewer ?[/QUOTE] Windows has this awful feature that displays dark images not the way they are. Firefox has it too but I turned it off I think.
[IMG]http://anyhub.net/file/3FKe-tmpdd44.png[/IMG] The not responding thing is me being lazy and making my main loop while(true) and not handling any events. [editline]24th July 2011[/editline] Whats a good way to render particles on a 2D screen? At the moment I'm using 1 pixel = 1 particle but it's kinda hard to see. [editline]24th July 2011[/editline] Also at the moment it is creating 1 particle per frame until it reaches the limit, is there a better way to do it?
Question. I have an Entity class, and under certain circumstances I want it to not update and draw. Is there some way to do this in the base class? For example, I have entity then drawableEntity, and if some condition is true I want the drawableEntity to not draw. But I want this to work for all subclasses of Entity. I thought of only calling base.Draw/base.Update if the condition is false, but since Entity is a superclass that wouldn't work. For example: [csharp] class Entity : DrawableGameComponent { public GameScreen screen; public SpriteBatch spriteBatch; public Type type; public Entity(GameScreen scrn) : base(scrn.ScreenManager.Game) { screen = scrn; spriteBatch = scrn.ScreenManager.SpriteBatch; } public override void Draw(GameTime gameTime) { if (spriteBatch == null) { spriteBatch = screen.ScreenManager.SpriteBatch; } if(screen.IsActive){allow drawing to happen} else{ don't} base.Draw(gameTime); } public virtual void HandleInput(InputHelper input) { } } [/csharp]
Make the update function: [cpp] void Update(blah) { if(alive) {update2()} } [/cpp]
[QUOTE=neos300;31308716][IMG]http://anyhub.net/file/3FKe-tmpdd44.png[/IMG] The not responding thing is me being lazy and making my main loop while(true) and not handling any events. [editline]24th July 2011[/editline] Whats a good way to render particles on a 2D screen? At the moment I'm using 1 pixel = 1 particle but it's kinda hard to see. [editline]24th July 2011[/editline] Also at the moment it is creating 1 particle per frame until it reaches the limit, is there a better way to do it?[/QUOTE] Lots of sprites, in alpha/additive blending mode. And depending on what kind of effects you need, you should allow your particle system to emit n particles after every x seconds (or just once). For example, for a steam or smoke effect, you might want to emit 1 particle every 0.1 seconds. For a spark burst effect, you might want to emit 10 particles once.
[QUOTE=bobthe2lol;31309218]Question. I have an Entity class, and under certain circumstances I want it to not update and draw. Is there some way to do this in the base class? For example, I have entity then drawableEntity, and if some condition is true I want the drawableEntity to not draw. But I want this to work for all subclasses of Entity. I thought of only calling base.Draw/base.Update if the condition is false, but since Entity is a superclass that wouldn't work. For example: [csharp]code[/csharp][/QUOTE] The method easiest to implement is to have a Base::_Update function called by the engine that calls this->Update() depending on a condition (as neos300 suggested). The method with the smallest 'live' overheard (i.e: what is executed every time Update is called) is to use a lookup table for the functions. In C, the only way to do this is with function pointers. The easiest way to do this in C++ (which is what I assume you're using ([csharp] tags?!?)) is to use virtual methods (which essentially uses function pointers) and override the entries in the virtual table. See [url=http://stackoverflow.com/questions/1542108/how-to-hack-virtual-table/1543353#1543353]this Stack Overflow[/url] anwser. I recommend ignoring the accepted answer; it over does it a bit. You should be able to turn the theory into a utility class (macro.. if you must) that can easily change the virtual table. In case you're not sure, the way you'd use it is to have Entity::Update and Entity::Draw declared as virtual and by default point to the child's active Update and Draw functions. Then have the Base::SetEnabled function change this.Update and this.Draw to point to empty functions when disabling, and change it back to the child's functions when enabling. As it's following a pointer without any condition checking, there is [i][u]very[/u][/i] little overhead.
[QUOTE=simie;31307933][IMG]http://dl.dropbox.com/u/3077939/AOEII2/0.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/1.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/2.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/3.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/4.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/5.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/6.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/7.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/8.png[/IMG][IMG]http://dl.dropbox.com/u/3077939/AOEII2/9.png[/IMG] I'm working on extracting and converting the AOEII assets. I need to load the palette files to get the colours, and work out a way of storing the player specific colour data in a PNG. It might need to be a separate image and applied in a shader.[/QUOTE] Well, I'm assuming that the colour palette is stored in a sane way that points out where the team colours are, a shader would be an excellent way of doing it since you could apply any colour you wanted. That may not fit with whatever art-style you're after, but it's nice to not be hampered by technological or implementation limitations.
snip
[QUOTE=cathal6606;31310920]If any of you guys ever get bored could you do me a favour? Write a simple program which converts a specified youtube video into .mp3 and downloads it.[/QUOTE] Have you considered using Google to use things like listentoyoutube.com or things like that? Surely you can't be asking the programming forum for these things when there's already tons of services like that out there.
A less kludgy way of disabling drawing/updates could be used depending on how you call draw and update and exactly where you want drawing disabled. Say, if you only need to disable drawing on a "world basis" but not on a "peer basis", you would only need to disable the draw call on the "world loop". Here, we are probably iterating through a map of entity indices to entity objects - so we can make a few parallel lists/maps that hold what entities need to be drawn/updated. (To make managing these parallel lists/maps simple, override the methods that create/destroy entities). Now, when we want to draw or update, we iterate the draw or update map instead of the primary map. This also demonstrates a classic time versus space problem-thingamajigger. This method will take up a little more space, but is arguably optimal (arguing that draw/update calls are at least an order of magnitude more frequent than state changes). (Note that we no longer need to iterate through all entities, just the entities that are relevant. If we forget this part, this seems like an all-around bad alternative.) If we wanted to disable "peer calls" (calls from one entity to draw another), we may want to simply redirect the call to the "entity manager". This configuration could also be used to prevent infinite recursion by keeping a draw recursion count on the entity manager draw dispatch method.
[QUOTE=cathal6606;31310920]If any of you guys ever get bored could you do me a favour? Write a simple program which converts a specified youtube video into .mp3 and downloads it.[/QUOTE] That has [url=http://dvdvideosoft.com/products/dvd/Free-YouTube-to-MP3-Converter.htm]never[/url] been done [url=http://rg3.github.com/youtube-dl/]before[/url].
[QUOTE=cathal6606;31310920]If any of you guys ever get bored could you do me a favour? Write a simple program which converts a specified youtube video into .mp3 and downloads it.[/QUOTE] There's a ton of programs like these and some websites dedicated to it. One is literally [URL="http://www.youtubetomp3.com/"]youtubetomp3.com[/URL].
[QUOTE=danharibo;31310368]since you could apply any colour you wanted. .[/QUOTE] That's the plan! Though I think something went wrong with the palette loading... [IMG]http://dl.dropbox.com/u/3077939/AOEII2/0%202.png[/IMG] Better, but still a bit odd: [img]http://dl.dropbox.com/u/3077939/AOEII2/0%203.png[/img]
[QUOTE=simie;31313417]That's the plan! Though I think something went wrong with the palette loading... [IMG]http://dl.dropbox.com/u/3077939/AOEII2/0%202.png[/IMG][/QUOTE] I love AoE II, keep up the nice work. Sprite exports would be incredibly useful :v:
[QUOTE=iNova;31313620]I love AoE II, keep up the nice work. Sprite exports would be incredibly useful :v:[/QUOTE] There are already a lot of tools out there to export/import the data to AoE2, I'm just making my own so I can convert the data directly into formats I need automatically. But thanks :D [editline]24th July 2011[/editline] Sorted! [img]http://dl.dropbox.com/u/3077939/AOEII2/0%204.png[/img] Does anyone remember the name of that resizing algorithm people were experimenting with in this thread a while back? I'd like to try it on these sprites
[QUOTE=simie;31313820]There are already a lot of tools out there to export/import the data to AoE2, I'm just making my own so I can convert the data directly into formats I need automatically. But thanks :D [editline]24th July 2011[/editline] Sorted! [img]http://dl.dropbox.com/u/3077939/AOEII2/0%204.png[/img] Does anyone remember the name of that resizing algorithm people were experimenting with in this thread a while back? I'd like to try it on these sprites[/QUOTE] hq4x?
[QUOTE=iNova;31314180]hq4x?[/QUOTE] That's it, thanks!
DAT ANTI-ALIASING [quote][img]http://img202.imageshack.us/img202/6361/unledpge.png[/img][/quote]
[QUOTE=Richy19;31314638]DAT ANTI-ALIASING[/QUOTE] Dat anti-aliasing, there is barely any. :(
DAT TERRIBLE CRYPTOGRAPHY [media]http://www.youtube.com/watch?v=f3LLt-F_oCs[/media] I didn't notice the Steam sound at first, I just thought I was getting spammed a lot. :v:
Do any german speakers want to have a go at translating the projects on this page? [url]http://www.spieleprogrammierung.net/p/opengl-tutorial-liste.html[/url]
[url]http://www.overvprojects.nl/opengl/[/url] 4 Days :v:
[QUOTE=Loli;31317143][url]http://www.overvprojects.nl/opengl/[/url] 4 Days :v:[/QUOTE] And 20 hours! [editline]25th July 2011[/editline] I've also been working on a game engine, and decided to clean up the code and the dependencies a little. Went from 22% of used dropbox storage to about 15.8%. I really need to watch my space more carefully. Does anyone know if FTPBox is usable as of now?
Sorry, you need to Log In to post a reply to this thread.