Android Dev Protips! — Why isn’t NotifyDataSetChanged working?
Fun bug from this afternoon: let’s say you have a custom ListAdapter you’re working with to fill in data into a ListView, and you’re trying to implement a method which allows you to insert a new element into that list. You’re competent with the use of Adapters, so you’re confident it works - in fact, the model for your add function matches most of the recommendations on StackOverflow:
So, you’re confident everything is looking good, yet whenever you actually go to add the new string, the list doesn’t update! It comes up when you leave and return to the activity (because you’re properly serializing elsewhere in code), but it won’t update on the spot.
So you go hunting further into StackOverflow to see if there was something subtle you missed about how to hook up a ListAdapter properly in your ListFragment. Maybe using setListAdapter doesn’t properly set up your fragment’s ListView as an observer for the adapter? That wouldn’t make much sense, but you aren’t sure. Perhaps it was something else…
Regardless, you spend a few hours hunting, and nothing comes up. All the errors with NotifyDataSetChanged are pretty dumb errors regarding simply misusing the class, which you’ve confirmed many times over by now that you haven’t done.
So what’s the problem?
Well, in case you had the same issues I did this afternoon, it may be that you accidentally let Eclipse fill in your functions for you, so among them you overwrote registerDataSetObserver and unregisterDataSetObserver, and they’re filled in with TODO messages rather than calling the superclass’s versions. WHOOPS.
The fix: delete those functions, dummy - you’re not doing anything in there anyway!
I caught Yveltal in a Quick Ball on the first turn while he was at full health?
And it looks like everyone else has a pretty easy time catching him, too.
…that’s ridiculous. This game is way too easy. Catching the Legendary’s supposed to be one of the game’s major challenges, but he’s practically a hand-out!
This is nothing terribly new, however. As I recall, catching Lugia in Silver was not that much harder.
What they’ve done is separated “legends tied to the main quest” and “post-quest legends”. Catching Kyogre / Groudon in R/S was easy. Catching Rayquaza was a bitch (much harder than capturing Mewtwo in the original games, IMO). The same holds in X/Y: Yveltal and Xerneas are critical to the plot, so they make it easy to capture so kids don’t feel bad that they forgot (or didn’t realize they needed) to bring a shit ton of ultra balls to the battle. However, capturing Zygarde as very difficult.
At the end of the day, though, I wouldn’t complain about difficulty on capturing pokemon when discussing difficulty of gameplay. Honestly, spending hours of chucking ultra balls waiting for the one lucky chance for the RNG to let me capture it is just a matter of grinding - not a matter of skill. I’m more concerned about the excessively distributed EXP (seriously, the new Exp. Share is OP as fuck) and bonus starters.
Anyone need an Eevee?
I’ve got a flock of them from breeding, and I was just going to push them up onto the Wonder Trade, but since maybe someone wants one I guess I may as well ask.
The Utah MTG: Open was awesome!
Really glad I had a chance to be on the judge staff for that event, and really looking forward to it next year. A huge thank you to the 114 players who came out to support it!
Along the very edge of Muraille Coast, I was challenged to a sky battle by a trainer seated at a rock very far from the shoreline. It’s rude to turn down a battle, so I accepted. I released my only flying Pokemon, Elise, and my opponent chose a Mantyke. The moment I saw that Mantyke make his first move, I knew we were terribly outmatched. At the same time, Elise was putting up an incredible fight, and for a moment, I thought maybe she would pull through and win this. She’s so passionate about battle, I didn’t think it wise to stop her now.
What horrible, horrible mistake that was.
I know he didn’t mean to hurt her like this, but the Mantyke’s final blow was put forth with such excessive force, I saw Elise’s wings crumple and break instantly with the impact. The Mantyke’s trainer was kind enough to fish her out of the water for me after she fell.
After Nurse Joy gave her a thorough evaluation, she concluded that Elise would probably never fly properly again. I sent her back to Professor Sycamore in hopes he might be able to do something, and although he said he’d do his best to have the wings repaired, he confirmed that she’d always be crippled to an extent, too crippled to ever battle like she used to.
I feel so guilty, I don’t know what to do with myself.
((That battle was bullshit. My Pokemon were all at Lv. 21, and this guy whips out a Lv. 28 Mantyke. I’m glad I had the option to take on that trainer, as I love a good challenge, but I really wish there had been some sort of warning about how much stronger he was. I have a feeling I shouldn’t have been able to battle that guy at that point. Elise did very well in that battle in spite of the type advantage, so I’m very sad I lost her before I could see what she was fully capable of))
Forewarning: every sky battle is like that. I ended up turning them all down, because they are not worth the risk.
Wait, wait, what?
So was randomly looking for a wild pokemon encounter to see Mega Mewtwo, and then randomly Articuno and it fled before a turn even happened and I’m still kind of what?
Oops. Accidentally stayed up until 4 in the morning, but I finished Pokemon so now maybe I can do my homework?
Fun fact: Pokemon centers give you a birthday celebration in Pokemon X and Y.
To the guy who gave me the Prize Money O-Power:
A million thank yous! Ended up getting close to 50k off of a trip to the restaurant thanks to that boost. Bought the rest of my expensive outfit with that cash. <3
> Go to restaurant, and pay 15k for lunch
> Battle the Waiters, Chef, and Owner with Amulet Coin equipped
> Make ~20k from the battles
And that’s why restaurants are now my training ground of choice. :)