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! :)
@Ramstrong. Alright, I'll do that. I assume I can find that in the PTC QR thread.
@Linput Sweet . Thanks
Yeah, we should. My FC is in my signature. Also, you should know I'm not all that good with PTC.
@pHUNTERq I tried that and it seems to make it blink more...
I don't think it shouldn't though. Because that if statement is true when BTN is equal to anything but zero, so when your not moving, BTN = 0 so it shouldn't flicker... What I think you should do is this:
@MOVE
LOCATE X, Y: PRINT " "
IF BTN==1 THEN CLS: Y=Y-1/20
IF BTN==2 THEN CLS: Y=Y+1/20
IF BTN==4 THEN CLS: X=X-1/20
IF BTN==8 THEN CLS: X=X+1/20
LOCATE X,Y:PRINT"■"
GOTO @MAIN
@Ramstrong. Alright, I'll do that. I assume I can find that in the PTC QR thread.
@Linput Sweet . Thanks
Yeah, we should. My FC is in my signature. Also, you should know I'm not all that good with PTC.
@pHUNTERq I tried that and it seems to make it blink more...
I don't think it shouldn't though. Because that if statement is true when BTN is equal to anything but zero, so when your not moving, BTN = 0 so it shouldn't flicker... What I think you should do is this:
@MOVE
LOCATE X, Y: PRINT " "
IF BTN==1 THEN CLS: Y=Y-1/20
IF BTN==2 THEN CLS: Y=Y+1/20
IF BTN==4 THEN CLS: X=X-1/20
IF BTN==8 THEN CLS: X=X+1/20
LOCATE X,Y:PRINT"■"
GOTO @MAIN
No, when it's not moving it's fine. It's when it starts moving because it's constantly clearing the screen and printing it.
It was kinda tricky finding the QR codes from the blog site since the link did not go to the file page. I found them by going on to the project box, then select files, and go to the QR codes. You truly did an outstanding job on remaking these soundtracks for the Petit Computer. I been composing my music for my game and making sound FX for it. It can be difficult to work with when you type in the code into the box. It's a good experience for me to create music and sound FXs. I really love the freedom that Petit Computer gives you to work with. I'm getting off track. I really enjoy listening to these soundtracks. Great job.
If you're using the text graphic. You want to erase your previous your previous spot with a blank tile. @MAIN
BTN = BUTTON(0)
IF BTN THEN GOTO @MOVE
GOTO @MAIN
@MOVE
LOCATE X, Y: PRINT " "
IF BTN==1 THEN LOCATE X,Y:PRINT " ": Y=Y-1/20
IF BTN==2 THEN LOCATE X,Y:PRINT " ": Y=Y+1/20
IF BTN==4 THEN LOCATE X,Y:PRINT " ": X=X-1/20
IF BTN==8 THEN LOCATE X,Y:PRINT " ": X=X+1/20
LOCATE X,Y:PRINT"■"
VSYNC 1
GOTO @MAIN
Make sure that the loop have VSYNC 1 so it'll update the screen 60 frames per second for movement or game logic loops. Your "■" will still blink as it move currently. My current solution would be Delete the /20, and then increase to vsync 3. Then that box won't flicker anymore. Vsync 3 will update the screen 20 frames per seconds.
I have just a quick query regarding the use of Button(), or rather how everyone else seems to be using it
When using a series of IF statements to read the button input, everyone's code seems to be preceeded by a BTN=BUTTON(0) or such, specifically assigning a varitable to the use of storing the button inputs and then basing the IF statements on that.
In my own code I just incorperate the BUTTON() function directly into the IF statement, ie; IF BUTTON(0)==16 THEN PRINT "That's an A Button right there".
I just want to know if there's a specific advantage to using a spare varitable this way, or if there is something I'm missing here?
Using a variable to store button input is good for using BUTTON(0) only once, instead of constantly checking for button presses. Constantly checking button presses could cause problems with the user changing buttons midway through your IF's, which could cause weird stuff to happen. It's more consistent if you use a variable.
Still waiting for EU release. I actually contacted SmileBoom and asked when/if it will be released in Europe. I got the answer a couple of days later and it said:
Thank you for your e-mail.
But, Petit Computer can be downloaded in USA or Japan.
I'm very sorry.
Now, we try to sell Petit Computer in another country.
Thank you
I hope I won't need to wait much longer...
It's its, not it's.
Switch Friend Code: SW-8287-7444-2602 | Nintendo Network ID: LateXD
hey morphtroid, how is petitcross coming. i can't wait for the release of petit farm v 1.2. really m hoping that it will come out before the next demo of mega man 2 by discostew. also found out that my 99999, money dissipearing was because i forgot to save, sorry about that.
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! :)
For that type of ai you basically do a bunch of random movements at random time intervals.
Some psuedocode:
@LOOP
MOVETIME=MOVETIME-1
IF MOVETIME < 0 THEN MOVEDIRECTION=RAND(4) : MOVETIME=RAND(300)
IF MOVEDIRECTION==0 THEN ENEMY_Y=ENEMY_Y - 1
IF MOVEDIRECTION==1 THEN ENEMY_Y=ENEMY_Y +1
IF MOVEDIRECTION==2 THEN ENEMY_X=ENEMY_X - 1
IF MOVEDIRECTION==3 THEN ENEMY_X=ENEMY_X+ 1
GOTO @LOOP
Forums
Topic: Petit Computer
Posts 981 to 1,000 of 9,620
Please login or sign up to reply to this topic