메뉴 건너뛰기

창조도시 기록보관소

안녕하세요~ 전역을 앞에 두고 다시 RPG만들기에 불붙은 녹색주머니입니다+_+

 


---------------------------------------------------------------------------------------------------------------------


open(file[, mode]) {|io| ... }

Opens file and returns a File object. mode specifies one of the following strings. When mode is omitted, the default is "r".



  • "r": Opens file in read mode.

  • "w": Opens file in write mode. If a file already exists when file is opened, the previous file's contents will be deleted.

  • "a": Opens file in write mode. Output will always be appended to the end of the file.

Using "+" opens the file in read-write mode (RDWR):




  • "r+": Sets the read-write position to the beginning of the file.

  • "w+": The same as "r+", but if a file already exists when file is opened, the previous file's contents will be deleted.

  • "a+": The same as "r+", but if a file already exists when file is opened, the read-write position will be set to the end of the file.

The "b" flag can also be added to any of these (in the format "r+b") to open the file in binary mode.


--------------------------------------------------------------------------------------------------------------------


 


대충 r은 읽기모드. w는 쓰기모드라는 건 알겠는데..


 


Q1.  w와 a의 차이점.


 


Q2. +의 기능은?  안 붙이면 파일의 첫단부터 읽는거고 붙이면 마지막단부터읽는게 맞는지...


 


Q3. b는 ? 제한모드라는데 전혀 감을 못잡겠네요.

번호 제목 글쓴이 날짜 조회 수
7210 rpg만들기2000게임을 하는데 화면이 왼쪽으로 이동해있네요;; 에너미컨트롤러 2010.12.16 210
7209 rpg2003게임을 실행하면 글자가 이상하게 나오네욤ㅠㅠ(그림첨부) file Foxduck 2010.12.05 262
7208 혹시 RPGXP로 모바일 게임이나 어플을 제작 가능한가요? [1] 설영 2010.12.03 402
7207 아래에 질문했던 대시에 문제가 생겼습니다. Vermond 2010.11.27 148
7206 RPG만들기VX로 수사반장이나 카마이타치의밤같은거가능? [2] 하이욘 2010.11.27 223
7205 아래에 질문했던 대시에 문제가 생겼습니다. file Iriaroan。 2010.11.26 121
7204 아래에 질문했던 대시에 문제가 생겼습니다. [6] 정신나간애 2010.11.26 343
7203 RPG만들기 툴이요. Iriaroan。 2010.11.22 120
7202 RPG만들기 툴이요. [1] 하얀초코 2010.11.22 274
7201 rpg2000 무게 시스템 만들기 (360크링) Iriaroan。 2010.11.21 129
7200 [5000크링] 2003 질문들. file Iriaroan。 2010.11.21 131
7199 [5000크링] 2003 질문들. [2] 정신나간애 2010.11.21 393
7198 비극의 시련 S2민정S2 2010.11.20 192
7197 rpg2000 무게 시스템 만들기 (360크링) 우주쓰레기 2010.11.19 292
7196 VX] 주인공 캐릭터이미지 게임진행중 바꿀수있는 방법은? 무묘랑 2010.11.16 141
7195 VX] 주인공 캐릭터이미지 게임진행중 바꿀수있는 방법은? 무묘랑 2010.11.16 214
7194 캐릭터 레이더로 캐릭터 그리는 법좀 질문이요;; raddtr 2010.11.15 199
7193 액션알피지 만드는 중인데 질문이요;; [2] raddtr 2010.11.15 299
7192 아주 오래전에 재미있게 했던 게임을 찾습니다 알피지만들기09 2010.11.14 184
7191 포토샵 투명색 그라데이션 찰드 2010.11.13 223