Forums

Topic: Petit Computer

Posts 3,441 to 3,460 of 9,620

TexMurphy

I have updated the qr codes on page 65 of the qr code forum for my side scroller template. It would be nice if we created templates for different game types (side scroller, RPG, King's Quest type, etc...) I need to add background scrolling, climbing, and shooting(shouting). There is a strange effect where Miku changes when I press A and left. She changes into other sprites that were not called for.

@randomous Are you talking about a mini map for a larger RPG adventure. I would assume one cannot sample the sprite within PTC and would have to choose the color. btw Thanks for the music tutorials.

TexMurphy

randomous

@TexMurphy Oh, you liked them? Cool, I'm glad you did!

I was just wondering about the minimap, that's all. I decided to make a better minimap for Village so that it showed each individual cell, and I did it the "pick your own colors" way. It makes it harder to add extra stuff to the minimap, but it sure is less code... for now.

randomous

ramstrong

Gimmemorecoinz wrote:

Are there any tutorials made on using custom tiles in petit computer at all? Or even maybe some forum posts that might be helpful? example code?

Discostew answered your question beautifully. From your response, I'm guessing that you still don't understand the difference between BG Tiles, and BG MAP. Think of BG Tiles as custom font, similar to ASCII table. There are only 256 entries on that. Where as BG MAP is a 2D map 64x64 containing those characters. Much larger than 256 entries.

@bluerobin2
If you're thinking about path finding, A* is about all you need. There are other approaches. Gauntlet uses cellular automata pattern recognition. If I'm doing it, I'd use hill climbing algorithm. I'd radiate declining values starting from the player, and let the monster climbs to the highest value, thus finding the player. It's rather complicated to explain, though, so not a forum post

@randomous
I wouldn't sample the color. I'd define the color separately. For example: Players=green, monster=red, treasure=orange, and so on. Regardless of the actual color of the sprites.

Thanks for the music tutorial. I'll be sure to do something nice with my newfound knowledge.

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

Let's just call a spade, a spade.

3DS Friend Code: 1091-7596-4855

randomous

Wow, I can't believe you all used it! Well, not everyone... you know what I mean. Thank you!

randomous

swordx

randomous wrote:

Wow, I can't believe you all used it! Well, not everyone... you know what I mean. Thank you!

...I'm not using it...I prefer my own coding...

swordx

swordx

Gimmemorecoinz wrote:

it seems like i've missed out on alot the last few weeks.. I had a tooth removed. it hurts. I had it removed piece by piece and it's healing now.
I'm really happy to see how active this forum is still.
I have more free time on my hands again to program and I'm getting back slowly to working on legend of zelda lttp more seriously.
There's alot of things I have to add , I just did a play through of the original lttp, the first part of the game and first dungeon. I realized I may have to
change the way I'm doing this game. There might still be some pallete issues at first because ptc utilities is buggy with how it exports sprites.
I'm without a laptop right now to so I'm looking into a replacement but I'm short on money.
I would like to form a better project file or folder that I can keep on a usb or something with me that way working on it from anywhere is never an issue.
Oh. That's right. I noticed my youtube video about lttp for petit computer got alot more comments than I was expecting. So I commented back and posted the QR codes in the comments. For those of you who might have missed out or might want the link again here it is: https://www.youtube.com/watch?v=93YhyV3XvTY

In the near future, like in a couple of days I might want some help with developing this remake of zelda. There's a couple things I'm going to have problems with mainly with making sure the sprites get formatted properly into petit computer and making sure that the right sprites are in memory for me when I need them. Maybe Discostew you can help me out there pretty soon? That's one of the things holding me back actually is I'm still getting that glitched pallete issue with link swinging his sword.

Your QR code demo doesn't work, unlike the video.

swordx

Pixelrobin

So here is a simple "Move Toward" ai

IF EX>Y THEN EX=EX-1
IF EY<Y THEN EX=EX+1
IF EY>Y THEN EY=EY-1
IF EY< THEN EY=EY+1

This method allows other things, such as collision tests to be added to the IF statements. And you can even check idf the player is near beforehand.

I am using this when the player gets near, but I need neutral AI. Soooooo, anyone got any suggestions?

I am also planning to add some sort of pathfinding to the game.
.............
This isn't going to be very easy

Everybody do a chirp. CHIRP.

3DS Friend Code: 3007-9228-5126

randomous

Would anyone happen to know the total memory space I can use for just general variables in Petit Computer? I know the limit for a single array is 32,000 something, which is fine. However, I've got around 50,000 numbers floating around and I'm about to add 22,000 more. Eventually, I'm going to have around 100,000 (if I can). The reason I'm asking is because I can reduce the 22,000 to 7,000 by increasing the complexity of retrieving the data. Unfortunately, this processing would occur quite frequently, which isn't cool.

I guess part of my question is this: Is the "FREEMEM" variable reliable? Does it include the space required for ALL program assets, including the program itself (which is currently 155k)? Is it just memory in general, which means absolutely anything that goes in memory will reduce the number?

randomous

Discostew

randomous wrote:

Would anyone happen to know the total memory space I can use for just general variables in Petit Computer? I know the limit for a single array is 32,000 something, which is fine. However, I've got around 50,000 numbers floating around and I'm about to add 22,000 more. Eventually, I'm going to have around 100,000 (if I can). The reason I'm asking is because I can reduce the 22,000 to 7,000 by increasing the complexity of retrieving the data. Unfortunately, this processing would occur quite frequently, which isn't cool.

I guess part of my question is this: Is the "FREEMEM" variable reliable? Does it include the space required for ALL program assets, including the program itself (which is currently 155k)? Is it just memory in general, which means absolutely anything that goes in memory will reduce the number?

If I recall, you can have up to a total of 262144 elements across various array names, but you are only limited to about 2048 actual variable names which may include array names. you can check how many available variable names you have left by checking FREEVAR The element count may only refer to numbers as strings may take up more than the 4 bytes each numerical value can have, which with that multiplied by the number of max elements would be 1048576 bytes, the amount of memory available from the start of the program. Unfortunately, I believe FREEMEM only accounts for available memory not used for the program code, not the actual variables/arrays themselves, as after testing my program with checking that value mid-execution, it stayed the same as it did before actually running the program, which deals with DIM'ing a number of arrays.

Discostew

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

InsertPi

randomous wrote:

Would anyone happen to know the total memory space I can use for just general variables in Petit Computer? I know the limit for a single array is 32,000 something, which is fine. However, I've got around 50,000 numbers floating around and I'm about to add 22,000 more. Eventually, I'm going to have around 100,000 (if I can). The reason I'm asking is because I can reduce the 22,000 to 7,000 by increasing the complexity of retrieving the data. Unfortunately, this processing would occur quite frequently, which isn't cool.

I guess part of my question is this: Is the "FREEMEM" variable reliable? Does it include the space required for ALL program assets, including the program itself (which is currently 155k)? Is it just memory in general, which means absolutely anything that goes in memory will reduce the number?

Holy crap that's huge! What are you making?!?!

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:

randomous

@IAmAPerson620 Village. They're not all individual variables; it's mostly arrays. I've gotta store things like items per block in the village, meta data for each block, background tile information across 2 layers, items in inventory/chest/meta data for both. Oh, and a whole bunch of random information here and there, like the entire color palette, prices, names, item "classes", a list of the trees in the village, the moving entities on the map (which include type, xy position, xy velocity, pattern, activated, etc.). A bunch of crap lol.

@Discostew Yeah, I've noticed that even if I clear the variables, or check the memory before execution, the number doesn't change. Thanks though, I'll just assume that I have 1MB between the program and variables.

Edited on by randomous

randomous

swordx

For Dungeon Adventure 2, I'm going to have the overworld music be the Zelda theme, with each are using the theme from a different game. At the moment, I have the forest using the Link's Awakening theme, and the next area will use the ALTTP theme.

swordx

InsertPi

How do you make compressed memory files? I know that there is one file type that allows for a ton of saved data, but don't know what type of file it is or how to use it. Right now in all my games, I have something like this:

MEM$=STR$(VARIABLE1)
SAVE"MEM:SAVE1
MEM$=STR$(VARIABLE2)
SAVE"MEM:SAVE2

and so on. The reason I have so many MEM files is because of all the save data in my games. Please help.

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:

Ralph

What are the possible causes of an "Out of memory" error? I check the FREEVAR and FREEMEM variables but the numbers are both >1000 so I don't know what the problem is.

Ralph

damolii

Ok, everyone. Finally finished the demo for my rpg!! Please bear in mind 2 things. 1: I used PTC Utilities XD. 2:The main reason I am uploading these is so that if anybody has a fix for my collision, they can tell me. Well here it is!! http://imgur.com/a/DkYSp

@IAmAPerson620 Why don't you just get all your variables and save them in one MEM file?? That's what I'm doing with my RPG, and it works....

Edited on by damolii

I don't have a 3DS so what do I put here? -Damolii

randomous

zorkzedork wrote:

What are the possible causes of an "Out of memory" error? I check the FREEVAR and FREEMEM variables but the numbers are both >1000 so I don't know what the problem is.

There are generally two culprits:

  • You used a GOTO or a RETURN to jump out of a FOR loop before the FOR loop ended
  • You used GOSUB when you meant to use GOTO. GOSUB should only be used when you intend to RETURN.

Hope that helped!

Edited on by randomous

randomous

Hairmanban19

damolii wrote:

Ok, everyone. Finally finished the demo for my rpg!! Please bear in mind 2 things. 1: I used PTC Utilities XD. 2:The main reason I am uploading these is so that if anybody has a fix for my collision, they can tell me. Well here it is!! http://imgur.com/a/DkYSp

@IAmAPerson620 Why don't you just get all your variables and save them in one MEM file?? That's what I'm doing with my RPG, and it works....

I'll try this tomorrow. And when i do,i'll be sure to give you feedback.

...

3DS Friend Code: 3136-7615-5907

Please login or sign up to reply to this topic