Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Serapth

Pages: 1 ... 3 4 [5] 6 7
61
General / Visual Studio Buffer Overrun
« on: January 02, 2012, 09:06:19 pm »
Quote from: "Dekuzora"
Thank you so much! It works now perfectly. I am glad that there are some people who know what they're doing when it comes to this, because I certainly don't.



Dont worry, knowledge comes from slamming your head off your desk over and over, so consider those bumps and bruises a good thing. :)

62
General / Packaging my open source game with SFML questions
« on: January 02, 2012, 08:19:17 pm »
SFML is released under perhaps the most permissive license in existence.

http://www.sfml-dev.org/license.php


With the following addition:

SFML - Copyright (c) 2007-2008 Laurent Gomila

This software is provided 'as-is', without any express or
implied warranty. In no event will the authors be held
liable for any damages arising from the use of this software.

Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:

1. The origin of this software must not be misrepresented;
   you must not claim that you wrote the original software.
   If you use this software in a product, an acknowledgment
   in the product documentation would be appreciated but
   is not required.

2. Altered source versions must be plainly marked as such,
   and must not be misrepresented as being the original software.

3. This notice may not be removed or altered from any
   source distribution.



So basically, don't try to take credit for being the author of SFML, if you change the source to SFML in any way ( not derived products ), you need to make it clear you have altered SFML, and include the license details in your code.  




Quote

If so, can someone give me a zipped folder of a Visual Studio project/solution that includes all of the SFML library, and all of the files automatically configured in the linker, and all of the .dll files placed in the runtime folder?



The project files included at the end of each chapter of my C++/SFML tutorial  does exactly this.  It makes the project files a fair bit bigger, as all of SFML and the supporting libraries are included in each zip, but fortunately a new developer can simply download, unzip and double click the SLN file.

 
This particular zip file contains virtually no code, just a preconfigured project with SFML, libraries/DLLs compiled for VS 2010,  the linker and include settings configured properly, etc.  It weighs in at 8MB.  You can probably work from there as a base.


/EDIT:  On thing to be aware of, that code only configures the DEBUG build.  It's up to the user to go through the configuration process if they want a RELEASE build.  Although the instructions ( as described in part 1 ) are virtually identical for a release build.

63
General / Visual Studio Buffer Overrun
« on: January 02, 2012, 07:39:25 pm »
You can download them pre-compiled here if you want.  Link at pages bottom, but being new the page and the one after it might be handy to you any ways.

Compiling them yourself isn't really a big task, but there are some gotchas you will run into.

64
General / Re: State Machines
« on: January 02, 2012, 04:01:39 pm »
Quote from: "StormWingDelta"
I've got something useful for you Serapth if you can wrap your mind around what a state machine is.

http://
https://sites.google.com/site/onlinegameworkcjr/useful-things


The two things there those two files should help with the AI.
This code is from Digipen's game engine FunEditor1.5 so most of the codes in it are useless unless you know what you are doing.

The .txt file shows the code from the inside of a state machine I had to make for pong and I thought it might give you some ideas on how to fix up your AI in this game.

The other file is a code of the C# engine that they use in Microsoft Visual C++ 2010 Express and in mostly DirectX code if I remember right.  It has a few things that could be used to make a state machine in a compiler and has one already made and in use.  Just look for the state machine codes in these files and you should get some idea of how to make a state machine of some kind. :)


The only reason I have these things is because I'm in a game design class that has connections to Digipen. :)


Thanks StormWingDelta, I will take a look.


It's not so much that AI is broken at this point; it simply hasn't been implemented.  At this point it is just a stub, I ran out of room.  Then again, in Pong, one of the keys to AI is actually making it stupid in believable ways, as frankly an AI controlled paddle will never miss.

65
General / SFML Complete Game Tutorial
« on: January 02, 2012, 02:17:44 am »
Quote from: "Lee R"
Quote from: "Serapth"
Part 9 is now online


I haven't looked at your code in any detail, but a quick look revealed at least four memory leaks. You're new'ing up exceptions (why?) but attempt to catch them by reference.




Oops.


The why is easy, it was a mistake.  :oops:


The why of the why is also easy, I've spent far too long using C#, and you develop a certain muscle memory when typing code...

Thanks for the catch, fixing.  One other potential leak was actually on purpose and will be resolved in the next chapter.

66
General / SFML Complete Game Tutorial
« on: January 01, 2012, 02:02:53 am »
Part 9 is now online


This part of the tutorial deals with playing sf::Music and sf::Sound objects using a (simple) caching system.  In addition it implements the AI paddle with some exceedingly stupid AI, although no collision detection.  Along the way it explores the C++ topics of exception handling and templates.



