Author Topic: Super mario z80  (Read 20194 times)

0 Members and 1 Guest are viewing this topic.

Offline annoyingcalc

  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1953
  • Rating: +140/-72
  • Found in Eclipse.exe
    • View Profile
Re: Help with Mario game
« Reply #15 on: May 08, 2011, 07:08:33 pm »
PLEASE HELP I ADDED A GOOMBA IT DECREASED SPEED HELP AND NO SPRITE COLLISION WITH GOOMBA BUT WITH ? BLOCKS ALSO MAKE A BETTER GOOMBA SPRITE


EDIT:: Look at post before I acidentally posted this

EDIT2:: Oh yeah no double posting and oh yea you quit Axe and Oh yeah I'll stop posting untill a few hours are over
« Last Edit: May 08, 2011, 07:24:12 pm by annoyingorange »
This used to contain a signature.

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55942
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Help with Mario game
« Reply #16 on: May 08, 2011, 07:22:00 pm »
As a rule of thumb: Double (and even triple) posting is not allowed here, unless it has been several hours since your last post. Also I recommend being patient and avoiding all-caps bold text. I am sure someone will be able to help eventually if you give them time. I unfortunately cannot help, though, because I quit Axe 1 year ago.

Ashbad

  • Guest
Re: Help with Mario game
« Reply #17 on: May 08, 2011, 09:20:02 pm »
annoyingorange, heads up, but you're being incredibly inpatient.  I personally don't get fed up with triple posting much, but usually it isn't mixed with 3 other regulation-breakings.  So, please stop and be patient, one post at a time.  Just don't do it again SVP.

Also, it seems as if you need to slow down a bit ;) I would actually look up at some source code for other mario-like games before attempting much more, this is a harder project to take on as your first Axe game.  I wish you good luck, but I'm not sure if you should rush in so soon with this -- however, if you do keep working on it, slow down and ask more specific questions about your problems, we can help you more that way ;)

Offline Michael_Lee

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1019
  • Rating: +124/-9
    • View Profile
Re: Help with Mario game
« Reply #18 on: May 09, 2011, 12:34:51 am »
Here's annoyingorange's code, verbatim:

