Forums

Topic: Petit Computer

Posts 2,661 to 2,680 of 9,620

MrSirr

OH also how do u change a sprites position? would I use SPOFS? cuz thats not working...

MrSirr

Pixelrobin

@Mrsirr SPOFS (sprite number),(x position),(y position),(frames (keep this 0 and you'll be fine))

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

MrSirr

Bluerobin2 wrote:

@Mrsirr SPOFS (sprite number),(x position),(y position),(frames (keep this 0 and you'll be fine))

Yea I got it now thx. Now how would I make a sprite start moving up and keep going that way?

MrSirr

ramstrong

MrSirr wrote:

Bluerobin2 wrote:

@Mrsirr SPOFS (sprite number),(x position),(y position),(frames (keep this 0 and you'll be fine))

Yea I got it now thx. Now how would I make a sprite start moving up and keep going that way?

Don't take it the wrong way, but you really need to learn how to ask specific questions. How to make a sprite move to a certain direction and keep at it? Use infinite loop. @LOOP:Move Sprite UP:GOTO @LOOP.
I doubt that's what you meant, so how about you tell us what you're trying to program. How about showing us your code so far?

We do have some sprite samples in Tutorial thread, and I have some code samples for sprite manipulation: Petit Computer Journal #11: Trigonometry.

Edited on by ramstrong

Petit Computer Journal
Old site http://ramstrong.blogspot.com

Let's just call a spade, a spade.

3DS Friend Code: 1091-7596-4855

MrSirr

ramstrong wrote:

MrSirr wrote:

Bluerobin2 wrote:

@Mrsirr SPOFS (sprite number),(x position),(y position),(frames (keep this 0 and you'll be fine))

Yea I got it now thx. Now how would I make a sprite start moving up and keep going that way?

Don't take it the wrong way, but you really need to learn how to ask specific questions. How to make a sprite move to a certain direction and keep at it? Use infinite loop. @LOOP:Move Sprite UP:GOTO @LOOP.
I doubt that's what you meant, so how about you tell us what you're trying to program. How about showing us your code so far?

We do have some sprite samples in Tutorial thread, and I have some code samples for sprite manipulation: Petit Computer Journal #11: Trigonometry.

Srry, i just dont know how to explain it. Like i said, its like Frogger. Cars come on the screen and go to the other side and disappear. THATS IT. Do you know what Frogger is?

MrSirr

TexMurphy

@VincentFaraday
I suggest getting Bloodshed Dev C++ for a free c compiler. I used "Pure C Programming" in school. It appears that C# (c sharp) is more populer today for application programming.
@MrSirr
Use SPSET to create your sprites. If the sprite does not exist, using this command, none of your other commands will work. Use SPOFS to place your sprite. Use variables like X or Y instead of hard coded numbers for the coordinates. Use X=X+1 to move right and X=X-1 to move left for cars, logs, alligators. Use SPCLS to delete your sprite when it reaches the other side or you can move it back to the other side. Remember if you remove a sprite you must recreate it using SPSET or any attempt to move that sprite will give you an error. I hope this helps.

Edited on by TexMurphy

TexMurphy

ramstrong

MrSirr wrote:

Srry, i just dont know how to explain it. Like i said, its like Frogger. Cars come on the screen and go to the other side and disappear. THATS IT. Do you know what Frogger is?

Yes, I do know Frogger. Do you know Frogger? Here's a few questions I'd like to ask:
1. How big is the playfield? 16x12? 32x24? 12x9? 10x8?
2. Are you going to do wrap around or scroll?
3. Have you done a mock up with character based screen? That only takes LOCATE, PRINT. Easy to do. What are you doing with sprites right now? If you're so intend on learning sprite programming, I suggest PONG would be a whole lot easier.
4. How fast are the movement rates? How many obstacles?
5. What's the winning conditions? Is there a time limit?

If you look at my Journal entry for The Apple Picker Game, you'll see that as simple as it is, it takes a lot of considerations for it to be a game. The Coral Maze also went under similar ponderous journey. It's not enough to say that your game is just like (insert game here). You need to provide the specific details as well.

Yes, I do know Frogger, and Pong, and a whole lot of other stuff. Some of them by heart. I always write all the details down, because every time I didn't, I'd always regret it. Looks to me that by not providing the specific, you're just setting yourself for a whole lot of frustration in the future.

Besides, there's more than one way to skin a cat. There's more than one way to write a program, and without providing specifics, you just basically asked people to do your homework for you, instead of asking for help. Don't be surprised if people are reluctant to help you, okay?

Petit Computer Journal
Old site http://ramstrong.blogspot.com

Let's just call a spade, a spade.

3DS Friend Code: 1091-7596-4855

randomous

@TexMurphy I'm totally going to promote my own program and say this: Did you make that image on your own? You should try out my program that does it automatically! Haha just kidding, I like the way your images turn out.

randomous

MrSirr

TexMurphy wrote:

@VincentFaraday
I suggest getting Bloodshed Dev C++ for a free c compiler. I used "Pure C Programming" in school. It appears that C# (c sharp) is more populer today for application programming.
@MrSirr
Use SPSET to create your sprites. If the sprite does not exist, using this command, none of your other commands will work. Use SPOFS to place your sprite. Use variables like X or Y instead of hard coded numbers for the coordinates. Use X=X+1 to move right and X=X-1 to move left for cars, logs, alligators. Use SPCLS to delete your sprite when it reaches the other side or you can move it back to the other side. Remember if you remove a sprite you must recreate it using SPSET or any attempt to move that sprite will give you an error. I hope this helps.

That doesnt really help, I already know all that, but your program might, I'll have to wait till tomorrow though

MrSirr

MrSirr

ramstrong wrote:

MrSirr wrote:

Srry, i just dont know how to explain it. Like i said, its like Frogger. Cars come on the screen and go to the other side and disappear. THATS IT. Do you know what Frogger is?

Yes, I do know Frogger. Do you know Frogger? Here's a few questions I'd like to ask:
1. How big is the playfield? 16x12? 32x24? 12x9? 10x8?
2. Are you going to do wrap around or scroll?
3. Have you done a mock up with character based screen? That only takes LOCATE, PRINT. Easy to do. What are you doing with sprites right now? If you're so intend on learning sprite programming, I suggest PONG would be a whole lot easier.
4. How fast are the movement rates? How many obstacles?
5. What's the winning conditions? Is there a time limit?

If you look at my Journal entry for The Apple Picker Game, you'll see that as simple as it is, it takes a lot of considerations for it to be a game. The Coral Maze also went under similar ponderous journey. It's not enough to say that your game is just like (insert game here). You need to provide the specific details as well.

Yes, I do know Frogger, and Pong, and a whole lot of other stuff. Some of them by heart. I always write all the details down, because every time I didn't, I'd always regret it. Looks to me that by not providing the specific, you're just setting yourself for a whole lot of frustration in the future.

Besides, there's more than one way to skin a cat. There's more than one way to write a program, and without providing specifics, you just basically asked people to do your homework for you, instead of asking for help. Don't be surprised if people are reluctant to help you, okay?

1. pretty much the whole screen.
2. WTH does that even mean?
3. I dont know how I'd use that. It seems thats making them act like sprites.
4. I dont know what u mean, and just the cars!
5. There is none. Its a survival game. As time goes by, score goes up(already taken care of, plus highscore system.)

YES I KNOW FROGGER AND PONG.

the rest thats kinda rude.

MrSirr

Pixelrobin

So, We up to keeping creating coral maze? I good improve it a bit more.....

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

ramstrong

MrSirr wrote:

1. the whole screen.
2. WTH?
3. I dont know
4. I dont know
5. There is none.

YES I KNOW FROGGER.
the rest thats kinda rude.

You know Frogger? I doubt that. Why don't you start with Pong?

Sorry. I'm just giving you advice. If you take all advice that is not to your liking as insults, then congratulations because now you know how it feels to deal with people like you. Remember this?

MrSirr wrote:

HOW COME IM ALWAYS IGNORED!! I NEED HELP U JERKS!

Good luck in your future endeavour. I will cheerfully ignore you from now on. Ah, I feel my blood pressure dropping already.

@bluerobin2
Sure. The code is out there. Go ahead. Looking forward to it.

Petit Computer Journal
Old site http://ramstrong.blogspot.com

Let's just call a spade, a spade.

3DS Friend Code: 1091-7596-4855

MrSirr

ramstrong wrote:

MrSirr wrote:

1. the whole screen.
2. WTH?
3. I dont know
4. I dont know
5. There is none.

YES I KNOW FROGGER.
the rest thats kinda rude.

You know Frogger? I doubt that. Why don't you start with Pong?

Sorry. I'm just giving you advice. If you take all advice that is not to your liking as insults, then congratulations because now you know how it feels to deal with people like you. Remember this?

MrSirr wrote:

HOW COME IM ALWAYS IGNORED!! I NEED HELP U JERKS!

Good luck in your future endeavour. I will cheerfully ignore you from now on. Ah, I feel my blood pressure dropping already.

@bluerobin2
Sure. The code is out there. Go ahead. Looking forward to it.

What did I do to you? Of course I know Frogger! And plus I didnt say that, I was gone somewhere. Someone mustve hacked my account!

MrSirr

MrSirr

TexMurphy wrote:

@MrSirr
This should get you started. Note: I did not use SPCLR in this example. This bit of code demonstrates moving sprites and collision.
Untitled

I have a question. What does the Initialize Variable part mean? X=15*8: Y=20*8
LNX1=22*8
LNX2=0

MrSirr

Linput

Hey, lib put here. Just been focusing on school work lately. Anyways, anyone want to help me make SALLY OS any better?

Linput-3DS friend code: 4725-8494-2702
Pokemon White 2 pal-pad code: 1979 9213 55

I'm currently looking for some peeps to make SALLY a website, facebook, and email. If anyone does this u will be mentioned as a producer in the SALLY OS credits! :)

steriaca

I haven't posted in a while. Basicly, right now I got tons of ideals for non-text games, and waiting for a pay period where I get lot of cash, and I don't have to dedicate most of my free cash. Why? So I can pick up one of the e-books about petit computer.

My question is...which version should I get for my black and white Nook? The Android one? The other one? Defently not the PC version of the e-book.

My Friend Code is 3368-1310-0690.

Justlink

hi. I have returned. I am wondering, how do you save and reload numbers for a certain variable. I'm working on a program (tba l8r). Plz help. The reason i haven't been on is because of school.

Do you like videogames? If so, you must know
It's dangerous to go Alone.

Pixelrobin

@justlink...

Saving
SCORE=0
-SCORE UPDATE, GAME STUFF, BLAH BLAH-
HISCORE=SCORE
MEM$=STR$(HISCORE)
SAVE "MEM:NAMEHERE"

Info
•mem$ is the loading + saving string
•str$ turns a variable into a string
•Using save (mem) will save the contents of the mem$ string to a mem file.

Loading
(Put near beginning)
LOAD "MEM:NAMEHERE"
HISCORE=VAR(MEM$)
etc...

More Info
•During saving a variable, If it is a high score, you may want to do something like this to the saving code:
IF SCORE>HISCORE THEN SAVE"MEM:NAMEHERE"
•var turns a string into a variable

Hope it helps! Good luck!

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

Pixelrobin

I have tried and failed use of sphome. I know what it does but cannot make it cooperate. Could anyone supply an instance?

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

Please login or sign up to reply to this topic