Drawing grid on canvas and calling procedure from item from "insert list item"?

389 views
Skip to first unread message

Jack Woolford

unread,
Sep 25, 2014, 9:52:36 AM9/25/14
to
Hello again,

So I've encountered two more problems although am almost done now making something I think that is fairly complicated (Conway's Game of Life whether it works is another thing...). Anyway I need to draw a grid presumable on a canvas from a given global variable for rows and columns. I also need it to be able to fill each square in the grid, and un-fill.

Besides the above I'm having a slight problem with an "insert list item" with wanting to call a procedure and not being able to from the item tab. So any possible ideas on how to fix that would also be highly appreciated.

Oh one last thing I might as well mention, when my app initialises the buttons appear before loading fully and then disappear as planned until the screen is dragged down. How can I have the buttons not appear to be loading each time I open a screen?

Thank you, so far everyone has been extremely helpful.

Thanks.

Edit: Attached is the code for the "Insert list item" problem.
Insert list item.png

Taifun

unread,
Sep 25, 2014, 10:17:57 AM9/25/14
to mitappinv...@googlegroups.com


Besides the above I'm having a slight problem with an "insert list item" with wanting to call a procedure and not being able to from the item tab. So any possible ideas on how to fix that would also be highly appreciated.
use a procedure with result

procedure result

Same as a procedure do block, but calling this procedure returns a result. 



Oh one last thing I might as well mention, when my app initialises the buttons appear before loading fully and then disappear as planned until the screen is dragged down.
probably this is only a companion app issue? did you test it after building the app?
Taifun

Trying to push the limits of App Inventor! Snippets and Tutorials from Pura Vida Apps by Taifun.         


Jack Woolford

unread,
Sep 25, 2014, 11:16:22 AM9/25/14
to mitappinv...@googlegroups.com
Sorry I had marked it as completed as I thought I had worked it out with your help taifun but alas I've encountered a new problem.

See I've seen Scott's version of Conway's Game of Life but it didn't quite do what I wanted it to. So I've tried something else, attached is MazeMaker (which I found in this forum), now somehow it detects which squares it has travelled to and which it hasn't but so far I can't work out what code does that. Once I can get that out of the way I also need to know is there a way to fill a square with a colour if it has a border?

Also thanks taifun as that procedure-result block was just what I needed at first I didn't think it would work but it did.

Also I haven't tested it as an actual app just in AI2 Companion so far, once I'm done I shall though and will report back if the buttons still appear before disappearing.


MazeMaker.aia
Reply all
Reply to author
Forward
0 new messages