4,513 karma · joined March 23, 2015
This is really common because of two design features that most UI frameworks share:
- The code that changes the color of the button is an internal part of the "button" component, so that people don't have to individually implement it on every button. But this means that it's kind of disconnected from the code that actually performs the action. If the "on click" handler has some last-ditch check that aborts the action, like the "don't rotate the image if it's in the middle of the rotate animation" check from the article, often there's no way for it to tell the button to cancel the color change. (And conversely sometimes the "on click" handler can fire even if the color change animation doesn't play correctly.)
- Buttons usually change color when you press down the mouse button, but only perform the action when you release the mouse button. Sometimes this is used to intentionally give you a chance to cancel the action at the very last minute by dragging your mouse off the button while it's still held down (or, on mobile, to e.g. reinterpret your interaction as scrolling instead of clicking), other times it just creates more opportunities for something to happen that prevents the action from working after the color change has already happened.
In most other languages this would be written as "this.current_index" or some other property name.
This same issue also seems like it would prevent you from quickly double-tapping the button to turn an image upside-down, a much more common use case.
There's still the obvious problem that if the build system emits malicious code, you'll probably run that code anyway. Personally I think this kind of sandboxing is more useful for enforcing build reproducibility rather than, like, protecting you from viruses in the build.zig file.
The first page of the published paper ( https://orb.binghamton.edu/nejcs/vol8/iss1/6/ ) also claims that the game was developed by "Josh Wordle", so maybe it just isn't the highest-quality scholarship in the world.
Not quite: https://jisho.org/search/%23words%20%23v1%20%3F*%E3%82%8A%E3...
Wiktionary lists eight whole words that use it! (The entry for スィ itself, a couple obscure loanwords and proper names, and a couple alternate spellings of words that Japanese people normally pronounce using the "shi" sound.) https://en.wiktionary.org/wiki/Category:Japanese_terms_spell...
For all that I'm not totally sold on this article's idea of "stems" and "suffixes", I think it does a good job of avoiding this pitfall and correctly explaining the groups.
Which, like, is clean in the sense that Redux is technically Turing-complete (you can encompass _any_ difference between two strings by saying that one string uses the stuff in brackets and the other string uses the stuff in parentheses), but that doesn't make it a good idea.
It's definitely useful to understand how "chi" and "tsu" fit into the hiragana chart, and if your asterisk notation helps you remember which verbs are ichidan vs godan then that's great, but I'm not sure it's worth trying to unify -masu and -nai into one model.
You can kind of get away with that if you're implementing, like, 2048 (although the official version at play2048.co doesn't do this), but it feels way too unresponsive to be usable in an action game.
As a game it doesn't seem especially well-designed. In particular the author has missed a key aspect of the original Pac-Man, which is that ghosts have to run back to the start when they're eaten and that gives Pac-Man time to freely move around and eat dots. Instead, getting eaten teleports both you and Pac-Man back to the starting positions and consumes a life. You get three lives, so it's way too easy to just tank two power pellets and then keep Pac-Man trapped in the bottom half of the level forever (aided by his not-great AI logic, as other commentors mention).
Personally, I found this take on the "Pac-Man but you're the ghosts" idea more interesting and less obviously plagiarized: https://youtu.be/96xNkL1Z_8M
The author alleges that the real reason WebAssembly uses loop/block is because that's how V8 worked internally at the time and Google didn't want to go to the trouble of implementing something different. But more recently V8 has started moving towards CFGs ( https://v8.dev/blog/leaving-the-sea-of-nodes ) so maybe there's hope in the future.
The overall model is similar to tap-to-pay debit cards. They're only used for consumer-to-business payments. When you tap the card, the card sends over an account number / signature / etc, which the merchant sends to a central clearinghouse to finalize the transactions.
The main difference is that the card itself keeps a running balance of how much money the customer has available to spend. In many cases, this gives the merchant enough confidence to e.g. let you through the train turnstile without actually waiting for the central clearinghouse to confirm the transaction. (I think in practice they usually send all the transactions in batches, daily or weekly or something.)
The readers do some trusted-computing/secure-enclave type stuff but are not especially hard to obtain; I think there have even been cases where companies like Nintendo have built them into consumer products, so that you could e.g. tap your card to your Nintendo 3DS to buy a video game.
I imagine there's a bit more security on the machines that let you load money on the cards, but it's probably not completely impossible to make a fake card. But the low value limit (usually a couple hundred dollars, depending on the card provider), the inability to get cash out of the system (often you can't even buy things like postage stamps), and the fact that you'll get caught relatively quickly (once the central clearinghouse notices the transactions don't match up) make it unattractive to do it in practice.
> What makes it aggressive?
The parent comment already contained the answer to your question (the multiple links are what makes it aggressive, in GP's opinion). Your comment might have been seen as more constructive if it engaged with that directly.
Well, you're allowed to write it, but the browser will just ignore the <?end> marker. The range will end at the </em> tag, the same place https://github.com/WICG/declarative-partial-updates/blob/mai... says it goes by default if you don't write the <?end> at all. (That default wouldn't make a ton of sense if patch ranges were allowed to break out of their parent elements like this.)
Jake Archibald thinks it'd be cool to use a similar syntax to do CSS highlights, but there are other problems with that (like not being able to create overlapping ranges), and he's not on the Chrome team that's pushing this proposal.