VX 스크립트

기타
2009.03.29 12:24

캐릭터 소개화면

조회 수 6044 추천 수 0 댓글 16
Atachment
첨부 '1'
스크립트에서 수정을 해주셔야합니다.

캐릭터의 키, 몸무게, 나이등을 스크립트에 적어주세요.

아래에 있는 커스터마이즈에서 하실수있습니다.

그리고 캐릭터 그래픽을 반드시 넣어주셔야합니다.

Graphic/face 폴더안에 그래픽을 넣어주세요

그래픽의 이름도 스크립트에서 제대로 수정하셔야합니다.

















====================================================== # ■ VX-RGSS2-1 캐릭터소개화면 [Ver.1.0.0] by Claimh #------------------------------------------------------------------------------ #  ·스테이터스 화면시에 어떠한 버튼을 누르는 것으로,
#    각 캐릭터의 상세 설명 화면을 표시할 수 있습니다.
#   ·버튼은 HELP의 Input를 보고, 확인해 주세요.
#   ·표준에서는, 캐릭터의 연령, 출신지, 신장, 체중,
#    그 외의 문장 설명을 대응하고 있습니다.
#   ·이외에 추가하고 싶은 경우는, 개조해 주세요. #============================================================================== module Chara_Review #---------------------------------------------------------------------------- # 설정START #---------------------------------------------------------------------------- # 캐릭터 소개로 전환하는 버튼(디폴트:C) CHENGE_KEY = Input::C #-------------------------------------------------------------------------- # ● 연령(액터 ID의 순서에 넣어 가 주세요)
#-------------------------------------------------------------------------- CHARA_AGE = { # アクターID => "나이" 1 => "??", 2 => "??", 3 => "??", 4 => "??", 5 => "??", 6 => "??", 7 => "??", 8 => "??" } #-------------------------------------------------------------------------- # ● 출신지(사는곳) #-------------------------------------------------------------------------- CHARA_FROM = { # アクターID => "출신지" 1 => "??", 2 => "??", 3 => "??", 4 => "??", 5 => "??", 6 => "??", 7 => "??", 8 => "??" } #-------------------------------------------------------------------------- # ●신장(키) #-------------------------------------------------------------------------- CHARA_H = { # アクターID => "신장" 1 => "??", 2 => "??", 3 => "??", 4 => "??", 5 => "??", 6 => "??", 7 => "??", 8 => "??" } #-------------------------------------------------------------------------- # ● 체중(몸무게) #-------------------------------------------------------------------------- CHARA_W = { # アクターID => "체중" 1 => "??", 2 => "??", 3 => "??", 4 => "??", 5 => "??", 6 => "??", 7 => "??", 8 => "??" } #-------------------------------------------------------------------------- # ● 그 외 문장(n를 넣으면 개행합니다)
#-------------------------------------------------------------------------- CHARA_INFO = { # アクターID:1 1 => "???", # アクターID:2 2 => "???", # アクターID:3 3 => "???", # アクターID:4 4 => "???", # アクターID:5 5 => "???", # アクターID:6 6 => "???", # アクターID:7 7 => "???", # アクターID:8 8 => "???" } #-------------------------------------------------------------------------- # ● 버스트 업 화상 (소개화면에 표시할 캐릭터 그래픽) #-------------------------------------------------------------------------- # 얼굴 그래픽이 아니고, 버스트 업 화상을 사용한다
BSTUP = true # 버스트 업 화상의 파일명(Graphics/Face) BSTUP_FILE = { # 액터ID:1 1 => "Actor1-1", # 액터ID:2 2 => "Actor2-2", # 액터ID:3 3 => "Actor3-3", # 액터ID:4 4 => "Actor4-4" } #---------------------------------------------------------------------------- # カスタマイズEND #---------------------------------------------------------------------------- end #============================================================================== # ■ Window_Charactor #------------------------------------------------------------------------------ #  キャラ紹介画面 #============================================================================== class Window_Charactor < Window_Base #-------------------------------------------------------------------------- # ● オブジェクト初期化 # actor : アクター #-------------------------------------------------------------------------- def initialize(actor) super(0, 0, 544, 416) self.contents = Bitmap.new(width - 32, height - 32) refresh(actor) end #-------------------------------------------------------------------------- # ● リフレッシュ #-------------------------------------------------------------------------- def refresh(actor) self.contents.clear return if actor.nil? if Chara_Review::BSTUP refresh_bstup(actor) # バストアップの描画 else refresh_face(actor) # 顔グラフィックの描画 end end #-------------------------------------------------------------------------- # ● リフレッシュ(BSTUP) #-------------------------------------------------------------------------- def refresh_bstup(actor) draw_face_picture(Chara_Review::BSTUP_FILE[actor.id], 0, 0) self.contents.font.color = system_color self.contents.draw_text(280, 30, 80, WLH, "Name:") self.contents.draw_text(280, 60, 80, WLH, "Age:") self.contents.draw_text(280, 90, 80, WLH, "From:") self.contents.draw_text(280, 120, 80, WLH, "Height:") self.contents.draw_text(280, 150, 80, WLH, "Weight:") self.contents.font.color = normal_color draw_actor_name(actor, 380, 30) self.contents.draw_text(380, 60, 80, WLH, Chara_Review::CHARA_AGE[actor.id]) self.contents.draw_text(380, 90, 180, WLH, Chara_Review::CHARA_FROM[actor.id]) self.contents.draw_text(380, 120 , 200, WLH, Chara_Review::CHARA_H[actor.id]) self.contents.draw_text(380, 150, 250, WLH, Chara_Review::CHARA_W[actor.id]) draw_enter_text(20, 300, 500, WLH, Chara_Review::CHARA_INFO[actor.id]) end #-------------------------------------------------------------------------- # ● リフレッシュ(FACE) #-------------------------------------------------------------------------- def refresh_face(actor) draw_actor_face(actor, 8, 32) self.contents.font.color = system_color self.contents.draw_text(200, 30, 80, WLH, "Name:") self.contents.draw_text(200, 60, 80, WLH, "Age:") self.contents.draw_text(200, 90, 80, WLH, "From:") self.contents.draw_text(200, 120, 80, WLH, "Height:") self.contents.draw_text(200, 150, 80, WLH, "Weight:") self.contents.font.color = normal_color draw_actor_name(actor, 300, 30) self.contents.draw_text(300, 60, 80, WLH, Chara_Review::CHARA_AGE[actor.id]) self.contents.draw_text(300, 90, 180, WLH, Chara_Review::CHARA_FROM[actor.id]) self.contents.draw_text(300, 120 , 200, WLH, Chara_Review::CHARA_H[actor.id]) self.contents.draw_text(300, 150, 250, WLH, Chara_Review::CHARA_W[actor.id]) draw_enter_text(20, 200, 500, WLH, Chara_Review::CHARA_INFO[actor.id]) end end class Window_Base < Window #-------------------------------------------------------------------------- # ● 改行を認識して表示 #-------------------------------------------------------------------------- def draw_enter_text(x, y, width, height, text) info_box = text.split(/n/) for i in 0...info_box.size self.contents.draw_text( x, y+i*WLH, width, WLH, info_box[i]) break if (y+i*WLH) > (self.height-WLH) end end #-------------------------------------------------------------------------- # ● ピクチャ表示(Graphics/Face) #-------------------------------------------------------------------------- def draw_face_picture(file_name, x, y) bitmap = Cache.face(file_name) cw = bitmap.width ch = bitmap.height src_rect = Rect.new(0, 0, cw, ch) self.contents.blt(x, y, bitmap, src_rect) end end #============================================================================== # ■ Scene_Charactor #------------------------------------------------------------------------------ #  キャラ紹介画面の処理を行うクラスです。 #============================================================================== class Scene_Charactor < Scene_Base #-------------------------------------------------------------------------- # ● オブジェクト初期化 # actor_index : アクターインデックス #-------------------------------------------------------------------------- def initialize(actor_index = 0) @actor_index = actor_index end #-------------------------------------------------------------------------- # ● 開始処理 #-------------------------------------------------------------------------- def start super create_menu_background @actor = $game_party.members[@actor_index] @status_window = Window_Charactor.new(@actor) end #-------------------------------------------------------------------------- # ● 終了処理 #-------------------------------------------------------------------------- def terminate super dispose_menu_background @status_window.dispose end #-------------------------------------------------------------------------- # ● 元の画面へ戻る #-------------------------------------------------------------------------- def return_scene $scene = Scene_Status.new(@actor_index) end #-------------------------------------------------------------------------- # ● 次のアクターの画面に切り替え #-------------------------------------------------------------------------- def next_actor @actor_index += 1 @actor_index %= $game_party.members.size $scene = Scene_Charactor.new(@actor_index) end #-------------------------------------------------------------------------- # ● 前のアクターの画面に切り替え #-------------------------------------------------------------------------- def prev_actor @actor_index += $game_party.members.size - 1 @actor_index %= $game_party.members.size $scene = Scene_Charactor.new(@actor_index) end #-------------------------------------------------------------------------- # ● フレーム更新 #-------------------------------------------------------------------------- def update update_menu_background @status_window.update if Input.trigger?(Input::B) Sound.play_cancel return_scene elsif Input.trigger?(Input::R) Sound.play_cursor next_actor elsif Input.trigger?(Input::L) Sound.play_cursor prev_actor end super end end #============================================================================== # ■ Scene_Status #============================================================================== class Scene_Status #-------------------------------------------------------------------------- # ● フレーム更新 #-------------------------------------------------------------------------- alias update_chara update def update if Input.trigger?(Chara_Review::CHENGE_KEY) Sound.play_decision $scene = Scene_Charactor.new(@actor_index) end update_chara end end

 

