#include "pcbnet2.as" #define PORT 3301 ;ポート番号 ;///////////////////////////////////////////// 初期化 randomize sdim name,64 sdim host,256 sdim msg,256 sdim memberlist,16000 sdim buf,2000 sdim s,2000 sdim ss,2000 host="127.0.0.1" r = rnd(100) name="Test"+r title "Simple Chat" objmode 2 ;///////////////////////////////////////////// メニュー画面 *menu cls 1 pos 10,10 mes "接続先:" pos 20,30 input host,200,24,255 pos 10,70 mes "ニックネーム:" pos 20,90 input name,200,24,63 pos 40,150 objsize 120,24 button "接続",*connect objsel 0 stop ;///////////////////////////////////////////// 接続開始 *connect if (name="")|(host="") : dialog "必要事項を入力してください" : stop cls 1 tcpopen soc,host,PORT if stat : dialog "tcpopenに失敗しました!",1 : end mes host+" に接続中..." *@ tcpiscon soc if stat=0 : wait 1 : goto *@b if stat>1 : tcpclose soc : dialog "接続に失敗しました!",1 : goto *menu mes "接続が完了しました." wait 50 cls 1 pos 0,ginfo_winy-24 mesbox msg,ginfo_winx-160,24,1 pos ginfo_winx-160,0 objsize 160,ginfo_winy listbox dummy,0,"" tcpput "login "+name+"\n",soc goto *main ;///////////////////////////////////////////// メイン *main tcpfail soc if stat : tcpclose soc : dialog "接続が切断されました!",1 : end tcpgetl buf,1024,soc if stat : gosub *recv a = instr(msg,0,"\n") if a!-1 : gosub *send wait 1 goto *main *recv sdim cmd,1024 sdim arg,1024 getstr cmd,buf,0,' ' getstr arg,buf,strsize if cmd="joined" : gosub *joinedmember if cmd="left" : gosub *leftmember if cmd="msg" : gosub *message return *joinedmember memberlist+=arg+"\n" objprm 1,memberlist objsel 0 return *leftmember notesel memberlist members = notemax repeat members noteget s,cnt if s=arg : notedel cnt : break loop objprm 1,memberlist objsel 0 return *message redraw 2 pos 0,0 gcopy 0,0,20,ginfo_winx,ginfo_winy-20 pos 0,ginfo_winy-24-20 mes arg redraw 1 return *send s=msg a = instr(s,0,"\n") getstr ss,s,a+2 poke s,a,0 s+=ss buf="say "+s+"\n" tcpput buf,soc msg = "" objprm 0,msg return
エラー↓
Error 38 in line 121
外部DLLの呼び出しに失敗しました
↑
と出ます...
対処法を教えてくださいw