omz:forum

    • Register
    • Login
    • Search
    • Recent
    • Popular
    1. Home
    2. chriswilson
    3. Best

    Welcome!

    This is the community forum for my apps Pythonista and Editorial.

    For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.


    • Profile
    • Following 1
    • Followers 1
    • Topics 6
    • Posts 79
    • Best 20
    • Controversial 0
    • Groups 0

    Best posts made by chriswilson

    • Pythonista-made game now on App Store

      Hi all,

      The puzzle game I have been working on is now available for free on the App Store.

      Here is the link

      Thanks to those who helped with my code, and to @omz for the awesome Pythonista Xcode template!

      Icon

      Screenshot

      posted in Pythonista
      chriswilson
      chriswilson
    • [share] Grid-based game for Pythonista

      I have been working on a simple game to try to learn the Scene module. Feel free to try it. I would welcome feedback of any sort. I am a beginner and so my code will not be particularly tidy!

      It consists of a few files (high score saving, configuration etc) and can be downloaded from GitHub here.

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Pythonista-made game now on App Store

      @JonB @cook @shaun-h @Webmaster4o @disorientedp @ccc @omz

      Version 1.2 is now on the App Store with a host of bug fixes! Thanks for pointing them out.

      The high score table now just shows the top score for each player, so the table is simpler and won't be taken up by those who play a lot; not looking at anyone in particular! 😉

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Pythonista-made game now on App Store

      By the way, App Store reviews are very much appreciated of course! 😀

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Bokeh, Matplotlib or Plotly?

      @Webmaster4o I'm starting to learn JS now, so hopefully it won't be a problem!

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Bokeh, Matplotlib or Plotly?

      @Webmaster4o Looks great! I'll check it out.

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Pythonista 3 Rect attributes

      Are the attributes of the scene.Rect class not x, y, width and height (without parentheses as they are attributes, not methods)?

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Woo woo, question number 4! Seems simple.... change a node's (shapenode primarily) size after the fact?

      @WTFruit

      This seems to work for me (code within an instance of scene hence use of self:

      my_path = ui.Path().rounded_rect(0, 0, 20, 20, 4)
      my_path.fill()
      my_path.close()
      		
      self.my_node = ShapeNode(my_path, color = 'white', position = (100, 100), size = (20, 20))
      self.add_child(self.my_node)
      
      self.my_node.size = (40, 40) # Changes size
      
      

      In your method, which uses the path object, the x and y can just be zero I think, and you could set a variable equal to the path object like above to simplify the code. Not sure why the above is not working for you though, sorry! :)

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Error message?

      Hi @dat2357
      Try making line 4 this:

      sender.superview['txtOutput'].text = (str(sum)) #4

      The equals sign is all-important. Hope this helps!

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Action.repeat() won't repeat.

      I hadn't realised the A.call() thing existed - loads of possibilities for animations!

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Pythonista-made game now on App Store

      @Webmaster4o @JonB
      Thanks for the feedback. I've reproduced both those bugs. I think it's something to do with the difference between A.rotate_by() and A.rotate_to() animations.

      I also use a method to stop animation of squares when needed, but it doesn't seem to reset square rotation back to zero. I'll play around with this and look at releasing an update when I can.

      @JonB I never thought of filling up with locked squares to get the white square bonus! Maybe the bonus is too generous or the penalty for locked squares too lenient?! 😉

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Pythonista-made game now on App Store

      Some impressive scores from @JonB !

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Pythonista-made game now on App Store

      @cook @shaun-h
      Version 1.1 is now on the App Store. I've made changes based on your advice regarding the highscore button, settings and instructions screens etc. It's also a universal app now. Thanks!

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Pythonista-made game now on App Store

      @Webmaster4o
      Thanks - I didn't realise as I don't use Twitter!

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: MySQL Client

      @dgelessus @JonB @Tizzy @ccc

      So I have produced a game which has a highscore table for each of three difficulty settings. I have now adapted this to use a MySQL database to store results for any user, rather than just a local highscore table.

      For this I set up a limited database user account (not my admin account!) with privileges restricted to INSERT and SELECT (i.e. not DROP, TRUNCATE etc). Is it safe/acceptable to bundle the account username and password in the code so people can use this feature? Would you suggest a different way?

      I have not pushed it to GitHub yet as I'm new to SQL and wanted some advice! :)
      (I am aware someone could cheat and simply use the details to insert a top score if they wished, but I'm hoping for honesty!)

      Thanks

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: [share] Grid-based game for Pythonista

      Oh and I should say thanks to @Cethric and @JonB who helped with some queries in this post last month.

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: [share] Grid-based game for Pythonista

      Thanks to @ccc for many useful edits. I've just learned a lot! :)

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: [share] Grid-based game for Pythonista

      Yes I wrote it on an iPhone. I did try to make the geometry relative to screen sizes, but don't have an iPad to check what it actually looks like! :)

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: [share] Grid-based game for Pythonista

      Thanks @omz
      Yeah I was thinking I need to provide instructions. The object is to clear a white path across the grid by pressing squares. Doing this toggles the 8 surrounding squares and takes the pressed square out of action (this can be reset using the second 'power-up' below the title).

      The other two 'power-ups' toggle all the squares, or allow you to toggle only a single square and not those around it.

      Score is awarded for maximising the number of squares in the path, and points are deducted for remaining white squares and squares that you pressed. It's possible to lose points in a given round. The timer gets quicker with each level.

      Unfortunately I imagine it will only work on iPhone 6/6S size screens, though I hope to change this.

      posted in Pythonista
      chriswilson
      chriswilson
    • RE: Crash when using Sleep() in Scene module

      Thanks @Cethric and @JonB for the advice.

      I've posted the code here.

      posted in Pythonista
      chriswilson
      chriswilson