Code: [Select]
.MARIO
Fix 9
0->A
0->I
0->J
0->P
56->Y
0->X
88->D
56->G
[00007E5A5A7E7EFF]->Pic4
[7E81A58181A5817E]->Pic3
[F0F8908890F090D8]->Pic2
[7E99A5858981897E]->Pic1
Pt-On(X,Y,Pic2
Pt-On(0,48,Pic1)
Pt-On(88,48,Pic1
D-1->D
Pt-On(D,G,Pic4
DispGraph
Lbl MOV
If getKey(54)
    1->J
    Pt-On(X,Y,Pic2
    For(A,0,10)
        ClrDraw
        Y-1->Y
        D-1->D
        Pt-On(X,Y,Pic2
        Pt-On(D,G,Pic4
        DispGraph
    End
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
    If I=0
        D-1->D
        Pt-On(D,G,Pic4
        Pt-On(88,48,Pic1
    Else
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
        Pt-On(88,48,Pic3
    End
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
    If P=0
        D-1->D
        Pt-On(D,G,Pic4
        Pt-On(0,48,Pic1)
        DispGraph
    Else
        D-1->D
        Pt-On(D,G,Pic4
        Pt-On(0,48,Pic3
        DispGraph
    End
    DispGraph
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
    If (X>88) and (J=1)
        1->I
    End
    DispGraph
    If (X<9) and (J=1)
        1->P
    End
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
    For(B,0,10)
        ClrDraw
        Y+1->Y
        Pt-On(X,Y,Pic2
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
        If I=0
            Pt-On(88,48,Pic1
            D-1->D
            Pt-On(D,G,Pic4
            DispGraph
        Else
            Pt-On(88,48,Pic3
            D-1->D
            Pt-On(D,G,Pic4
            DispGraph
        End
        If P=0
            Pt-On(0,48,Pic1
            D-1->D
            Pt-On(D,G,Pic4
            DispGraph
        Else
            Pt-On(0,48,Pic3
            D-1->D
            Pt-On(D,G,Pic4
            DispGraph
        End
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
    End
End
0->J
If getKey(3)
    X+1->X
    ClrDraw
    Pt-On(X,Y,Pic2)
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
    If I=0
        Pt-On(88,48,Pic1
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
    Else
        Pt-On(88,48,Pic3
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
    End
    If P=0
        Pt-On(0,48,Pic1
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
    Else
        Pt-On(0,48,Pic3
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
    End
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
End
If getKey(2)
    X-1->X
    ClrDraw
    Pt-On(X,Y,Pic2)
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
    If I=0
        Pt-On(88,48,Pic1
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
    Else
        Pt-On(88,48,Pic3
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
    End
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
    If P=0
        Pt-On(0,48,Pic1
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
    Else
        D-1->D
        Pt-On(D,G,Pic4
        DispGraph
        Pt-On(0,48,Pic3
    End
    D-1->D
    Pt-On(D,G,Pic4
    DispGraph
End
If getKey(9)
    Goto END
End
Goto MOV
Lbl END
    ClrDraw
    Normal

And a screenie I made with Wabbitemu.

A few quick suggestions (off the top of my head):
> Close all your parenthesis (leaving them causes random bugs)
> Don't use 'Lbl MOV and 'Goto MOV' -- use a 'While' or 'Repeat' loop instead.
> Also, I don't know if this is intentional or not, but it looks like you're constantly updating the screen without ever clearing it: toss in a ClrDraw somewhere in the loop.
« Last Edit: May 09, 2011, 12:38:07 am by Michael_Lee »
My website: Currently boring.

Projects:
Axe Interpreter
   > Core: Done
   > Memory: Need write code to add constants.
   > Graphics: Rewritten.  Needs to integrate sprites with constants.
   > IO: GetKey done.  Need to add mostly homescreen IO stuff.
Croquette:
   > Stomping bugs
   > Internet version: On hold until I can make my website less boring/broken.

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55942
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Help with Mario game
« Reply #19 on: May 09, 2011, 12:36:38 am »
So basically it just quits unexpectedly?

Offline leafy

  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1554
  • Rating: +475/-97
  • Seizon senryakuuuu!
    • View Profile
    • keff.me
Re: Help with Mario game
« Reply #20 on: May 09, 2011, 12:38:19 am »
Looking at the code it just draws sprites according to keypresses, I think.
In-progress: Graviter (...)

Offline Michael_Lee

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1019
  • Rating: +124/-9
    • View Profile
Re: Help with Mario game
« Reply #21 on: May 09, 2011, 12:40:03 am »
I guess so.  From looking at the source, it doesn't look like he intended for that to happen...

Edit: Ninja'd
« Last Edit: May 09, 2011, 12:40:18 am by Michael_Lee »
My website: Currently boring.

Projects:
Axe Interpreter
   > Core: Done
   > Memory: Need write code to add constants.
   > Graphics: Rewritten.  Needs to integrate sprites with constants.
   > IO: GetKey done.  Need to add mostly homescreen IO stuff.
Croquette:
   > Stomping bugs
   > Internet version: On hold until I can make my website less boring/broken.

Offline TIfanx1999

  • ಠ_ಠ ( ͡° ͜ʖ ͡°)
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 6173
  • Rating: +191/-9
    • View Profile
Re: Help with Mario game
« Reply #22 on: May 09, 2011, 02:30:54 am »
@Annoyingorange: I'm happy that you are trying to learn to program, however; it might be a good idea to start with something simpler first. Learning from other peoples programs is a good way to get experience as well. You can look at their code and change things bit by bit and learn how things work. :) I would also suggest typing in full sentences, and making sure to express complete thoughts. It will make it much easier for people to understand you, and it wil be easier for them to provide you with help. =)

Offline Netham45

  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2103
  • Rating: +213/-4
  • *explodes*
    • View Profile
Re: Help with Mario game
« Reply #23 on: May 09, 2011, 06:01:05 am »
And, making your questions more specific helps us help you quite a bit.

Something like
Quote
Why does this code only execute 4 times?
Code: (Problematic Code) [Select]
5->a
while (a>1)
...
a-1->a
end

is a LOT more helpful than

PLEASE HELP I ADDED A GOOMBA IT DECREASED SPEED


Possibly post a small piece of code and ask for possible optimizations, too?
Omnimaga Admin

Offline aeTIos

  • Nonbinary computing specialist
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3915
  • Rating: +184/-32
    • View Profile
    • wank.party
Re: Help with Mario game
« Reply #24 on: May 09, 2011, 10:55:47 am »
Also, of course does adding more objects decrease speed :)
I'm not a nerd but I pretend:

Offline BrownyTCat

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 420
  • Rating: +37/-8
    • View Profile
Re: Help with Mario game
« Reply #25 on: May 09, 2011, 11:29:45 am »
I always run multiple copies of a program and test suspicious areas while keeping the others the "fixed variable" of the experiment, since usually I pass spare time with AXE and obviously have no net access on my calculator. Try using the good old-fashioned scientific method.

Offline aeTIos

  • Nonbinary computing specialist
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3915
  • Rating: +184/-32
    • View Profile
    • wank.party
Re: Help with Mario game
« Reply #26 on: May 09, 2011, 11:31:29 am »
Scientific method?? You mean trial and error?
also, the general name is Axe or axe, just for your typing ease :P
I'm not a nerd but I pretend:

Ashbad

  • Guest
Re: Help with Mario game
« Reply #27 on: May 09, 2011, 01:25:29 pm »
Scientific method?? You mean trial and error?

Indeed :) with all programminh, you need to test the outputs of a program at least once.  Unless you're Kevin Flynn and therefore a programming god, or Tony Stark and miraculously make high-tech information systems without programming at all.

Offline aeTIos

  • Nonbinary computing specialist
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3915
  • Rating: +184/-32
    • View Profile
    • wank.party
Re: Help with Mario game
« Reply #28 on: May 09, 2011, 01:33:52 pm »
lol cuz we're the coders of tomorrow we should program.
I'm not a nerd but I pretend:

Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: Help with Mario game
« Reply #29 on: May 09, 2011, 04:26:43 pm »
Why don't you start with something easier.  For instance, you could try to make this game (it starts at about one minute in; press [Enter] to jump, and if you hit the ? block, you kill Mario).  If you could get this to work, then you'd be on your way to being able to easier make a full Mario game. :)  Good luck! ;D