Re: string_contains in python?

While we're asking technically-googlable-but-hard-to-clarify questions... what's up with _javascript_ arrays / dicts? I've found that trying to replace "new Array" in my games made when literally all the tutorials and examples said to use "new Array" with either seems to fail. I mostly just want those to work again with minimum modification.
I say this here because Googling it gives confusing and useless information (mostly just "new Array is bad, because XYZ" rants). ... About like anything JS related post HTML5, really.
I can easily imagine the way that Python "in" works being sufficiently different from what one understands that some clarification might be necessary, though I have not tried Googling it to check. And what one Googles might vary if string_contains is all that one knows.
(Random observation: BGT / Angelscript has the "xor" keyword, and Python does not, unless it was added since I last checked. That seems weird, somehow. I've found xor useful in 2d games in particular, especially for things like "is a facing b?" (if (a.faceright xor b.x<a.x).)

(But no for real why is it so hard to figure out how to replace "new Array"? You'd think however basic arrays or dicts work these days should cover it. But I have that mystery game (where arrays make more sense for NPC information, and dicts for reviewing information), and Jeqo Legends (where things get weird because there are numeric index arrays for in-game team-members, but string-indexing for character information, and guh why did it take me longer to learn OOP than to start releasing games? And why can't I work that fast anymore?)

-- 
Audiogames-reflector mailing list
Audiogames-reflector@sabahattin-gucukoglu.com
https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
  • ... AudioGames . net Forum — Developers room : ashleygrobler04 via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : camlorn via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : ashleygrobler04 via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : amerikranian via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : chrisnorman7 via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : ashleygrobler04 via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : camlorn via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : CAE_Jones via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : ogomez92 via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : ogomez92 via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : ogomez92 via Audiogames-reflector

Reply via email to