﻿<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>C++博客-NoNews-随笔分类-作品</title><link>http://www.cppblog.com/hannosogno/category/17680.html</link><description /><language>zh-cn</language><lastBuildDate>Thu, 08 Sep 2011 16:46:50 GMT</lastBuildDate><pubDate>Thu, 08 Sep 2011 16:46:50 GMT</pubDate><ttl>60</ttl><item><title>连连看</title><link>http://www.cppblog.com/hannosogno/archive/2011/09/05/155177.html</link><dc:creator>NoNews</dc:creator><author>NoNews</author><pubDate>Mon, 05 Sep 2011 15:45:00 GMT</pubDate><guid>http://www.cppblog.com/hannosogno/archive/2011/09/05/155177.html</guid><wfw:comment>http://www.cppblog.com/hannosogno/comments/155177.html</wfw:comment><comments>http://www.cppblog.com/hannosogno/archive/2011/09/05/155177.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.cppblog.com/hannosogno/comments/commentRss/155177.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/hannosogno/services/trackbacks/155177.html</trackback:ping><description><![CDATA[<span style="color: #283769; font-family: arial; font-size: 13px; line-height: 19px; background-color: #ffffff; ">
<h3 xmlns="http://www.w3.org/1999/xhtml" id="sites-page-title-header" align="left" style="font-size: 1.4em; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-left: 10px; padding-right: 10px; font-family: arial !important; color: #5064ae; border-bottom-width: initial; border-bottom-style: none; border-bottom-color: initial; font: normal normal bold 1.8em/normal 'Trebuchet MS', arial, sans-serif; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "><span id="sites-page-title" dir="ltr">&nbsp;连连看<br />
&nbsp;项目代码下载：<a href="/Files/hannosogno/LLK.rar">/Files/hannosogno/LLK.rar</a><br />
<br />
</span></h3>
<div id="sites-canvas-main" class="sites-canvas-main" style="background-color: transparent; background-image: none !important; min-height: 150px; padding-bottom: 5px; padding-top: 15px; ">
<div id="sites-canvas-main-content">
<table xmlns="http://www.w3.org/1999/xhtml" cellspacing="0" class="sites-layout-name-one-column sites-layout-hbox" style="width: 752px; table-layout: fixed; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">
    <tbody>
        <tr>
            <td class="sites-layout-tile sites-tile-name-content-1" style="vertical-align: top; padding-top: 10px; padding-right: 10px; padding-bottom: 10px; padding-left: 10px; ">
            <div dir="ltr">学习Java的处女作，已经基本完善了，再花时间去完善这个游戏不太值得了。
            <div>源代码在Eclipse下编写，运行在Java SE1.6上<br />
            <div></div>
            <div>基本的功能都有了：自动生成可用的关卡、连线、道具、计时。</div>
            <div></div>
            <div>不过没有通过写这个游戏研究一下怎么显示不同的游戏界面等这个有些遗憾。有空来研究一下。</div>
            <div>初步的想法是通过几个不同的视图来做到。比如GamePlayingView, GameWaittingView, GameOverView来处理不同时候的视图吧。</div>
            <div></div>
            <div>努力的以我自己的思维去实现MVC模式的界面程序设计，真正的标准的MVC程序还需要我努力来研究才能完全的明白。<br /><br /><br /><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/1.png" alt="" /><br /><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/2.png" alt="" /><br /><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/3.png" width="400" height="281" alt="" /><br /><br /><br /><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/4.png" width="329" height="178" alt="" /><br /><br /><br /><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/3.png" alt="" /></div></div></div></td></tr></tbody></table></div></div></span><span style="color: #283769; font-family: arial; font-size: 13px; line-height: 19px; background-color: #ffffff; "><div class="sites-canvas-main" style="background-color: transparent; background-image: none !important; min-height: 150px; padding-bottom: 5px; padding-top: 15px; "><div>