Who's 좀비사냥꾼

?

 

 

Comment '16'
  • profile
    미니♂ban♀ 2009.03.31 00:04
    이거 너무 오류가 많이 나오네요.
    맨 처음에 #<-- 이것도 빠졋고 게임에 맞게 수정해서 해도 안돼고 그냥 해도 이 스크립트에 오류 나는거 같은데요.
  • ?
    칼맞은법사 2009.04.22 20:20
    스크립트에서 #는 주석처리할떄 쓰는거 아닌가요.. ? -_-..;
    제가 알기로는 뭐 설정할때( true 같은거 ) 빼고는 필요 없다고 알고있습니다만..?
  • ?
    알카 2009.03.31 00:14
    저도 오류나요...어떻게하면 되는거죠 ;;
  • ?
    루시페르 2009.04.05 14:53
        if Chara_Review::BSTUP
    이 부분이 이상하다고 에러뜬답니다아~
  • ?
    더네임ㅈㅈ 2009.04.05 22:40
    으음 사용법이..
  • ?
    백년술사 2009.04.09 19:15
  • ?
    크런키맛아듀크림 2009.05.05 03:29

    오류나요..ㅜㅜ

  • ?
    유스갈 2009.07.12 15:18
  • ?
    078656577er 2009.09.23 12:43

    잘 됩니다.

    다만

    # 얼굴 그래픽이 아니고, 버스트 업 화상을 사용한다 BSTUP = true

    이 부분을

    # 얼굴 그래픽이 아니고, 버스트 업 화상을 사용한다
      BSTUP = true

    이렇게 바꾸면 잘 됩니다.

    BSTUP = true 부분이 주석부분에 들어가게 되서 에러가 나는군요..

    바이오만 나온거 필요했는데 감사

  • ?
    1000℃ 복숭아 2010.01.27 15:17

    오류가 나는데요;

  • ?
    아직은초보 2010.01.28 12:00

    오류하지만 좋음

  • ?
    우지긴토키덮밥 2010.07.24 07:36

    오류가 나는데요?

  • ?
    김브레이커 2010.07.28 16:01

    어..엄청난..

  • ?
    KMS 2011.02.11 10:34
    감사합니다.
    좋은 거 얻고 가네요
  • ?
    캬무캬무 2011.07.25 21:04

    우와

  • ?
    초마 2011.11.05 07:02

    좋은 스크립트 감사드립니다~


