XP 스크립트

#==============================================================================
# ■ Window_PlayTime
#------------------------------------------------------------------------------
#  메뉴 화면에서 플레이 시간을 표시하는 윈도우입니다.
#==============================================================================

class Window_PlayTime < Window_Base
#--------------------------------------------------------------------------
# ● 오브젝트 초기화
#--------------------------------------------------------------------------
def initialize
super(0, 0, 160, 126)
self.contents = Bitmap.new(width - 32, height - 32)
refresh
end
#--------------------------------------------------------------------------
# ● 리프레쉬
#--------------------------------------------------------------------------
def refresh
self.contents.clear
self.contents.font.color = text_color(6)
time = Time.now
text = time.strftime(" 시계 - %X")
self.contents.draw_text(-10, 0, 135, 32, text, 2)
self.contents.font.color = system_color
self.contents.draw_text(4, 32, 120, 32, "플레이시간")
@total_sec = Graphics.frame_count / Graphics.frame_rate
hour = @total_sec / 60 / 60
min = @total_sec / 60 % 60
sec = @total_sec % 60
text = sprintf("%02d:%02d:%02d", hour, min, sec)
self.contents.font.color = normal_color
self.contents.draw_text(4, 32, 120, 88, text, 2)
end

#--------------------------------------------------------------------------
# ● 프레임 갱신
#--------------------------------------------------------------------------
def update
super
if Graphics.frame_count / Graphics.frame_rate != @total_sec
refresh
end
end
end

 

메뉴위에 찔러넣으세요..;

그냥 메뉴에 들어가면 현제시간이 표시되는

별것아닌 스크립트에요;

Who's 백호

?

이상혁입니다.

http://elab.kr

Comment '4'

List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
공지 스크립트 자료 게시물 작성시 주의사항 습작 2012.12.24 6153
154 기타 KGC - 입수 경험치&금 증가 스크립트 백호 2009.02.22 1301
153 기타 Complete Climate and Time System 1.2 by ForeverZer0 1 Alkaid 2010.09.17 1310
152 기타 Text to RGSS by DerVVulfman Alkaid 2011.04.18 1319
151 기타 엔딩에 스탭롤을 도입하는 스크립트 1 file 백호 2009.02.21 1335
150 기타 랜덤 지하 감옥 작성 스크립트 1 file 백호 2009.02.21 1338
149 기타 (T-RPG) 데미지 표시 시의 폰트를 설정 백호 2009.02.22 1348
» 기타 실제시간표시스크립트입니다...[중뷁이면지성;;] 4 백호 2009.02.22 1349
147 기타 빛의 퍼즐 -미니게임- 1 file 백호 2009.02.21 1360
146 기타 스크린샷 찍는 스크립트 9 file 백호 2009.02.22 1363
145 기타 Minesweeper(지뢰찾기) by SephirothSpawn (SDK호환) 3 file 백호 2009.02.22 1363
144 기타 Chaos Project Debug System 1.06b by Blizzard file Alkaid 2010.09.07 1367
143 기타 [All RGSS] 게임 다중 실행 방지 스크립트 1 file Cheapmunk 2014.05.24 1373
142 기타 CG모드 도입 스크립트 file 백호 2009.02.21 1383
141 기타 KGC_UsableWeapon file 백호 2009.02.22 1384
140 기타 Shift Puzzles by SephirothSpawn (SDK호환) 1 file 백호 2009.02.22 1389
139 기타 간단한 Scene_Base Alkaid 2010.09.09 1390
138 기타 게이지 3 백호 2009.02.21 1395
137 기타 마법반사스크립트 4 *ps인간 2009.01.26 1403
136 기타 Multiple Languages v2 by SephirothSpawn (SDK호환) file 백호 2009.02.22 1404
135 기타 풀스크린 스크립트 2 백호 2009.02.22 1407
Board Pagination Prev 1 2 3 4 5 6 7 8 9 10 11 12 13 Next
/ 13