DSiWare Forum

Topic: Petit Computer

Showing 9,041 to 9,060 of 9,506

AuthorMessage
Avatar

Espurr

9,041. Posted:

Hey, @Morpheel? I was wondering if I could help make a winter pack.

EDIT: Hey, the textures in CHRED are in a 1x4 format.

Edited on by Espurr

"The heart has reasons the mind knows nothing of."-Blaise Pascal
Pokemon X Friend Code:3883-5184-5725
Safari: Grass
Pokemon: Pansage, Sawsbuck (Spring), Gogoat.

AuthorMessage
Avatar

Espurr

9,042. Posted:

Almost done. How do I make a QR code for a CHR?

"The heart has reasons the mind knows nothing of."-Blaise Pascal
Pokemon X Friend Code:3883-5184-5725
Safari: Grass
Pokemon: Pansage, Sawsbuck (Spring), Gogoat.

AuthorMessage
Avatar

LeviCelJir

9,043. Posted:

Espurr wrote:

Almost done. How do I make a QR code for a CHR?

same way you make a QR for a prg

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

AuthorMessage
Avatar

TobuKatsu

9,044. Posted:

@DiscoStew How can I save MML as GRP?

3DS FC : 4613 - 7463 - 3640
I dont do things like a boss.Thats too mainstream.I do things like a MOOSE!!!1
I Love Japan! :3

AuthorMessage
Avatar

Espurr

9,045. Posted:

http://instagram.com/p/lQPde5x-Ci/

It's almost ready! All it needs is a qr code.
EDIT: Tell me what you think!

Edited on by Espurr

"The heart has reasons the mind knows nothing of."-Blaise Pascal
Pokemon X Friend Code:3883-5184-5725
Safari: Grass
Pokemon: Pansage, Sawsbuck (Spring), Gogoat.

AuthorMessage
Avatar

T-bender

9,046. Posted:

@Mariominer your Nintendo Network ID (you wrote in your signature) is alsa a shop in the Netherlands... Thats why I was wondering.

@TobuKatsu now I'm wondering how to save MML as GRP too...

Progress:
Alarm Clock (PTC) 75% done
Shooter w/o a name yet (PTC) 0,01% done Xd

AuthorMessage
Avatar

Discostew

9,047. Posted:

TobuKatsu wrote:

@DiscoStew How can I save MML as GRP?

Before I get into how to save/load MMLs via GRPs, I will make this completely clear. You cannot load an MML via strings that is greater than 2304 bytes long via BGMSET or 2560 bytes via BGMPLAY for loading strings. This is because PTC functions cannot have an excess of 10 parameters. BGMSET requires 1 parameter for the song number to set, making 9 strings you can use following it. BGMPLAY is completely for MML strings, so that is 10. Each string can hold up to 256 characters, so that makes it 2304 characters/bytes for 9 strings, and 2560 for 10.

I just typed this up without checking if it is correct, so if there are any errors when attempting to run it, I apologize. I was kinda in a hurry. Assume we are reading/writing to GRP1, using song #128 for testing/loading, and the label for the MML script is @MY_MML. We'll also assume you want to load but not necessary play immediately, so we are restricting length to 2304 bytes.

@SAVE_MML

' First examine if the MML is valid and within the 2304 byte limit
BGMSETD 128,@MY_MML: 'If it errors here, then the MML is not valid (has errors)
RESTORE @MY_MML:MML_L=0:READ MML$
'Examine and add the length of each line to the overall. End when MML$=="0" (from DATA 0)
FOR I=1 TO (MML$!="0"):MML_L=MML_L+LEN(MML$):READ MML$:I=0:NEXT I
IF MML_L>2304 THEN ?"MML scripts too long!":END: 'If it is too long, it'll end the program

'Begin the procedure
'Initialize the data, and first write the length of the MML, splitting into 2 bytes
GPAGE 0,1,0:GIDX=2:GPSET 0,0,MML_L%256:GPSET 1,0,MML_L/256
'Restart from the beginning of the MML, and run through it all
RESTORE @MY_MML:READ MML$
'Continue writing until MML$==0
FOR I=1 TO (MML$!="0")
IF GIDX+LEN(MML$)>49152 THEN ?"Reached end of GRP, cannot continue":END
'Convert each character to a number (0-255), and write it in sequentially
FOR J=0 TO LEN(MML$)-1:GPSET (GIDX+J)%256,(GIDX+J)/256,ASC(MID$(MML$,J,1)):NEXT J
'Offset the write index and read the next string
GIDX=GIDX+LEN(MML$):READ MML$:I=0
NEXT I
RETURN

