Joyce Posted June 19, 2010 Author Share Posted June 19, 2010 Well, I've been fiddling around with it trying to figure out why it crashes.. but I can't seem to make any sense out of it! The darn thing crashes on saving it for some reason.. Here's the sub that saves the quests(works fine when generating empty quest files)```Sub SaveQuest(ByVal QuestNum As Long) Dim filename As String Dim F As Long filename = App.Path & "\data\quests\quest" & QuestNum & ".dat" F = FreeFile Open filename For Binary As #F Put #F, , Quest(QuestNum) Close #FEnd Sub```And here's the type(s) I use for it(yes, they are set as a public named Quest())```Private Type QuestObjectiveRec FlagKillNPC As Boolean FlagGather As Boolean FlagTalk As Boolean KillNPC As Byte GatherItem As Byte TalkNPC As Byte Amount As ByteEnd TypePrivate Type QuestRewardRec ID As Byte Amount As ByteEnd TypePublic Type QuestRec Name As String Description As String StartText As String AwaitText As String EndText As String ReqQuest As Long Objective(1 To QUEST_MAXOBJ) As QuestObjectiveRec Reward(1 To QUEST_MAXREW) As QuestRewardRec RewardExp As LongEnd Type```Does anyone know why it does that? It doesn't give any errors, the server just instantly freezes and crashes with the generic "has stopped working" message. Link to comment Share on other sites More sharing options...
Robin Posted June 19, 2010 Share Posted June 19, 2010 Strings need to be static.Name As String * 50Description As String * 100etc. Link to comment Share on other sites More sharing options...
Joyce Posted June 19, 2010 Author Share Posted June 19, 2010 *facepalm* I should've known that xD Thanks :azn: 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