I think with Sanji, Oda kind of pigeonholed his vision into his narrative arc for Onigashima to be his identity crisis and his newfound powers. So either he completely overlooked the fact that he is in a country with a nationwide famine (resulting to a parent killing their own child) or that he noticed that discrepancy but had already penned down the Queen and Sanji's conflict in his head. I personally thought that some good points were raised and in hindsight, his narrative arc would have more character weight to it if he were to confront and defeat the person that was the primary cause of the famine. However, that would mean that, because he is ALSO in conflict with the use of his new powers, his narrative arc then would be weighted down by a little too much compared to the other crew members involved. I think it can be a valid point when you are handling a large cast of characters and don't want to do that for a myriad of reasons. But it is also equally valid to call it out as bad planning because there is a certain way to work around it without sacrificing characterization. Characters feel more like a variable and plot devices which is really something that One Piece has been insufferable for since the time skip.
I've said it and I'll say it again, Wano was not a good arc. Zoro being the one instead of Sanji reacting to the red bean soup wastage, Carrot being shelved despite everything signaling a bigger role before the ship landed on Wano, Yamato having so much potential but ultimately just exist, the Samurais being severely underutilized, the Flying six being a letdown, bullshit fake out deaths, bullshit actual deaths, a terrible, terrible handling of the companion pieces (Kinemon and Momo), Hiyori's handling, Zoro's non-existent "this is his arc" bullshit, and there are so, so many problems with the arc that showed Oda at both his best and his worst. People keep going on and on about how peak One Piece is because the world is so big and there are so many characters and I keep saying the same thing over and over again that it is the series biggest strength but also biggest weakness. Wano DIDN'T even need that huge of a cast. No, seriously. And I shudder to think about how a much, much larger cast is going to be handled in the end game.
Regarding the Sanji thing, I'm not defending the writing whatsoever but since the famine is a nationwide tragedy and Luffy is the main character, it stands to reason that Oda wants those themes to be the motivation, or at least one of the primary motivations, of Luffy's conflict with Kaido. And this isn't something new either because if we think back to Alabasta where the tragedy was the lack of rain leading to heavy periods of drought, Luffy does bring that up in his conflicts with Crocodile. We can even look towards Dressrosa which does the same thing. His ending line to Doflamingo before defeating him was about how suffocating/enslaved the country is and that defeating him would save the country from that tragedy. So really, it's not something new because for whatever reason, Luffy always has to represent what is wrong with the circumstances of the country before destroying said circumstances. At this point it is predictable and whether we like it or not, he is being written to be the saint/hero/jesus character and that he alone, will scream the moral punchline before absolving the countries of their tragedies.
Sanji isn't even the first because, in Punk Hazard, it would have made so much more sense and created more room for character development had Chopper played a key role in the defeat of Caesar. Had he even shown any sign of introspection or used any of what he encountered to further his dream and beliefs? But not really, because despite his utter hatred for what opposes his very core, he was willing to praise Caesar in an offhand and casual remark for comedic effect. Personally, I'm glad that more people are calling the series out for this but I have long resigned and understood that whatever happens before the time skip serves the crew as a whole (formative years) and whatever happens later exist only to serve Luffy and plot. Oda has made the shift from a plot that has prioritized characterization where there was a lot of heart in it, to a plot where characterization exist as a checklist to tick through because things now have to be "bigger", "grander", and with more character ideals in place.
Unlike post new world where there is a clear central theme to each island/arc, newer ones seem to be muddled with different character motivations (that would have been fine and is an amazing thing to think about, if all of them actually delivered), a bunch of things happening to serve the grander plot, a bunch of things happening that didn't need to happen, Luffy always has to be the one that connects with the damsel/companion piece in distress and god forbide if ANY of the other straw hats have anything to do with the climatic resolution regarding said companion piece, I had no fucking idea what the fuck was the point of Zoro befriending Hiyori even since it doesn't do shit for King's fight and his backstory and his motivations. And in the midst of it, oh wow, look, Oda is doing ANOTHER "world exposition/worldbuilding" instead of making a fight narratively driven again so his whole Lunarian thing stole a huge chunk of the spotlight too.
I can go on and on but honestly, the TLDR of it all is that characters are basically checklists and tropes. And for Oda, he feels like "having more is better" when it really, really isn't if you can't do them justice. I genuinely mean this when I say that we can remove half of the Samurai gang and nothing would've really changed. Having a lot of characters/motivations/plotlines would have been fine if he actually cared to stick the landing instead of changing his mind or forgetting his characters (remember what's his name samurai guy who was hyped up but amounted to doing a whole bunch of nothing? The pompadour hair?) or consistently portray them to be something and then have them turn out to be irrelevant, lackluster, or just to be a "variable ABC" who inevitably only reason to exist is to serve Luffy and his messiah crusade.