UID139661
帖子
精華
主題
積分33646
現金
積極性
威望
違規
熱心
推廣次數
閱讀權限30
註冊時間2009-3-22
在線時間 小時
最後登錄1970-1-1
TA的每日心情 | 無聊 2025-2-26 12:31 PM |
---|
簽到天數: 73 天 連續簽到: 1 天 [LV.6]常住居民II
|
發表於 2011-12-24 21:33:07
|
顯示全部樓層
本帖最後由 sb66665112 於 2011-12-24 09:34 PM 編輯
- *getmapxy("授予你地圖的變數名稱"(字串),授予你地圖的x變數名稱(數字),授予你地圖的y變數名稱(數字),種類{,"搜尋字樣"})
- This function will locate a character object(這個函數將會找出一個目標角色, NPC object or pet's coordinates (目標Npc或者寵物??)
- and place their coordinates into the variables specified when calling it.(寄他們的動作在變數裡) It
- will return 0 if the search was successful(如果他查詢成功,將會返回0), and -1 if the parameters given were
- not variables or the search was not successful.(如果變數給的不是可變的(???白癡翻譯+1)或者查詢不成功就會返回-1
- Type is the type of object to search for:(以下是搜查目標的種類)
- 0 - Character object (角色,就是玩家)
- 1 - NPC object (Npc,廢話當然是Npc)
- 2 - Pet object (寵物,嗯..不知道要怎麼解釋)
- 3 - Monster object. (怪物...,你查的到才有鬼)
-
- While 3 is meant to look for a monster object, no searching will be done if you
- specify type 3, and the function will always return -1.
- The search string is optional. If it is not specified, the location of the
- invoking character will always be returned for types 0 and 2, the location of
- the NPC running this function for type 1.
- If a search string is specified, for types 0 and 1, the character or NPC with
- the specified name will be located. If type is 3, the search will locate the
- current pet of the character who's name is given in the search string, it will
- NOT locate a pet by name.
- What a mess. Example, a working and tested one now:
- prontera,164,301,3%TAB%script%TAB%Meh%TAB%730,{
- mes "我的名字是Meh. Nyah能夠找到在這裡的我."; (這句廢話請無視)
- close;
- }
- prontera,164,299,3%TAB%script%TAB%Nyah%TAB%730,{
- mes "我的名字是 Nyah.";
- mes "現在我將會橫過這個世界去找尋 Meh !"; // (??!!?這句我翻錯很大 (當然,我翻的沒一句是對的)
- if (getmapxy(@mapname$,@mapx,@mapy,1,"Meh")!=0) goto Notfound; //當然這個指令是當
- 找到Npc (種類1) Meh的時候 會把Meh的地圖名稱紀錄在@mapname$ X做標記錄在@mapx Y座標記錄在@mapy
- mes "然而我找到他了,地圖是 "+@mapname$+" 位於X座標:"+@mapx+" Y座標:"+@mapy+" !";
- close;
- Notfound:
- mes "我在我能所見的任何地方沒有找到Meh!";
- close;
- }
-
- Notice that NPC objects disabled with 'disablenpc' will still be located.
- (這句大概是表達複製Npc的話只會回傳本尊的座標地圖)
複製代碼 |
|