? DocWaluigean's Extremely Annoying Millions of Questions (Page 1) ● SmileBASIC Source Forums

Sign In

Register
*Usernames are case-sensitive
Forgot my password
This website has been moved, please see this post

DocWaluigean's Extremely Annoying Millions of Questions

1 2
  • #1 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs Hello, I'm new to the communities involving SmileBASICSource. I don't want to tell anyone if I have autism or not, but lets just say I have complex in understanding programming situations. I asked a lot of questions to try to understand certain codes, but I don't want to be bothersome about things..even if it's too repetitive and simple. So I made this thread so I can express or speak whatever I want without feeling very bothersome to anyone. Possibly all my questions will be here. And yes, I'm from NESDev, and I would come back to it later when I gain enough confidences in myself. The first question I have now is what do I make now? A "Hello World" program with nothing but PRINT and things? Posted Edited by DocWaluigean
  • #2 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs I made my first program! But I can't use keyboard with SmileBASIC 4. Posted
  • #3 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs Posted
  • #4 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs Before I go to sleep, one important question: What is the list of most common code used like PRINT? Posted Edited by DocWaluigean
  • #5 ✎ 1090 Yolkai Head Admin randomous' tutorial series: http://smilebasicsource.com/page?pid=402 niconii's language changes guide: http://smilebasicsource.com/page?pid=1362 enclosed instruction booklet: https://sup4.smilebasic.com/doku.php?id=reference:top Posted
  • #6 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs Thank you very much, Yolkai! So I'm back! I read the official Japanese tutorials about it! Here's what I read about: PRINT VIBRATE BEEP and other important features: SPSET SPOFS SPROT HERE'S WHAT I BELIEVE IN THIS THEORIES AND SITUATIONS: SPSET is a SPrite SET, meaning "setting up the sprite, like give the sprite permission to appear in your program or games" SPSET 10, 0 The first digit of where 10 is are the identity of the sprite, and the second digit where 0 is is the location of the sprite. Zero is usually where strawberry is. So, judging by that, if you want to use it or place it in somewhere on that specific sprite, you always have to put 10 on the first digit on SPOFS SPOFS might mean SPrite OFfSet to mean the amount or distance by which something is out of line. Most likely wrong words. SPOFS 1, 2, 3 The digit of 1 is an identification of what SPR/SPRITE is judging from SPSET. The digit of 2 is the location of the X-axis (Left and right) where higher number means the sprite will go right. The digit of 3 is the location of the Y-axis (Up and down) where higher number means the sprite will go down. SPROT 1, 359 Obviously SPrite ROTate. The digit from 1 is the identity from SPSET 1. The digits from 359 is the rotation angle. 0 and 360 is the same thing. The sprite turns around toward 359 degrees. Then there's VSYNC and LOOP with IF THEN and THEN BREAK and ENDLOOP Like.... LOOP JOE = JOE + 1 VSYNC IF JOE == 100 THEN BREAK ENDLOOP It will keep adding JOE the Variable into one every 1/60th second, and if it reaches 100, it will "break" and continue the code after ENDLOOP. VSYNC is a special kind of "WAIT" code where instead of infinite, it's frame by frame, or 1/60 second by 1/60 second. If you don't have VSYNC in anyway, IT WILL MOVE INCREDIBLY FAST WITHOUT ANY STYLE OF VSYNC!!! There's the BUTTON function, but I didn't use it at all. ---- So the question is.. am I right 100% on understanding? Or there's something I am missing right now? Posted
  • #7 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs I'm reading the Randomous's tutorial right now while figuring out what to have fun in program: On part 3, What is the point in using DIM and VAR? In GameMaker stuff, there's 3 types of variables: Global, Normal {I forgot the name}, and Local. Global is that the variable can be used by ANYTHING in the program, while Local is only used once in one code. I remember that VAR is used to use the code ONCE then get deleted if the code is finished, which is to save memory so much. So in this situation, what's the point in DIM and VAR and what's the differences? I know I have to re-read it to get it, but I always get confused in anything. Posted
  • #8 ✎ 18 Na_trium DIM and VAR declare variables you will use. These do the same thing, so you can use whichever you like. In fact, you can use variables without using DIM or VAR. COOKIES%=5 PRINT "I have ";COOKIES%;" cookies!" When you put OPTION STRICT at the beginning of your code, you must use DIM or VAR to use variables. OPTION STRICT VAR COOKIES%=5 'I will use COOKIES% PRINT "I have ";COOKIE%;" cookies!" 'But COOKIE% isn't declared! In this case, if you use variables without DIM or VAR, it stops with Undefined variable error. Therefore, it prevents you from mistaking variable names. If you use DIM or VAR in DEF code, it will be a Local variable which can be used only in the DEF. The other variables are Global variables. (I don't know what Normal variable is. Sorry.) DEF ABC VAR X%=15 END X%=150 'This X% is different from the X% in ABC In addition, you have to use DIM or VAR if you use array variables. (like DIM ARY%[5]) (Is this the right way to use spoiler? I'm also new to SmileBASIC Source.) Posted
  • #9 ✎ 41 S_DE_Solutions Avatar Taboo I didn't change my avatar for 180 days Website First Year My account is over 1 year old Website Zelda Is Awesome! I love The Legend Of Zelda! Express Yourself In Smilebasic you have primary 2 types of Variables: global and Local. All variables will be global, if you don't write them in a function. Inside the Function you can use local Variables, and manipulate the global. Posted
  • #10 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs HOLY SMOKES English is now supported in official English name: SmileBASIC 4. Is there a way to change it back to Japanese? I don't mind either way. Posted
  • #11 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs I just found a way to change languages: you have to go to Settings in home menu on the Switch, not the Smilebasic 4, and change your languages found in the bottom section of the setting list. So I’m reading the DIM/VAR in SmileBASIC 4, and there are two extra pages compare to 3ds, only two, what is new to DIM and VAR?? Posted
  • #12 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs There’s a opcode called SGN, and it’s telling me “get the sign”. What is it used for and what good example could I use for it? I looked up into the help on sb4 and it said A=SGN(12.345).. any use for it? I see FALSE is no longer the code anymore, so I have to use #FALSE now? What does INIT mean when I look in other peoples code, and the official code? —- After frustrations on DATA atm, I’m looking into the Smilebasic official game with Jamaica story. So the option is Strict, and I hope to remember everything one person told us about it. What is a CONST? I know I can look into a book, but I always suck at getting the message across, like in NESDev 6502. It took me days to figure out what A X Y Register does. I checked it out what XSCREEN does now: It changes the format of how the screen gets zoomed in or not instead of what 3ds is. What is a TSCREEN? Set the width of console and font used for display. Examples please or good explanation using children analogy or food or smash brothers analogy so I can remember better... GTARGET. Specifying the graphic drawing target page. So it’s to change the usage of graphic? ...or...? That game has too many VAR and CONST... SNDSTOP stops all the sounds. Got it. Now, I get what SPSET is thanks to the beginners guide, but... SPHOME, SPLINK, SPCOL, SPFUNC. I’m feeling that SPCOL is to make the character appear “Huey color” no matter the sprite color used. SPCOL 1, 15, 100 In this pseudo code, the 1 is the ID of the sprite, 15 is the color, which I call it blue, and 100 is the opacity of the color, the character appearing full blue. Is this semi correct? Aside from SPCOL, what does SPHOME, SPLINK, SPFUNC, SPPAGE, SPUSED, SPVAR, and SPCOL do? And what does SPANIM do? Looking through the code, there’s SPCOLOR, so I am not sure what SPCOL and SPCOLOR does now.... SPSCALE and FILL? SPSCALE is a code that allows you to stretch or fatten the sprite, right? The SPSCALE 1, 20, 10 which is 1 as ID, 20 as X axis, and 10 in Y axis, which would make the sprite so widen and fatten left and right, Right? GLINE? SPHITSP? Hilaiously, SETANIM is not an opcode, but SPANIM is Posted
  • #13 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs I’m sorry if it’s so annoying, thats why I made this thread of me asking millions of annoying questions. I don’t go into other people’s code and ask the stupidest obvious questions, and having overwhelm with figuring out what it does and what limitations does and stuff. I know programming isn’t fun and easy, which is why there isn’t any fun pictures or fun stuff for beginner codes like what BEGINNER GUIDE in SmileBASIC 4 has. Posted
  • #14 ✎ 1528 rando Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Second Year My account is over 2 years old Website Avatar Taboo I didn't change my avatar for 180 days Website
    I’m sorry if it’s so annoying, thats why I made this thread of me asking millions of annoying questions. I don’t go into other people’s code and ask the stupidest obvious questions, and having overwhelm with figuring out what it does and what limitations does and stuff. I know programming isn’t fun and easy, which is why there isn’t any fun pictures or fun stuff for beginner codes like what BEGINNER GUIDE in SmileBASIC 4 has.
    What do you mean "not fun?" Programming can be really fun if you're into what your doing. I always find it super satisfying when I make a world system that works, or learn a new concept that I didn't previousley know. Sure, it can be hard, but you can make it fun. Sorry if this sounds rude in any way.
    Posted Edited by rando
  • #15 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs
    I’m sorry if it’s so annoying, thats why I made this thread of me asking millions of annoying questions. I don’t go into other people’s code and ask the stupidest obvious questions, and having overwhelm with figuring out what it does and what limitations does and stuff. I know programming isn’t fun and easy, which is why there isn’t any fun pictures or fun stuff for beginner codes like what BEGINNER GUIDE in SmileBASIC 4 has.
    What do you mean "not fun?" Programming can be really fun if you're into what your doing. I always find it super satisfying when I make a world system that works, or learn a new concept that I didn't previousley know. Sure, it can be hard, but you can make it fun. Sorry if this sounds rude in any way.
    One of my old friend years ago told me that Randomouscrap (Sorry if it’s you or not. I’m still new to this site.) said in the anonymous chat that no one is interested in programming BASIC as common as the old days anymore and no one “could force him to do what they say”? It kind of strike me as a warning not to fool around and learn something with proof here or I get scolded. Like the rules of NESDev stuff about not to be an a.s.s. or something. So sorry if I made error explaining. Your right, programming can be fun. But not many took the time to enjoy the pedagogue in programming. I’m around 24 years old and I struggle with learning things that looks boring compare to my high school days where it kind of was the last school where learning is fun. Again, sorry, just need to show my background a little to tell where I come from. If you were in NESDev and see me there, you totally understand where I’m coming from.
    Posted
  • #16 ✎ 1528 rando Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Second Year My account is over 2 years old Website Avatar Taboo I didn't change my avatar for 180 days Website Oh ok Posted
  • #17 ✎ 18 Na_trium
    There’s a opcode called SGN, and it’s telling me “get the sign”. What is it used for and what good example could I use for it? I looked up into the help on sb4 and it said A=SGN(12.345).. any use for it?
    I found this code in GAME3JUMP(a sample game in SB3) AX1=AX1-(0.05*SGN(AX1)) If AX1 is larger than 0, it decreases AX1 by 0.05 If AX1 is smaller than 0, it increases AX1 by 0.05 Therefore, AX1 will eventually be 0.
    I see FALSE is no longer the code anymore, so I have to use #FALSE now?
    Yes.
    What does INIT mean when I look in other peoples code, and the official code?
    It means initialize.
    What is a CONST? I know I can look into a book, but I always suck at getting the message across, like in NESDev 6502. It took me days to figure out what A X Y Register does.
    It is constant. It's different from variables because constants can't be changed after. CONST #COOKIES=5 'You can't change the number of cookies anymore
    Now, I get what SPSET is thanks to the beginners guide, but... SPHOME, SPLINK, SPCOL, SPFUNC. I’m feeling that SPCOL is to make the character appear “Huey color” no matter the sprite color used. SPCOL 1, 15, 100 In this pseudo code, the 1 is the ID of the sprite, 15 is the color, which I call it blue, and 100 is the opacity of the color, the character appearing full blue. Is this semi correct?
    No. SPCOL means sprite collision. It allows to use SPHITSP or SPHITRC, which checks whether sprites hit other sprites. But you can change the color of sprite with SPCOLOR. SPCOLOR 1,#C_BLUE
    Posted
  • #18 ✎ 14 DocWaluigean Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Drawing I like to draw! Hobbies RNG Hidden Easter Eggs
    There’s a opcode called SGN, and it’s telling me “get the sign”. What is it used for and what good example could I use for it? I looked up into the help on sb4 and it said A=SGN(12.345).. any use for it?
    I found this code in GAME3JUMP(a sample game in SB3) AX1=AX1-(0.05*SGN(AX1)) If AX1 is larger than 0, it decreases AX1 by 0.05 If AX1 is smaller than 0, it increases AX1 by 0.05 Therefore, AX1 will eventually be 0.
    I see FALSE is no longer the code anymore, so I have to use #FALSE now?
    Yes.
    What does INIT mean when I look in other peoples code, and the official code?
    It means initialize.
    What is a CONST? I know I can look into a book, but I always suck at getting the message across, like in NESDev 6502. It took me days to figure out what A X Y Register does.
    It is constant. It's different from variables because constants can't be changed after. CONST #COOKIES=5 'You can't change the number of cookies anymore
    Now, I get what SPSET is thanks to the beginners guide, but... SPHOME, SPLINK, SPCOL, SPFUNC. I’m feeling that SPCOL is to make the character appear “Huey color” no matter the sprite color used. SPCOL 1, 15, 100 In this pseudo code, the 1 is the ID of the sprite, 15 is the color, which I call it blue, and 100 is the opacity of the color, the character appearing full blue. Is this semi correct?
    No. SPCOL means sprite collision. It allows to use SPHITSP or SPHITRC, which checks whether sprites hit other sprites. But you can change the color of sprite with SPCOLOR. SPCOLOR 1,#C_BLUE
    So a SGN is a "Round the numbers down or up from .5 -> 1.0 or .4 -> 0.0 ? I see. "set to the value or put in the condition appropriate to the start of an operation." I kind of don't understand. Is this means "A type of variable creation mode"? Like INIT section is a full of variables and DIM and VAR? So CONST [Constant] is a permanent-lockup VAR/DIM/ regular variables where, no matter what, you can NOT change the variables before and after line? What was the point when you could just not change the VAR/DIM/variables? Or it's a "String/Word-only" variable? SPrite HIT SPrite and SPrite HIT [R?] Check? I'll think about those. There's still many more questions I need to answer, but thanks for replying. How can code be easy to learn?
    Posted
  • #19 ✎ 481 MasterR3C0RD Power User Amazing Contributor Someone thinks I'm an awesome person who has done so much for the community! Achievements Third Year My account is over 3 years old Website osu! Is Awesome! I love osu! Express Yourself
    So a SGN is a "Round the numbers down or up from .5 -> 1.0 or .4 -> 0.0 ?
    SGN takes a number as input and returns: * -1 if the number is negative * 1 if the number is positive * 0 if the number is 0
    Posted
  • #20 ✎ 1882 12Me21 Syntax Highlighter Received for creating the code syntax highlighter on SBS Night Person I like the quiet night and sleep late. Express Yourself SGN checks if a number is greater or less than 0 SGN(100) -> 1 SGN(0) -> 0 SGN(-5) -> -1 CONST is faster than using a variable (it's the same speed as using a number directly) CONST #SIZE = 8 * 2 VAR SIZE = 8 * 2 X = X + SIZE 'slower 'These are the same speed: X = X + 16 X = X + 8*2 X = X + #SIZE Posted
1 2