Next chapter we will be polishing things up a bit. fixing a flaw or two, adding a score board and will be much closer to a full game.  As always, any and all feedback appreciated.[/url]

67
General / [ANSWERED] Window not showing up (perhaps ATI-related)
« on: December 07, 2011, 09:22:26 pm »
Quote from: "purkskis"
I get BSOD when adding that DLL  :lol:



This is really odd, that's the 3rd time i've heard that in the last month, and never before that.  Did you by chance recently upgrade drivers?  If so, what revision, OS ( including bitness) and what card are you running?

Also, does it still bluescreen when run within VS, or just when run directly?

68
General / [ANSWERED] Window not showing up (perhaps ATI-related)
« on: December 05, 2011, 05:56:57 am »
Quote from: "Legion"
Oh, that's a bummer. I guess I'll have to wait patiently for 2.0 then. Thank you very much for the fast answer.



The fix is in that thread you posted, simply add that DLL to your run directory and everything will work fine.  Otherwise you can see details here.

69
General / Problem with moving/turning a sprite in cursor direction
« on: December 01, 2011, 02:45:15 am »
Quote from: "lapayo"
Thanks for the reply :)
The 45/PI was for adding 90 degress to the angle.



45/pi is 14.3 ( or a meaningless number in radians )

90 degrees is pi/2 or 1.57 radians.



EDIT: As you have expressed things, 14.3 radians is 819.3 degrees.  So I suppose once translated back to an angle that will become ( I am guessing here, 819.3%360 ) or 99.3 degrees, which is why your code *kinda* works, even though it is logically wrong, by happy coincidence, your odd ball value is resolving reasonably close to the value you want.

70
General / SFML 1.6 in visual C++ 2010
« on: November 29, 2011, 09:20:28 pm »
Wierd, I swore I responded to this already...

Anyways, my C++ with SFML tutorial covers this in detail, especially this part.  So if you cant get going from atomical's instructions, my link is extremely detailed on setting up VS2k10 with SFML 1.6

71
General / SFML Complete Game Tutorial
« on: November 15, 2011, 12:03:08 am »
Quote from: "P@u1"
I really like your tutorials.

In the last one I found a thing you should change:
Code: [Select]
#include <string.h>
should be
Code: [Select]
#include <string> instead.

If you include it with the .h it is not placed in the std:: namespace afaik.




You are right, it should have been <string>, more to the matter, it shouldn't even be there.  I think its merely left overs from some code I was messing about with or possibly a code completion mistake...  I am a bit haphazard with my includes...  

Either way, its been updated.

72
General / SFML Complete Game Tutorial
« on: November 14, 2011, 09:39:14 pm »
Chapter 8 is now live and can be accessed here and the post summary is available here.


This chapter is a bit... different.  So far as I have ever seen, I have never really seen another game tutorial post like this one.  It covers using audio ( poorly ) and in fact shows how to use a library other than SFML ( sorry Laurent :) ) for audio, as an option anyways.  Most importantly, almost all of the code is absolute garbage.

Sound interesting? ;)


This chapter is more about design than code and if you are fairly new to programming in an OO style, I hope it is enlightening.

On the other hand, you may absoluely hate this chapter and want me to never go off track like this again.  Please read it and let me know which way you lean!


There is another post, one that shows how to more properly use SFML audio, so don't worry about that part.  It is nearly complete and should be live very shortly.

73
General / SFML Complete Game Tutorial
« on: November 11, 2011, 02:40:02 pm »
Thanks for the kind words, they are very much appreciated.

The next two chapters are very much in the works and should be released soon.  To be completely honest I am not really sure how well the next chapter will be taken, as it goes off slightly into unexplored territory, which is why I am releasing two chapters at once... don't like it, skip it! ;)

I would have been done a while ago, but I got a bit distracted by PlayN, shiny new toys are always a major distraction for me!  All said though, I should have them up in the next couple days.  I have to, my Skyrim order arrives today...  ooooh Shiny!

74
Audio / sf::Sound by value
« on: November 10, 2011, 07:52:43 pm »
Hello all,

I just want to verify, SoundBuffer is heavy and should be cached, but sf::Sound itself is light weight and passing it by value should not be a big deal, right?

75
General / SFML Complete Game Tutorial
« on: October 31, 2011, 05:53:43 pm »
Oops, but of a bug crept in in PlayerPaddle, at the end change the "Bounce" test to :

Code: [Select]
if(pos.x  <= GetSprite().GetSize().x/2
|| pos.x >= (Game::SCREEN_WIDTH - GetSprite().GetSize().x/2))
{
_velocity = -_velocity; // Bounce by current velocity in opposite direction
}


It should have be <= and >=, otherwise on the condition of == 0, the paddle can get stuck to the wall.  Oops.[/code]

Pages: 1 ... 3 4 [5] 6 7