Archiverse Internet Archive
投稿のみ 投稿と返信
前のページ(最近)
110 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 3048
次のページ(過去)
返信[1]
親投稿
Oscar PwnageBlock
Well, since it involves waiting for the right moment, you could have a timer loop that accepts input, and you'd code the damage output depending on the time passed. It'd look something like this... 'THE VARIABLE 'T' REPRESENTS TIME PASSED IN FRAMES FOR T=0 TO 120 'WAIT 2 SECONDS AT MOST IF BUTTON() AND #A THEN BREAK 'EXIT WAIT LOOP WHEN USER PRESSES A WAIT 1 'WAIT UNTIL NEXT FRAME NEXT
0そうだね
プレイ済み
返信[3]
親投稿
Oscar PwnageBlock
Reuploading and publishing programs that were taken down is against the rules. If it was taken down before, it'll get taken down again.
2そうだね
プレイ済み
返信[24]
親投稿
Oscar PwnageBlock
As Xavier said, you must change all center coordinates to that of the touch screen. That includes the circle, as well as all line and paint coordinates/offsets.
0そうだね
プレイ済み
返信[20]
親投稿
Oscar PwnageBlock
You probably had a white background when drawing the pie chart, which meant that the circle and divisions weren't being drawn properly. A background color other than white will make it work. You could also specify <GCOLOR #BLACK> before the pie chart code or append <,#BLACK> to every graphics instruction that doesn't already specify color.
0そうだね
プレイ済み
返信[4]
親投稿
Oscar PwnageBlock
Yep! It's simple, and allows for different files to contain different data!
1そうだね
プレイ済み
返信[17]
親投稿
Oscar PwnageBlock
What color is the background you're drawing on? If it's white, you might want to write GCOLOR #BLACK before the pie chart code to set the default drawing color to something visible.
0そうだね
プレイ済み
返信[14]
親投稿
Oscar PwnageBlock
Circular geometric logic can be pretty confusing if you've never learned trigonometry, but if you need help you can always ask!
0そうだね
プレイ済み
返信[2]
親投稿
Oscar PwnageBlock
Similarly, to load the data back, you'd use another numerical array and the LOAD command. You can keep the array empty as it will be expanded automatically. All data will be in the same order as you saved it. I suggest wrapping the load in a CHKFILE conditional. IF CHKFILE("DAT:FILENAME") THEN DIM LOADARR[0] LOAD "DAT:FILENAME",LOADARR,FALSE HP=LOADARR[0] XP=LOADARR[1] IDK=LOADARR[2] ENDIF
0そうだね
プレイ済み
返信[1]
親投稿
Oscar PwnageBlock
You can use the SAVE command in conjunction with an array. First, you'd define the array, which must be numerical and will hold the data you want to save. Afterwards, you can use the save command by specifying the file type as DAT and specifying the array. E.g.: DIM SAVARR[3] SAVARR[0]=HP SAVARR[1]=XP SAVARR[2]=IDK SAVE "DAT:FILENAME",SAVARR
0そうだね
プレイ済み
返信[11]
親投稿
Oscar PwnageBlock
INC SUM,2*PI()*RED/TOTAL 'INCREMENT THE PERCENTAGE SUM GLINE 200,120,200+50*SIN(SUM),120-50*COS(SUM) 'DRAW DIVISION LINE ANG=SUM-PI()*RED/TOTAL 'AUXILIARY ANGLE FOR PAINTING GPAINT 200+45*SIN(ANG),120-45*COS(ANG),#RED 'PAINT IN DIVISION You can then simply repeat this above code for every color, replacing RED with the appropriate color.
0そうだね
プレイ済み
返信[10]
親投稿
Oscar PwnageBlock
Afterwards, you'll increase the percentage sum by an amount relative to 2*PI (a circumference) and the color in respect to the total. Afterwards, draw a line from the center of the circle to the percentage of circumference that corresponds to the division. We can get this value using simple trigonometry. You can also use a similar value to paint in the division. (Code in next comment)
0そうだね
プレイ済み
返信[9]
親投稿
Oscar PwnageBlock
Making a pie chart is actually not too hard! You'll have to draw a circle, and then divide it into segments using lines. The lines can be drawn logically using a bit of trigonometry and a relative sum. You'll have to setup some things first... TOTAL=RED+BLUE+GREEN+YELLOW 'SUM OF ALL COLORS SUM=0 'PERCENTAGE SUM GCIRCLE 200,120,50 'DRAW CIRCLE GLINE 200,120,200,70 'DRAW 1ST LINE
0そうだね
プレイ済み
返信[4]
親投稿
Oscar PwnageBlock
It's disclosure, not credit.
3そうだね
プレイ済み
返信[13]
親投稿
Oscar PwnageBlock
Just like Gale said, I'm just trying to keep this community alive and well by reminding people to follow a really basic set of rules and recommendations. Other communities have already gotten muted, removed, or afflicted by other restrictions. We don't want anything to happen to this game and its community. Also, hyperbole and slander are quite rude; don't use them.
2そうだね
プレイ済み
返信[2]
親投稿
Oscar PwnageBlock
To expand on what Xavier said, and copied from a previous comment of mine... You can use TOUCH OUT STTM,TX,TY STTM is how long the screen has been touched. It will be 0 if there's no touch. The time it returns is in hundredths of a second. TX and TY are the coordinates of the point that is being touched, or the last touched if the user is no longer touching the screen.
3そうだね
プレイ済み
返信[8]
親投稿
Oscar PwnageBlock
Here's the URL to the Miiverse Code of Conduct. You should actually read it. https://miiverse.nintendo.net/guide/
0そうだね
プレイ済み
返信[5]
親投稿
Oscar PwnageBlock
May I remind you, sharing friend codes is prohibited by the Miiverse Code of Conduct. So please refrain from doing so. Also, SmileBASIC only connects online to upload/publish/download programs and to buy DLC. No multiplayer interaction.
2そうだね
プレイ済み
返信[6]
親投稿
Oscar PwnageBlock
Ok! That's pretty good.
0そうだね
プレイ済み
返信[6]
親投稿
Oscar PwnageBlock
It's definitely interesting! I think it'd be nice if you could see your own colors after looking at the color descriptions, though.
0そうだね
プレイ済み
返信[3]
親投稿
Oscar PwnageBlock
I'd suggest centering the text a bit more vertically.
0そうだね
プレイ済み