Murdoc Posted September 25, 2011 Share Posted September 25, 2011 @Spiked:> I can't confirm the always drop thing, but I've set an item at item slot 2 and it saved from the npc.When you reopen the editor is that data still showing the same or different?The drop item part is definately bugged.. The percentages dont work right Link to comment Share on other sites More sharing options...
Scott Posted September 25, 2011 Author Share Posted September 25, 2011 I have not really tested this tutorial to hard I just ripped it from my game since people where posting about it. If there is something wrong it must be something simple I left out because mine works fine and I have not edited it since I made this tutorial. Link to comment Share on other sites More sharing options...
Murdoc Posted September 25, 2011 Share Posted September 25, 2011 @Scott:> I have not really tested this tutorial to hard I just ripped it from my game since people where posting about it. If there is something wrong it must be something simple I left out because mine works fine and I have not edited it since I made this tutorial.Okay… Well, when you put the chance at lets say 1 out of 4 on a second item does that item spawn only 1 out of 4 times or everytime? You say there must not be anything wrong, and at the same time that you have not tested it fully. If you want to help try replicating the error instead of being no help at all, thanks. Link to comment Share on other sites More sharing options...
Spiked Posted September 25, 2011 Share Posted September 25, 2011 @Murdock:> Okay… Well, when you put the chance at lets say 1 out of 4 on a second item does that item spawn only 1 out of 4 times or everytime? You say there must not be anything wrong, and at the same time that you have not tested it fully. If you want to help try replicating the error instead of being no help at all, thanks.The editor saved the info even after I reclosed it and such. I have not tested the drop 100% bug yet. I can work on that now =] Link to comment Share on other sites More sharing options...
Scott Posted September 25, 2011 Author Share Posted September 25, 2011 Use .25 for 25% thats how the orignal script was made to work its not a 1 out of 4 chance like it was before. All I can say is when I tested I made 4 items 10%,25%,50%,100% and there drop rate was the same as there name and it seemed to work fine to me. Link to comment Share on other sites More sharing options...
Murdoc Posted September 25, 2011 Share Posted September 25, 2011 @Scott:> Use .25 for 25% thats how the orignal script was made to work its not a 1 out of 4 chance like it was before. All I can say is when I tested I made 4 items 10%,25%,50%,100% and there drop rate was the same as there name and it seemed to work fine to me.Okay, I didnt know that was the format. Ill test it out again. Thanks. Link to comment Share on other sites More sharing options...
Scott Posted September 25, 2011 Author Share Posted September 25, 2011 Np my fault really, I will add that to the first post, if you put 1 in it is a 100% drop and anything over 1 is also 100%. Link to comment Share on other sites More sharing options...
LoneWolf Posted September 28, 2011 Share Posted September 28, 2011 I deleted all my previous npc and started with new onesI have been testing the chance of dropingwhen the NPC is saved it keeps changesnow lets say:Drop 1 Drop 2chance: 2 chance:10item: Gold num:1 item: HP potion num:2value: 10 value:1when the NPC is killed it drops everything everytimeanother minor thing is that when you set the animation for the NPC and hit save, it saves the changes but the next time you open that NPC the animation is set to 0 BUT it does have the animation Link to comment Share on other sites More sharing options...
Guest Posted September 28, 2011 Share Posted September 28, 2011 the animaton error is not related to this tut, and has been covered before i belive.http://www.touchofdeathforums.com/smf/index.php/topic,74391.msg797956.html#msg797956as for the drops. your droping all the time because 2 = 100% 10 = 100%.2 = 20% .02 = 2% .002 = .2% ect. they wont drop every time if you set it right. Link to comment Share on other sites More sharing options...
Murdoc Posted October 5, 2011 Share Posted October 5, 2011 Noticed a small error. If more than one item is dropped, the character picks up the bottom items before the ones on top. I'm not sure if this is a rendering bug or what. Anyone else notice this?Edit: I tested to see if after dropping items from the inventory it did the same thing, and it does. So I dont think its related to this mod.. Link to comment Share on other sites More sharing options...
Catapult Posted October 5, 2011 Share Posted October 5, 2011 Please attach a fresh Eclipse Origins with feature said. Link to comment Share on other sites More sharing options...
Scott Posted October 6, 2011 Author Share Posted October 6, 2011 Do it your self it's easy. Link to comment Share on other sites More sharing options...
PVJsquad Posted October 8, 2011 Share Posted October 8, 2011 Error subscript out of range```NPC(EditorIndex).DropChance(DropIndex) = 0``` Link to comment Share on other sites More sharing options...
Scott Posted October 8, 2011 Author Share Posted October 8, 2011 That means1.Editorindex is not between 1-255or2.Dropindex is not between 1-10 Link to comment Share on other sites More sharing options...
PVJsquad Posted October 25, 2011 Share Posted October 25, 2011 I Cann't Hit the NPC Why ? Link to comment Share on other sites More sharing options...
RyokuHasu Posted October 25, 2011 Share Posted October 25, 2011 @GoldSide:> I Cann't Hit the NPC Why ?you didnt give it all stats at least one, you didn't make it the right type, you didn't give it health… pick one or more Link to comment Share on other sites More sharing options...
xppxdd Posted October 25, 2011 Share Posted October 25, 2011 Its says the Script is out of rangehere's is my frmEDITOR_NPC:```Option ExplicitPrivate DropIndex As BytePrivate Sub cmbBehaviour_Click() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler NPC(EditorIndex).Behaviour = cmbBehaviour.ListIndex ' Error handler Exit Suberrorhandler: HandleError "cmbBehaviour_Click", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub cmdDelete_Click()Dim tmpIndex As Long ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler ClearNPC EditorIndex tmpIndex = lstIndex.ListIndex lstIndex.RemoveItem EditorIndex - 1 lstIndex.AddItem EditorIndex & ": " & NPC(EditorIndex).Name, EditorIndex - 1 lstIndex.ListIndex = tmpIndex NpcEditorInit ' Error handler Exit Suberrorhandler: HandleError "cmdDelete_Click", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub Form_Load() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler DropIndex = scrlDrop.Value scrlDrop.Max = MAX_NPC_DROPS scrlDrop.Min = 1 fraDrop.Caption = "Drop - " & DropIndex scrlSprite.Max = NumCharacters scrlAnimation.Max = MAX_ANIMATIONS 'ALATAR scrlQuest.Max = MAX_QUESTS '/ALATAR ' Error handler Exit Suberrorhandler: HandleError "Form_Load", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub cmdSave_Click() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler Call NpcEditorOk ' Error handler Exit Suberrorhandler: HandleError "cmdSave_Click", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub cmdCancel_Click() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler Call NpcEditorCancel ' Error handler Exit Suberrorhandler: HandleError "cmdCancel_Click", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub lstIndex_Click() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler NpcEditorInit ' Error handler Exit Suberrorhandler: HandleError "lstIndex_Click", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub scrlAnimation_Change()Dim sString As String ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler If scrlAnimation.Value = 0 Then sString = "None" Else sString = Trim$(Animation(scrlAnimation.Value).Name) lblAnimation.Caption = "Anim: " & sString NPC(EditorIndex).Animation = scrlAnimation.Value ' Error handler Exit Suberrorhandler: HandleError "scrlAnimation_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub scrlSprite_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler lblSprite.Caption = "Sprite: " & scrlSprite.Value Call EditorNpc_BltSprite NPC(EditorIndex).Sprite = scrlSprite.Value ' Error handler Exit Suberrorhandler: HandleError "scrlSprite_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub scrlDrop_Change() DropIndex = scrlDrop.Value fraDrop.Caption = "Drop - " & DropIndex txtChance.text = NPC(EditorIndex).DropChance(DropIndex) scrlNum.Value = NPC(EditorIndex).DropItem(DropIndex) scrlValue.Value = NPC(EditorIndex).DropItemValue(DropIndex)End SubPrivate Sub scrlRange_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler lblRange.Caption = "Range: " & scrlRange.Value NPC(EditorIndex).Range = scrlRange.Value ' Error handler Exit Suberrorhandler: HandleError "scrlRange_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub scrlNum_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler lblNum.Caption = "Num: " & scrlNum.Value If scrlNum.Value > 0 Then lblItemName.Caption = "Item: " & Trim$(Item(scrlNum.Value).Name) End If NPC(EditorIndex).DropItem = scrlNum.Value ' Error handler Exit Suberrorhandler: HandleError "scrlNum_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub scrlStat_Change(Index As Integer)Dim prefix As String ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler Select Case Index Case 1 prefix = "Str: " Case 2 prefix = "End: " Case 3 prefix = "Int: " Case 4 prefix = "Agi: " Case 5 prefix = "Will: " End Select lblStat(Index).Caption = prefix & scrlStat(Index).Value NPC(EditorIndex).Stat(Index) = scrlStat(Index).Value ' Error handler Exit Suberrorhandler: HandleError "scrlStat_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub scrlValue_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler lblValue.Caption = "Value: " & scrlValue.Value NPC(EditorIndex).DropItemValue = scrlValue.Value ' Error handler Exit Suberrorhandler: HandleError "scrlValue_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub txtAttackSay_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler NPC(EditorIndex).AttackSay = txtAttackSay.text ' Error handler Exit Suberrorhandler: HandleError "txtAttackSay_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub txtChance_Change() On Error GoTo chanceErr If Not IsNumeric(txtChance.text) And Not Right$(txtChance.text, 1) = "%" And Not InStr(1, txtChance.text, "/") > 0 And Not InStr(1, txtChance.text, ".") Then txtChance.text = "0" NPC(EditorIndex).DropChance(DropIndex) = 0 Exit Sub End If If Right$(txtChance.text, 1) = "%" Then txtChance.text = Left(txtChance.text, Len(txtChance.text) - 1) / 100 ElseIf InStr(1, txtChance.text, "/") > 0 Then Dim i() As String i = Split(txtChance.text, "/") txtChance.text = Int(i(0) / i(1) * 1000) / 1000 End If If txtChance.text > 1 Or txtChance.text < 0 Then 'Err.Description = "Value must be between 0 and 1!" 'GoTo chanceErr End If NPC(EditorIndex).DropChance(DropIndex) = txtChance.text Exit SubchanceErr: MsgBox "Invalid entry for chance! " & Err.Description txtChance.text = "0" NPC(EditorIndex).DropChance(DropIndex) = 0End SubPrivate Sub txtDamage_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler If Not Len(txtDamage.text) > 0 Then Exit Sub If IsNumeric(txtDamage.text) Then NPC(EditorIndex).Damage = Val(txtDamage.text) ' Error handler Exit Suberrorhandler: HandleError "txtDamage_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub txtEXP_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler If Not Len(txtEXP.text) > 0 Then Exit Sub If IsNumeric(txtEXP.text) Then NPC(EditorIndex).EXP = Val(txtEXP.text) ' Error handler Exit Suberrorhandler: HandleError "txtEXP_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub txtHP_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler If Not Len(txtHP.text) > 0 Then Exit Sub If IsNumeric(txtHP.text) Then NPC(EditorIndex).HP = Val(txtHP.text) ' Error handler Exit Suberrorhandler: HandleError "txtHP_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub txtLevel_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler If Not Len(txtLevel.text) > 0 Then Exit Sub If IsNumeric(txtLevel.text) Then NPC(EditorIndex).Level = Val(txtLevel.text) ' Error handler Exit Suberrorhandler: HandleError "txtlevel_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub txtName_Validate(Cancel As Boolean)Dim tmpIndex As Long ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler If EditorIndex = 0 Then Exit Sub tmpIndex = lstIndex.ListIndex NPC(EditorIndex).Name = Trim$(txtName.text) lstIndex.RemoveItem EditorIndex - 1 lstIndex.AddItem EditorIndex & ": " & NPC(EditorIndex).Name, EditorIndex - 1 lstIndex.ListIndex = tmpIndex ' Error handler Exit Suberrorhandler: HandleError "txtName_Validate", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub txtSpawnSecs_Change() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler If Not Len(txtSpawnSecs.text) > 0 Then Exit Sub NPC(EditorIndex).SpawnSecs = Val(txtSpawnSecs.text) ' Error handler Exit Suberrorhandler: HandleError "txtSpawnSecs_Change", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd SubPrivate Sub cmbSound_Click() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler If cmbSound.ListIndex >= 0 Then NPC(EditorIndex).Sound = cmbSound.List(cmbSound.ListIndex) Else NPC(EditorIndex).Sound = "None." End If ' Error handler Exit Suberrorhandler: HandleError "cmdSound_Click", "frmEditor_NPC", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd Sub'ALATARPrivate Sub scrlQuest_Change() lblQuest = "Quest Num: " & scrlQuest.Value NPC(EditorIndex).QuestNum = scrlQuest.ValueEnd Sub'/ALATAR``` Link to comment Share on other sites More sharing options...
Justn Posted October 26, 2011 Share Posted October 26, 2011 did you delete your npcs .dat files out of your "server/data/npcs/" folder? Link to comment Share on other sites More sharing options...
Scott Posted October 26, 2011 Author Share Posted October 26, 2011 @Goldside- Because you didn't delete your npc files like the tutorial said or you messed something up, the tutorial works fine.@xppxdd- Give us the line it points to… Link to comment Share on other sites More sharing options...
Taegan Posted October 26, 2011 Share Posted October 26, 2011 Any chance we can just remove the NPCs and then add them back to the folder? o.o Probably not, but asking doesn't hurt. Link to comment Share on other sites More sharing options...
Displaced Posted October 26, 2011 Share Posted October 26, 2011 Jup just write a converter. Link to comment Share on other sites More sharing options...
xppxdd Posted October 26, 2011 Share Posted October 26, 2011 whats wong with this lines:Private Sub scrlDrop_Change() DropIndex = scrlDrop.Value fraDrop.Caption = "Drop - " & DropIndex txtChance.text = NPC(EditorIndex).DropChance(DropIndex) scrlNum.Value = NPC(EditorIndex).DropItem(DropIndex) scrlValue.Value = NPC(EditorIndex).DropItemValue(DropIndex)End Subim getting an subscript out of range on the fourth(4) line… Link to comment Share on other sites More sharing options...
Justn Posted October 26, 2011 Share Posted October 26, 2011 did you delete your npcs??? Link to comment Share on other sites More sharing options...
PVJsquad Posted October 26, 2011 Share Posted October 26, 2011 means delete all the NPCs that have been made? Link to comment Share on other sites More sharing options...
Taegan Posted October 26, 2011 Share Posted October 26, 2011 I had to fix the form to include the quest scroll bar from Alatar's system but it works perfectly. Good job, thanks. 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