Omnimaga: The Coders Of Tomorrow
Welcome, Guest. Please login or register.
 
Omnimaga: The Coders Of Tomorrow
20 May, 2013, 15:37:45 *
Welcome, Guest. Please login or register.

Login with username, password and session length
 
   home   news downloads projects tutorials misc forums rules new posts irc about Login Register  
+-OmnomIRC

You must Register, be logged in and have at least 40 posts to use this shout-box! If it still doesn't show up afterward, it might be that OmnomIRC is disabled for your group or under maintenance.

Note: You can also use an IRC client like mIRC, X-Chat or Mibbit to connect to an EFnet server and #omnimaga.

Pages: 1 [2]   Go Down
  Print  
Author Topic: Mirage OS usage - write back  (Read 842 times) Bookmark and Share
0 Members and 1 Guest are viewing this topic.
danny90444
LV3 Member (Next: 100)
***
Offline Offline

Gender: Male
Last Login: 13 February, 2013, 20:28:02
Date Registered: 18 June, 2012, 19:37:24
Location: Across the Universe
Posts: 41


Topic starter
Total Post Ratings: 0

View Profile WWW
« Reply #15 on: 02 July, 2012, 21:08:34 »
0

^r needs to be included if you are using 16-bit integers (0 to 65535) for your score.

OK . is this right ?

Data(100^r,90^r,80^r,70^r,60^r,50^r,40^r,30^r,20^r,10^r,0^r)->GDB1HS
.later...
S->{GDB1HS+10}
sub(SORTD,GDB1HS,11)
.assume SORTD is a subroutine. # of items is 11.

So first 11 items are sent to GDBHS , then the users score is sent to the list and the list is sorted ?
« Last Edit: 02 July, 2012, 21:10:59 by danny90444 » Logged

Schrodinger's cat walks into a bar... and doesn't.
danny90444
LV3 Member (Next: 100)
***
Offline Offline

Gender: Male
Last Login: 13 February, 2013, 20:28:02
Date Registered: 18 June, 2012, 19:37:24
Location: Across the Universe
Posts: 41


Topic starter
Total Post Ratings: 0

View Profile WWW
« Reply #16 on: 02 July, 2012, 21:10:21 »
0

Assume that the SORTD subroutine sorts data in descending order.
I also want to correct something:


1
2
3
4
5
6
Data(100^r,90^r,80^r,70^r,60^r,50^r,40^r,30^r,20^r,10^r,0^r)->GDB1HS
.later...
S->{GDB1HS+10}
sub(SORTD,GDB1HS,11)
.assume SORTD is a subroutine. # of items is 11.
But then, a r is missing after the S->{GDB1HS+10}
Moreover, no need to make a routine if it is only used once. What I suspect is that you wrote sub(SORTD,GDB1HS,11) to say "you must sort it" without giving the proper code Tongue

I personally do it the other way round in MisterOops!
I check how many scores the current score beats, shift them, then insert the new highscore Smiley

Where does that "r" need to be ?
Logged

Schrodinger's cat walks into a bar... and doesn't.
Hayleia
Programming Absol
LV11 Super Veteran (Next: 3000)
***********
Offline Offline

Last Login: Today at 14:39:14
Date Registered: 01 June, 2011, 20:12:47
Location: ud-ud ?
Posts: 2045


Total Post Ratings: +254

View Profile
« Reply #17 on: 02 July, 2012, 21:49:35 »
0

Right behind the S->{GDB1HS+10}
It would be S->{GDB1HS+10}r
Logged





Spoiler for what I am according to...:
me: useless
Pokemon Test: an Absol
turiqwalrus: an eggplant
p2: A HUMAN BEING !
Blackpilar and p2: iplantonlyplantwantplanttoplantknowplantifplantyouplantareplantaplantboyplantorplantaplantgirlplant
click here to know where you got your last +1s
danny90444
LV3 Member (Next: 100)
***
Offline Offline

Gender: Male
Last Login: 13 February, 2013, 20:28:02
Date Registered: 18 June, 2012, 19:37:24
Location: Across the Universe
Posts: 41


Topic starter
Total Post Ratings: 0

View Profile WWW
« Reply #18 on: 02 July, 2012, 22:04:25 »
0

Assume that the SORTD subroutine sorts data in descending order.
I also want to correct something:


1
2
3
4
5
6
Data(100^r,90^r,80^r,70^r,60^r,50^r,40^r,30^r,20^r,10^r,0^r)->GDB1HS
.later...
S->{GDB1HS+10}
sub(SORTD,GDB1HS,11)
.assume SORTD is a subroutine. # of items is 11.
But then, a r is missing after the S->{GDB1HS+10}
Moreover, no need to make a routine if it is only used once. What I suspect is that you wrote sub(SORTD,GDB1HS,11) to say "you must sort it" without giving the proper code Tongue

I personally do it the other way round in MisterOops!
I check how many scores the current score beats, shift them, then insert the new highscore Smiley

So could i use "SORTD("  to sort the list ?
Logged

Schrodinger's cat walks into a bar... and doesn't.
blue_bear_94
LV7 Elite (Next: 700)
*******
Offline Offline

Gender: Male
Last Login: Today at 05:12:16
Date Registered: 09 May, 2012, 02:45:26
Location: Earth
Posts: 582


Total Post Ratings: +3

View Profile
« Reply #19 on: 03 July, 2012, 02:57:03 »
0

Right behind the S->{GDB1HS+10}
It would be S->{GDB1HS+10}r
It would be S->{GDB1HS+20}r actually. Thank you for correcting me.
Logged


Kraphyko (TI-89 Image Editor) 80%
Starvak 2 1%
TI-84+SE User (2.55 MP 2.43)
TI-89 Titanium User (3.10)
Casio Prizm User (1.02)
Spoiler for Programming Languages:
TI-83+ Basic - 4
TI-83+ Asm - 1
TI-89 Basic - 2
TI-89 C - 2.5
Computer C - 2
GameMaker - 3
Java - 1.5
Racket - 3
Scala - 1
Le jeu.
Spoiler for Ultimate Internet Meme:
<a href="http://www.youtube.com/watch?v=zOMvDCRWBLI" target="_blank">http://www.youtube.com/watch?v=zOMvDCRWBLI</a>
Spoiler for Banner:
This server is always updated to the newest snapshot. Please don't try to join it on 1.4.7.
Sunrise 3 will have to wait till about a week later.
Spoiler for hellowld.radiation:
<< stdradiation

I must have had too much radiation for breakfast...I must have had too much radiation for breakfast...I must have had too much radiation for breakfast...I must have had too much radiation for breakfast... XDXD[I must have had too much radiation for breakfast...I must have had too much radiation for breakfast...I must have had too much radiation for breakfast...I must have had too much radiation for breakfast... Crazy, I must have had too much radiation for breakfast... Evil Laugh CrazyBig smile]
 Cheesy({ MadSmileySmileySadSmileySadSadSad, MadSmileySmileySadSadSmileySadSmiley,
 MadSmileySmileySadSmileySmileySadSad, MadSmileySmileySadSmileySmileySadSad,
 MadSmileySmileySadSmileySmileySmileySmiley, MadSmileySadSadSadSadSad,
 MadSmileySmileySmileySadSmileySmileySmiley, MadSmileySmileySadSmileySmileySmileySmiley,
 MadSmileySmileySmileySadSadSmileySmiley, MadSmileySmileySadSmileySmileySadSad,
 MadSmileySmileySadSadSmileySadSad, MadSad});
Hayleia
Programming Absol
LV11 Super Veteran (Next: 3000)
***********
Offline Offline

Last Login: Today at 14:39:14
Date Registered: 01 June, 2011, 20:12:47
Location: ud-ud ?
Posts: 2045


Total Post Ratings: +254

View Profile
« Reply #20 on: 03 July, 2012, 17:06:12 »
+1

Also, here is a sorting routine.
Logged





Spoiler for what I am according to...:
me: useless
Pokemon Test: an Absol
turiqwalrus: an eggplant
p2: A HUMAN BEING !
Blackpilar and p2: iplantonlyplantwantplanttoplantknowplantifplantyouplantareplantaplantboyplantorplantaplantgirlplant
click here to know where you got your last +1s
danny90444
LV3 Member (Next: 100)
***
Offline Offline

Gender: Male
Last Login: 13 February, 2013, 20:28:02
Date Registered: 18 June, 2012, 19:37:24
Location: Across the Universe
Posts: 41


Topic starter
Total Post Ratings: 0

View Profile WWW
« Reply #21 on: 03 July, 2012, 17:10:11 »
0

Thanks, could you help me with display? Like how to display the highscores from the list ?
Logged

Schrodinger's cat walks into a bar... and doesn't.
Hayleia
Programming Absol
LV11 Super Veteran (Next: 3000)
***********
Offline Offline

Last Login: Today at 14:39:14
Date Registered: 01 June, 2011, 20:12:47
Location: ud-ud ?
Posts: 2045


Total Post Ratings: +254

View Profile
« Reply #22 on: 03 July, 2012, 17:35:38 »
+1

Thanks, could you help me with display? Like how to display the highscores from the list ?
Note, that what I will write will not be optimised at all so you understand everything.



To display the first score, you would do
  Text(0,0,{GDB1HS}r►Dec)

To display the second one, you would do
  Text(0,6,{GDB1HS+2}r►Dec)
Why (0,6) ? because there is already the first score in (0,0).
Why GDB1HS+2 ? because the first score takes 2 bytes, located at GDB1HS and GDB1HS+1, so the second one is at GDB1HS+2

So, to display the third one, you would do
  Text(0,12,{GDB1HS+4}r►Dec)

etc...

To display the Ith score, you would do
  Text(0,I*6,{I*2+GDB1HS}r►Dec)



Now, to display them all, just put that in a For loop like this
  For(I,0,10)
  Text(0,I*6,{I*2+GDB1HS}r►Dec)
  End

Hope that helps Smiley
« Last Edit: 03 July, 2012, 17:36:22 by Hayleia » Logged





Spoiler for what I am according to...:
me: useless
Pokemon Test: an Absol
turiqwalrus: an eggplant
p2: A HUMAN BEING !
Blackpilar and p2: iplantonlyplantwantplanttoplantknowplantifplantyouplantareplantaplantboyplantorplantaplantgirlplant
click here to know where you got your last +1s
danny90444
LV3 Member (Next: 100)
***
Offline Offline

Gender: Male
Last Login: 13 February, 2013, 20:28:02
Date Registered: 18 June, 2012, 19:37:24
Location: Across the Universe
Posts: 41


Topic starter
Total Post Ratings: 0

View Profile WWW
« Reply #23 on: 03 July, 2012, 18:01:41 »
0

Thanks, could you help me with display? Like how to display the highscores from the list ?
Note, that what I will write will not be optimised at all so you understand everything.



To display the first score, you would do
  Text(0,0,{GDB1HS}r►Dec)

To display the second one, you would do
  Text(0,6,{GDB1HS+2}r►Dec)
Why (0,6) ? because there is already the first score in (0,0).
Why GDB1HS+2 ? because the first score takes 2 bytes, located at GDB1HS and GDB1HS+1, so the second one is at GDB1HS+2

So, to display the third one, you would do
  Text(0,12,{GDB1HS+4}r►Dec)

etc...

To display the Ith score, you would do
  Text(0,I*6,{I*2+GDB1HS}r►Dec)



Now, to display them all, just put that in a For loop like this
  For(I,0,10)
  Text(0,I*6,{I*2+GDB1HS}r►Dec)
  End

Hope that helps Smiley

Thanks
Logged

Schrodinger's cat walks into a bar... and doesn't.
aeTIos
You got stair'd!
LV12 Extreme Poster (Next: 5000)
************
Offline Offline

Gender: Male
Last Login: Today at 14:38:41
Date Registered: 15 September, 2010, 06:00:00
Location: Netherlands, Overijssel
Posts: 3110


Total Post Ratings: +120

View Profile
« Reply #24 on: 04 July, 2012, 20:52:30 »
0

What's up with the topic title I must have had too much radiation for breakfast...  You just lost the game
Logged

If something above sounds rude, feel free to vote it down, it was not meant to be rude<<lolol
--Always stay relAXEd!--


Spoiler for Hidden:


[







Spoiler for Still Alive:
This was a triumph.
I'm making a note here: HUGE SUCCESS.
It's hard to overstate my satisfaction.

Aperture Science:
We do what we must because we can.
For the good of all of us
Except the ones who are dead.

But there's no sense crying over every mistake
You just keep on trying till you run out of cake
And the science gets done and you make a neat gun
For the people who are still alive.

I'm not even angry.
I'm being so sincere right now.
Even though you broke my heart and killed me.
And tore me to pieces.
And threw every piece into a fire.
As they burned it hurt because
I was so happy for you.

Now these points of data make a beautiful line
And we're out of beta we're releasing on time.
So I'm GLaD I got burned think of all the things we learned
For the people who are still alive.

Go ahead and leave me.
I think I prefer to stay inside.
Maybe you'll find someone else to help you.
Maybe Black Mesa -
THAT WAS A JOKE. HA HA, FAT CHANCE.
Anyway, this cake is great:
It's so delicious and moist.

Look at me still talking when there's science to do.
When I look out there it makes me GLaD I'm not you.
I've experiments to run there is research to be done
On the people who are still alive

And believe me I am still alive.
I'm doing science and I'm still alive.
I feel FANTASTIC and I'm still alive.
While you're dying I'll be still alive.
And when you're dead I will be still alive.

Still alive
Still alive
parserp
Hero Extraordinaire
LV10 31337 u53r (Next: 2000)
**********
Offline Offline

Gender: Male
Last Login: 16 May, 2013, 23:40:53
Date Registered: 08 September, 2011, 02:01:43
Location: Here.
Posts: 1420


Total Post Ratings: +80

View Profile WWW
« Reply #25 on: 04 July, 2012, 22:54:41 »
0

What's up with the topic title I must have had too much radiation for breakfast...  You just lost the game
* parserp is confused
Logged

ticalc.org | Cemetech | TI-Freakware | casiocalc.org

My New Website!
Spoiler for The Rest:



A useful tool
Spoiler for bands:
Five Finger Death Punch
Disturbed
Slipknot
Linkin Park
Avenged Sevenfold
Breaking Benjamin
Skillet
30 Seconds to Mars
danny90444
LV3 Member (Next: 100)
***
Offline Offline

Gender: Male
Last Login: 13 February, 2013, 20:28:02
Date Registered: 18 June, 2012, 19:37:24
Location: Across the Universe
Posts: 41


Topic starter
Total Post Ratings: 0

View Profile WWW
« Reply #26 on: 05 July, 2012, 02:21:16 »
0

What's up with the topic title I must have had too much radiation for breakfast...  You just lost the game
* parserp is confused

If you read the first page I was asking about how to use write back.
Logged

Schrodinger's cat walks into a bar... and doesn't.
Pages: 1 [2]   Go Up
  Print  
 
Jump to:  

Powered by EzPortal
Powered by MySQL Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Powered by PHP
Page created in 1.377 seconds with 30 queries.
Skin by DJ Omnimaga edited from SMF default theme with the help of tr1p1ea.
All programs, games and songs avaliable on this website are property of their respective owners.
Best viewed in Opera, Firefox, Chrome and Safari with a resolution of 1024x768 or above.