【正文】
畢業(yè)設(shè)計(jì) ( 論文 ) 五子棋手機(jī)網(wǎng)絡(luò)對(duì)戰(zhàn)游戲的設(shè)計(jì)與實(shí)現(xiàn) 論文作者姓名: 申請(qǐng)學(xué)位專業(yè): 申請(qǐng)學(xué)位類別: 指導(dǎo)教師姓名(職稱): 論文提交日期: 五子棋手機(jī)網(wǎng)絡(luò)對(duì)戰(zhàn)游戲的設(shè)計(jì)與實(shí)現(xiàn) 摘 要 在現(xiàn)代社會(huì)中 ,手機(jī)及其它無(wú)線設(shè)備越來(lái)越多的走進(jìn)普通老百姓的工作和生活。隨著 3G 技術(shù)的普及與應(yīng)用,基于 Java 開發(fā)的軟件在手機(jī)上的使用非常的廣泛,手機(jī)增值服務(wù)的內(nèi)容也是越來(lái)越多,對(duì)豐富人們的生活內(nèi)容、提供快捷的資訊起著不可忽視的作用。 本文基于 J2ME 技術(shù),以計(jì)算機(jī)網(wǎng)絡(luò)游 戲的運(yùn)行流程為基礎(chǔ),分模塊開發(fā)一款網(wǎng)絡(luò)五子棋游戲軟件。 本文對(duì)以下幾點(diǎn)內(nèi)容做了重點(diǎn)研究和探討: 系統(tǒng)整體結(jié)構(gòu),根據(jù)設(shè)計(jì)目標(biāo),結(jié)合普通網(wǎng)絡(luò)游戲的運(yùn)行流程,給出了系統(tǒng)總體設(shè)計(jì)方案,并探討了系統(tǒng)設(shè)計(jì)時(shí)需要用到的關(guān)鍵技術(shù)。 手機(jī) MIDP 客戶端的實(shí)現(xiàn), MIDP 客戶端是游戲的唯一客戶端,主要功能包括連接服務(wù)器進(jìn)行身份驗(yàn)證、進(jìn)行游戲并不斷的與服務(wù)器交換數(shù)據(jù)。 后臺(tái)系統(tǒng)的設(shè)計(jì)與實(shí)現(xiàn),后臺(tái)用來(lái)處理與數(shù)據(jù)庫(kù)的互聯(lián)來(lái)驗(yàn)證用戶身份、處理由客戶端發(fā)送過(guò)來(lái)的數(shù)據(jù)。 由于受到客觀條件的限制,本系統(tǒng)的測(cè)試是在三星手機(jī)模擬器上完成的,但它仍 不失具一定的實(shí)用價(jià)值。 關(guān)鍵詞: J2ME;手機(jī)游戲; Servlet The Design and Implementation of The Gobang War Game on Cell Phone Network Abstract In modern society, more and more cell phones and other wireless devices e into the work and life of ordinary people. With the popularization and application of the 3rd Generation of Digital munication technology, the development of Javabased software in the use of mobile phones is very broad, mobile valueadded services are more and more. It plays an import role to enrich people39。s lives and provide easier access to information. This paper is based on J2ME technology, it expounds how to take the running flow of puter work as basis, introduce a kind of gobang game on work by the submodule method. . The main points of this paper go as follows: (1) The overall system structure. According to the design goals, with the general operation of the work game flow, gives the system design, and explores the key technology, which is used by the design of this system. (2) The implementation of the phone MIDP client. MIDP client is the only game client, the main functions include connecting the server to check the status, playing games and keeping the exchange of data with the server. (3) The implementation and design of background system. Background is to deal with the Inter database to verify the identity of users, processing the data, which is sent by the clients. Due to the restrictions of objective conditions, the system39。s test pleted in the Samsung handset simulator. But it does have some advantages. Key words: J2ME。 Handset game。 Servlet 目 錄 論文總頁(yè)數(shù) : 24 頁(yè) 1 引言 .............................................................................................................................. 5 2 系統(tǒng)綜述 ....................................................................................................................... 5 3 手機(jī)游戲的現(xiàn)狀和關(guān)鍵技術(shù)介紹 .................................................................................... 6 軟件現(xiàn)狀 ................................................................................................................. 6 J2ME 概況 ............................................................................................................... 6 J2ME 的由來(lái) ..................................................................................................... 6 J2ME 的 3 層體系結(jié)構(gòu)及 MIDP 簡(jiǎn)介 .................................................................. 7 TOMCAT 服務(wù)器介紹 ................................................................................................. 8 SERVLET 技術(shù)介紹 .................................................................................................... 9 4 開發(fā)環(huán)境介紹 ............................................................................................................. 11 開發(fā)環(huán)境 ................................................................................................................11 關(guān)于 SAMSUNG WIRELESS TOOL KIT .......................................................................11 5 客戶端模塊的開發(fā) ...................................................................................................... 11 綜述 ......................................................................................................................11 程序的類結(jié)構(gòu) ........................................................................................................11 游戲的功能流程圖 ................................................................................................ 12 游戲的實(shí)現(xiàn) ........................................................................................................... 13 主類 Omok 的實(shí)現(xiàn) .......................................................................................... 13 游戲登錄界面以及操作說(shuō)明界面的實(shí)現(xiàn) .......................................................... 14 游戲畫布類的實(shí)現(xiàn) ........................................................................................... 16 網(wǎng)絡(luò)連接類的實(shí)現(xiàn) ........................................................................................... 18 五子棋獲勝算法 .............................................................................................. 19 6 服務(wù)器端程序的開發(fā) ................................................................................................... 21 數(shù)據(jù)庫(kù)的設(shè)計(jì)與實(shí)現(xiàn) ............................................................................................. 21 SERVLET 程序的編寫 .............................................................................................. 21 7 改進(jìn)建議和措施 .......................................................................................................... 24 關(guān)于圖片問(wèn)題 ........................................................................................................ 24 軟件測(cè)試 ............................................................................................................... 24 測(cè)試前的準(zhǔn)備工作 ........................................................................................... 24 進(jìn)行測(cè)試 ......................................................................................................... 25 有待添加和完善的功能 .................................................................................... 26 結(jié) 論 ...............................................................