List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
공지 스크립트 자료 게시물 작성시 주의사항 3 습작 2012.12.24 5398
130 기타 게임시간&밤낮 54 file 허걱 2009.02.14 6111
» 기타 캐릭터 소개화면 16 file 좀비사냥꾼 2009.03.29 6044
128 기타 작은 게이지바 표시 스크립트 44 file 허걱 2009.02.05 5979
127 기타 빛 이펙트 71 file DEVIL<Li Patanis Roni Kraudus> 2008.06.06 5860
126 기타 몬스터 리얼한 효과 27 file 사람이라면? 2010.08.16 5074
125 기타 RPG 2000이나 RPG 2003처럼 전체화면으로 나오게 하는 스크립트(대박) 21 Man... 2008.10.28 4821
124 기타 rpg vx 렉 줄이는 스크립트 34 아방스 2008.03.09 4813
123 기타 게임 해상도를 조절 하는 스크립트 19 아방스 2008.01.21 4780
122 기타 아이디를 띄우기 20 12345678 2011.11.07 4626
121 기타 간단한 스크립트의 사용법 6 아방스 2008.03.09 4552
120 기타 책 읽기 스크립트 44 file 히류 2010.10.05 4506
119 기타 책 읽기 스크립트. 19 허걱 2009.01.31 4490
118 기타 태양 스크립트. 15 file 할렘 2009.02.20 4463
117 기타 로딩중 스크립트 24 file NO.0 2009.07.11 4461
116 기타 글씨표시 스크립트 32 file 허걱 2009.08.10 4421
115 기타 심플 마우스 시스템 1.5 애드온 11 file RMdude 2009.02.11 4325
114 기타 집안의 가구를 내마음대로 데코레이션하기 15 file EuclidE 2010.09.18 4303
113 기타 [자작] 횡스크롤 점프스크립트 18 file 좀비사냥꾼 2009.04.03 4276
112 기타 (이거 정말 좋군요) 말이나 용을 탈수있게 하는 스크립트. 31 file 아방스가 짱 2010.02.28 4261
111 기타 아이콘 캐릭터 17 file 허걱 2010.02.28 4224
Board Pagination Prev 1 2 3 4 5 6 7 Next
/ 7