u/___user_0___

4 post karma · 439 comment karma · joined Mar 2022

  1. 1points

    Sound playback problems (self.archlinux) [SUPPORT]

    1 comments

  2. 1points

    C++23 <print> (self.cpp)

    3 comments

  3. 1points

    How do I reconnect flex cable? (i.redd.it) [Hardware]

    5 comments · source

___user_0___
___user_0___

What about English's "Malice"? :D

___user_0___

It runs well already, but I'm sure there's room for improvement; depsite being a 2d game with no "extra fancy" graphics (I play with most graphics settings to lowest possible), it still heats up my laptop up to the CPU's recommended temperature limit (80°C; and I was able to turn down Minecraft graphics settings enough to run just with slightly above 60°C (1.7 with optifine)). Though it works and runs even on quite bad devices, so it's not worth it rewriting it. Also a perk of Java (and other JIT compiled languages) is runtime reflection, which alows mods to do way cooler things, (Minecraft illustrates this well :) ). Also Java uses a lot of RAM, but Mindustry is small enough so that's not a problem here.

___user_0___

calculated it for poly as well now, it has almost 700 rps :D, so a between third and half of a mega :)

___user_0___

Poly is overpowered for unattended defense, mega is even more ridiculous :)
I've already made a bit more detailed comment on a similar post:

https://www.reddit.com/r/Mindustry/comments/12jtar5/comment/jg05y56/?utm_source=share&utm_medium=web3x&utm_name=web3xcss&utm_term=1&utm_content=share_button

Edit:

I've looked at the code again, and I think that the problem is that the code uses 60 * repair_percent as health repaired by one bullet, which is true when the block being repaired has 6000 health, which is more than even the tetrative reconstructor :D. I think that it was meant to be 60 * repair_percent% (or 60 * (repair_percent / 100)) instead, which fits for the block that is being repaired having 60 health, which is way more realistic :D Maybe this should go into github issues... :D

___user_0___

It turned out that Musescore somehow breaks something (probably pipewire) and when I close it then everything returns back to normal...
Though I don't know how Musescore can even do it

___user_0___

S ohledem na to, jak přemnožení lidé jsou to je podle mě vlastně dobře :) (i když sám dítě asi docela chci)

___user_0___

I guess that we just have a different idea of what "modern best practices" for c++ are...   

I don't think that copying when moving suffices or using virtual for tagged unions is a modern best practice/idiomatic (and use of variant doesn't seem to me as unidiomatic, though it is more uncomfortable than rust's enums)

(edit: formatting)

___user_0___

it's one of things making c++ slower, but I wouldn't call it a practice... potentionaly using compiler extensions for restrict could be a best practice, but as far as iso is concerned, it is just a part of the language

___user_0___

When you have to use shared_ptr (in many cases you can get away by using unique and raw pointers as "weak references") and the overhead is important, then it's quite simple to write a rc yourself...
Overall I just think that "modern best practices" along with modern c++ itself is mainly about having zero overhead...

___user_0___

AFAIK using shared pointer when it's not needed isn't a best practice... unique pointers shouldn't have overhead unless you don't count not freeing memory for short-lived programs as an overhead, and even in that case I'm pretty sure you can make it use a custom allocator. It might be even faster because of some UBs, but Rust unwraps should get mostly optimized out anyways, so by default it's probably equivalent to Box in terms of performance

___user_0___

Just curious, which modern best practices for c++ cause overhead?

___user_0___

I'm sure it can be - in the worst case you can just replace some entry function with your own, and then use the rest of the game as a library

___user_0___

I guess at least alternating router / gate (overflow or underflow) or distributor and a lot of conveyors

___user_0___

Nepoužívám windows, takže o tom tolik nevím, ale vypadá to, že máš nějaký powershell skript co se spustí při startupu. (a chce kopírovat nějaké soubory; nevím co znamená to 24)

Asi se zkus podívat do startup složky (doporučuji zobrazit skryté soubory a přípony souborů; `windows+R` a `shell:startup` by to mělo otevřít) a zkontrolovat co tam je.

___user_0___

C is defined by a standard, not by implementation of some compiler - so you either use platform/compiler-specific extensions/assumptions or the code works with any standard conforming C compiler

there's also <stdint.h> since C99

___user_0___

You can also do more things you just want to do without the language making it (intentionally) annoying, so when safety isn't top concern then you can be faster. But for comparing different languages, you should probably add some context about what you want to do with them - it's like "should I learn Finnish or Swahili?"; there are things to say, but most of it depends on asker's interests.

___user_0___

In order to make strong enough countergravity on Earth, you'd need to build pretty much another Earth just next to it. Also the gravity at some point in a sphere with regular density is equivalent to the gravity "produced" by the part of it closer to the center than the point, so the whole ring would cancel it's own gravitational effects on the equator, leaving it with just normal Earth gravity, and the poles with somewhat stronger gravity, depending on the mass of the ring.

___user_0___

Isn't Edge basically the same but just with Microsoft? Not that I know a lot/care about it, but to me it doesn't seem like a reason to use Edge instead of Chrome...

Edit: Well, I used a really bad wording here, I meant that I don't care if Edge does/doesn't collect data since I don't use either of them, I'm on Linux with Firefox :D

___user_0___

std::vector<bool> :D

___user_0___

Thanks for reply, I finally managed to do it!
I had to push the cable further into the port, but it was getting stuck on some tiny ledge so I didn't insert it so far before :D

___user_0___

every time I tried that, it just slipped out right after - (when I was taking it out, the connection was definitely able to hold itself though)
also, how far in should the cable be?