KO2 68000 quiz #2

Talk about EVERYTHING related to Kick Off 1 + 2.

Moderator: Moderators

User avatar
Steve Camber
Mad! 7000+ poster!
Mad! 7000+ poster!
Posts: 7545
Joined: Sat Jun 16, 2001 12:00 am
Location: Sheffield, England
Contact:

KO2 68000 quiz #2

Postby Steve Camber » Wed Sep 14, 2005 12:37 pm

Today's chunk of KO2 code..

Hopefully this one will be easier than yesterday's!

Code: Select all

    CMPI.B    #$61,D4
    BLT.S     jump
    CMPI.B    #$7A,D4
    BGT.S     jump
    ADDI.B    #$E0,D4
jump:
    RTS


Answers in a PM to me please :)
--
SteveC - Kick Off engineer - Ranked somewhere waaaay down the list
18 Dec 2003 - "One day I'm going to disassemble the 68000 code, and find out exactly what's going on in there!! "

Ask me about online KO2 :)
User avatar
JamesHBeard
The guru!
The guru!
Posts: 13807
Joined: Mon Jun 11, 2001 12:00 am
Location: The Forest Of Dean, United Kingdom
Contact:

Postby JamesHBeard » Wed Sep 14, 2005 1:26 pm

Replied
WC - QF 2001,2002, SilverCup Winner 2006, Best Defence 2006
UKC - Winner 2005
Newent 2008 Championship Winner

Image
Hi ! My name is James and I have been KO2 free since 8th March 2009.
Robert Swift
Moderator
Moderator
Posts: 16357
Joined: Fri Jun 15, 2001 12:00 am

Postby Robert Swift » Wed Sep 14, 2005 1:41 pm

Is it 42 again?
User avatar
Steve Camber
Mad! 7000+ poster!
Mad! 7000+ poster!
Posts: 7545
Joined: Sat Jun 16, 2001 12:00 am
Location: Sheffield, England
Contact:

Postby Steve Camber » Wed Sep 14, 2005 1:47 pm

No, sorry!
--
SteveC - Kick Off engineer - Ranked somewhere waaaay down the list
18 Dec 2003 - "One day I'm going to disassemble the 68000 code, and find out exactly what's going on in there!! "

Ask me about online KO2 :)
User avatar
Steve Camber
Mad! 7000+ poster!
Mad! 7000+ poster!
Posts: 7545
Joined: Sat Jun 16, 2001 12:00 am
Location: Sheffield, England
Contact:

Postby Steve Camber » Thu Sep 15, 2005 12:38 pm

Any last minute entries?!
--
SteveC - Kick Off engineer - Ranked somewhere waaaay down the list
18 Dec 2003 - "One day I'm going to disassemble the 68000 code, and find out exactly what's going on in there!! "

Ask me about online KO2 :)
User avatar
Steve Camber
Mad! 7000+ poster!
Mad! 7000+ poster!
Posts: 7545
Joined: Sat Jun 16, 2001 12:00 am
Location: Sheffield, England
Contact:

Postby Steve Camber » Thu Sep 15, 2005 1:03 pm

Code: Select all

    CMPI.B    #$61,D4
    BLT.S     jump
    CMPI.B    #$7A,D4
    BGT.S     jump
    ADDI.B    #$E0,D4
jump:
    RTS


This little snippet of code checks if the number is D4 is in the range 97 to 122 and if so adds 224 to it. (As it is using bytes (.B) adding 224 can also be called subtracting 32).

So it converts numbers in the range from 97 to 122 to numbers in the range 65 to 90.

So why would that be of use?!?!

It's easy when you look at an ASCII chart.. 97 to 122 are the characters 'a' to 'z', and 65 to 90 are the characters 'A' to 'Z'.

So the answer is it converts a letter to uppercase! (In KO2 this function is used in the formatting of filenames.)
--
SteveC - Kick Off engineer - Ranked somewhere waaaay down the list
18 Dec 2003 - "One day I'm going to disassemble the 68000 code, and find out exactly what's going on in there!! "

Ask me about online KO2 :)
User avatar
Danny D
4000+ Poster!
4000+ Poster!
Posts: 4765
Joined: Mon Jun 11, 2001 12:00 am
Contact:

Postby Danny D » Thu Sep 15, 2005 1:06 pm

Gay, I thought these were ko2 routines! is the score now Beard 2, everyone else 0 ?
"We are now on the threshold of a newer movement, with a newer hope and a new inspiration."
James Larkin
User avatar
Abyss
Moderator
Moderator
Posts: 5904
Joined: Wed Sep 18, 2002 12:00 am
Location: Athens, Greece
Contact:

Postby Abyss » Thu Sep 15, 2005 1:13 pm

Damn! I should have thought about it.

How many people sent their answers? How many right ones?
User avatar
JamesHBeard
The guru!
The guru!
Posts: 13807
Joined: Mon Jun 11, 2001 12:00 am
Location: The Forest Of Dean, United Kingdom
Contact:

Postby JamesHBeard » Thu Sep 15, 2005 1:40 pm

Surely I got this mother correct Steve.
WC - QF 2001,2002, SilverCup Winner 2006, Best Defence 2006
UKC - Winner 2005
Newent 2008 Championship Winner

Image
Hi ! My name is James and I have been KO2 free since 8th March 2009.
User avatar
Steve Camber
Mad! 7000+ poster!
Mad! 7000+ poster!
Posts: 7545
Joined: Sat Jun 16, 2001 12:00 am
Location: Sheffield, England
Contact:

Postby Steve Camber » Thu Sep 15, 2005 2:19 pm

Jim was the only winner of this quiz! :shock:
--
SteveC - Kick Off engineer - Ranked somewhere waaaay down the list
18 Dec 2003 - "One day I'm going to disassemble the 68000 code, and find out exactly what's going on in there!! "

Ask me about online KO2 :)
User avatar
Danny D
4000+ Poster!
4000+ Poster!
Posts: 4765
Joined: Mon Jun 11, 2001 12:00 am
Contact:

Postby Danny D » Thu Sep 15, 2005 2:21 pm

Steve Camber wrote:Jim was the only winner of this quiz! :shock:
puffs always get these "special" prizes ! I promise you I will win the next one as in the current one as in the one that ends tomorrow.Resign now Jamed.
"We are now on the threshold of a newer movement, with a newer hope and a new inspiration."
James Larkin
User avatar
JamesHBeard
The guru!
The guru!
Posts: 13807
Joined: Mon Jun 11, 2001 12:00 am
Location: The Forest Of Dean, United Kingdom
Contact:

Postby JamesHBeard » Fri Sep 16, 2005 10:35 am

Do not go crying Danny, you know you cannot defeat me at any game we play..including AOE2.. :lol: :lol: :lol: :lol:
WC - QF 2001,2002, SilverCup Winner 2006, Best Defence 2006
UKC - Winner 2005
Newent 2008 Championship Winner

Image
Hi ! My name is James and I have been KO2 free since 8th March 2009.

Who is online

Users browsing this forum: No registered users and 4 guests