Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Another RTE9 Problem
#1
OK. I am trying to add an item feature that stores its value (the worth of the item to the markets). But, when I open the itemeditor and try to edit an item it says RTE 9: Subscript Out of Range, and it highlights "Item(n).Value = Val(Parse(9))"

I traced the variable, it was declared.
I scrolled over it and the tool-tip box popped up saying that "Item(n).Value = 0"

The value variable itself is a long. I made sure that the server and client had the same packet information for that variable.

Any help?
Reply
#2
This is the code before it, and it executes properly, so I know the item exists:
Code:
Item(n).Name = Parse(2)
        Item(n).Pic = Val(Parse(3))
        Item(n).Type = Val(Parse(4))
        Item(n).Data1 = Val(Parse(5))
        Item(n).Data2 = Val(Parse(6))
        Item(n).Data3 = Val(Parse(7))
        Item(n).Weight = Val(Parse(8))
        Item(n).Value = Val(Parse(9))

And I checked the packets sent between the client and server and they include the value attribute at the 9th section.
Reply
#3
The value of Parse(9) is the item.value, which, since I have no items, is zero.

When I started this project, I cleared all items, npcs, and shops.
Reply
#4
No, when I'm opening the itemeditor, there are no files, so it should load everything at zero.
Reply
#5
Make sure your server is loading and saving the items properly is what Dave was getting at I think.

I would try following everything from your client to server to client to server and so on and so forth. Find /edititem and follow the packets back and forth till you find an error in the parsing or something.
Reply
#6
Already checked all that, but I'll check it again I guess. Might have missed something...

[Edit] Everything is fixed, I lost a SEP_CHAR in my packet that loads the Item. My items work fine now! Thanks for the help.
Reply
#7
I thought it existed, but, since I'm an idiot, I didn't see the missing SEP_CHAR.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)