Page 2 of 3
Re: Journal
Posted: June 18th, 2017, 6:42 am
by Zedtho
oh, the image is too wide
edit: got it to work! Will add other images now too
edit 2: Why is there a delete button next to this message, but not next to others?
Re: Journal
Posted: June 18th, 2017, 9:41 am
by albinopapa
Once your post has be superceded by other posts, you can't delete them. Admin and moderators can though.
Re: Journal
Posted: June 24th, 2017, 7:13 am
by ceofil
Salta looks cool mate. You could make doodle jump out of that.
Re: Journal
Posted: June 24th, 2017, 4:42 pm
by Zedtho
Thanks! I've been working on Simon Says a bit more. Im having a lot of problems with timing and a lot of errors too. Frustrated.
Re: Journal
Posted: July 2nd, 2017, 6:47 am
by Zedtho
I got the timing to work. The only problem now is that it won't take input. I'll try different types of input, but I think it's another logic error because I'm a derp
.
Re: Journal
Posted: July 8th, 2017, 7:13 am
by chili
Did you end up fixing to work with state variables across frames, or are you still doing timing loops within a single frame?
Re: Journal
Posted: July 8th, 2017, 6:34 pm
by Zedtho
I'm currently using the former, the latter didnt work well and made the program unresponsive.
Do you mean boolean values by state variables?
Re: Journal
Posted: July 8th, 2017, 6:41 pm
by albinopapa
booleans are but one way to handle state, and depending on how defined a state is, a switch statement using enums would be a better fit, at least at the level you are at. You can also make state classes, where each defined state is it's own class.
Re: Journal
Posted: July 9th, 2017, 8:16 am
by Zedtho
I haven't actually had enums yet as far as I know, atleast Im not that far yet in the tutorial. Enums do seem like the perfect way for handling the different squares, thanks for the answer
Re: Journal
Posted: July 11th, 2017, 3:22 am
by chili
Yup, enums are the right fit. If there are only 2 possible states I often go for bool. You can also make a custom class or a class heirarchy for your states, and that will allow to do you some cool bullshit, but usually it's gonna be unwarranted overkill that will just make your code worse overall by overcomplicating it.
Just don't make your states int and we're cool (float is fine though :kappa:)