Embrisk

Members
  • Content count

    246
  • Joined

  • Last visited

Community Reputation

105 House Lord

1 Follower

About Embrisk

  • Rank
    Ookla The Civilian
  • Birthday 06/09/1997

Profile Information

  • Gender
    Male
  • Location
    Great Southern Land
  • Interests
    Ookla

Recent Profile Visitors

505 profile views
  1. Yeah, I've tried StackOverflow. Nobody knows what's wrong.
  2. So, um, I may or may not have a python programming assignment due tomorrow. I was wondering if anyone could help me work out this code. (Please) It comes up with a name error and says that 'self' hasn't been defined. Anyone know why? (please help.....please) import tkinter import tkinter.messagebox import random import json class programGUI: def __init__(self): self.main=tkinter.Tk() self.main.title('Fruit Test') try: j=open('data.txt', 'r') self.data=json.load(j) j.close() except: tkinter.messagebox.showerror('File Error') self.main.destroy() return fib=0 for i in self.data: fib=fib+1 if fib<2: tkinter.messagebox.showerror('Not enough fruit') self.main.destroy() return self.Tbutton=tkinter.Button(text='True', command=lambda: checkAnswer(answer=True)) self.Fbutton=tkinter.Button(text='False', command=lambda: checkAnswer(answer=False)) self.Tbutton.pack(side='left') self.Fbutton.pack(side='right') def showQuestion(self): fruits=random.sample(self.data, 2) fruit0=fruits[0]['name'] fruit1=fruits[1]['name'] self.components=['calories', 'fibre', 'sugar', 'vitamin_c'] nutrition=random.choice(self.components) fruitNutr0=fruits[0][nutrition] fruitNutr1=fruits[1][nutrition] if nutrition=='vitamin_c': nutrition='vitamin c' measurement='milligrams' else: measurement='grams' moreLess=random.choice(['more', 'less']) self.mainMessage=tkinter.Label(self.main, text='100 '+str(measurement)+' of '+str(fruit0)+' contains '+moreLess+' '+str(nutrition)+' than a 100 '+str(measurement)+' of '+str(fruit1)) self.mainMessage.pack() def checkAnswer(answer=None): checkAnswer(showQuestion) if (answer==True and moreLess=='more' and fruitNutr0>fruitNutr1) or (answer==True and moreLess=='less' and fruitNutr0<fruitNutr1) or (answer==False and moreLess=='less' and fruitNutr0>fruitNutr1) or (answer==False and moreLess=='more' and fruitNutr0<fruitNutr1): tkinter.messagebox.showinfo('Correct!') else: tkinter.messagebox.showerror('Incorrect!') self=programGUI() showQuestion(self) self.showQuestion() <This is where it says I have a problem. tkinter.mainloop() gui=programGUI() Edit: The file I'm loading is a list containing dictionaries of fruit and nutritional information, eg: [{'name':'lemon', 'calories':'43', 'fibre':'75'...}{'name':'apple', 'calories':'89'....}]
  3. What would happen to a broken shardblade? It takes eleven seconds to summon?
  4. To me, Harry Potter scores 9.7/10 Non-cosmere about 9.2/10 cosmere about 6.8/10 Most important to least important: Engaging Characters doing what the established character would do in that situation Humour consistency (consistent magic, too) Certain story points all adding up perfectly. Yeah, Harry Potter has some odd stuff. Why are a few first year students able to get past obstacles designed by teachers? Why is moaning mertyl not questioned about the basalisk? Why is Harry Potter protected by plot armour? BUT it is engaging, with characters that feel real, and is full of humour. The magic might not follow strict rules, but it's fairly consistent, eg: magic tends to wear off depending on how well the spell was performed. That's why I like it so much. I like his non-cosmere works next. And then cosmere works last, (unpopular opinion,) because the plot seems to be dragging the characters around all the time to save the world from imminent doom, especially Shallan. Stormlight series is my favourite cosmere work, though.
  5. I've said this in another unpopular opinion section, but.. I prefer Harry Potter.
  6. It mentions that once you start compounding, it becomes dangerous to stop. That's just one thing I noticed.
  7. 1. Kaladin dressed as Dobby the house elf because it amuses the lighteyes. 2. Alcatraz realised he was in the wrong series. 3. I draw a chalk time machine for my chalking. He grabs chalk technology from the future. 4. Brandon Sanderson has nightmares about not including enough foreshadowing.
  8. I play a fast white deck with a little green. My reasoning? 74% of people think that blue is the strongest colour. The best defence against a control deck is a speed deck, usually white or green. Yay for MTG.
  9. Maybe it's because there are people in other countries who like Brandon Sanderson... Just maybe, though. ^^
  10. Is the alchemy in full metal alchemist a hard or soft magic system?
  11. Someone said: "introducing scorbunny and two literal pieces of trash."
  12. I got bored of anime. Except for the girl who leapt through time, everything I watch is inconsistent and full of boring plots, boring characters, or both.
  13. Maybe she IS just an emotionless slab of granite. Just kidding, I don't know.
  14. I think the only reason odium kills would be so he can inflict more pain.
  15. I think a nicrosil spike might have done it. Maybe not.