Forums

Topic: Petit Computer

Posts 7,821 to 7,840 of 9,620

Miblon

IAmAPerson wrote:

EDIT EDIT: @Miblon one equals sign (=) is used for assigning a value to a string/variable. Two equal signs (==) is for comparison.

I did that. For each direction, it assigns a number to variable DIREC like this:
@LEFT
code
code
code
DIREC=4
code
RETURN

And now I'm trying to get my character to slash, like this:
IF DIREC==4 AND BTRIG()==16 THEN GOSUB @SLASHLEFT
and it gives me a syntax.
Here's what I positively sure I have:
A @SLASHLEFT
The DIREC is assigned to a number
Two equal signs

Edited on by Miblon

This isn't a interesting signature. Go look at someone elses.
Friend Code: 5370-0889-8930

Discostew

Working on the fade-in/fade-out effect that happens in Quickman's stage (not available in any other stage). Plan is to make it an entity like everything else that (when entity comes into view) sets to either fade-out or fade-in the level. This will allow easy placement in the editor. Already have the Hot Head enemies deal with the fade-in/fade-out effect with the fire-like shade, but now I have to handle how to have both interact with each other.

Discostew

3DS Friend Code: 4425-1477-0127 | Nintendo Network ID: Discostew

Miblon

JLMan wrote:

Miblon wrote:

IAmAPerson wrote:

EDIT EDIT: @Miblon one equals sign (=) is used for assigning a value to a string/variable. Two equal signs (==) is for comparison.

I did that. For each direction, it assigns a number to variable DIREC like this:
@LEFT
code
code
code
DIREC=4
code
RETURN

And now I'm trying to get my character to slash, like this:
IF DIREC==4 AND BTRIG()==16 THEN GOSUB @SLASHLEFT
and it gives me a syntax.
Here's what I positively sure I have:
A @SLASHLEFT
The DIREC is assigned to a number
Two equal signs

Try doing BTRIG(0). May not work, though.

Syntax Error!

This isn't a interesting signature. Go look at someone elses.
Friend Code: 5370-0889-8930

LeviCelJir

@IAmAPerson um If I were... um to have 2 or more slimes in MCDS and have some of them be different textures... how would I do that?

Hi I'm Levi and I like Bloopys :^)

Discostew

Miblon wrote:

JLMan wrote:

Miblon wrote:

IAmAPerson wrote:

EDIT EDIT: @Miblon one equals sign (=) is used for assigning a value to a string/variable. Two equal signs (==) is for comparison.

I did that. For each direction, it assigns a number to variable DIREC like this:
@LEFT
code
code
code
DIREC=4
code
RETURN

And now I'm trying to get my character to slash, like this:
IF DIREC==4 AND BTRIG()==16 THEN GOSUB @SLASHLEFT
and it gives me a syntax.
Here's what I positively sure I have:
A @SLASHLEFT
The DIREC is assigned to a number
Two equal signs

Try doing BTRIG(0). May not work, though.

Syntax Error!

BTRIG(0)==16 causes a syntax error. BTRIG()==16 does not.

Discostew

3DS Friend Code: 4425-1477-0127 | Nintendo Network ID: Discostew

TAINT_Zzyex

he gave up on the community

"Did somebody say Aincrad?"
"No, go back to your own game!"
"awwww"
"And make out with Asuna."
"Aww-I mean YAY"

Twitter:

Miblon

TexMurphy wrote:

@Miblon
I don't like posting others qr code, but this comes from the late PetitProfessor. Don't know where he is now. It is a character that walks around the screen slashing with a sword when you push the A button.
Untitled

The problem is, I can't read QR codes. My outer camera is broken, and I plan on getting it fixed soon. Could you, if possible, give me the code for the program using Notepad or Word or something? It would be helpful.

This isn't a interesting signature. Go look at someone elses.
Friend Code: 5370-0889-8930

InsertPi

@Leviceljir is this what you're talking about? It's new in 1.8
Untitled

If Facebook, Myspace, Twitter, Instagram, and Snapchat were all destroyed, 90% of teens would go insane. If you're one of the 10% that would be laughing at them, copy & paste this into your signature and hope it happens.

3DS Friend Code: 2148-9259-0831 | Nintendo Network ID: IAmAPerson620 | Twitter:

ramstrong

Miblon wrote:

And now I'm trying to get my character to slash, like this:
IF DIREC==4 AND BTRIG()==16 THEN GOSUB @SLASHLEFT
and it gives me a syntax.

Well, I typed that line and it doesn't give me syntax error. Either you typed it wrong in your device, or the error lies somewhere else. I suggest you condense it to the smallest program possible, and give the exact error message. That means the type of error and line number. Whatever your error is, it's not that line.

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

randomous

@ramstrong I've finally gotten around to posting the information @Discostew posted earlier about the GRP file format on the Wiki, along with the extra information @Calc84maniac provided. I'll add some sample code later, but for now, it seems all right. Hopefully people can find this information easily now, and can make their own external GRP manipulators.

http://petitcomputer.wikia.com/wiki/GRP_File_Format_(External)

@Discostew If you feel like you need more credit on the Wiki page, please let me know! You provided all the information lol.

Edited on by randomous

randomous

ramstrong

randomous wrote:

@ramstrong I've finally gotten around to posting the information @Discostew posted earlier about the GRP file format on the Wiki, along with the extra information @Calc84maniac provided. I'll add some sample code later, but for now, it seems all right. Hopefully people can find this information easily now, and can make their own external GRP manipulators.

Excellent! I ought to print that page already. So, where'd you put the "sprite on touchscreen" info?

edit:
So, am I correct in assuming that this code will "unscramble" the data so that loading on PC will yield straight data?

ACLS
FN$="G0":'GRAPHIC FILENAME
LOAD "GRP1:"+FN$,0
PNLTYPE "OFF"

CX=0:CY=0
FOR J=0 TO 2:FOR I=0 TO 3
FOR Y=0 TO 7:FOR X=0 TO 7
FOR YY=0 TO 7:FOR X=0 TO 7

GPAGE 1
C=GSPOIT(CX,CY)
GPSET CX,CY,0
CX=(CX+1)%256
IF CX==0 THEN CY=CY+1
GPAGE 0
GPSET (I*64+X*8+XX),(J*64+Y*8+YY),C

NEXT:NEXT
NEXT:NEXT
NEXT:NEXT

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

Pixelrobin

@ramstrong It would be rather short...

SPPAGE 1
LOAD"SPU0:‹sprite sheet name here›"

Don't tell me you didn't know that!

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

ramstrong

Bluerobin2 wrote:

@ramstrong It would be rather short...

SPPAGE 1
LOAD"SPU0:‹sprite sheet name here›"

Don't tell me you didn't know that!

No, I didn't know that. As I remember it, the explanation was rather long. There's a note (p. 37) saying "User characters cannot be displayed on this screen" thing, so I never bothered to learn it. So, one page sprite is okay?

Also, I thought the name is SPS0: Is that right?
I've been using GPUTCHR instead, so I guess I'm ignorant in that respect.

Edit:
Just tried it. Here it is:

ACLS
PNLTYPE "OFF"
SPPAGE 1
LOAD "SPS0:CHRFILE"
SPSET 1,0,0,0,0,0
SPANIM 1,64,20,0
WAIT 6000

So, the pages are SPS0 and SPS1. You can use upto 117 characters.

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

Pixelrobin

@ramstrong sorry. Yes, its SPS0. I was tired :3

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

Pixelrobin

@IamAPerson did you find my terrain generator useful? Any gripes or compliments?

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

ramstrong

On second thought, this is to unscramble the pic so it goes straight to PC

ACLS
FN$="G0":'GRAPHIC FILENAME
LOAD "GRP1:"+FN$,0
PNLTYPE "OFF"

CX=0:CY=0
FOR J=0 TO 2:FOR I=0 TO 3
FOR Y=0 TO 7:FOR X=0 TO 7
FOR YY=0 TO 7:FOR X=0 TO 7

GPAGE 1
C=GSPOIT((I*64+X*8+XX),(J*64+Y*8*YY))
GPSET (I*64+X*8+XX),(J*64+Y*8*YY),0
GPAGE 0
GPSET CX,CY,C
CX=(CX+1)%256
IF CX==0 THEN CY=CY+1

NEXT:NEXT
NEXT:NEXT
NEXT:NEXT

WAIT 6000

EDIT:
No. This isn't right either. This stuff is giving me a headache. In the end, I forced the issue. I think the right method will scan it venetian-blind like, 8 steps at a time. It's too late, and I'm tired. Will try it again tomorrow.

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

Pixelrobin

@ramstrong I'm having trouble too. I'm programming pathfinding ai. And I have a SORT that doesn't want to sort.

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

LeviCelJir

IAmAPerson wrote:

@Leviceljir is this what you're talking about? It's new in 1.8
Untitled

**Sigh** Pearson. Always making Mods that I am making into the game. But Except some were to be retextured. Now this Mod is too easy for me.

Also @IAmAPerson I tried a manual conversion of my 1.5 map. It worked. Well sorta. When I use it in 1.7.1 It randomly crashs and I can't build anything and save or its says its unreadable. So.... Can you fix what I did wrong sometime today? Please?

Hi I'm Levi and I like Bloopys :^)

InsertPi

@Leviceljir I was planning to do that anyway.

Also, Beta 1.8 is coming out very soon, but the changs in map saving are too complex for an auto conversion, so you'll have to start over on your maps. If you're too upset, I can attempt a manual conversion on your map, but I'm not sure it'll work.

If Facebook, Myspace, Twitter, Instagram, and Snapchat were all destroyed, 90% of teens would go insane. If you're one of the 10% that would be laughing at them, copy & paste this into your signature and hope it happens.

3DS Friend Code: 2148-9259-0831 | Nintendo Network ID: IAmAPerson620 | Twitter:

LeviCelJir

IAmAPerson wrote:

@Leviceljir I was planning to do that anyway.

Also, Beta 1.8 is coming out very soon, but the changs in map saving are too complex for an auto conversion, so you'll have to start over on your maps. If you're too upset, I can attempt a manual conversion on your map, but I'm not sure it'll work.

Manual converting is kinda easy... Isn't it just changing the colors on the top of the grp to the same as a map from the same update?

Hi I'm Levi and I like Bloopys :^)

Please login or sign up to reply to this topic