@LOAD_MML
IF !MML_DIM THEN DIM MMLA$(9):MML_DIM=1
'Initialize data, and grab the length first
FOR I=0 to 8:MMLA$(I)="":NEXT
GPAGE 0,1,0:GIDX=0:MML_L=GSPOIT(0,0)+GSPOIT(1,0)*256-1
'Begin OPERATION LOAD_MML!
FOR I=0 TO MML_L:MMLA$(I/256)=MMLA$(I/256)+CHR$(GSPOIT((GIDX+I)%256,(GIDX+I)/256)):NEXT I
BGMSET 128,MMLA$(0),MMLA$(1),MMLA$(2),MMLA$(3),MMLA$(4),MMLA$(5),MMLA$(6),MMLA$(7),MMLA$(8)
RETURN

Edited on by Discostew

"What fun is there in making sense?"
Lazer Light Studios - Home of the MM2 PTC project

Pokemon 3DS Friend Safari - Ice - Spheal, Sneasel, Lapras

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

AuthorMessage
Avatar

InsertPi

9,048. Posted:

Guys, please read this.

I probably won't be working on Minecraft DS for the next few weeks. Two reasons: school, and a friend recently got killed. I won't go into detail about either of those because it can be considered off-topic. I don't need any responses to this post, because that can be considered off-topic too. Just wanted to post this if you notice me be quiet and not respond to posts. Thanks for understanding.

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: @PhilLovesPi

AuthorMessage
Avatar

TobuKatsu

9,049. Posted:

@twinArmageddonz Oi, ya aint bin un chat since foeva, wha you bin doin'?

3DS FC : 4613 - 7463 - 3640
I dont do things like a boss.Thats too mainstream.I do things like a MOOSE!!!1
I Love Japan! :3

AuthorMessage
Avatar

TexMurphy

9,050. Posted:

TobuKatsu wrote:

@TexMurphy Thanks!, By the looks of it, is it just displaying the SCR layers and reading the grp's cols as collision?

Collision can be done by checking the background SCR tiles with the position of the sprite. The problem is: the sprite moves one pixel at a time but the background moves 8 pixels or one tile at a time. The collision point for the tile is in the upper left of each tile. Therefore, the sprite may walk inbetween these tiles. One can span 8 places and look for the tile like my miku example. I found it easier to match one tile to one number in an array. But, setting up an array for a large map takes alot of DATA statements. It is also hard to know where I am in the DATA statement to where the SCR tiles are. So I created Aster2 program to visually place graphic color blocks on the tiles. The program takes those blocks and saves them as a single pixel in a GRP file. The game program loads the GRP pixels and copies the color numbers into the array without using DATA statements. The neat thing about this is that I can use mupliple colors for different things like sound, death spots, collision, etc. When the program runs it test with IF statements to see what color matches the number its looking for.

Edited on by TexMurphy

TexMurphy

AuthorMessage
Avatar

InsertPi

9,051. Posted:

@Discostew I never thought you could do that with FOR loops!

FOR I=1TO (condition)STEP 0
NEXT

That helps a lot. I guess it's because if the condition is met, it returns a 1, completing the loop. This is like a WHILE loop in PTC! Except you'd have to flip the condition for it to work. So would these two codes work the same?

FOR I=1TO (NUMBER==5)STEP 0
LINPUT NUMBER$
NUMBER=VAL(NUMBER$)
NEXT

And this pseudocode:

while (number != 5){
number = ToVar(GetInput)
}

And one last question: are new lines or rebuttles faster? (A rebuttle is a colon in SB.) And by how much? If rebuttles are faster, would it be worth going through my entire code and rebuttle-izing?

EDIT: For people like @Randomous, @Hansausage, and anyone else who uses C#, should I create a PTC class? It'd work like this (a GLINE command):

ptc.gLine(x1, y1, x2, y2, color);

and a PRINT command:

ptc.print("hi!");

Would anyone use it?

Edited on by InsertPi

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: @PhilLovesPi

AuthorMessage
Avatar

Discostew

9,052. Posted:

@IAmAPersson Rebuttals are actually slightly slower. I assume it's because it adds more work to the parser. Use only with IF statements and if you feel you're going to hit the 9999 line limit. Having tested that out, I'll have to go through my code when I'm done with the project because I use an immense number of rebuttals. Then again, I'm at about 7500 lines of code and still not done.

