Ask your own question, for FREE!
Computer Science 6 Online
OpenStudy (poopsiedoodle):

@kainui

OpenStudy (poopsiedoodle):

http://pastebin.com/kaiXbWpT Near the bottom of the Main Form code is all the drawstrings and whatnot.

OpenStudy (poopsiedoodle):

OpenStudy (kainui):

ok what did you say was going wrong again I forget something like it's drawing the last string on top or underneath something?

OpenStudy (poopsiedoodle):

The last string is being drawn, and then for some reason when it's done drawing the strings, they all get re-drawn, and the last one disappears.

OpenStudy (kainui):

Hmm I looked but I don't do C# so I couldn't find your error. Two bits of opinion, I personally don't like when { are put on their own line, it makes the code a lot longer and harder to read through personally. Other thing is, you should consider using switch statements instead of all these else if statements. It also looks like you're repeating the same exact code within each of these else if statements, I suggest just making a single string, and then setting the string like `s="♛"` in the statements, then before and after all these else if statements just put this code: ``` Graphics g1 = t.CreateGraphics(); //else if stuff here setting the string s g1.DrawString(s, new Font("Arial", 25), Brushes.Black, new Point(11, 16)); ```

OpenStudy (poopsiedoodle):

ye, just started working on putting it all into one method while you were typing that :p

OpenStudy (kainui):

cool, yeah I'll give it another look if you can't find it. I suggest trying to break your code itself in simple ways, I feel like since it's the last thing in your list it's some kind of off by 1 error in an array or something funky, that's my guess lol

OpenStudy (poopsiedoodle):

Well, I added t.refresh before calling the draw function, and now they stick, but it seems that the program is stuck in an infinite loop of refreshing and it won't let me do anything else.

OpenStudy (poopsiedoodle):

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Latest Questions
Mari103: How to pop out like a Jacc In the box
7 hours ago 0 Replies 0 Medals
Breathless: Spooky witch but cute
14 hours ago 3 Replies 0 Medals
Arriyanalol: help
14 hours ago 10 Replies 2 Medals
Arriyanalol: @tinydinoUwU stop trying to find a argument u blad lil boy
1 day ago 5 Replies 4 Medals
Jaded012023: Please tell me what you all think of this song
17 hours ago 6 Replies 1 Medal
Arriyanalol: bro how
17 hours ago 2 Replies 3 Medals
Arriyanalol: cant wait for the new bluey movie in 2027
1 day ago 12 Replies 2 Medals
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!