XP 스크립트

http://www.dubealex.com/asylum/index.php?showtopic=9830
여러 개의 png파일을 사용한 애니메이션 처리. 단, 이 스크립트는 암호화된 프로젝트에서는 정상적으로 동작하지 않을 수 있습니다.


#==============================================================================
# ** Quick Animations
#==============================================================================
# SephirothSpawn
# Version 1
# 2006-07-06
#------------------------------------------------------------------------------
# * Instructions
#
# ~ Creating Animation
#
# = Quick_Animation.new(directory, loop, frame_skip, viewport)
#
# directory : Directory in your Projects Folder for the image
# loop : true (image loops) or false (image plays and disposes itself)
# frame_skip : number of frames to proceed to next image
# viewport : viewport of image
#
# ~ Object must update, or frames won't pass through.
# ~ Don't update a object after it disposes. A quick way around of this
#
#.update unless.nil? ||.disposed?
#==============================================================================

#------------------------------------------------------------------------------
# * SDK Log Script-x
#------------------------------------------------------------------------------
SDK.log('Quick Animations', 'SephirothSpawn', 1, '2006-07-06')

#------------------------------------------------------------------------------
# * Begin SDK Enable Test
#------------------------------------------------------------------------------
if SDK.state('Quick Animations') == true

#==============================================================================
# ** Quick_Animation
#==============================================================================

class Quick_Animation < Sprite
#--------------------------------------------------------------------------
# * Object Initialization
# ~ directory : foldername in Pictures Folder
# ~ loop : true or false to loop or not loop image
# ~ frame_skip : number of frames to advance next image
# ~ viewport : viewport on window
#--------------------------------------------------------------------------
def initialize(directory, loop = true, frame_skip = 10, viewport = nil)
super(viewport)
# Stores Directory, Loop & Frame Skip Count
@directory, @loop, @frame_skip = directory, loop, frame_skip
# Starts Index Count
@index = 0
# Updates Bitmap
update
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update
# Stop Unless Frame Skip Reached
return unless Graphics.frame_count % @frame_skip == 0
# Adds 1 to the index
@index += 1
# If not Last Image
if Dir.entries(@directory).include?("#{@index}.png")
# Sets Bitmap
self.bitmap = RPG::Cache.load_bitmap(@directory, @index.to_s)
# If Last Image Already Displayed
else
# If Loop Image
if @loop
# Reset Index & Update Bitmap
@index = 0
update
# If No Loop
else
# Delete Image
self.dispose
end
end
end
end

#--------------------------------------------------------------------------
# * End SDK Enable Test
#--------------------------------------------------------------------------
end

Who's 백호

?

이상혁입니다.

http://elab.kr


List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
공지 스크립트 자료 게시물 작성시 주의사항 습작 2012.12.24 6159
981 오디오 WhiteFlute - AudioEX (XP/VX/VXA) file Alkaid 2012.12.26 1255
980 그래픽 WhiteFlute - BitmapEX 4 file JACKY 2012.12.10 2951
979 오디오 Audio Module Rewrite mciSendString 1.1 by DerVVulfman Alkaid 2012.09.18 1368
978 전투 Trickster씨의 전투 시스템 (SDK 필수?) Alkaid 2012.09.18 3257
977 스킬 Trickster's Bag of Skill Effects (SDK 필요) Alkaid 2012.09.17 1289
976 변수/스위치 Switchless Common Events by PK8(XP/VX/VXA) Alkaid 2012.09.15 1199
975 변수/스위치 Initial Switches and Variables by PK8 (XP/VX/VXA) Alkaid 2012.09.14 1296
974 변수/스위치 The Self Data Suite by PK8 (XP/VX/VXA) Alkaid 2012.09.14 1232
973 그래픽 부드럽게 화면이 움직이는 스크립트 입니다. 16 GangSin 2012.09.12 4590
972 맵/타일 Editor Tiles by PK8 (XP/VX/VXA) Alkaid 2012.09.11 1868
971 장비 Auto Equipment Optimization for Guillaume777's Multi Slot Script by DerVVulfman Alkaid 2012.09.09 1497
970 메뉴 Leidy's Ring Command Window 1.2 by DerVVulfman Alkaid 2012.09.09 1431
969 그래픽 Pictures below Characters by PK8 (XP/VXA) Alkaid 2012.09.07 1640
968 그래픽 Event Transparency by DerVVulfman (XP/VX/VXA) Alkaid 2012.09.01 1485
967 전투 Etude87_Custom_Slip_Damage_XP ver.1.0 5 습작 2012.08.26 1857
966 전투 Mr.Mo's ABS Ultimate 7.0 by DerVVulfman 4 Alkaid 2012.08.26 2587
965 그래픽 Composite Window Skins by PK8 (XP/VX/VXA) Alkaid 2012.08.26 1559
964 스킬 Miriam's Handicrafts! 1.3 by DerVVulfman Alkaid 2012.08.26 1204
963 전투 Minkoff's Animated Battlers - Enhanced 13.8 by DerVVulfman 1 Alkaid 2012.08.26 1832
962 메뉴 메뉴를 바꾸는 스크립트 14 №1 2012.08.04 4209
Board Pagination Prev 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 ... 52 Next
/ 52