1. Post #4121
    Everyone has a $1 title
    Dj-J3's Avatar
    November 2008
    6,557 Posts
    Change your name to Garry'); DROP TABLE Donators;--
    I'm pretty sure they sanitize the string before.
    Reply With Quote Edit / Delete Sweden Show Events Funny Funny x 3Optimistic Optimistic x 2Agree Agree x 1 (list)

  2. Post #4122
    Gold Member
    katbug's Avatar
    January 2010
    3,961 Posts
    Cool. There seem to be some that quickly slide to different places though. Why is that?

    Also, maybe you could put hats on the arrows to complete the experience
    demoman rush. and is this live updating?

    EDIT: and teleporters
    Reply With Quote Edit / Delete United States Show Events

  3. Post #4123
    Gold Member
    esalaka's Avatar
    July 2007
    9,603 Posts
    I'm pretty sure they sanitize the string before.
    Having a middle name like that would still be awesome.
    Reply With Quote Edit / Delete Finland Show Events Agree Agree x 4 (list)

  4. Post #4124
    Gold Member
    Maya2008's Avatar
    September 2008
    1,664 Posts
    did some benchmarking on performance:
    Type Pieces Ticks [second]
    Uniform 20 0
    Uniform 32 0
    Uniform 64 0
    Uniform 100 0
    Uniform 128 0
    Uniform 256 0
    Uniform 512 1
    Uniform 1024 3
    Uniform 2048 6
    Uniform 4096 11
    Uniform 8192 22
    Point 32 0
    Point 64 0
    Point 128 0
    Point 256 1
    Point 512 1
    Point 1024 3
    Point 2048 6
    Point 4096 12
    Point 8192 25
    Line 32 0
    Line 64 0
    Line 128 1
    Line 256 1
    Line 512 1
    Line 1024 3
    Line 2048 5
    Line 4096 12
    Line 8192 23
    Plane 32 0
    Plane 64 0
    Plane 128 0
    Plane 256 1
    Plane 512 2
    Plane 1024 3
    Plane 2048 5
    Plane 4096 11
    Plane 8192 23
    Volume 32 0
    Volume 64 0
    Volume 128 0
    Volume 256 1
    Volume 512 2
    Volume 1024 3
    Volume 2048 6
    Volume 4096 11
    Volume 8192 23

    Hardware: 3GHz single thread.

    Since all of them share the same performance, I just plotted one chart:


    It's O(n), n being the pieces you want to get at the end.

    Basically,
    @3GHz, you get n / 400 seconds to shatter.

    and this is my shatter plugin, as a reminder:
    http://www.facepunch.com/threads/107...ttering-Plugin
    Reply With Quote Edit / Delete United States Show Events Programming King Programming King x 1 (list)

  5. Post #4125
    Gold Member
    Robber's Avatar
    January 2006
    5,350 Posts
    I'm pretty sure they sanitize the string before.
    They're using App Engine anyway. They'd have to try pretty hard to make SQL injection possible there since it doesn't even use SQL.
    Reply With Quote Edit / Delete Austria Show Events Funny Funny x 10Programming King Programming King x 1 (list)

  6. Post #4126
    DeadKiller987's Avatar
    September 2010
    1,068 Posts
    I'm pretty sure they sanitize the string before.
    I was trying to be funny and reference an xkcd comic...
    Reply With Quote Edit / Delete Lithuania Show Events

  7. Post #4127
    Gold Member
    Jallen's Avatar
    December 2007
    7,199 Posts
    Change your name to Garry'); DROP TABLE Donators;--
    Yeah lets try and fuck with indie game devs who were kind enough to offer out their games for any price and allow you to choose what goes to charity / to the devs etc. They really deserve it, right? Besides, they're too smart to forget about safeguarding against SQL injection.
    Reply With Quote Edit / Delete United States Show Events Dumb Dumb x 21Funny Funny x 1Late Late x 1Agree Agree x 1 (list)

  8. Post #4128
    Neigh
    CarlBooth's Avatar
    June 2007
    24,695 Posts
    In that case it might be because my Camera doesn't roll.

    I wasn't planning to implement it either, I just added roll for completeness.
    Reply With Quote Edit / Delete United Kingdom Show Events

  9. Post #4129
    open.gl
    Overv's Avatar
    February 2007
    7,431 Posts
    Besides, they're too smart to forget about safeguarding against SQL injection.
    Even the guys who made MySQL did at some point.
    Reply With Quote Edit / Delete Netherlands Show Events Funny Funny x 7Agree Agree x 4Zing Zing x 1 (list)

  10. Post #4130
    sLysdal's Avatar
    December 2008
    272 Posts
    Yup, Mysql.com was compromised... by SQL injections...
    http://techie-buzz.com/tech-news/mys...injection.html

    Thats kinda ironic..
    Reply With Quote Edit / Delete Denmark Show Events Late Late x 18 (list)

  11. Post #4131
    Strong Member
    thelinx's Avatar
    January 2007
    8,019 Posts
    Yup, Mysql.com was compromised... by SQL injections...
    http://techie-buzz.com/tech-news/mys...injection.html

    Thats kinda ironic..
    ALL MY CLOCKS
    Reply With Quote Edit / Delete Sweden Show Events Funny Funny x 5Agree Agree x 1 (list)

  12. Post #4132
    Gold Member
    BlkDucky's Avatar
    May 2008
    6,136 Posts
    Yeah lets try and fuck with indie game devs who were kind enough to offer out their games for any price and allow you to choose what goes to charity / to the devs etc. They really deserve it, right? Besides, they're too smart to forget about safeguarding against SQL injection.
    It was obviously a joke. Don't take it so seriously. D:
    Reply With Quote Edit / Delete United Kingdom Show Events Agree Agree x 6 (list)

  13. Post #4133
    Shrapnel :3's Avatar
    October 2009
    412 Posts
    In that case it might be because my Camera doesn't roll.

    I wasn't planning to implement it either, I just added roll for completeness.
    Then use quaternions for completeness. There is no point in opening yourself to reuse, then having to change it if you do use it again.
    Reply With Quote Edit / Delete United Kingdom Show Events Agree Agree x 2 (list)

  14. Post #4134
    This title has been removed due to a copyright claim from Viacom Inc.
    neos300's Avatar
    July 2008
    3,404 Posts
    Huh, when I do this it works fine
    std::string h = file.ReadString();
    int i = file.ReadInt();
    std::cout << "VAL:" << h << ":" << i << std::endl;

    But if I do
    std::cout << "VAL:" << file.ReadString() << ":" << file.ReadInt() << std::endl;

    I'm using a quick custom binary file io library (technically it's a wrapper of fstream that deals with the complications of my file format) so that's whats up with the weird names.
    Reply With Quote Edit / Delete United States Show Events

  15. Post #4135
    open.gl
    Overv's Avatar
    February 2007
    7,431 Posts
    That's because file.ReadInt() is executed first.
    Reply With Quote Edit / Delete Netherlands Show Events Informative Informative x 1 (list)

  16. Post #4136
    xAustechx's Avatar
    July 2009
    584 Posts
    It was obviously a joke. Don't take it so seriously. D:
    Yeah, what's your problem jall?
    Reply With Quote Edit / Delete United States Show Events Funny Funny x 2Optimistic Optimistic x 1Dumb Dumb x 1 (list)

  17. Post #4137
    COMEDY POLICE
    Xerios3's Avatar
    January 2009
    1,687 Posts
    do multiple uniform shadow samples for eye sex.



    I even added this fancy dialog box to my map editor
    Reply With Quote Edit / Delete Belgium Show Events Programming King Programming King x 11Artistic Artistic x 1 (list)

  18. Post #4138
    Gold Member
    BlkDucky's Avatar
    May 2008
    6,136 Posts
    Are those... numbers in the bottom right?

    1337?
    Reply With Quote Edit / Delete United Kingdom Show Events Winner Winner x 11Agree Agree x 1 (list)

  19. Post #4139
    xAustechx's Avatar
    July 2009
    584 Posts
    Are those... numbers in the bottom right?

    1337?
    What a huge coincidence.
    Reply With Quote Edit / Delete United States Show Events

  20. Post #4140
    COMEDY POLICE
    Xerios3's Avatar
    January 2009
    1,687 Posts
    Are those... numbers in the bottom right?

    1337?
    Yeah, it's actually written on the map :V:
    Reply With Quote Edit / Delete Belgium Show Events Programming King Programming King x 1 (list)

  21. Post #4141
    T3hGamerDK's Avatar
    January 2011
    2,551 Posts
    Just began writing a map generator. I'm thinking about using a JSON parser for whatever needs be saved.
    Code:
    {'seed': 'T3hGamerDK', 'mapdata': {'xyz': '1024,1024,2048'}, 'entity': {'xyz': '3,400,-10', 'type': 'player_spawn'}}
    Seed is used to generate the map.
    The "xyz" of "mapdata" is the size of the maps. Most of this stuff is just random and arbitrary, to give an idea of how things are going to look.
    Do you guys think this is a good idea?
    I'm thinking about doing an editor for it too, because I won't be needing to load entire maps, I just generate all that shit on the fly :D
    Reply With Quote Edit / Delete Denmark Show Events Informative Informative x 1 (list)

  22. Post #4142
    Interesting that you say that. Friend.
    NorthernGate's Avatar
    August 2007
    3,373 Posts


    Physics and a pretty camera are complete :D
    Reply With Quote Edit / Delete United States Show Events Programming King Programming King x 5Artistic Artistic x 4Winner Winner x 1 (list)

  23. Post #4143
    Gold Member
    bobthe2lol's Avatar
    July 2007
    1,363 Posts
    I need some help with passing params (C# params that is) to lua's ... . What i'm currently doing, is I have a method in C# that takes a params object[] args and passes args directly into lua via
    GetFunction("name").call(args);
    But the problem with this is that all of the args are of type object, or System.Object and since lua is dynamicly typed there is no casting. My question is, if the function that has the params as the arguments is called
    CallLua(String name, params object[] args)
    and I call it by doing
    CallLua("LFunc", "Bahaha!!");
    and in lua I have
    function LFunc(haha) print(haha) end
    it prints "System.Object [43952345(or some other number]" instead of "Bahahaha!!!". How do I get lua to convert (cast...?) it to a string?

    By the way, this code

    Code:
    Hook.Register('OnLoad','Unique',function()
    	print('Generating grid.')
    	Offset = 8;
    	MaxX = GetWidth()/16;
    	MaxY = GetHeight()/16;
    	for x=Offset,16*MaxX,16 do
    		for y=Offset,16*MaxY,16 do
    			if x==Offset or y==Offset or x==(16*MaxX)-Offset or y==(16*MaxY)-Offset then
    				AddBody('rect',params({x,y,16,16}))
    			end
    		end
    	end
    	circ = AddBody('circle',params({GetWidth()/2,GetHeight()/2,50,function(b1,b2)
    		print('Yay, collisions!')
    	end}))
    	circ.IsStatic = false
    	circ.Restitution = 1.1
    end)
    produces this:

    Reply With Quote Edit / Delete United States Show Events Programming King Programming King x 1 (list)

  24. Post #4144
    Richy19's Avatar
    May 2010
    4,851 Posts
    Does anyone have any experience with libGDX or Slick library?
    Really dont know whic to go for
    Reply With Quote Edit / Delete United Kingdom Show Events

  25. Post #4145
    Interesting that you say that. Friend.
    NorthernGate's Avatar
    August 2007
    3,373 Posts
    Did a quick video to show some of the more movement oriented bits:


    Sorry for the low quality :C
    Reply With Quote Edit / Delete United States Show Events Programming King Programming King x 3Artistic Artistic x 1 (list)

  26. Post #4146
    Gold Member
    BlkDucky's Avatar
    May 2008
    6,136 Posts
    Did a quick video to show some of the more movement oriented bits:


    Sorry for the low quality :C
    I love living in the future.
    "Hm. I kinda like the music in that video."
    5 minutes later. Bam. I had obtained several albums through perfectly legit sources.
    Reply With Quote Edit / Delete United Kingdom Show Events Funny Funny x 6 (list)

  27. Post #4147
    Moustach3's Avatar
    March 2011
    299 Posts
    Did a quick video to show some of the more movement oriented bits:


    Sorry for the low quality :C

    That's great programming music.
    Reply With Quote Edit / Delete United States Show Events Friendly Friendly x 3Dumb Dumb x 1 (list)

  28. Post #4148
    Interesting that you say that. Friend.
    NorthernGate's Avatar
    August 2007
    3,373 Posts
    That's great programming music.
    The band is Uh Huh Her, and the song is Dreamer if you want to give it a better listen :)
    Reply With Quote Edit / Delete United States Show Events Friendly Friendly x 2 (list)

  29. Post #4149
    Gold Member
    ThePuska's Avatar
    October 2005
    3,137 Posts
    I just spent an hour trying to figure out why my quaternions weren't working. Turns out I hadn't noticed that a + b ^ c is evaluated as (a + b) ^ c instead of a + (b ^ c).

    Which is bad because I'd overloaded ^ to stand for the cross product.

    Remember, kids: don't misuse your operators.
    Reply With Quote Edit / Delete Finland Show Events

  30. Post #4150
    xenodrox's Avatar
    February 2010
    311 Posts
    Aha! Just wrote a proof of concept for building a dynamic array of pointers to todo objects. This has been giving me trouble. I just have to tweak it so that it works with todo objects being read from a binary file and I'll have saving and loading finished for my todo program!
    Reply With Quote Edit / Delete United States Show Events

  31. Post #4151
    Gold Member
    ZenX2's Avatar
    February 2009
    3,907 Posts
    I implemented text entry controls to TopWise, things are getting texty up in here.
    Reply With Quote Edit / Delete United States Show Events

  32. Post #4152
    ~ ducks ~
    Kwaq's Avatar
    April 2011
    1,850 Posts
    Uhh I plan on moving from upgrading from console applications in C++ and adding something to look at.

    What do you think I should move on to? SDL? Or is there something else I need to learn first?
    Reply With Quote Edit / Delete United Kingdom Show Events

  33. Post #4153
    T3hGamerDK's Avatar
    January 2011
    2,551 Posts
    Uhh I plan on moving from upgrading from console applications in C++ and adding something to look at.

    What do you think I should move on to? SDL? Or is there something else I need to learn first?
    You could move straight to SDL or SFML if you feel like it. If things seems to complex, just come back later :)
    Reply With Quote Edit / Delete Denmark Show Events

  34. Post #4154
    Gold Member
    Dr Magnusson's Avatar
    July 2008
    2,642 Posts
    SFML is probably the easiest graphics library you're gonna find, especially if you're familiar with Gmod Lua as they use a very similar style.
    Reply With Quote Edit / Delete Denmark Show Events Agree Agree x 5Informative Informative x 1 (list)

  35. Post #4155

    March 2009
    104 Posts
    I need some help with passing params (C# params that is) to lua's ... . What i'm currently doing, is I have a method in C# that takes a params object[] args and passes args directly into lua via
    GetFunction("name").call(args);
    But the problem with this is that all of the args are of type object, or System.Object and since lua is dynamicly typed there is no casting. My question is, if the function that has the params as the arguments is called
    CallLua(String name, params object[] args)
    and I call it by doing
    CallLua("LFunc", "Bahaha!!");
    and in lua I have
    function LFunc(haha) print(haha) end
    it prints "System.Object [43952345(or some other number]" instead of "Bahahaha!!!". How do I get lua to convert (cast...?) it to a string?

    By the way, this code

    Code:
    Hook.Register('OnLoad','Unique',function()
    	print('Generating grid.')
    	Offset = 8;
    	MaxX = GetWidth()/16;
    	MaxY = GetHeight()/16;
    	for x=Offset,16*MaxX,16 do
    		for y=Offset,16*MaxY,16 do
    			if x==Offset or y==Offset or x==(16*MaxX)-Offset or y==(16*MaxY)-Offset then
    				AddBody('rect',params({x,y,16,16}))
    			end
    		end
    	end
    	circ = AddBody('circle',params({GetWidth()/2,GetHeight()/2,50,function(b1,b2)
    		print('Yay, collisions!')
    	end}))
    	circ.IsStatic = false
    	circ.Restitution = 1.1
    end)
    produces this:

    You probably just misstyped this but:

    CallLua("LFunc", "Bahaha!!");

    shouldn't that be:

    CallLua("LFunc", {"Bahaha!!"});

    because it's an array, right?
    Another thing, if I remember this correctly (which I probably don't) you shouldn't need to have it like a param, object[] should be enough. I am not certain though.
    Reply With Quote Edit / Delete Sweden Show Events

  36. Post #4156
    Icedshot's Avatar
    April 2010
    2,044 Posts


    Improved my sun a little
    Reply With Quote Edit / Delete United Kingdom Show Events Artistic Artistic x 4Winner Winner x 2 (list)

  37. Post #4157
    Gold Member
    Xera's Avatar
    November 2006
    3,089 Posts
    You probably just misstyped this but:

    CallLua("LFunc", "Bahaha!!");

    shouldn't that be:

    CallLua("LFunc", {"Bahaha!!"});

    because it's an array, right?
    Another thing, if I remember this correctly (which I probably don't) you shouldn't need to have it like a param, object[] should be enough. I am not certain though.
    No, it automatically passes every argument after the named arguments into the array.
    Reply With Quote Edit / Delete United Kingdom Show Events

  38. Post #4158
    Gold Member
    redonkulous's Avatar
    August 2008
    1,742 Posts
    Hooray for four hours of straight coding until late at night to get me game engine done. It is so beautiful.
    Reply With Quote Edit / Delete United States Show Events Winner Winner x 3 (list)

  39. Post #4159
    Gold Member
    bobthe2lol's Avatar
    July 2007
    1,363 Posts
    You probably just misstyped this but:

    CallLua("LFunc", "Bahaha!!");

    shouldn't that be:

    CallLua("LFunc", {"Bahaha!!"});

    because it's an array, right?
    Another thing, if I remember this correctly (which I probably don't) you shouldn't need to have it like a param, object[] should be enough. I am not certain though.
    public void TestFunction(params object[] args){
        foreach(Object obj in args){
            Console.out.writeline(obj.ToString());
        }
    }
    
    TestFunction("a","b","c","d","e",10);
    
    prints
    Code:
    a
    b
    c
    d
    e
    10
    Just FYI
    Reply With Quote Edit / Delete United States Show Events Informative Informative x 1 (list)

  40. Post #4160
    Gold Member
    Loli's Avatar
    April 2008
    2,263 Posts
    Guys... Garry's been 1 Up-ed... http://www.humblebundle.com/
    $2000.02
    Reply With Quote Edit / Delete United Kingdom Show Events Funny Funny x 35Zing Zing x 3Informative Informative x 3 (list)