Seite 201 von 342 ErsteErste ... 101 151 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 251 301 ... LetzteLetzte
Zeige Ergebnis 6.001 bis 6.030 von 10238

Lua Programming Help Thread

This is a discussion on Lua Programming Help Thread within the PSP Development Forum forums, part of the PSP Development, Hacks, and Homebrew category; help plz any i need to port the bible to LUA...

  
  1. #6001
    QJ Gamer Green
    Points: 6.446, Level: 52
    Level completed: 48%, Points required for next Level: 104
    Overall activity: 0%

    Registriert seit
    Jan 2007
    Ort
    beside my PC
    Beiträge
    520
    Points
    6.446
    Level
    52
    Downloads
    0
    Uploads
    0

    Standard

    help plz any i need to port the bible to LUA



  2. #6002
    QJ Gamer Green
    Points: 11.800, Level: 71
    Level completed: 38%, Points required for next Level: 250
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Ort
    Middle Europe
    Beiträge
    1.281
    Points
    11.800
    Level
    71
    Downloads
    0
    Uploads
    0

    Standard

    so... whats your problem... post code or something
    Geändert von myschoo (03-08-2007 um 01:55 PM Uhr)

  3. #6003
    Developer
    Points: 4.205, Level: 41
    Level completed: 28%, Points required for next Level: 145
    Overall activity: 0%

    Registriert seit
    Oct 2006
    Ort
    San Diego
    Beiträge
    177
    Points
    4.205
    Level
    41
    Downloads
    0
    Uploads
    0

    Standard Ok

    Zitat Zitat von ai3gtmc
    help plz any i need to port the bible to LUA
    So what do you need help with? Lua's pretty easy to figure out.

  4. #6004
    .info
    Points: 15.395, Level: 80
    Level completed: 9%, Points required for next Level: 455
    Overall activity: 0%

    Registriert seit
    Jun 2006
    Ort
    ACT, Australia
    Beiträge
    1.674
    Points
    15.395
    Level
    80
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von ai3gtmc
    help plz any i need to port the bible to LUA
    If you have it in .txt format, use this code


    y = 10

    file = io.open("bible.txt","r")

    for line in file:lines() do
    y = y + 10
    screenrint(100,y,line,white)
    end

    file:close()

    -= Double Post =-
    Zitat Zitat von Access_Denied
    I have a modified version of Lua that can write to the flash0. It's really easy to do. But if I released it, we would have hundreds of bricked PSPs. That's why it will probably never be implemented. I would learn C if you want to write to the flash0.
    GIMME GIMME GIMME!!
    Geändert von Yongobongo (03-08-2007 um 02:53 PM Uhr) Grund: Automerged Doublepost

    http://www.yongobongo.com
    PSN - yongobongo

  5. #6005
    lol
    Points: 20.859, Level: 91
    Level completed: 2%, Points required for next Level: 491
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    Whittier, CA
    Beiträge
    5.791
    Points
    20.859
    Level
    91
    Downloads
    0
    Uploads
    0

    Standard

    He doesnt have it no more Yongobongo, i already asked :P
    ai3gtmc- if you really want to port it, Learn LUA.

  6. #6006
    .info
    Points: 15.395, Level: 80
    Level completed: 9%, Points required for next Level: 455
    Overall activity: 0%

    Registriert seit
    Jun 2006
    Ort
    ACT, Australia
    Beiträge
    1.674
    Points
    15.395
    Level
    80
    Downloads
    0
    Uploads
    0

    Standard

    Oh poo.

    http://www.yongobongo.com
    PSN - yongobongo

  7. #6007
    Points: 3.782, Level: 38
    Level completed: 88%, Points required for next Level: 18
    Overall activity: 0%

    Registriert seit
    Dec 2006
    Beiträge
    32
    Points
    3.782
    Level
    38
    Downloads
    0
    Uploads
    0

    Standard

    is there than nobody dat has it? or can make it?

  8. #6008
    lol
    Points: 20.859, Level: 91
    Level completed: 2%, Points required for next Level: 491
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    Whittier, CA
    Beiträge
    5.791
    Points
    20.859
    Level
    91
    Downloads
    0
    Uploads
    0

    Standard

    If you know C you can make it, Just edit LUA Player's source.

  9. #6009
    .info
    Points: 15.395, Level: 80
    Level completed: 9%, Points required for next Level: 455
    Overall activity: 0%

    Registriert seit
    Jun 2006
    Ort
    ACT, Australia
    Beiträge
    1.674
    Points
    15.395
    Level
    80
    Downloads
    0
    Uploads
    0

    Standard

    Thats the problem - i have little knowledge of C And luaplayer is C++

    http://www.yongobongo.com
    PSN - yongobongo

  10. #6010
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    Heh... Id bewilling to quickly implement flashing capabilities. If you use it the wrong way, your fault. Atleast it'd teach you not to go poking around where you dont belong.

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here


  11. #6011
    .info
    Points: 15.395, Level: 80
    Level completed: 9%, Points required for next Level: 455
    Overall activity: 0%

    Registriert seit
    Jun 2006
    Ort
    ACT, Australia
    Beiträge
    1.674
    Points
    15.395
    Level
    80
    Downloads
    0
    Uploads
    0

    Standard

    SG, check your pm plz ;)

    http://www.yongobongo.com
    PSN - yongobongo

  12. #6012
    QJ Gamer Green
    Points: 11.800, Level: 71
    Level completed: 38%, Points required for next Level: 250
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Ort
    Middle Europe
    Beiträge
    1.281
    Points
    11.800
    Level
    71
    Downloads
    0
    Uploads
    0

    Standard

    yeah do it :) thx! :)

  13. #6013
    QJ Gamer Bronze
    Points: 9.316, Level: 64
    Level completed: 89%, Points required for next Level: 34
    Overall activity: 0%

    Registriert seit
    Sep 2006
    Ort
    Denmark
    Beiträge
    664
    Points
    9.316
    Level
    64
    Downloads
    0
    Uploads
    0

    Standard

    If the end of my menu code looks like this:

    if menustatus == 1 then
    screen:clear()
    screen:blit(0, 0, menu)
    screen.flip()
    if pad:cross() then
    presslay()
    screenrint(130,130, "The test worked!", white)
    screen.flip()
    end
    end

    if menustatus == 2 then
    screen:clear()
    screen:blit(0, 0, menu2)
    screen.flip()
    if pad:cross() then
    presslay()
    screen.waitVblankStart(60 )
    dofile("credits.lua")
    end
    end

    if menustatus == 3 then
    screen:clear()
    screen:blit(0, 0, menu3)
    screen.flip()
    if pad:cross() then
    presslay()
    screen.waitVblankStart(60 )
    System.Quit()
    end
    end

    if menustatus <= 0 then
    menustatus = 3
    end

    if menustatus >= 4 then
    menustatus = 1
    end
    ... and im going to add another function, let's say USB Connect, would it look like this?

    if menustatus == 1 then
    screen:clear()
    screen:blit(0, 0, menu)
    screen.flip()
    if pad:cross() then
    presslay()
    screenrint(130,130, "The test worked!", white)
    screen.flip()
    end
    end

    if menustatus == 2 then
    screen:clear()
    screen:blit(0, 0, menu2)
    screen.flip()
    if pad:cross() then
    presslay()
    screen.waitVblankStart(60 )
    dofile("credits.lua")
    end
    end

    if menustatus == 3 then
    screen:clear()
    screen:blit(0, 0, menu3)
    screen.flip()
    if pad:cross() then
    presslay()
    screen.waitVblankStart(60 )
    System.Quit()
    end
    end

    if menustatus == 4 then
    screen:clear()
    screen:blit(0, 0, menu4)
    screen.flip()
    if pad:cross() then
    presslay()
    screen.waitVblankStart(60 )
    SystemUsbDiskModeActivate ()
    end
    end

    if menustatus <= 0 then
    menustatus = 4
    end

    if menustatus >= 5 then
    menustatus = 1
    end
    My PSP Projects:
    ___________________
    None.

  14. #6014
    lol
    Points: 20.859, Level: 91
    Level completed: 2%, Points required for next Level: 491
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    Whittier, CA
    Beiträge
    5.791
    Points
    20.859
    Level
    91
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von SG57
    Heh... Id bewilling to quickly implement flashing capabilities. If you use it the wrong way, your fault. Atleast it'd teach you not to go poking around where you dont belong.
    Thanks!
    That will be awesome!

  15. #6015
    QJ Gamer Green
    Points: 11.800, Level: 71
    Level completed: 38%, Points required for next Level: 250
    Overall activity: 0%

    Registriert seit
    Jul 2006
    Ort
    Middle Europe
    Beiträge
    1.281
    Points
    11.800
    Level
    71
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von gameo
    If the end of my menu code looks like this:



    ... and im going to add another function, let's say USB Connect, would it look like this?
    its:

    Code:
    System.usbDiskModeActivate()
    and use CODE not QUOTE, or atleast disable smilies

  16. #6016
    QJ Gamer Blue
    Points: 4.918, Level: 44
    Level completed: 84%, Points required for next Level: 32
    Overall activity: 0%

    Registriert seit
    Sep 2006
    Ort
    6ft. Down Underground........Oh and guess what my avatar is
    Beiträge
    387
    Points
    4.918
    Level
    44
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von SG57
    Heh... Id bewilling to quickly implement flashing capabilities. If you use it the wrong way, your fault. Atleast it'd teach you not to go poking around where you dont belong.
    if you do it plz send me a copy, i was going to learn C to do this when i got the dreeded psptoolchain on my comp....but i hnever could get it installed right, even following the tuts....ill keep trying tho

  17. #6017
    QJ Gamer Blue
    Points: 4.561, Level: 43
    Level completed: 6%, Points required for next Level: 189
    Overall activity: 0%

    Registriert seit
    May 2006
    Beiträge
    224
    Points
    4.561
    Level
    43
    Downloads
    0
    Uploads
    0

    Standard

    yea i could never get all the c stuff to work ever either
    i thought i finally got it once but no

  18. #6018
    QJ Gamer Blue
    Points: 7.014, Level: 55
    Level completed: 32%, Points required for next Level: 136
    Overall activity: 0%

    Registriert seit
    Jan 2007
    Ort
    U.S.
    Beiträge
    405
    Points
    7.014
    Level
    55
    Downloads
    0
    Uploads
    0

    Standard

    Yeah it's really annoying..I haven't been successful yet.

  19. #6019
    QJ Gamer Blue
    Points: 4.561, Level: 43
    Level completed: 6%, Points required for next Level: 189
    Overall activity: 0%

    Registriert seit
    May 2006
    Beiträge
    224
    Points
    4.561
    Level
    43
    Downloads
    0
    Uploads
    0

    Standard

    if i create a function in one script, can i use that the function already created in a different script?

  20. #6020
    QJ Gamer Gold
    Points: 11.942, Level: 71
    Level completed: 73%, Points required for next Level: 108
    Overall activity: 0%

    Registriert seit
    Nov 2006
    Ort
    ...
    Beiträge
    2.080
    Points
    11.942
    Level
    71
    Downloads
    0
    Uploads
    0

    Standard

    i think so if you put=
    Code:
    dofile(yourscriptnamehere.lua)
    in the new different scrpit that doesnt have the function that you made

  21. #6021
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    Everyone wanting flashing capabilities in Lua, look at the thread i created that has a modded lua player for it.

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here


  22. #6022
    .info
    Points: 15.395, Level: 80
    Level completed: 9%, Points required for next Level: 455
    Overall activity: 0%

    Registriert seit
    Jun 2006
    Ort
    ACT, Australia
    Beiträge
    1.674
    Points
    15.395
    Level
    80
    Downloads
    0
    Uploads
    0

    Standard

    Thanks so much SG57!

    http://www.yongobongo.com
    PSN - yongobongo

  23. #6023
    QJ Gamer Blue
    Points: 4.369, Level: 42
    Level completed: 10%, Points required for next Level: 181
    Overall activity: 0%

    Registriert seit
    Feb 2007
    Beiträge
    246
    Points
    4.369
    Level
    42
    Downloads
    0
    Uploads
    0

    Standard

    anyone have a link to a good tutorial on using the 3d gu?

  24. #6024
    QJ Gamer Blue
    Points: 4.561, Level: 43
    Level completed: 6%, Points required for next Level: 189
    Overall activity: 0%

    Registriert seit
    May 2006
    Beiträge
    224
    Points
    4.561
    Level
    43
    Downloads
    0
    Uploads
    0

    Standard

    thanks sg57!

    and by the way, i have released my newest version the super mario bros. portable, so check the forum for that as many of you already have. thanks!

  25. #6025
    QJ Gamer Blue
    Points: 4.369, Level: 42
    Level completed: 10%, Points required for next Level: 181
    Overall activity: 0%

    Registriert seit
    Feb 2007
    Beiträge
    246
    Points
    4.369
    Level
    42
    Downloads
    0
    Uploads
    0

    Standard

    Searching through this thread, I found an old post by Yaustar with this bit of code:

    Code:
    RED_COLOUR = Color.new( 255, 0, 0 );
    
    SQUARE_POLYGON = 
    {
    	{ RED_COLOUR, -0.5,  0.5, -1.0 },
    	{ RED_COLOUR,  0.5,  0.5, -1.0 },
    	{ RED_COLOUR,  0.5, -0.5, -1.0 },
    	
    	{ RED_COLOUR,  0.5, -0.5, -1.0 },
    	{ RED_COLOUR, -0.5, -0.5, -1.0 },
    	{ RED_COLOUR, -0.5,  0.5, -1.0 }
    };
    
    local gRotationAngle = 0;
    
    while true do	
    	Gu.start3d();
    	Gu.clearDepth( 0 );
    	Gu.clear( Gu.COLOR_BUFFER_BIT + Gu.DEPTH_BUFFER_BIT );
    	Gum.matrixMode( Gu.PROJECTION );
    	Gum.loadIdentity();
    	
    	Gum.perspective(75, 16/9, 0.5, 1000);
    
    	Gum.matrixMode( Gu.VIEW );
    	Gum.loadIdentity();
    
    	Gum.matrixMode( Gu.MODEL );
    	Gum.loadIdentity();
    
    	Gu.disable( Gu.TEXTURE_2D );	
    	Gum.translate(0, 0, -3.5);
    	Gum.rotateXYZ( 0, 0, gRotationAngle * ( Gu.PI / 180.0 ) );	
    	Gum.drawArray( Gu.TRIANGLES, Gu.COLOR_8888 + Gu.VERTEX_32BITF + Gu.TRANSFORM_3D, SQUARE_POLYGON );	
    	Gu.end3d();
    
    	screen.waitVblankStart();
    	screen.flip();	
    	
    	gRotationAngle = gRotationAngle + 1;
    	
    	if Controls.read():start() then
    		break;
    	end
    end

    I've been looking all over, but all I've been able to find are lists of the gu functions, with no info on what each one does or how to use them.

    Can someone explain how this works, and what I would need to do to make it display a tile image instead of a red square?

  26. #6026
    QJ Gamer Green
    Points: 6.520, Level: 52
    Level completed: 85%, Points required for next Level: 30
    Overall activity: 0%

    Registriert seit
    Nov 2005
    Ort
    Sweden
    Beiträge
    460
    Points
    6.520
    Level
    52
    Downloads
    0
    Uploads
    0

    Standard

    What do you guys get from you FPS counter when your script is not doing much? What i get is 60 FPS, i just printed the FPS string, nothing more.
    [CENTER]Some of my homebrew Applications/Games:
    [URL=http://forums.qj.net/showthread.php?t=47294&page=1&pp=10]Planet Fighter[/URL] | [URL=http://forums.qj.net/showthread.php?p=641672#post641672]Graphic Creator (V2.0)[/URL] | [URL=http://forums.qj.net/showthread.php?p=512717]Fire Pong[/URL] | [B][URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html#post1430891"][COLOR="Red"][SIZE="3"]Brushes v2.0[/COLOR][/SIZE][/B][/URL] [URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html"][B][SIZE="2"][COLOR="Black"]Released![/COLOR][/SIZE][/B][/URL]
    [URL="http://haxxblaster.2u.se/"][COLOR="black"][FONT="Arial Black"]www.HaxxBlaster.com[/FONT][/COLOR][/URL]

    [URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html"][IMG]http://img19.imageshack.us/img19/1346/brushesbannerqz3.png[/IMG][/URL][/CENTER]

  27. #6027
    QJ Gamer Silver
    Points: 10.263, Level: 67
    Level completed: 54%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jun 2006
    Ort
    UK
    Beiträge
    2.326
    Points
    10.263
    Level
    67
    Downloads
    0
    Uploads
    0

    Standard

    60 fps is the maximum since that is the screens max refresh rate (60 hz). If you want to get 'more', then don't call waitForVSync but the display will look VERY weird.

  28. #6028
    QJ Gamer Green
    Points: 6.520, Level: 52
    Level completed: 85%, Points required for next Level: 30
    Overall activity: 0%

    Registriert seit
    Nov 2005
    Ort
    Sweden
    Beiträge
    460
    Points
    6.520
    Level
    52
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von yaustar
    60 fps is the maximum since that is the screens max refresh rate (60 hz). If you want to get 'more', then don't call waitForVSync but the display will look VERY weird.
    "waitForVSync"? I made my own FPS counter without looking at others code, this is what i came up with. You just need to call the function, no variables needed.

    Code:
    function FPS()
    if fps==nil then
    timer=Timer.new()
    fps=0
    lastfps=0
    end
    timer:start()
    if timer:time() > 1000 then
    timer:reset()
    lastfps=fps
    fps = 0
    return lastfps
    else
    fps=fps+1
    return lastfps
    end
    end
    [CENTER]Some of my homebrew Applications/Games:
    [URL=http://forums.qj.net/showthread.php?t=47294&page=1&pp=10]Planet Fighter[/URL] | [URL=http://forums.qj.net/showthread.php?p=641672#post641672]Graphic Creator (V2.0)[/URL] | [URL=http://forums.qj.net/showthread.php?p=512717]Fire Pong[/URL] | [B][URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html#post1430891"][COLOR="Red"][SIZE="3"]Brushes v2.0[/COLOR][/SIZE][/B][/URL] [URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html"][B][SIZE="2"][COLOR="Black"]Released![/COLOR][/SIZE][/B][/URL]
    [URL="http://haxxblaster.2u.se/"][COLOR="black"][FONT="Arial Black"]www.HaxxBlaster.com[/FONT][/COLOR][/URL]

    [URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html"][IMG]http://img19.imageshack.us/img19/1346/brushesbannerqz3.png[/IMG][/URL][/CENTER]

  29. #6029
    QJ Gamer Silver
    Points: 10.263, Level: 67
    Level completed: 54%, Points required for next Level: 187
    Overall activity: 0%

    Registriert seit
    Jun 2006
    Ort
    UK
    Beiträge
    2.326
    Points
    10.263
    Level
    67
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von HaxxBlaster
    "waitForVSync"? I made my own FPS counter without looking at others code, this is what i came up with. You just need to call the function, no variables needed.
    Vblank/VSync whatever. The call that everyone uses to wait for the screen to finish drawing every frame limits the FPS to the screen's refresh rate of 60hz which is 60 fps. Removing this call will mean that the game will run as fast as it can but you will end up with a VERY flickerly display.

  30. #6030
    QJ Gamer Green
    Points: 6.520, Level: 52
    Level completed: 85%, Points required for next Level: 30
    Overall activity: 0%

    Registriert seit
    Nov 2005
    Ort
    Sweden
    Beiträge
    460
    Points
    6.520
    Level
    52
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von yaustar
    Vblank/VSync whatever. The call that everyone uses to wait for the screen to finish drawing every frame limits the FPS to the screen's refresh rate of 60hz which is 60 fps. Removing this call will mean that the game will run as fast as it can but you will end up with a VERY flickerly display.
    Well, i know. I've just never used "waitForVSync".
    [CENTER]Some of my homebrew Applications/Games:
    [URL=http://forums.qj.net/showthread.php?t=47294&page=1&pp=10]Planet Fighter[/URL] | [URL=http://forums.qj.net/showthread.php?p=641672#post641672]Graphic Creator (V2.0)[/URL] | [URL=http://forums.qj.net/showthread.php?p=512717]Fire Pong[/URL] | [B][URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html#post1430891"][COLOR="Red"][SIZE="3"]Brushes v2.0[/COLOR][/SIZE][/B][/URL] [URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html"][B][SIZE="2"][COLOR="Black"]Released![/COLOR][/SIZE][/B][/URL]
    [URL="http://haxxblaster.2u.se/"][COLOR="black"][FONT="Arial Black"]www.HaxxBlaster.com[/FONT][/COLOR][/URL]

    [URL="http://forums.qj.net/f-psp-development-forum-11/t-release-brushes-v20-99207.html"][IMG]http://img19.imageshack.us/img19/1346/brushesbannerqz3.png[/IMG][/URL][/CENTER]


 

Tags for this Thread

Forumregeln

  • Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
  • Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
  • Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
  • Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.
  •  





Alle Zeitangaben in WEZ -8. Es ist jetzt 09:01 PM Uhr.

Use of this Web site constitutes acceptance of the TERMS & CONDITIONS and PRIVACY POLICY
Copyright © , Caputo Media, LLC. All Rights Reserved. Cluster .