Read a couple pages back. I knew doom and raycasting would show up sooner or later. I forgot who it was that was making pinball. I peeked the blog. Is it an EM or SS or pc based? I dunno too much but i kinda know what a dash 35 is.
Any standard libraries to append that support stack or structures? Any msg box stuff?
I'm not to advanced, but I get around not having a big list of variable names to remember for subroutines by using a stack.
just sucks having to do
sd= x: GOSUB @push
sd= y: GOSUB @push
str$= "some pt"
gosub @newp
MyP = ret
it bloats every function definition with pops and pretty much everything is now an array access such as:
PX(LP0(SomeLine)) to access the L.p0.x basically
but i feel like im not really programming in basic this way
any mouse like event handling code in use for touch screen support like pressed, hover, release etc?
Just wanna avoid re inventing the wheel.
Any gui stuff like on screen buttons with states to monitor etc?
Basically a standard starting point/template.
maybe im not embracing the shining points of basic.
i was playing with maincntl and noticed it is slower than the time$ var by about 1 second every 5 minutes. Was making a five minute timer/alarm to tap while playing destiny to remind me my cooldown was up and noticed it was slow. Is that because of the 59.97 hz i was reading about a few pages back? I know that was regarding nes sound or files, but though it might be a standard clock frequency in hardware/games.
anywho thanks for any replies or links to templates/starting points.
For mm ptc?
Anywho. Is there a way to check if a file has been appended?
Just thinking outloud.
If I store my "objects" in separate files and append them at runtime, will they still work?
If my program is nothing more than
Append "stackdef"
Append "pointdef"
append "demo"
Gosub @stackdef
Gosub @pointdef
Gosub @demo
Edit*
It appears append is run mode only.
So i dont think i can write a program that will append what it needs. Ill have to do it by hand and not save the changes to make editing and removing lines easier.
Doing something like exec "stackdef" from inside demo wont return back to demo unless I make all my objects end with an exec demo.
so i could do:
if ReturnFunction$!="" goto ReturnFunction$
Call$ ="@stackfunction"
Prog$="stackdef"
ReturnProgram$="demo"
ReturnFunction$="@returner"
Gosub @caller 'should give us a return point that can be used in @returner after the executed program executes us back.
?"returned sucessully":end @caller
exec Prog$
End 'should never execute this line because next run will jump to @returner @returner
return 'should return to line after "Gosub @caller"
End 'should never execute because we return.
Stackdef always executes call$ and returns by exec'ing returnprog$
At the top of demo itll check to see if ReturnFunction$ is empty
If it is empty it assumes its being ran for first time. If not itll goto the function. In this case to a function that just returns...
But it appears when exec'ing the return mechanism internal to ptc is cleared... i get an error saying return without gosub.
=(
Its obvious the strings are holding values between execs. But i dunno if the "return stack" is reset...
so something
Gosub @test @test
Exec"test"
Will eventually run out of memory because its a bunch of gosubs over and over...
Seems ill only be able to use hard label return points when coming back from an execute.
posted my qr code in the qr code forum entry 1692
I can't figure out any use for this since I lose whatever sub I'm in when exec'ing back.
Unless calling a loader/saver and passing it data in a common array or onetime initialization routine that executes. Would this save line count or characters, therefore allowing for bigger programs? assuming the strings aren't wasting too much space? or maybe a loader that loads in strings from another prg? I haven't tested what happens with data statements between EXECs either. https://www.nintendolife.com/forums/dsiware/petite_computer_qr...
Today I tried to make a qr code for a grp, it did not work well. I clicked Make QRCode and then PTC Utilities stopped responding. Also I imported the grp from a png file. I checked and its the correct dimensions. Does anybody know how to get this to work?
Today I tried to make a qr code for a grp, it did not work well. I clicked Make QRCode and then PTC Utilities stopped responding. Also I imported the grp from a png file. I checked and its the correct dimensions. Does anybody know how to get this to work?
Hmm... Not sure, as it seems like you did everything correctly... Have you tried running it in compatibility mode?
I tried running it with compatibility mode for: Windows XP (Service Pack 3), same result. I'm not sure what compatibility mode to try. Also the program only stops responding when I import a grp and try to make a qr code.
@MyLegGuy, on the MML code, did it give you an error? If so, please tell us so it would be easier to tell you what went wrong. If you fixed it then great.
Also, I may not be making any progress on any of my programs for a while. Why? Because ORAS are out (Yes, that's correct grammar. ORAS is an abbreviation for Omega Ruby and Alpha Sapphire.) But however my programs aren't out, and even those finished probably wouldn't be released for quite a while.
Like a boss? Please, I AM a boss. You're welcome
3DS Friend Code: 1543-5315-3818 | Nintendo Network ID: Storybookten9
edit
I get a garbled sprite using
Spset 0,448, 8,0,0,0,64,64
I should be getting the space ship right from the default sprites but i get a garbled sprite.
It was appearing on screen fine but i then loaded a few samples and ran them to get the spread syntax from the listing.
To do what everybody does when first playing with sprites. Map the left and right buttons to spangle calls. But after fumbling with spread syntax i got messed up sprites.
Restarted ptc, restarted the 3ds. I cant figure out why it is doing it.
Did chr init to spu7 before and after. Cant get it to ungarble.
The only thing i can think of is ptc is loading something I saved like a custom sprite but i thought ya had to load your own sprite everytime.
Am i missing a parameter somewhere
This what i get in chred
which makes me think i somehow saved to spu7 but i dont kno whow toclear it back to "factory"
Im pretty surr a fresh ptc boot and ine line in run mode isnt gonna garbl sprites so either i have a huge concept error or i somehow i am missing the storage/read modes of sprites
I used chred and made a 32x32 and Copy and pasted it and filled in with diff colors. Saced yhe chr and color and loaded to show that im not crazy the sprites are loading properly.
here is what it looks like in chred
I can use gputgcr with a few 0-3 and 0 to 1 x and y loops to get it to show up. I read either around page 319ish or 400 something on the forums somebody posted a nice one screen program I saw. That did some nice saving an loading.
Saw a question asking why people program in ptc.
My answer is it is a fun! Not to complex, quick turnaround time environment that is fun to bug chase etc.
It also kinda gives clues into how other languages and conventions we know and love came about.
I like the idea of interpreters being written in basic but i dunno if i have a use for them. Its like playing with clay or crayons quick and responsive.
I like hearing about other peoples hobbies motivate them or being tied in. With no problem, comes no solution. I havent plugged in too many other peoples qr codes, i like snippets myself.
Enjoy starring at code and wondering, am i finding a bug or do I not understand it. Its like reading high-row-glyphs and figure'ing out the story.
Id like to see an awesome standard library that people use almost everytime. It might not get used but it is pretty cool.
saw old posts about people asking for type support or dot operators.
I wrestled with this myself in base object index and offsets for properties. Using one array for a type ya can get
Type(Type(type(ref+property)+property)+property)
Ya can see the dot operator evolved from +property)
And see what looks like casting kinda at the front.
I use an array for each "type" property and use it backwards.
PX(L1(some line) I call it the "of" style.
x of point 1 of some line. Just sucks that ya have to add an array for every property/member of your type/class.
I did see a cool thing in game5 demo where they pushed and popped the sprite variables into their functions parameters, kinda. I noticed it had some offset constants kinda called vhp or something that did nothing but say what sprite var to read 0-7 i think. Very cool stuff. Just rambling. Forum is moving slow. Id bet all this has been discussed or moved to other forums.
Hopefully with ptc 3ds or smilebasic whatever its being called, isnt too much of a shift.
I love the pros and cons of having real colors in every pixel but indexed sometimes is fun or snappier. Cant wait.
She rotates.
05dec14 edit*
Watching nasa launch and a lil jack crenshaw reading has me wondering if anybody has a safe math library if needed for ptc? I do recall either the tan or atan functions will cause div by zero in some cases.
I haven't posted here in awhile but I wanted to come back to give congratulations to DiscoStew for the phenomenal work on Mega Man 2 PTC. This could easily qualify as a Special Edition that never was and deserves all the credit where credit is due.
hey it's me! i was Zombie Chiggers but it's been so log that ive been on the forum that i forgot my entire login so i am under a different name now.
i know this is off the forum topic but i was playing pokemon leaf green and i came across something and i was wondering if you guys knew what it was.
Want to add a saying to the DarkTimes A Tale of a mage and the lost kittens Game Battle system?
If so just leave it in a comment in the format like this...
Example: [ for DT FN- ( player slash at monster and misses..)] or (monster jumps at player clawing and slashing)
This is just for fun while I'm spending time on updating engine for doors stairs and other little thing.
so if you want your saying to be add to battle system just make sure you keep it clean, unless it was already added by me.
@GraphicGenius I know you posted this over a month ago, but all of my programs can be found on the Petit Computer Wiki. Just search for "Credits Example". Another alternative is to look at my user page for my programs specifically: http://petitcomputer.wikia.com/wiki/User:Randomouscrap98
Forums
Topic: Petit Computer
Posts 9,481 to 9,500 of 9,620
Please login or sign up to reply to this topic