dmail

Members
  • Content count

    927
  • Joined

  • Last visited

Community Reputation

116 Neutral

About dmail

  • Rank
    Advanced Member
  1. [quote name='Michael Tanczos' timestamp='1336771714' post='4939420'] I think in general people are pretty good about contributing in a positive way to a community when they realize the greater good. Wikis \ open source thrive on that idea. [/quote] Ok this is the last time I intend to log in, I have no need for epenis points. I just wanted to ask is the gamedev wiki an example of this? You know the one which tore another community apart?
  2. Clean lua stack

    If you are determining that the stack is not empty via the return value of lua_gc then you are mistaken. The stack is not the only place when memory is used and a separate stack space is given to each C function which Lua calls, for instance there is _G the global table or _ENV the environment table in 5.2 (of which there can be many) and also the registry. Added to this a variable which is on the stack and also stored in another place will not be collected. Rest assured your stack is empty and after such a time that there are no more references to the data, without you doing a gc (never mind 10), the memory will be released.
  3. Why LUA Script ?

    [quote name='falconmick' timestamp='1334114935' post='4930097'] the downvote button is for not agreeing with someones opinion. [/quote] Congratulations, you have earned the award of being downvoted by me again. Grow up, I sent the private message to explain the reason and to tell you it was me that downvoted you please do not use private messages to insult me.
  4. Opening up the tagging system

    So only the OP can add tags? I get a message telling me I am not authorised "invalid credentials - you cannot modify tags".
  5. Why LUA Script ?

    [quote name='falconmick' timestamp='1334079283' post='4929946'] Oh, and the documentation isn't always that helpful, for instance, lua_pcall(L, NumArgs, numRet, 0) when I first started using it I had my numArgs being the number of arguments the function needed, the documentation didn't specify specifically that the function call was also an argument, so it was failing on me. The documentation wasn't wrong, it just wasn't helpful enough for an impatient tiered student as of myself find understand it how it was meant to be. [/quote] Take no notice of this, Lua's documentation is excellent. falconmick maybe you should read the documentation next time it clearly tells you the protocol as lua_pcall links to [url="http://www.lua.org/manual/5.1/manual.html#lua_call"]lua_call[/url] As people are mentioning the speed of Lua compared to C and C++, if this does become a problem you can always you use the excellent and blazingly fast [url="http://luajit.org/"]LuaJIT[/url] which supports quite a lot of platforms now with speed being the same or close to C code. edit: I just can not let it go The Language's name is Lua not LUA,
  6. [quote]"Lua" (pronounced LOO-ah) means "Moon" in Portuguese. As such, it is neither an acronym nor an abbreviation, but a noun. More specifically, "Lua" is a name, the name of the Earth's moon and the name of the language. Like most names, it should be written in lower case with an initial capital, that is, "Lua". Please do not write it as "LUA", which is both ugly and confusing, because then it becomes an acronym with different meanings for different people. So, please, write "Lua" right![/quote] [url="http://www.lua.org/about.html"]http://www.lua.org/about.html[/url]
  7. Alternative to singleton

    [quote name='Potatoman' timestamp='1332086459' post='4923055'] Is a constructor with over 50 arguments 'better code'? [/quote] No it is a code smell that could indicate the class is doing too much.
  8. Locking Down an Application

    [quote][color=#1C2837][size=2]Is there any way to say, limit its permissions to files in a specific folder with no access to things like installed programs and stuff like that?[/quote][/size][/color] [size="2"][color="#1c2837"]If you really must bend over and accept their terms then why not change your way of thinking about it. Let it see what ever it wants, just give it a clean OS so there is nothing you would like to protect.[/color][/size]
  9. OS X question

    [quote name='wood_brian' timestamp='1316822122' post='4865344'] [quote name='dmail' timestamp='1316804014' post='4865247'] [ [quote][color="#1C2837"][size="2"]error: type_traits: No such file or directory[/quote][/size][/color] [color="#1C2837"][size="2"]Yep your compiler does not support C++11, hence this error and some of the others.[/size][/color] [color="#1C2837"][size="2"][/quote] I posted to humor Cornstalks. [/size][/color] [color="#1C2837"][size="2"][quote[/size][/color] [size="2"][color="#1c2837"]Final gcc for 10.5.8 [url="http://www.opensource.apple.com/source/gcc_42/gcc_42-5531/"]http://www.opensourc...42/gcc_42-5531/[/url][/color][/size] [/quote] I'm not sure what to do with that link. [/quote] In that case I wil humour you. It is the "source browser" for the latest gcc version for your OS, you look at it in your browser.
  10. OS X question

    [quote name='wqking' timestamp='1316742708' post='4864973'] The newest free OSX is 10.6. To install new compiler, just download and install the latest XCode which is compatible with 10.6 [/quote] 10.6 is free? You get free updates till the next major version of which 10.5.8 is the last which officially supports PPC CPUs IIRC. [quote][color=#1C2837][size=2]error: type_traits: No such file or directory[/quote][/size][/color] [color=#1C2837][size=2]Yep your compiler does not support C++11, hence this error and some of the others.[/size][/color] [color=#1C2837][size=2] [/size][/color] [color=#1C2837][size=2][quote]error: ISO C++ does not support ‘long long’[/quote][/size][/color] [size="2"][color="#1c2837"]You have a number of options here:[/color][/size] [size="2"][color="#1c2837"]Remove -Wall from the command line.[/color][/size] [size="2"][color="#1c2837"]switch to int64_t[/color][/size] [size="2"][color="#1c2837"]Use the pragma to tell g++ it is a system header and therefore be quiet about it.[/color][/size] [size="2"][color="#1c2837"] [/color][/size] [size="2"][color="#1c2837"]Final gcc for 10.5.8 http://www.opensource.apple.com/source/gcc_42/gcc_42-5531/[/color][/size] [size="2"][color="#1c2837"]Final Xcode 3 version which run on PPC CPU, for this you need to login to apple and download Xcode 3.2.5[/color][/size] [size="2"][color="#1c2837"] [/color][/size] [size="2"][color="#1c2837"] [/color][/size]
  11. Firstly when ever I hear a type which has "manager" as part of it's name, my first reaction is always you are doing it wrong. It sounds like what you want it a Lua reference [1] yet you have to take into account that this reference by default will keep the object alive. [1] http://www.lua.org/manual/5.1/manual.html#luaL_ref
  12. [quote name='IFooBar' timestamp='1314312173' post='4853855'] Aw common dude. I [b]just[/b] saw that MS acknowledged my feedback!! I was not monitoring that thing 24/7 you know... :/ And I was not going to post here that the issue was posted there before I was sure it was actually something solid. But yeah it turns out it's a bug in VC and it'll be resolved in the next version. It would be interesting to see what was going wrong on the backend though. [/quote] FYI the bug report had not been acknowledged as a bug when I added that link. What I am saying is that people suggested to file a bug report and instead of wasting peoples time (as the issue was being looked at by MS) then to state this is what you did. By linking to that report if also allows potential future viewers to see what the outcome was.
  13. [url="https://connect.microsoft.com/VisualStudio/feedback/details/685461/c-compiler-bug-in-certain-situation-involving-using-declaration-and-overloaded-base-member-functions"]https://connect.micr...ember-functions[/url] Issue created on connect, it would have been nice if the OP updated the post to reflect this.
  14. There is a compiler option in Visual Studio (sorry name of it escapes me at the moment) that can remove duplicate functions, ie functions which have similar or same functionality even with different types. I would be wary (or at least check) that the template function name is not changed by this and gives incorrect information about the typename T.