ScriptUO

Official ScriptUO EasyUO Scripts => Script Debug => Topic started by: The Ghost on January 13, 2014, 12:35:27 PM

Title: clent crach on drop sub
Post by: The Ghost on January 13, 2014, 12:35:27 PM
It seen that this sub make my client crash sometime.  it could be find for a few day and other it will crash a few time in a day.     any reason for it.  The flow seen to make seen to me.   Should I increase the wait time.

Code: [Select]
sub organize
 namespace push
  namespace local ORG
FindItem %TurnIN C_ , %itembox
if #FINDCNT =  100
   return
finditem %TurnIN C_ , #backpackid
  for #FINDINDEX 1 #FINDCNT
  {
  exEvent Drag #findID
  exevent dropc %itembox
  wait 21
  }
  namespace pop
return #true
Title: Re: clent crach on drop sub
Post by: manwinc on January 13, 2014, 12:41:58 PM
When using
Code: [Select]
For #Findindex 1 #Findcnt
{
}
Always make sure that there are items before doing it.

Code: [Select]
if #Findcnt > 0
{
For #Findindex 1 #findcnt
{
}
}
This is the Reason
Code: [Select]
For %Number 1 0
{
Display This is the Reason
}
Halt

Everyone is different, but usually I use  
Exevent Drag
wait 15
Exevent Dropc
wait 15

This usually gets me some Stability when moving things. People will fight it all day long, its slower, but when you lag you don't usually get the ghost images.
Title: Re: clent crach on drop sub
Post by: Tidus on January 13, 2014, 02:58:42 PM
Could be because you have no wait between your drag and then the drop.  MW pointed out alot of good things. Read his post well and expiriment and you will understand.