• bortels38

    Heh, would be overkill for me - I was showing my daughters how if you write the code, you can modify the game to make it what you want, and suggested they could, for example, change the pictures in the "Cards.py" sample.

    FWIW - I replaced the "images =" line with:

        # pick random images
        builtin_images = [name for name in os.listdir(os.path.join(os.path.dirname(os.__file__), "../Textures")) if "@2x" not in name]
        images = random.sample(builtin_images, 8)
        images = [os.path.splitext(x)[0] for x in images]
        images = images * 2
    

    And added "random" and "os" to the imports, and there was much rejoicing. :-)

    (I'm not sure os.path.splitext was the best choice, but MEH it works)

    posted in Pythonista read more
  • bortels38

    @dgelessus - awesome, exactly what I was looking for; explanation plus why I was having issues (I was only seeing my own stuff using regular old os.walk - now I know why).

    @TutorialDoctor - thank you as well, that looks like a handy utility, and it's useful to look at working code, even if Apple is a bit of a moving target!

    posted in Pythonista read more
  • bortels38

    While we're talking wishes...

    Camera support, or thoughts thereof? I'm wanting to do either augmented reality or time-lapse stuff, both of which would need/want camera support.

    That's mostly it. Just to say, I totally love the way you're adding modules - good stuff. In particular, beautiful soup and PIL are both going to be handy for me.

    Just to mention - you'll get a lot of comparisons to Codea; it's a neat program with lots of features. Don't let it get you down - the reason you get the comparisons is because Pythonista is ALSO a neat program with lots of features - if it wasn't, people wouldn't bother. The cross-pollination of ideas makes both programs better - keep adding the things you think are fun and useful, and you won't go wrong.

    posted in Pythonista read more
  • bortels38

    How about pygame? One of the things I like about pythonista (in contrast to Codea, which I do love) is the traditional procedural architecture; you're not forced into an event loop, which makes certain types of programming (I'm looking at the http server example, which makes me very happy) much easier. Python has pygame, it's very popular, and I suspect a nice chunk of code would be able to come over unmodified.

    posted in Pythonista read more

Internal error.

Oops! Looks like something went wrong!