Also, I never realized using STEP 0 could actually work in these scenarios because of how I understood FOR/NEXT loops. STEP (positive number) would indicate an exit of the loop if the iteration number is greater than the number being counted to, while STEP (negative number) would indicate an exit if the iteration is less than. I assumed STEP 0 was neither of these so it could not tell whether it should go up or down. Perhaps SB understands 0 as a positive number, but what's odd is that, based on tests, it considered -0 as a positive number as well.

One last thing about this method. This method of while loops is quite a bit faster than what I listed in my code above because it doesn't have to parse the line to reset the iteration variable (which does assigning, and that is slow in SB).

"What fun is there in making sense?"
Lazer Light Studios - Home of the MM2 PTC project

Pokemon 3DS Friend Safari - Ice - Spheal, Sneasel, Lapras

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

AuthorMessage
Avatar

TexMurphy

9,053. Posted:

Is there a PC program that can take an image and convert it to a GRP file or qr code?

TexMurphy

AuthorMessage
Avatar

InsertPi

9,054. Posted:

TexMurphy wrote:

Is there a PC program that can take an image and convert it to a GRP file or qr code?

PTCUtilities. That's what I use for porting Minecraft DS's textures, backgrounds, etc.

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: @PhilLovesPi

AuthorMessage
Avatar

TexMurphy

9,055. Posted:

@IAmAPersson Do you have to draw the image in PTCUtilities or can you import any image?

TexMurphy

AuthorMessage
Avatar

Morphbug

9,056. Posted:

If I remember correctly, Utilities allows you to import any image and it resizes them and all.

Espurr wrote:

http://instagram.com/p/lQPde5x-Ci/

It's almost ready! All it needs is a qr code.
EDIT: Tell me what you think!

Pretty nice!

Oh look! A Morphloggery.
Oh! eShop Gurus.

3DS Friend Code: 0173-1330-0080 | Nintendo Network ID: Abgarok

AuthorMessage
Avatar

InsertPi

9,057. Posted:

@TexMurphy you can import a PNG, it will convert the colours to a 256 colour pallette (it still liiks great), and will convert it to a QR.

You still have to resize the image manually via a program like Paint.

Edited on by InsertPi

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: @PhilLovesPi

AuthorMessage
Avatar

SmokedSausage

9,058. Posted:

IAmAPersson wrote:

@Discostew I never thought you could do that with FOR loops!

FOR I=1TO (condition)STEP 0
NEXT

That helps a lot. I guess it's because if the condition is met, it returns a 1, completing the loop. This is like a WHILE loop in PTC! Except you'd have to flip the condition for it to work. So would these two codes work the same?

FOR I=1TO (NUMBER==5)STEP 0
LINPUT NUMBER$
NUMBER=VAL(NUMBER$)
NEXT

And this pseudocode:

while (number != 5){
number = ToVar(GetInput)
}

And one last question: are new lines or rebuttles faster? (A rebuttle is a colon in SB.) And by how much? If rebuttles are faster, would it be worth going through my entire code and rebuttle-izing?

EDIT: For people like @Randomous, @Hansausage, and anyone else who uses C#, should I create a PTC class? It'd work like this (a GLINE command):

ptc.gLine(x1, y1, x2, y2, color);

and a PRINT command:

ptc.print("hi!");

Would anyone use it?

Wait what? That would be pretty amazing..
This may "Seem" off-topic but would anyone care for my Windows Forms app for rock paper scissors?

Hi, I'm SmokedSausage and i like meemoos :^)

Twitter: GabrielWarfield

AuthorMessage
Avatar

InsertPi

9,059. Posted:

@SmokedSausage so you'd use the PTC class? I'm thinking of doing

class SmileB { }

Good name? Bad name? I'd use the PTC class.

Sorry for the off-topicness. :(

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: @PhilLovesPi

AuthorMessage
Avatar

LeviCelJir

9,060. Posted:

I'm just going to say what I plan to add to rayspace more as a reminder to me but:
Campaign wise:
9 missions
mission 1 will take place in a forest
mission 2 will take place in a forerunner ruins
mission 3 will take place in an unsc base
mission 4 will take place in a desert
mission 5 will take place in icy mountains
mission 6 will take place in an covenant ship
mission 7 will take place in an unsc ship
mission 8 will take place in a covenant base
mission 9 will be the last mission haven't decided how to end it yet

Firefight wise:
multiple maps
a few enemy types
5 waves
settings and junk

Multiplayer wise:
Not real multiplayer everyone are bots
a few maps that work with every gametype
few gametypes
settings and junk
fun

Menu wise:
make fancy menus

Now for todays preview pics!
Untitled
Untitled

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