Results 1 to 7 of 7

Thread: error

                  
   
  1. #1
    PSP Mod Creator nomi's Avatar
    Join Date
    Dec 2005
    Location
    Karachi, Pakistan
    Posts
    328
    Rep Power
    0

    Angry error

    This is how much iv dun lttle but i will work on if this much works. the game loads and has a black screen nuthin loads up wat do i do???

    -- Slime Volleyball by Nomi

    System.usbDiskModeActivate()


    player=Image.load("slimeplayer.png")
    player2=Image.load("slimeplayer2.png")
    background=Image.load("Slimecourt.png")

    screenwidth = 480 - player:width()
    screenheight = 272 - player:width()

    while true do

    screen:clear()
    screen:blit(0,0,background, true)
    end

    -- Arrays

    Player = {}
    Player[1] = { x = 30, y = 100 }
    Player2 = {}
    Player[2] = {x = 400, y = 100 }



    function movePlayer()
    pad = Controls.read()
    if pad:left() then
    Player[1].x = Player[1].x - 6
    direction = "left"
    end
    end
    if pad:right() then
    Player[1].x = Player[1].x + 6
    direction = "right"
    end

    function movePlayer2()
    if pad:square() then
    Player[2].x = Player[2].x - 6
    direction2 = "left"
    end
    end
    if pad:circle() then
    Player[2].x = Player[2].x + 6
    direction2 = "right"
    end

  2. #2
    DCEmu Coder dalejrrocks's Avatar
    Join Date
    Feb 2006
    Location
    Alabama
    Age
    34
    Posts
    240
    Rep Power
    71

    Default

    post your source. and we'll look at it. somewhere you have a problem with a variable called image that you're trying to do something with. you probably defined it twice for two different things.. so post your source.

  3. #3
    PSP Mod Creator nomi's Avatar
    Join Date
    Dec 2005
    Location
    Karachi, Pakistan
    Posts
    328
    Rep Power
    0

    Default

    heres ma source now it dont give a image error i juss get a black screen when i try to load the game. what is wrong PLZ help!!!

    -- Slime Volleyball by Nomi

    System.usbDiskModeActivate()


    player=Image.load("slimeplayer.png")
    player2=Image.load("slimeplayer2.png")
    background=Image.load("Slimecourt.png")

    screenwidth = 480 - player:width()
    screenheight = 272 - player:width()

    while true do

    screen:clear()
    screen:blit(0,0,background, true)
    end

    -- Arrays

    Player = {}
    Player[1] = { x = 30, y = 100 }
    Player2 = {}
    Player[2] = {x = 400, y = 100 }



    function movePlayer()
    pad = Controls.read()
    if pad:left() then
    Player[1].x = Player[1].x - 6
    direction = "left"
    end
    end
    if pad:right() then
    Player[1].x = Player[1].x + 6
    direction = "right"
    end

    function movePlayer2()
    if pad:square() then
    Player[2].x = Player[2].x - 6
    direction2 = "left"
    end
    end
    if pad:circle() then
    Player[2].x = Player[2].x + 6
    direction2 = "right"
    end

  4. #4
    PS3 User Gizmo356's Avatar
    Join Date
    Feb 2006
    Age
    33
    Posts
    1,756
    Rep Power
    124

    Default

    put end after the function pad=controls.read()

  5. #5
    DCEmu Coder dalejrrocks's Avatar
    Join Date
    Feb 2006
    Location
    Alabama
    Age
    34
    Posts
    240
    Rep Power
    71

    Default

    -- Slime Volleyball by Nomi
    -- THIS SHOULD BE A WORKING GAME.

    System.usbDiskModeActivate()


    player=Image.load("slimeplayer.png")
    player2=Image.load("slimeplayer2.png")
    background=Image.load("Slimecourt.png")
    -- Arrays

    Player = {}
    Player[1] = { x = 30, y = 100 }
    Player2 = {}
    Player[2] = {x = 400, y = 100 }

    screenwidth = 480 - player:width()
    screenheight = 272 - player:width()

    function movePlayer()
    pad = Controls.read()
    if pad:left() then
    Player[1].x = Player[1].x - 6
    direction = "left"
    end
    if pad:right() then
    Player[1].x = Player[1].x + 6
    direction = "right"
    end
    end

    function movePlayer2()
    if pad:square() then
    Player[2].x = Player[2].x - 6
    direction2 = "left"
    end
    if pad:circle() then
    Player[2].x = Player[2].x + 6
    direction2 = "right"
    end
    end


    while true do

    screen:clear()
    screen:blit(0,0,background, true)
    movePlayer()
    movePlayer2()
    screen:blit (Player[1].x,Player[1].y,player)
    screen:blit (Player[2].x,Player[2].y,player2)


    screen:flip()
    screen:waitVblankStart()
    end

  6. #6
    PSP Mod Creator nomi's Avatar
    Join Date
    Dec 2005
    Location
    Karachi, Pakistan
    Posts
    328
    Rep Power
    0

    Default

    now it gives me a error that sayas
    error:SCRIPT.LUA: 39: loop in gettable
    what do i do now
    -- Slime Volleyball by Nomi

    System.usbDiskModeActivate()


    player=Image.load("slimeplayer.png")
    player2=Image.load("slimeplayer2.png")
    background=Image.load("Slimecourt.png")
    -- Arrays

    Player = {}
    Player[1] = { x = 30, y = 100 }
    Player2 = {}
    Player[2] = {x = 400, y = 100 }

    screenwidth = 480 - player:width()
    screenheight = 272 - player:width()



    function moveplayer()
    pad = Controls.read()
    if pad:left() then
    player[1].x = player[1].x - 6
    direction = "left"
    end
    if pad:right() then
    player[1].x = player[1].x + 6
    direction "right"
    end
    end

    function moveplayer2()
    if pad:square() then
    player[2].x = player[2].x - 6
    direction2 "left"
    end
    if pad:circle() then
    player[2].x = player[2].x + 6
    direction2 = "right"
    end
    end

    while true do

    screen:clear()
    screen:blit(0,0,background,true)
    moveplayer()
    moveplayer2()
    screen:blit(Player[1].x,Player[1].y,player)
    screen:blit(Player[2].x,Player[2].y,player2)


    screen.waitVblankStart()
    screen.flip()
    end

  7. #7
    DCEmu Coder dalejrrocks's Avatar
    Join Date
    Feb 2006
    Location
    Alabama
    Age
    34
    Posts
    240
    Rep Power
    71

    Default

    System.usbDiskModeActivate()


    player=Image.load("slimeplayer.png")
    player2=Image.load("slimeplayer2.png")
    background=Image.load("Slimecourt.png")
    -- Arrays

    Player = {}
    Player[1] = { x = 30, y = 100 }
    Player2 = {}
    Player[2] = {x = 400, y = 100 }

    screenwidth = 480 - player:width()
    screenheight = 272 - player:width()



    function moveplayer()
    pad = Controls.read()
    if pad:left() then
    player[1].x = player[1].x - 6
    direction = "left"
    end
    if pad:right() then
    player[1].x = player[1].x + 6
    direction = "right"
    end
    end

    function moveplayer2()
    if pad:square() then
    player[2].x = player[2].x - 6
    direction2 = "left"
    end
    if pad:circle() then
    player[2].x = player[2].x + 6
    direction2 = "right"
    end
    end

    while true do

    screen:clear()
    screen:blit(0,0,background,true)
    moveplayer()
    moveplayer2()
    screen:blit(Player[1].x,Player[1].y,player)
    screen:blit(Player[2].x,Player[2].y,player2)


    screen.waitVblankStart()
    screen.flip()
    end

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
  •