Alice Community  

Go Back   Alice Community > Alice 2 > Bugs and Troubleshooting

Reply
 
Thread Tools Display Modes
Project Saving Issue (2.3)
Old
atomcollider
Guest
 
Status:
Posts: n/a
Default Project Saving Issue (2.3) - 12-01-2012, 09:46 PM

I was working on a project for class; we had to make a board game in the alice world. I chose to do connect 4. I got done coding everything, including the 4 in a row detection. It worked perfectly, until I saved it. Opening it back up, alice throws up an error. The peculiar thing is, if I go into my "win detection" methods (there are 3, one for horizontal, vertical, and diagonal), and simply re-code the IF statements that check a list for a color, in the exact same way, it works again, until I save it. I have the project attached. Is this a bug? Or do I have to code my program in a different way?

EDIT --

It seems to be the way I coded it doesn't get saved properly. I redid the program another way, using one huge list for all the "slots", and simply advancing by an offset value (6 for horizontal, 1 for vertical, and 7 or 5 for diagonal, for each of the two cross directions). Alice apparently doesn't like complex methods involving rapidly changing lists, which is what I had before. Now I just have a static list for win detection, and just use a couple number variables to keep track. It works perfectly now. I would be interested to know why this error happens, though, and if it's fixed in 3.x.
Attached Files
File Type: a2w ConnectFour_R4.a2w (487.8 KB, 4 views)

Last edited by atomcollider; 12-02-2012 at 08:02 PM. Reason: Problem Discovered
   
Reply With Quote
Old
CellularDecay
Junior Member
 
Status: Offline
Posts: 7
Join Date: Jan 2013
Location: Kapolei, Hawaii
Default 04-15-2013, 05:20 PM

Ah yes, Alice, the world's first write-only programming environment. You can save your programs, but you can't reload them later.

I've had this happen several times, and, in my case at least, it seems to be caused by something that I deleted still getting saved. In other words, it looks like Alice does not always delete things correctly. I delete something, and it seems to go away, but some part of it is still referenced in the save file, and that causes an error when attempting to reload the code later.

(Alice 2.3)

PS: Some might argue that APL was the first write-only programming language, but you'd have to be pretty old to get that joke.
   
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Copyright ©2024, Carnegie Mellon University
Alice 2.x © 1999-2012, Alice 3.x © 2008-2012, Carnegie Mellon University. All rights reserved.