Results 1 to 10 of 10

Thread: Lua Error

                  
   
  1. #1

    Default Lua Error

    Im getting a lua error of global timer 'timer' a nil value
    what is that.
    And when it says the line
    like lua:script.lua:10
    do you count spaces or not.

  2. #2
    GP2X Coder/Moderator
    Join Date
    Jan 2006
    Posts
    1,678
    Rep Power
    83

    Default

    a) It means that 'timer' variable was created but not given a value yet.

    b) Yes, you count blank lines. Use Crimson Editor or another text editor that shows line numbers.

  3. #3
    DCEmu Coder MasterChafed's Avatar
    Join Date
    Jul 2005
    Location
    Colorado
    Age
    33
    Posts
    832
    Rep Power
    90

    Default

    i use Text editor, all you press is alt-g and type the line with the error and it goes right to it. It also has a nifty find and replace feature.
    http://one.revver.com/watch/170516
    http://one.revver.com/watch/167200

    Please click the links above to watch my stick figure animations,
    and please, if you have the time, click the ads at the end to earn me some money.

  4. #4
    DCEmu Coder ninja9393's Avatar
    Join Date
    Dec 2005
    Location
    Space Pirate Homeworld
    Age
    33
    Posts
    1,028
    Rep Power
    82

    Default

    ConTEXT is also a good text editor

  5. #5
    GP2X Coder/Moderator
    Join Date
    Jan 2006
    Posts
    1,678
    Rep Power
    83

    Default

    Text Editor is not freeware and ConTEXT had problems with line wrap last time I used it.

    Notepad2 is the lightest weight one that I have used but lacks sytanx highlighting for Lua.

    PsPad Editor is my weapon of choice. Syntax highlighting for various languages, diff, spell checking, splitviews on the same file and a ton more features. Free as well.

  6. #6
    DCEmu Pro jman420's Avatar
    Join Date
    Oct 2005
    Location
    Colorado, USA
    Posts
    756
    Rep Power
    72

    Default

    I think that all you have to do is add () after you declare your "timer"

    timer()

    at least thats the same error I got when I tried to call

    "player"

    without the ()

    and when it tells you what line its on, thats the line, even if lines 1 - 9 are empty

    and personaly, I use microsoft wordpad lol...

  7. #7
    DCEmu Old Pro BL4Z3D247's Avatar
    Join Date
    Jun 2006
    Location
    BL4Z3D 24/7 in CT
    Posts
    1,970
    Rep Power
    80

    Default

    cool i've been gettin that error for a couple days and now i know why lol i was drivin me crazy

  8. #8

    Default

    Is it possible to make 3d games in lua

  9. #9
    PSP User Apoklepz's Avatar
    Join Date
    Oct 2005
    Location
    Bottom of The Pit
    Posts
    1,542
    Rep Power
    76

    Default

    To answer your last question, Yes it is possible to make 3D games in Lua...There's samples in the DCemu Lua Downloads page...I advise you check them out.

  10. #10
    DCEmu Pro jman420's Avatar
    Join Date
    Oct 2005
    Location
    Colorado, USA
    Posts
    756
    Rep Power
    72

    Default

    also, I just got (from Apoklepz) a GMax 2 PSP plugin for GMax, that supposedly allows for 3D models to be used on Lua. I havent tried it yet, but when I do I will make a thread about how to use it (if I can figure it out:P)

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •