Jump to content



Photo
- - - - -

Space Invaders For Fx-9860


  • Please log in to reply
19 replies to this topic

#1 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 27 January 2007 - 01:07 AM

Current Version: 1.01

OK, I completed my next game on the list: Space Invaders. It's quite fun with nice graphics and goes smoothly. :D You start out with 99 shields (trust me, you're going to need them!) Some screenshots:

Posted Image Posted Image

Gameplay:

<span class=EXE' /> - Pauses the game
<span class=Shift' /> - Launches missile
Right and Left Keys - Move the cannon

Here's the link to download it: http://www.casiocalc...amp;load_that=1. Any comments and suggestions, please reply them here. :)

#2 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 27 January 2007 - 03:43 PM

Has anyone tested this out yet?

#3 The_AFX_Master

The_AFX_Master

    Casio Overlord

  • [Legends]
  • PipPipPipPipPipPipPip
  • 519 posts
  • Gender:Male
  • Location:Black Mesa Research Facility (sector C)
  • Interests:BASIC +FORTRAN 90+ C++.....and HALF LIFE

  • Calculators:
    Casio Algebra FX 2.0 Plus, Casio fx 570 ms, Classpad 300, And a crowbar

Posted 27 January 2007 - 05:03 PM

9860 add-ins comes with emulation? (as some CP ones)

#4 eew

eew

    Casio Freak

  • Members
  • PipPipPipPip
  • 139 posts
  • Gender:Female
  • Location:Netherlands

  • Calculators:
    recent calculators:
    Casio fx-9860G SD
    Casio fx-82ms

    old calculators:
    HP 41C (1979)
    TI SR-40 (1976)
    Commodore [unkown type] (-+1970)

Posted 27 January 2007 - 06:11 PM

It's gread :roflol:

#5 samy

samy

    Casio Fan

  • Members
  • PipPip
  • 46 posts
  • Location:France

  • Calculators:
    graph 100; graph85

Posted 27 January 2007 - 08:42 PM

yes a great add in, very funny! a good job

#6 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 27 January 2007 - 09:14 PM

It's gread :roflol:

yes a great add in, very funny! a good job


Thanks for the comments. I re-updated the game and fixed some bugs and optimized it. I encourage everyone to download v1.01 if they haven't done so yet.

Updates:
* New invader sprite
* Instead of moving in a box pattern, they now move closer to the player as you destroy each row like the original!
* Game runs a bit faster now
* Improved measure of difficulty according to what level you're on

Here's the link again to download the updated version: http://www.casiocalc...amp;load_that=1

Take a look at the first post of this thread to see screenshots of the improved version. :D

9860 add-ins comes with emulation? (as some CP ones)


What do you mean by this AFX_Master? The SDK comes with a fx-9860 emulator.

#7 Menno

Menno

    Casio Freak

  • Members
  • PipPipPipPip
  • 184 posts
  • Gender:Male
  • Location:Netherlands

  • Calculators:
    Casio 880P
    Casio Graph 25+
    Casio fx-9860g sd

Posted 27 January 2007 - 10:06 PM

Hey,

I am still learning C, i have decided to first learn C extensivly (?) on the pc (windows environment(and dos)) because there are more tutorials for that. But i have some troubles converting to the sdk for casio. Would you please be so kind to add the source files? I have lots of trouble with the sscanf on the casio...

and yes i like your games :)

also, would you please be so kind to write a sample application for calculating a*b=c with user input?

like
give a
give b
answer is c

Thanks anyhow

#8 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 27 January 2007 - 10:31 PM

Hey,

I am still learning C, i have decided to first learn C extensivly (?) on the pc (windows environment(and dos)) because there are more tutorials for that. But i have some troubles converting to the sdk for casio. Would you please be so kind to add the source files? I have lots of trouble with the sscanf on the casio...


That's a good way to start. :D

and yes i like your games :)


Thanks!

I have lots of trouble with the sscanf on the casio...

...

also, would you please be so kind to write a sample application for calculating a*b=c with user input?

like
give a
give b
answer is c

Thanks anyhow


Recieving user input and placing the value into a variable is kind of tricky since scanf() is not supported. sscanf() is like scanf(), but scanff() reads from a buffer, unlike scanf() which reads from STDIN. The SDK is still kind of basic (can't do greyscales which is kind of disappointing, no serial communication functions however their ECON add-in which uses serial communications, lacking some crucial standard C functions, etc.) and right now CASIO isn't supporting it. However, you can program in Assembly, but CASIO states:

Please do not directly access hardware(ports, address, others) because if the calculator's OS is updated the Add-In applications might not operate.


However you could simulate scanf() using these two functions: IsKeyUp() & IsKeyDown().

For example:

if(IsKeyDown(KEY_CTRL_XTT)){
		key_a_pressed = 1;
} else {
		key_a_pressed = 0;
}

This piece of code returns 1 if <span class=Alpha' /> + [X,O,T] has been pressed, if not, then it returns 0. To make it effective, you can place this inside a main loop like while(). For example:


while(true){
	if(IsKeyDown(KEY_CHAR_A)){
		key_a_pressed = 1;
	} else {
		key_a_pressed = 0;
	}
	// Just an example. Place more stuff.....
	if(IsKeyDown(KEY_CTRL_EXIT)){
		return 1;
	}
}

The Key Code List shows what values you may use with the IsKeyDown() and IsKeyUp() functions. If you need more help, please ask me. :D

#9 muelsaco

muelsaco

    Newbie

  • Members
  • Pip
  • 13 posts

Posted 28 January 2007 - 12:54 PM

Recieving user input and placing the value into a variable is kind of tricky since scanf() is not supported. sscanf() is like scanf(), but scanff() reads from a buffer, unlike scanf() which reads from STDIN. The SDK is still kind of basic (can't do greyscales which is kind of disappointing, no serial communication functions however their ECON add-in which uses serial communications, lacking some crucial standard C functions, etc.) and right now CASIO isn't supporting it. However, you can program in Assembly, but CASIO states


My library do this fonction (available here : http://www.planet-ca...programme.html)
I work an a new fonction that permits to have images with more than 128x64 pixels. We can focuse on different image's part with arrow for example :D It's very interesting for games like mario, pok?mon, strategy,...

#10 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 28 January 2007 - 01:10 PM

My library do this fonction (available here : http://www.planet-ca...programme.html)
I work an a new fonction that permits to have images with more than 128x64 pixels. We can focuse on different image's part with arrow for example :D It's very interesting for games like mario, pok?mon, strategy,...


That new function sounds awesome. Can't wait for it! It'll work perfectly for my next game...

About that function in your library about gathering input, that function is similar to what I was showing Menno. Although, your technique uses GetKey() while mine uses IsKeyDown() & IsKeyUp(). However, IsKeyDown() & IsKeyUp() is faster than GetKey(), as GetKey() draws everything from V(ideo)RAM to the Display Driver.

#11 Xerxes

Xerxes

    Casio Freak

  • Members
  • PipPipPipPip
  • 130 posts
  • Gender:Male

Posted 28 January 2007 - 04:37 PM

Hi kucalc,

well done, I like your prog.

Are you sure, it is correct, that the enemies do not move horizontally to the edge of the screen, if a complete outside column is shot?

#12 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 28 January 2007 - 04:50 PM

Hi kucalc,


Hello to you also, this is my first time talking to you. :D

well done, I like your prog.


Thanks! :D

Are you sure, it is correct, that the enemies do not move horizontally to the edge of the screen, if a complete outside column is shot?


Hmmm, I haven't thought about that. Playing Space Invaders (on DOS) doesn't seem to have that feature. I think what I'm missing are those shelters that block the alien lasers. Maybe I will implement in a later version and instead of using pixel-by-pixel drawing, I will use bitmaps to increase speed and maintain speed consistency. But that will have to wait after my next game which will be a 2D sidescroller which will feature use of bitmaps instead of pixel-by-pixel drawing and improved programming techniques compared to my previous games.

#13 Xerxes

Xerxes

    Casio Freak

  • Members
  • PipPipPipPip
  • 130 posts
  • Gender:Male

Posted 28 January 2007 - 05:19 PM

Sorry for my english, but I am not sure that my previous post was clear enough.

For example if only one enemy is left, in the original game it moved completely from one edge of the screen to the other edge and vice versa. In your version it makes the same move like the beginnig of the game. Try this link to see what I mean:



#14 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 28 January 2007 - 05:42 PM

I understood what you meant Xerxes. If one column of aliens are destroyed, the rest of the invaders should move from one side of the screen to the other. As, I said, I might implement that feature later on as I am currently busy working on another game.

#15 purplemonkey

purplemonkey

    Newbie

  • Members
  • Pip
  • 13 posts
  • Location:somewhere near Perth, W.A

  • Calculators:
    casio fx-9860G AU

Posted 11 February 2007 - 08:27 AM

this is an awesome game, its pretty funny at school when theres rows of ppl just playing space invaders, trying to look like theyre doing work! :lol2: But the only thing is that it kinda does suck not having the shields that block the lasers, and also not having any rapid fire type thing. its kinda hard sometimes (and boring) when you fire but miss and you have to dodge the invaders fire until the shot you fired dissapears. this is often why i keep getting hit! :(

#16 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 11 February 2007 - 03:17 PM

this is an awesome game, its pretty funny at school when theres rows of ppl just playing space invaders, trying to look like theyre doing work! :lol2: But the only thing is that it kinda does suck not having the shields that block the lasers, and also not having any rapid fire type thing. its kinda hard sometimes (and boring) when you fire but miss and you have to dodge the invaders fire until the shot you fired dissapears. this is often why i keep getting hit! :(


I'll try to improve when I get the time. In the meantime, I believe there is a really good Space Invaders (the original, in fact!), for the CHIP-8, maybe you could use it with my emulator: http://www.casiocalc...?showtopic=3186

#17 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 17 February 2007 - 08:56 AM

Wow! My Space Invaders game has been downloaded over 300 times within only a couple weeks (Not even a month yet)! I look around the FileShare and it's take months and years (like Marco's SkyRoads) for other programs to reach 300 downloads! I am so amazed, never thought that a Space Invaders game would rack up this much downloads in such a short amount of time and be so popular. I like to thank all of you. Because of this, I'm deciding to continue working on the Space Invaders game. :D

#18 Guest_Zyphyras_*

Guest_Zyphyras_*
  • Guests

Posted 20 February 2007 - 06:03 AM

Hey it's Zyphyras from Casio kingdom,

Keep it up! I love your games.

#19 alias4399

alias4399

    Casio Freak

  • Members
  • PipPipPipPip
  • 180 posts
  • Location:Impossible to say.. Its not like this is a constant!

  • Calculators:
    CFX 9850GB Plus
    FX 9860G

Posted 20 February 2007 - 08:25 AM

Good on you kucalc!
I want to see how you can develop your game further (there are many, many, many possibilities!)

#20 kucalc

kucalc

    Casio Maniac

  • [Legends]
  • PipPipPipPipPipPipPipPip
  • 1422 posts
  • Gender:Male
  • Location:USA
  • Interests:Programming: C/C++, Fortran, LISP, COBOL 85 Standard, PHP, x86 and SH3 Assembly

    Computer graphics

  • Calculators:
    fx-9860G / fx-7400G Plus / Algebra FX 2.0+ / fx-9770G / CFX-9850G / CFX-9850GB+ / TI-89 / TI-nSpire

Posted 20 February 2007 - 04:23 PM

Hey, I'm glad you like my work Zyphyras! :D I'm currently rewriting the game, so you'll have to wait and see... :D




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users