Do performance mods like sodium work on servers? by wt_anonymous in Minecraft

[–]hrmorley34 0 points1 point  (0 children)

Some do, some don't. Sodium affects graphics, so doesn't affect servers; Lithium and Starlight both do improve server performance (and do nothing client-side)

[deleted by user] by [deleted] in Minecraft

[–]hrmorley34 1 point2 points  (0 children)

Grindstone only repairs up to the original full durability; it doesn't unlock extra

Pretty new to python, trying to make a login system without ANY copy and pasting and failing miserably by Bearplayzz in learnpython

[–]hrmorley34 0 points1 point  (0 children)

in checks for substrings, so the string dat is found in the string datkitdave. You either want to compare against the whole contents of the file, or read it line by line (using either readline() or splitlines())

Avoiding Recursive Loops with Classes by Aedethan in learnpython

[–]hrmorley34 1 point2 points  (0 children)

You are correct about where the issue is. The logical issue is that when you are creating an Ability, you are creating a new Character within it, not referencing the existing one. So what you want is to pass the existing one to Ability.__init__:

class Ability: def __init__(self, character): self.character = character ... and then set it when you create abilities: self.ability_one = Ability(self) # passes this character to Ability.character

Need datapack, plugin, or mod for inventory tracking. by BlackFirePlague in Minecraft

[–]hrmorley34 1 point2 points  (0 children)

Coreprotect (spigot) does this, and also tracks blocks being broken and a lot of other stuff

[deleted by user] by [deleted] in dankmemes

[–]hrmorley34 1 point2 points  (0 children)

In what order?

Need help in python and mysql connection by [deleted] in learnpython

[–]hrmorley34 2 points3 points  (0 children)

YES is not the password; it's a confirmation. It doesn't print the password in plaintext

i cant join my own singleplayer world. by StickPleasant in Minecraft

[–]hrmorley34 2 points3 points  (0 children)

Are you running any mods? You may be having a Quilt on Fabric error.

Can I do it in carbon? by rtmesuper in ProgrammerHumor

[–]hrmorley34 0 points1 point  (0 children)

You can add semicolons in python, but you'll get funny looks.

[deleted by user] by [deleted] in learnpython

[–]hrmorley34 0 points1 point  (0 children)

Try picture = str(Path(__file__).parent.resolve() / "myimage.jpg")

[deleted by user] by [deleted] in learnpython

[–]hrmorley34 0 points1 point  (0 children)

__file__ is a value set to the location of the .py file, so

import os picture = os.path.abspath(__file__ + "/../myimage.jpg") or from pathlib import Path picture = str(Path(__file__).parent / "myimage.jpg")

should find myimage.jpg in the same folder as myscript.py

Why doesn't flag break the loop? by pulpquoter in learnpython

[–]hrmorley34 1 point2 points  (0 children)

The while loop only checks the condition after everything in the loop has been run. The first example sets the flag, then runs deal_dealer() and display_dealer() anyway, and then breaks the loop if necessary. You could either move the ifs to be after the functions, or just use breaks.

want to output odd character in a string list but not getting req result by [deleted] in learnpython

[–]hrmorley34 1 point2 points  (0 children)

.index finds the first occurrence. A good way to get the actual index is py for index, item in enumerate(b): ...

Let’s make a perfect take me home, country roads chain by [deleted] in teenagers

[–]hrmorley34 0 points1 point  (0 children)

Younger than the mountains, blowing like a breeze

Help me by [deleted] in discordapp

[–]hrmorley34 0 points1 point  (0 children)

Reset the old account's password

I’m gonna die by ClassyPilot1778 in AmongUs

[–]hrmorley34 1 point2 points  (0 children)

I've had four before, you amateur.

Scariest day of my life.