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 - minirop

Pages: 1 [2] 3
16
General discussions / Re: SFML for PS3?
« on: July 27, 2012, 10:51:08 am »
maybe. how do indies do for games on the PSN ?

17
General discussions / Re: SFML 2.0 RC
« on: July 09, 2012, 10:48:15 pm »
the « problem » is that :
    enum Key
    {
        A,            ///< The A key
nothing before so A == 0.
So something like :
    enum Key
    {
        Unknown,
        A,            ///< The A key
should be enough (?)

18
SFML projects / Re: SFML2 V8 JavaScript Binding
« on: July 01, 2012, 10:49:39 am »
I tested with MinGW but didn't encounter the problem.
mingw is very permissive. do you use options ? you should use some like :
Quote
-Wall -Wextra -Wwrite-strings -Wstrict-prototypes
and you can try the "paranoiac" mode (it can trigger errors/warning in the standard headers) :
Quote
-ansi -O2 -Wchar-subscripts -Wcomment -Wformat=2 -Wimplicit-int -Werror-implicit-function-declaration -Wmain -Wparentheses -Wsequence-point -Wreturn-type -Wswitch -Wtrigraphs -Wunused -Wuninitialized -Wunknown-pragmas -Wfloat-equal -Wundef -Wshadow -Wpointer-arith -Wbad-function-cast -Wwrite-strings -Wconversion -Wsign-compare -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wmissing-noreturn -Wformat -Wmissing-format-attribute -Wno-deprecated-declarations -Wpacked -Wredundant-decls -Wnested-externs -Winline -Wlong-long -Wunreachable-code

19
float is not precise enough for timing.
did you look at the source code ? internally it's a Uint64 (so microseconds) and it's cast to float when asked.
float Time::asSeconds() const
{
    return m_microseconds / 1000000.f;
}
if you really need floating and accuracy, take asMicroseconds and cast it yourself to double.

20
Network / Re: Extracting sf::Int/Uint array from sf::Packet
« on: June 18, 2012, 07:28:46 pm »
you can't extract an array directly, you have to do
packet >> uint8[0] >> uint8[1];

21
System / Re: New line in sf::String
« on: May 07, 2012, 09:19:14 am »
\n works, how do you see that it doesn't work?
I just mixed up everything :-X . I'm on a project where the text is in a file and must be on 1 line.

22
System / Re: New line in sf::String
« on: May 07, 2012, 05:35:40 am »
\n and \t work perfectly, you have to put the right code, 0x0a not just "\n" won't work. I need it too, so I made this function :
Code: [Select]
sf::String evaluateSpecialChars(sf::String string)
{
sf::String tmp;

std::size_t i = 0;
while(i < string.getSize())
{
sf::Uint32 c = string[i];

if(c == '\\')
{
i++;
sf::Uint32 n = string[i];

switch(n)
{
case '\\':
tmp += n;
break;
case 'n':
tmp += '\n';
break;
case 't':
tmp += '\t';
break;
default:
std::cerr << "Error: invalid special char found : " << c << n << std::endl;
}
}
else
tmp += c;

i++;
}

return tmp;
}

23
Btw... The mouse wheel.. why can´t be read at realtime using sf::Mouse?
because it's not like a joystick, a mouse wheel doesn't have a "middle/neutral/whatever" position. it's button-like.

24
Feature requests / Re: Adding optional background color to sf::Text
« on: April 23, 2012, 08:23:59 am »
Ceylo, SFML does handle line-breaks.
Your example is more useful if you want to "highlight" some words (like a selection), so it shouldn't be "global background color" but "setBackgroundColor(sf::Color, int start, int length)" (start being the position of the first character to "highlight").

25
General discussions / New naming convention
« on: January 23, 2012, 08:33:08 pm »
JayArby > a quote I love :
Quote
there is no such thing as 'American English'. There is English and there are mistakes.

anyway, I'm used to "Color" because everybody use it. (except Ogre3D for what I know)

26
General discussions / New graphics API ready
« on: January 07, 2012, 08:49:39 am »
Quote from: "Lee R"
If we're being pedantic, it's worth mentioning that ISO C++ doesn't define anonymous structs, thus the above construct relies on a compiler specific language extension.

C++11 does.

27
General / SFML Intenger to sf::String?
« on: December 26, 2011, 05:02:05 pm »
Quote from: "Zinlibs"
Do you have an idea for that ?

just looked in my headers (mngw 4.5.2), and I have them in bits/basic_string (included by string) with the condition :
Quote
#if (defined(__GXX_EXPERIMENTAL_CXX0X__) && defined(_GLIBCXX_USE_C99) \
     && !defined(_GLIBCXX_HAVE_BROKEN_VSWPRINTF))

you used -std=c++11 ? and what about -std=c++0x ?

28
General / SFML Intenger to sf::String?
« on: December 26, 2011, 04:01:27 am »
Before C+11 : std::ostringstream
Since C+11 : std::to_string

29
SFML projects / Pac Cat
« on: December 22, 2011, 05:02:41 pm »
at least it looks good (no time to test for now). but did you read the "pacman unveiled" in the pacaman thread ?
Basically, does the ghost have different IA ? or they are all "kill pac man" ?

30
General discussions / New graphics API ready
« on: December 03, 2011, 02:32:16 pm »
virtual isn't totally useless for a private member ?
ps : i wasn't in "drawable branch"

Pages: 1 [2] 3
anything