귀환장소 설정
2007.04.12 13:02
INS에 있는 내용을 가져온 것입니다.
----------------------------------------------------------------
1. global.c 에 '귀환장소'명령어를 추가한다.
2. mtype.h 에 PRTACI , PRTNOW , PRTPAS 추가한다.
3. 밑의 소스 추가 ^^ (현재 귀환장소가 디폴트값)
/***********************************************************************/
/* 귀환장소 설정 */
/***********************************************************************/
/* Make by 젤가디스 */
int return_place(ply_ptr,cmnd)
creature *ply_ptr;
cmd *cmnd;
{
room *rom_ptr;
char *str[20];
int fd;
fd = ply_ptr->fd;
rom_ptr = ply_ptr->parent_rom;
if(cmnd->num < 2){
ANSI(fd,CYAN);
print(fd,"어디로 귀환하시려구요?\n");
print(fd,"- 형식 : 귀환희망장소 귀환장소 -\n");
ANSI(fd,WHITE);
return(0);
}
if(!strcmp(cmnd->str[1],"과거")){
F_SET(ply_ptr,PRTACI);
F_CRL(ply_ptr,PRTNOW);
F_CRL(ply_ptr,PRTPAS);
print(fd,"과거로 귀환합니다.\n");
return 0;
}
else if(!strcmp(cmnd->str[1],"현대")){
F_SET(ply_ptr,PRTNOW);
F_CRL(ply_ptr,PRTACI);
F_CRL(ply_ptr,PRTPAS);
print(fd,"현대로 귀환합니다.\n");
return 0;
} else if(!strcmp(cmnd->str[1],"미래")){
F_SET(ply_ptr,PRTPAS);
F_CRL(ply_ptr,PRTACI);
F_CRL(ply_ptr,PRTNOW);
print(fd,"미래로 귀환합니다.\n");
return 0;
}
else{
print(fd,"그런 귀환장소는 없습니다.\n");
print(fd,"현대로 귀환합니다.\n");
F_CRL(ply_ptr,PRTPAS);
F_CRL(ply_ptr,PRTACI);
F_SET(ply_ptr,PRTNOW);
return 0; }
}
5. COMMAND1.C 부분의 귀환장소 수정
int return_square(ply_ptr,cmnd)
creature *ply_ptr;
cmd *cmnd;
{
room *rom_ply;
int fd;
ctag *cp;
rom_ply=ply_ptr->parent_rom;
fd=ply_ptr->fd;
if(ply_is_attacking(ply_ptr,cmnd)) {
print(fd,"당신은 싸우고 있는 중입니다!!");
return 0;
}
/*if(rom_ply->rom_num==1001) {
print(fd,"당신은 이미 광장에 와 있습니다!");
return 0;
}*/
if(F_ISSET(ply_ptr,PRTNOW) && rom_ply->rom_num==1001)
{ print(fd,"당신은 이미 광장에 와 있습니다!\n");
return 0; }
else if(F_ISSET(ply_ptr,PRTACI) && rom_ply->rom_num==7)
{ print(fd,"당신은 이미 광장에 와 있습니다!\n");
return 0; } else if(F_ISSET(ply_ptr,PRTPAS) && rom_ply->ro
{ print(fd,"당신은 이미 광장에 와 있습니다!\n");
return 0; }
if(ply_ptr->following) {
cp = ply_ptr->following->first_fol;
}
else {
cp = ply_ptr->first_fol;
}
if(cp){
print(fd,"먼저 그룹에서 나오세요.");
return(0);
} if(ply_ptr->level>20 && ply_ptr->class print(fd, "당신이 귀환하려하자 흑암의 세력이 당신의 도력을 뺏습니다.\n");
ply_ptr->mpcur = 0;
}
print(fd, "당신이 \"귀환!\"이라고 외치자 이상한 힘에 의해 어딘가로 빨려들어갑니
다.");
if(!F_ISSET(ply_ptr,PDMINV))
broadcast_rom(fd,ply_ptr->rom_num,"\n%m님이 갑자기 사라집니다!",ply_ptr);
del_ply_rom(ply_ptr,rom_ply); if(!F_ISSET(ply_ptr,PFRTUN)){
if(F_ISSET(ply_ptr,PRTNOW))
/*현대 광장으로 귀환*/
load_rom(1001,&rom_ply);
/*과거 광장으로 귀환*/
else if(F_ISSET(ply_ptr,PRTACI))
load_rom(7,&rom_ply);
/*미래 광장으로 귀환*/
else if(F_ISSET(ply_ptr,PRTPAS))
load_rom(16,&rom_ply); }
else
load_rom(3300 + ply_ptr->daily[DL_EXPND].max, &rom_ply);
add_ply_rom(ply_ptr,rom_ply);
if(!F_ISSET(ply_ptr,PDMINV))
broadcast_rom(fd,ply_ptr->rom_num, "\n%m님이 갑자기 자욱한 연기와 함께 나타났습
니다!",ply_ptr);
return 0;
}
홈지기 "그륨"
----------------------------------------------------------------
1. global.c 에 '귀환장소'명령어를 추가한다.
2. mtype.h 에 PRTACI , PRTNOW , PRTPAS 추가한다.
3. 밑의 소스 추가 ^^ (현재 귀환장소가 디폴트값)
/***********************************************************************/
/* 귀환장소 설정 */
/***********************************************************************/
/* Make by 젤가디스 */
int return_place(ply_ptr,cmnd)
creature *ply_ptr;
cmd *cmnd;
{
room *rom_ptr;
char *str[20];
int fd;
fd = ply_ptr->fd;
rom_ptr = ply_ptr->parent_rom;
if(cmnd->num < 2){
ANSI(fd,CYAN);
print(fd,"어디로 귀환하시려구요?\n");
print(fd,"- 형식 : 귀환희망장소 귀환장소 -\n");
ANSI(fd,WHITE);
return(0);
}
if(!strcmp(cmnd->str[1],"과거")){
F_SET(ply_ptr,PRTACI);
F_CRL(ply_ptr,PRTNOW);
F_CRL(ply_ptr,PRTPAS);
print(fd,"과거로 귀환합니다.\n");
return 0;
}
else if(!strcmp(cmnd->str[1],"현대")){
F_SET(ply_ptr,PRTNOW);
F_CRL(ply_ptr,PRTACI);
F_CRL(ply_ptr,PRTPAS);
print(fd,"현대로 귀환합니다.\n");
return 0;
} else if(!strcmp(cmnd->str[1],"미래")){
F_SET(ply_ptr,PRTPAS);
F_CRL(ply_ptr,PRTACI);
F_CRL(ply_ptr,PRTNOW);
print(fd,"미래로 귀환합니다.\n");
return 0;
}
else{
print(fd,"그런 귀환장소는 없습니다.\n");
print(fd,"현대로 귀환합니다.\n");
F_CRL(ply_ptr,PRTPAS);
F_CRL(ply_ptr,PRTACI);
F_SET(ply_ptr,PRTNOW);
return 0; }
}
5. COMMAND1.C 부분의 귀환장소 수정
int return_square(ply_ptr,cmnd)
creature *ply_ptr;
cmd *cmnd;
{
room *rom_ply;
int fd;
ctag *cp;
rom_ply=ply_ptr->parent_rom;
fd=ply_ptr->fd;
if(ply_is_attacking(ply_ptr,cmnd)) {
print(fd,"당신은 싸우고 있는 중입니다!!");
return 0;
}
/*if(rom_ply->rom_num==1001) {
print(fd,"당신은 이미 광장에 와 있습니다!");
return 0;
}*/
if(F_ISSET(ply_ptr,PRTNOW) && rom_ply->rom_num==1001)
{ print(fd,"당신은 이미 광장에 와 있습니다!\n");
return 0; }
else if(F_ISSET(ply_ptr,PRTACI) && rom_ply->rom_num==7)
{ print(fd,"당신은 이미 광장에 와 있습니다!\n");
return 0; } else if(F_ISSET(ply_ptr,PRTPAS) && rom_ply->ro
{ print(fd,"당신은 이미 광장에 와 있습니다!\n");
return 0; }
if(ply_ptr->following) {
cp = ply_ptr->following->first_fol;
}
else {
cp = ply_ptr->first_fol;
}
if(cp){
print(fd,"먼저 그룹에서 나오세요.");
return(0);
} if(ply_ptr->level>20 && ply_ptr->class print(fd, "당신이 귀환하려하자 흑암의 세력이 당신의 도력을 뺏습니다.\n");
ply_ptr->mpcur = 0;
}
print(fd, "당신이 \"귀환!\"이라고 외치자 이상한 힘에 의해 어딘가로 빨려들어갑니
다.");
if(!F_ISSET(ply_ptr,PDMINV))
broadcast_rom(fd,ply_ptr->rom_num,"\n%m님이 갑자기 사라집니다!",ply_ptr);
del_ply_rom(ply_ptr,rom_ply); if(!F_ISSET(ply_ptr,PFRTUN)){
if(F_ISSET(ply_ptr,PRTNOW))
/*현대 광장으로 귀환*/
load_rom(1001,&rom_ply);
/*과거 광장으로 귀환*/
else if(F_ISSET(ply_ptr,PRTACI))
load_rom(7,&rom_ply);
/*미래 광장으로 귀환*/
else if(F_ISSET(ply_ptr,PRTPAS))
load_rom(16,&rom_ply); }
else
load_rom(3300 + ply_ptr->daily[DL_EXPND].max, &rom_ply);
add_ply_rom(ply_ptr,rom_ply);
if(!F_ISSET(ply_ptr,PDMINV))
broadcast_rom(fd,ply_ptr->rom_num, "\n%m님이 갑자기 자욱한 연기와 함께 나타났습
니다!",ply_ptr);
return 0;
}
홈지기 "그륨"
댓글 0
번호 | 제목 | 글쓴이 | 날짜 | 조회 수 |
---|---|---|---|---|
57 | 특수 아이템 만들기 | 그리움 | 2007.04.12 | 253 |
56 | 몹과 자신을 "비교" | 그리움 | 2007.04.12 | 219 |
55 | 패거리 전쟁시 적과 아군 구분 | 그리움 | 2007.04.12 | 216 |
54 | 순위 소스 | 그리움 | 2007.04.12 | 215 |
53 | 개량형 우체국 | 그리움 | 2007.04.12 | 228 |
52 | 명성치 도입 | 그리움 | 2007.04.12 | 229 |
51 | 자기 아파트 방설명은 자기가 #2 | 그리움 | 2007.04.12 | 222 |
50 | 이동력 추가하기 | 그리움 | 2007.04.12 | 225 |
49 | 경매 소스 | 그리움 | 2007.04.12 | 217 |
48 | 글자색, 배경색 15색 사용하기 | 그리움 | 2007.04.12 | 213 |
47 | Ctrl+Enter 패치하기 | 그리움 | 2007.04.12 | 198 |
46 | 패거리 상점 만들기 | 그리움 | 2007.04.12 | 199 |
» | 귀환장소 설정 | 그리움 | 2007.04.12 | 228 |
44 | 출구 정렬 | 그리움 | 2007.04.12 | 222 |
43 | 게시판 검색 기능 추가하기 | 그리움 | 2007.04.12 | 207 |
42 | 암호 *****로 보이게 하기 | 그리움 | 2007.04.12 | 215 |
41 | 레벨을 32767까지 가능하게 | 그리움 | 2007.04.12 | 236 |
40 | 잡담 안시 사용하기 | 그리움 | 2007.04.12 | 236 |
39 | 지도 소스 #2 | 그리움 | 2007.04.12 | 230 |
38 | 베팅소스 | 그리움 | 2007.04.12 | 242 |