Prince Posted December 23, 2012 Author Share Posted December 23, 2012 After attack the npc then i got this error![](http://www.freemmorpgmaker.com/files/imagehost/pics/71e7b43468832a040d90620b06e0bc12.png) Link to comment Share on other sites More sharing options...
hisherwin Posted December 23, 2012 Share Posted December 23, 2012 What's the message? Link to comment Share on other sites More sharing options...
DshWinchester Posted December 23, 2012 Share Posted December 23, 2012 I got this tooits because npcnum is 0put this on top> if mapnpc(mapnpcnum).num < 0 or mapnpc(mapnpcnum).num>max_map_npcs then exit sub Link to comment Share on other sites More sharing options...
Prince Posted December 24, 2012 Author Share Posted December 24, 2012 > What's the message?Its RTE 9 subscript out of range.> I got this too> > its because npcnum is 0> > put this on topstill doesn't fix it. Link to comment Share on other sites More sharing options...
Mal Posted December 24, 2012 Share Posted December 24, 2012 > Its RTE 9 subscript out of range.> > still doesn't fix it.Read the code then. Checking if the sum is less than zero doesn't do duck all to fix the problem since the problem is the sum being zero. Think. Link to comment Share on other sites More sharing options...
Prince Posted December 24, 2012 Author Share Posted December 24, 2012 > Read the code then. Checking if the sum is less than zero doesn't do duck all to fix the problem since the problem is the sum being zero. Think.Thanks you so much, i just did this:``` If MapNpc(MapNpcNum).num <= 0 or MapNpc(MapNpcNum).num >= MAX_MAP_NPCS Then Exit Sub```Its working now. Thanks you Link to comment Share on other sites More sharing options...
Mal Posted December 24, 2012 Share Posted December 24, 2012 > Thanks you so much, i just did this:> > ```> > If MapNpc(MapNpcNum).num <= 0 or MapNpc(MapNpcNum).num >= MAX_MAP_NPCS Then Exit Sub> > ```> > Its working now. Thanks youGlad you got it working. Helps to think about the problem and how to solve it rather than jump right on the forums. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now