</div>
</div>
</span><img src ="http://www.cppblog.com/hannosogno/aggbug/155177.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/hannosogno/" target="_blank">NoNews</a> 2011-09-05 23:45 <a href="http://www.cppblog.com/hannosogno/archive/2011/09/05/155177.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>俄罗斯方块</title><link>http://www.cppblog.com/hannosogno/archive/2011/09/05/155176.html</link><dc:creator>NoNews</dc:creator><author>NoNews</author><pubDate>Mon, 05 Sep 2011 15:43:00 GMT</pubDate><guid>http://www.cppblog.com/hannosogno/archive/2011/09/05/155176.html</guid><wfw:comment>http://www.cppblog.com/hannosogno/comments/155176.html</wfw:comment><comments>http://www.cppblog.com/hannosogno/archive/2011/09/05/155176.html#Feedback</comments><slash:comments>3</slash:comments><wfw:commentRss>http://www.cppblog.com/hannosogno/comments/commentRss/155176.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/hannosogno/services/trackbacks/155176.html</trackback:ping><description><![CDATA[<span class="Apple-style-span" style="color: #283769; font-family: arial; font-size: 13px; line-height: 19px; background-color: #ffffff; "><h3 xmlns="http://www.w3.org/1999/xhtml" id="sites-page-title-header" align="left" style="font-size: 1.4em; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-left: 10px; padding-right: 10px; font-family: arial !important; color: #5064ae; border-bottom-width: initial; border-bottom-style: none; border-bottom-color: initial; font: normal normal bold 1.8em/normal 'Trebuchet MS', arial, sans-serif; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "><span id="sites-page-title" dir="ltr"><a>俄罗斯方块<br /></a><br />项目代码下载：<a href="/Files/hannosogno/Tetris.rar">/Files/hannosogno/Tetris.rar</a><br /><br /><br /></span></h3><div id="sites-canvas-main" class="sites-canvas-main" style="background-image: none !important; min-height: 150px; padding-bottom: 5px; padding-top: 15px; background-color: transparent; "><div id="sites-canvas-main-content"><table xmlns="http://www.w3.org/1999/xhtml" cellspacing="0" class="sites-layout-name-one-column sites-layout-hbox" style="width: 752px; table-layout: fixed; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><tbody><tr><td class="sites-layout-tile sites-tile-name-content-1" style="vertical-align: top; padding-top: 10px; padding-right: 10px; padding-bottom: 10px; padding-left: 10px; "><div dir="ltr"><div><div style="display: block; text-align: left; ">以前学面向对象编程而写，用到了一些继承多态。<br /><br />操作：w、s、a、d分别对应上、下、左、右操作；j、k对应变形和快速下降操作。<br /><br /><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/tetris.jpg" width="432" height="477" alt="" /></div></div><div></div>俄罗斯方块游戏，在C++/CLI在VS2008下编码的，需要.NET 3.5的支持！ 项目文件见附件</div></td></tr></tbody></table></div></div></span><img src ="http://www.cppblog.com/hannosogno/aggbug/155176.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/hannosogno/" target="_blank">NoNews</a> 2011-09-05 23:43 <a href="http://www.cppblog.com/hannosogno/archive/2011/09/05/155176.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>游戏：Trap</title><link>http://www.cppblog.com/hannosogno/archive/2011/09/05/155175.html</link><dc:creator>NoNews</dc:creator><author>NoNews</author><pubDate>Mon, 05 Sep 2011 15:42:00 GMT</pubDate><guid>http://www.cppblog.com/hannosogno/archive/2011/09/05/155175.html</guid><wfw:comment>http://www.cppblog.com/hannosogno/comments/155175.html</wfw:comment><comments>http://www.cppblog.com/hannosogno/archive/2011/09/05/155175.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.cppblog.com/hannosogno/comments/commentRss/155175.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/hannosogno/services/trackbacks/155175.html</trackback:ping><description><![CDATA[<span class="Apple-style-span" style="font-family: arial; background-color: #ffffff; "><h3 xmlns="http://www.w3.org/1999/xhtml" id="sites-page-title-header" align="left" style="line-height: 19px; font-size: 1.4em; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-left: 10px; padding-right: 10px; font-family: arial !important; border-bottom-width: initial; border-bottom-style: none; border-bottom-color: initial; font: normal normal bold 1.8em/normal 'Trebuchet MS', arial, sans-serif; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "><span id="sites-page-title" dir="ltr"><font class="Apple-style-span" color="#5064ae">Trap!</font><br /><br /><font class="Apple-style-span" color="#5064ae">项目代码下载：</font><a href="/Files/hannosogno/Trap.rar"><font class="Apple-style-span" color="#5064ae">/Files/hannosogno/Trap.rar</font><br /><br /></a></span></h3></span><span class="Apple-style-span" style="font-family: arial; line-height: normal; background-color: #ffffff; font-size: medium; "><table xmlns="http://www.w3.org/1999/xhtml" cellspacing="0" class="sites-layout-name-one-column sites-layout-hbox" style="width: 752px; table-layout: fixed; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><tbody><tr><td class="sites-layout-tile sites-tile-name-content-1" style="vertical-align: top; padding-top: 10px; padding-right: 10px; padding-bottom: 10px; padding-left: 10px; "><div dir="ltr">本来试图模仿手机上的Trap!游戏，结果比想象中的要难一些，而且现在也没有时间做这个了。<div>暂时先传上来保存起来，以后再修改完美吧。</div><div>现在有一个办法就是把Wall变成3的宽度，就可以完美的解决球穿越墙的问题，而且UI还更好看。</div></div></td></tr></tbody></table></span><span class="Apple-style-span" style="font-family: arial; background-color: #ffffff; "><h3 xmlns="http://www.w3.org/1999/xhtml" align="left" style="line-height: 19px; font-size: 1.4em; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-left: 10px; padding-right: 10px; font-family: arial !important; border-bottom-width: initial; border-bottom-style: none; border-bottom-color: initial; font: normal normal bold 1.8em/normal 'Trebuchet MS', arial, sans-serif; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "><span dir="ltr"><a href="/Files/hannosogno/Trap.rar"><font class="Apple-style-span" color="#5064ae"><br /></font></a></span></h3></span><span class="Apple-style-span" style="font-family: arial; line-height: normal; background-color: #ffffff; font-size: medium; ">球之间的相互碰撞解决的真是非常好~~ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;：）</span><span class="Apple-style-span" style="color: #283769; font-family: arial; font-size: 13px; line-height: 19px; background-color: #ffffff; "><br /><div class="sites-canvas-main" style="background-color: transparent; background-image: none !important; min-height: 150px; padding-bottom: 5px; padding-top: 15px; "><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/start.PNG" width="647" height="513" alt="" /><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/playing.PNG" alt="" /><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/gameover.PNG" alt="" /></div></span><img src ="http://www.cppblog.com/hannosogno/aggbug/155175.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/hannosogno/" target="_blank">NoNews</a> 2011-09-05 23:42 <a href="http://www.cppblog.com/hannosogno/archive/2011/09/05/155175.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>The Game of Life</title><link>http://www.cppblog.com/hannosogno/archive/2011/09/05/155174.html</link><dc:creator>NoNews</dc:creator><author>NoNews</author><pubDate>Mon, 05 Sep 2011 15:40:00 GMT</pubDate><guid>http://www.cppblog.com/hannosogno/archive/2011/09/05/155174.html</guid><wfw:comment>http://www.cppblog.com/hannosogno/comments/155174.html</wfw:comment><comments>http://www.cppblog.com/hannosogno/archive/2011/09/05/155174.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.cppblog.com/hannosogno/comments/commentRss/155174.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/hannosogno/services/trackbacks/155174.html</trackback:ping><description><![CDATA[<span class="Apple-style-span" style="font-family: arial; background-color: #ffffff; "><h3 xmlns="http://www.w3.org/1999/xhtml" id="sites-page-title-header" align="left" style="line-height: 19px; font-size: 1.4em; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-left: 10px; padding-right: 10px; font-family: arial !important; color: #5064ae; border-bottom-width: initial; border-bottom-style: none; border-bottom-color: initial; font: normal normal bold 1.8em/normal 'Trebuchet MS', arial, sans-serif; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "><span id="sites-page-title" dir="ltr">The Game of Life</span></h3></span><br /><br />&nbsp; &nbsp;下载：<a href="/Files/hannosogno/Project_The_Game_of_Life.rar">/Files/hannosogno/Project_The_Game_of_Life.rar</a><a title="Game_of_Life" href="https://sites.google.com/site/chuanqitan/made-by-hannosogno/the-game-of-life/Project_The_Game_of_Life.rar?attredirects=0&amp;d=1"><br /><br /></a><span class="Apple-style-span" style="color: #283769; font-family: arial; font-size: 13px; line-height: 19px; background-color: #ffffff; "><div class="sites-canvas-main" style="background-image: none !important; min-height: 150px; padding-bottom: 5px; padding-top: 15px; background-color: transparent; "><div><table xmlns="http://www.w3.org/1999/xhtml" cellspacing="0" class="sites-layout-name-one-column sites-layout-hbox" style="width: 752px; table-layout: fixed; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><tbody><tr><td class="sites-layout-tile sites-tile-name-content-1" style="vertical-align: top; padding-top: 10px; padding-right: 10px; padding-bottom: 10px; padding-left: 10px; "><div dir="ltr"><span style="font-family: 'Lucida Grande'; line-height: normal; "><br style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; " /><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: 19px; min-width: 0px; display: block; clear: left; "><p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0.4em; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; line-height: 18px; ">介绍</p><p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0.4em; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; line-height: 18px; ">与其说是game，其实它更像是一个simulation，在1970年由英国数学家J. H. Conway提出的。The Game of Life的规则很简单：假设有一个无边界的矩形网格（我更喜欢把它称作宇宙，或者universe），这个矩形网格中的每个单元可被一个有机体占据（同样地，我更爱细胞这个词，或者cell）。被占据的单元称为活的（alive），未占据的单元称为死的（dead）。哪一个单元是活的要根据其周围活的邻居单元（neighbor）的数目而一代代（generation）地发生变化，规则如下：</p><ol style="list-style-type: decimal; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0.4em; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; line-height: 19px; "><li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 2em; list-style-position: outside; ">给定单元的邻居是与它在垂直、水平或对角方向上相接的8个单元。</li><li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 2em; list-style-position: outside; ">如果一个单元是活的，但没有邻居单元是活的，或者仅有一个邻居单元是活的，则在下一代，此单元就会因孤独而死亡。</li><li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 2em; list-style-position: outside; ">如果一个单元是活的，且有4个或4个以上的邻居单元也是活的，则在下一代，此单元会因为拥塞而死亡。</li><li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 2em; list-style-position: outside; ">一个活的单元，如果具有2个或3个或的邻居单元，则此单元在下一代仍是活的。</li><li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 2em; list-style-position: outside; ">如果一个单元是死的，如果它不多不少刚好有3个邻居单元是活的，则在下一代此单元变成活的。所有其他死的单元在下一代仍是死的。</li><li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 2em; list-style-position: outside; ">所有的出生和死亡都刚好在同一时间发生，因此正在死亡的单元有助于另一个单元的出生，但它不能通过减少阻塞而组织其他单元的死亡；正在出生的单元也不能保护或杀死上一代中活着的单元。</li></ol><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: 19px; "><br style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; " /></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: 19px; "><img src="http://www.cppblog.com/images/cppblog_com/hannosogno/TheGameOfLife.jpg" alt="" /><br style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; " /></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: 19px; "><br style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; " /></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: 19px; "><br style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; " /></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: 19px; ">可执行文件和项目文件都在附件里，需要.NET 2.0或以上的支持，解压后直接运行．</span></div></div></div></span></div></td></tr></tbody></table></div></div></span><font class="Apple-style-span" color="#283769" face="arial" size="2"><span class="Apple-style-span" style="line-height: 19px;"><br /></span></font><img src ="http://www.cppblog.com/hannosogno/aggbug/155174.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/hannosogno/" target="_blank">NoNews</a> 2011-09-05 23:40 <a href="http://www.cppblog.com/hannosogno/archive/2011/09/05/155174.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item></channel></rss>