UID2354
帖子
精華
主題
積分234172
現金
積極性
威望
違規
熱心
推廣次數
閱讀權限50
註冊時間2007-8-17
在線時間 小時
最後登錄1970-1-1
TA的每日心情 | 開心 2024-9-22 07:14 PM |
---|
簽到天數: 238 天 連續簽到: 1 天 [LV.7]常住居民III
|
發表於 2010-10-20 19:10:51
|
顯示全部樓層
attachrid(<account ID>)
detachrid;
A 'RID' is an ID of a character who caused the NPC script to run, as has been
explained above in the introduction section. Quite a bit of commands want a RID
to work, since they wouldn't know where to send information otherwise. And in
quite a few cases the script gets invoked with a RID of zero (like through
OnTime special labels). If an NPC script needs this, it can attach a specified
character's id to itself. by calling the 'attachrid' function.
'attachrid' returns 1 if the character was found online and 0 if it wasn't.
This could also be used, while running in a script invoked by a character
through talking to an NPC, to mess with other characters.
Detaching the RID will make the RID of the script zero. |
|