psp 用java_PSP编程概述

本文介绍了如何进行PSP编程,包括使用C或C++,借助Cygwin在Windows环境下搭建开发环境,以及在PSP上运行HTML、CSS和JavaScript程序。还提到了可能结合Perl、Python或Lua等脚本语言的可能性。
摘要由CSDN通过智能技术生成

元旦准备买NDS,顺带关注了下PSP,其实是想,或许买PSP也不错~

PSP很像一个平台,提供了很多东西,譬如官方的PS模拟器~在上面编程也是个不错的想法。

国外的一个网站提供了很多信息,PS2Dev Network (http://www.ps2dev.org),有教程http://ps2dev.org/psp/Tutorials,现在由于不久前的地震,基本无法登陆那个网站。更多的信息在http://wiki.ps2dev.org/。

要想进行PSP编程,需要学习C或C++。在windows下,需要安装Cygwin http://www.cygwin.com/, 这其实是个模拟linux的环境。在Mac OS X或Linux下需要编译PSPSDK和PSP 工具。这些东西都可以在http://ps2dev.org/psp/Projects找到。

4f1150b881333f12a311ae9ef34da474.png

--

starting positions

for

the character

4f1150b881333f12a311ae9ef34da474.png x

=

200

4f1150b881333f12a311ae9ef34da474.png y

=

100

4f1150b881333f12a311ae9ef34da474.png

4f1150b881333f12a311ae9ef34da474.png

--

A nice color

4f1150b881333f12a311ae9ef34da474.png color

=

Color.new(

128

,

255

, 0)

4f1150b881333f12a311ae9ef34da474.png

4f1150b881333f12a311ae9ef34da474.png

--

this flag tells whether the program needs to draw

4f1150b881333f12a311ae9ef34da474.png draw_character

=

true

4f1150b881333f12a311ae9ef34da474.png

4f1150b881333f12a311ae9ef34da474.png

--

loop forever

4f1150b881333f12a311ae9ef34da474.png

while

true do

4f1150b881333f12a311ae9ef34da474.png

4f1150b881333f12a311ae9ef34da474.png

if

draw_character then

4f1150b881333f12a311ae9ef34da474.png

--

print

a rogue at the x

/

y coordinates

4f1150b881333f12a311ae9ef34da474.png     screen:

print

(x, y,

"

@

"

, color)

4f1150b881333f12a311ae9ef34da474.png     screen.flip()

4f1150b881333f12a311ae9ef34da474.png   end

4f1150b881333f12a311ae9ef34da474.png

4f1150b881333f12a311ae9ef34da474.png

--

check whether the user pressed the pad,

and

move accordingly

4f1150b881333f12a311ae9ef34da474.png   pad

=

Controls.read()

4f1150b881333f12a311ae9ef34da474.png   draw_character

=

true

4f1150b881333f12a311ae9ef34da474.png

if

pad:left() then

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值