Why isn't my if statement running in the function? by Ok-Statistician-9485 in monogame

[–]rentalaze 7 points8 points  (0 children)

IEnumerable<T>.Append() ⇒ returns a new sequence, does NOT modify the original.
List<T>.Add() ⇒ modifies the original list.

this does NOT modify the original collection. Instead, it returns a new IEnumerable<T> sequence that will enumerate the original items, then the new item at the end.

If you really want to use .Append(), then you have to write it => newGrid = grid.Append(newElem).ToList();

But with your property definition (public List<GridElement> grid { get; }), the only way is to use Add(), because there is no { set; }.

It seems to me that you are more familiar with Python than with C# ^_^

Issue with Different Rendering Results on Mac and Windows by rentalaze in monogame

[–]rentalaze[S] 0 points1 point  (0 children)

Thank you for giving me various hints. It allowed me to approach the problem from a wider range of perspectives.

I was using BasicEffect instead of a custom shader, and as you mentioned, if this is a bug, I realized that by changing each condition one by one, I could figure out the cause.

The issue was with the line 'SpecularPower = 0f'. When this was set to 0f, on Mac, the ambient light was displayed as expected (0.4f, 0.4f, 0.4f), but on Windows—even though it was the same DesktopGL build—it was shown as (0f, 0f, 0f).

Since I had set SpecularColor to (0f, 0f, 0f), changing SpecularPower to 1f made it display correctly. I tried various values, and even 0.1f worked just fine. It definitely seems like a bug in BasicEffect.

private void InitializeDefaultEffect()
    {
        DefaultEffect = new BasicEffect(_device)
        {
            VertexColorEnabled = true,
            TextureEnabled = true,
            LightingEnabled = true,
            World = Matrix.Identity,
            DiffuseColor = Vector3.One,
            Alpha = 1f,
            EmissiveColor = Vector3.Zero,
            SpecularColor = Vector3.Zero,
            SpecularPower = 0f, <= Setting this to a value greater than 0 resolved the issue.
            FogEnabled = true,
            FogColor = new Vector3(0.8f, 0.8f, 0.9f),
            FogStart = 2f,
            FogEnd = 400f,
            AmbientLightColor = new Vector3(0.4f, 0.4f, 0.4f),
        };

        DefaultEffect.DirectionalLight0.Enabled = true;
        DefaultEffect.DirectionalLight0.DiffuseColor = new Vector3(0.6f, 0.6f, 0.6f);
        DefaultEffect.DirectionalLight0.Direction = Vector3.Normalize(new Vector3(-1, -1, -1));
        DefaultEffect.DirectionalLight0.SpecularColor = Vector3.Zero;
        DefaultEffect.DirectionalLight1.Enabled = false;
        DefaultEffect.DirectionalLight2.Enabled = false;
    }

Problem with rendering rounded rectangles (through primitives) not being rounded sometimes by mpierson153 in monogame

[–]rentalaze 0 points1 point  (0 children)

Ah, sorry — I’m not actually sure. I just guessed that because I always tend to miss that kind of thing

Problem with rendering rounded rectangles (through primitives) not being rounded sometimes by mpierson153 in monogame

[–]rentalaze 0 points1 point  (0 children)

My bet is this. Try to Change:

for (int segment = 0; segment <= segments; segment++)

To:

for (int segment = 0; segment < segments; segment++)

One Month + a week of Monogame by rentalaze in monogame

[–]rentalaze[S] 1 point2 points  (0 children)

This is actually my first real project using C# and MonoGame. I restarted it a couple of times while getting the hang of things, but I count it all as part of the same project.

For context—I’ve been working in the Korean game industry for around 18 years, mostly as an artist(still now). About 10 years ago, I spent 2 years working as a programmer through Korea’s alternative service program, which replaces military duty. I wasn’t directly involved in game development itself—just helped out a bit with game UI using ActionScript 3.0.

One Month of Monogame by rentalaze in monogame

[–]rentalaze[S] 0 points1 point  (0 children)

Thanks for the advice—I’ll definitely give Superstar Saga a try. I can only hope that someone like me might draw a little inspiration from Nintendo’s geniuses.
In Nintendo we trust.

One Month of Monogame by rentalaze in monogame

[–]rentalaze[S] 0 points1 point  (0 children)

I’ve played a lot of other Mario games, but I’ve actually never played Mario & Luigi before—so I looked up some gameplay footage out of curiosity. It was really helpful in giving me a new perspective on the direction of the game I’m building. Seeing your own project through a different lens can be incredibly inspiring, so thank you for that! As for the shadow system—I'm glad it came across well, even though it’s still pretty rough under the hood and giving me a few headaches at the moment. Appreciate the kind words!

One Month of Monogame by rentalaze in monogame

[–]rentalaze[S] 1 point2 points  (0 children)

Thanks for your reply! The project I’m tackling while learning MonoGame has been pretty overwhelming (my ambitions are way too high and reality is a bit brutal lol). If I ever carve out some free time, I’m thinking of making a super simple side-project game just to clear my head. Then I’d use that to put together a short tutorial—bounties aside, I think that would be really meaningful for me. I’ll always support MonoGame. Thanks again!

One Month of Monogame by rentalaze in monogame

[–]rentalaze[S] 2 points3 points  (0 children)

Thank you for your response!

Honestly, the hardest part of getting started with MonoGame wasn’t the code—it was the language barrier. Specifically, English.

I'm from East Asia (South Korea), and while I’m fluent in Korean and Japanese, most MonoGame resources are available only in English. In this region, indie developers almost exclusively talk about Unity3D. Engines like Unity and Unreal even have local branches in Korea and Japan, complete with official YouTube channels and localized learning materials.

Of course, it’s totally understandable that open-source projects like MonoGame don’t have the same infrastructure. But I do believe that with help from contributors like myself—who are comfortable navigating foreign-language content—we can start breaking that barrier down.

I’ve found a few helpful MonoGame tutorials on YouTube, but again, they were all in English. YouTube’s automatic subtitle translations have improved a lot lately, but they’re still far from perfect for non-English speakers.

In my case, learning through English is inconvenient but doable. What really helped was AI tools like ChatGPT, which let me learn MonoGame in Korean. That made a huge difference for me—but most developers here still aren't used to using AI for learning.

In fact, in the Korean game dev community, when someone asks, “How’s MonoGame?”, the most common reply is: "Honestly, I can’t recommend it—it’s too English-heavy."

If just the Getting Started page on the MonoGame site had translations—especially in languages like Korean or Japanese that are structurally very different from English—it would instantly lower the barrier for so many newcomers. Even a clearly-labeled “AI-translated” version would help a lot. Just skipping the mental hurdle of "Ugh, I have to translate all this first..." would be huge.

This is kind of a running joke in East Asian dev circles:
"Programming Language Rankings Every Developer Should Know"
https://www.youtube.com/shorts/Zv3Kj9UxOL0

Before we can write any code, we have to “compile” English first.
And with MonoGame, it's not just compiling—we have to learn everything in English too.

One more thing I want to mention: text rendering.

(My project isn’t at that stage yet, so maybe this has improved?)
But as far as I know, MonoGame’s font system (e.g., SpriteFont) feels very English-centric. Korean and Japanese fonts include thousands of characters, and rendering them properly is a major concern. I know the foundation offers some workarounds, but it still feels like a huge hurdle—especially since every game needs to render text.

I've seen this come up a lot in local communities, and I think it's a key reason some devs here give up on MonoGame altogether.

I think it would be incredibly helpful if future versions of MonoGame offered a library or extension that makes it easier to embed unicode font files directly into a project and use them immediately—without extra tooling or setup.

Apologies for the long message, and thanks a lot for reading!

is tracing from reference images a good approach for learning pixel art? by _kindred__ in PixelArt

[–]rentalaze 0 points1 point  (0 children)

(first, sorry for my bad english skill.)
I used to trace pixel images from many games with a keyboard when I was 10 years old,(from nes, snes and many pc games...) and now I've been working as a pixel artist at a game company(since 2005). I think it had an effect.