Matt Posted April 18, 2012 Share Posted April 18, 2012 I'm having trouble now. I added an item "Legs". All went well, but at the end. I compile and i get an error in this bar of code.>! Private Function IsEqItem(ByVal x As Single, ByVal y As Single) As Long Dim tempRec As RECT Dim i As Long ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler>! IsEqItem = 0>! For i = 1 To Equipment.Equipment_Count - 1>! If GetPlayerEquipment(MyIndex, i) > 0 And GetPlayerEquipment(MyIndex, i) <= MAX_ITEMS Then>! With tempRec .top = EqTop + ((**EqOffsetY** + 32) * ((i - 1) \ EqColumns)) .Bottom = .top + PIC_Y .Left = EqLeft + ((EqOffsetX + 32) * (((i - 1) Mod EqColumns))) .Right = .Left + PIC_X End With It worked before with the whole tutorial, but now it doesnt with the one extra item. Is there something i missed or screwed up? Link to comment Share on other sites More sharing options...
Justn Posted April 18, 2012 Author Share Posted April 18, 2012 You put this code in sub IsEqitem instead of Sub BltEquipment@Sigridunset:> With tempRec> .top = EqTop + ((EqOffsetY + 32) * ((i - 1) \ EqColumns))> .Bottom = .top + PIC_Y> .Left = EqLeft + ((EqOffsetX + 32) * (((i - 1) Mod EqColumns)))> .Right = .Left + PIC_X> End With Link to comment Share on other sites More sharing options...
Matt Posted April 19, 2012 Share Posted April 19, 2012 >! Private Function **IsEqItem**(ByVal x As Single, ByVal y As Single) As Long Dim tempRec As RECT Dim i As Long ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler>! IsEqItem = 0>! For i = 1 To Equipment.Equipment_Count - 1>! If GetPlayerEquipment(MyIndex, i) > 0 And GetPlayerEquipment(MyIndex, i) <= MAX_ITEMS Then>! With tempRec .top = EqTop + ((**EqOffsetY** + 32) * ((i - 1) \ EqColumns)) .Bottom = .top + PIC_Y .Left = EqLeft + ((EqOffsetX + 32) * (((i - 1) Mod EqColumns))) .Right = .Left + PIC_X End WithI know. I checked for that before i replied. Link to comment Share on other sites More sharing options...
Matt Posted April 19, 2012 Share Posted April 19, 2012 If i give you the code, could you add in the extra slot? Link to comment Share on other sites More sharing options...
Justn Posted April 19, 2012 Author Share Posted April 19, 2012 Yea pm me ur project Link to comment Share on other sites More sharing options...
TheRexion Posted April 20, 2012 Share Posted April 20, 2012 I was wondering, I tried to reverse-engineer this, I want only one equipment slot, but I haven't had much success. Do you know what I would have to do? Link to comment Share on other sites More sharing options...
Justn Posted April 20, 2012 Author Share Posted April 20, 2012 Yes if u just want to add one slot then skip the step for moddirectdraw7 and skip the last step in frmmain.Also in the "char constants" part change eqcolumns to 5 then play around the other numbers there to get the spacing correct ill make a note in the tutorial Link to comment Share on other sites More sharing options...
TheRexion Posted April 20, 2012 Share Posted April 20, 2012 Nonono, I don't want to _add_ one equipment slot. I only want one _total_. Do you know what I could do to achieve this? The ways I've tried haven't worked. Link to comment Share on other sites More sharing options...
Justn Posted April 20, 2012 Author Share Posted April 20, 2012 Oh I get it now lol.. umm what kind.of equipment is it? Weapon.shield? Link to comment Share on other sites More sharing options...
TheRexion Posted April 25, 2012 Share Posted April 25, 2012 I only wish to keep the Armor slot. Link to comment Share on other sites More sharing options...
Justn Posted April 26, 2012 Author Share Posted April 26, 2012 Hmm I have no idea how to do this off the top of my head I guess it would just require removing the other items from use item sub and changing the get protection stuff to only use armor and not helmets and removing/changing anything to do with weapons and shields.. ill smoke a blunt and try it on a default EO and see if I can do it.. ill let u know what I come up with Link to comment Share on other sites More sharing options...
ComingStorm Posted May 17, 2012 Share Posted May 17, 2012 Function GetPlayerEquipmentGetPlayerEquipment = Player(Index).Equipment(EquipmentSlot) <<<<Runtime Eror #9Help me plz Link to comment Share on other sites More sharing options...
onzinho Posted June 5, 2012 Share Posted June 5, 2012 @ComingStorm:> Function GetPlayerEquipment> > GetPlayerEquipment = Player(Index).Equipment(EquipmentSlot) <<<<> > Runtime Eror #9> > Help me plzI'm having the same problem.If anyone knows fix would greatly appreciate it. Link to comment Share on other sites More sharing options...
Justn Posted June 5, 2012 Author Share Posted June 5, 2012 Did u guys delete ur old accounts first? Link to comment Share on other sites More sharing options...
onzinho Posted June 5, 2012 Share Posted June 5, 2012 @Justn:> Did u guys delete ur old accounts first?Yes,–----------After many modifications the problem was solved.Now my item does not show the Frame "Equipment Data", if anyone knows where I should modify to tell it appears the "Equipment Data".Thanks in advance. Link to comment Share on other sites More sharing options...
Justn Posted June 5, 2012 Author Share Posted June 5, 2012 That is something u have done ur self I have added this tutorial many times with not a single issue.. if u want u can send me ur source before u added it and I will do it for you… Link to comment Share on other sites More sharing options...
onzinho Posted June 5, 2012 Share Posted June 5, 2012 @Justn:> That is something u have done ur self I have added this tutorial many times with not a single issue.. if u want u can send me ur source before u added it and I will do it for you…Adding according to the tutorial, only difference and put only one item. (Wing)–-----------As reverse the item in "Item Constants" appears "Spell, Consume ...." nothing of "Equipment Data". Link to comment Share on other sites More sharing options...
Justn Posted June 5, 2012 Author Share Posted June 5, 2012 im sorry im having trouble understanding the problem maybe can you explain whats going on or send me a message.. Also if you are adding just one slot you don't need to add the dd7 stuff or the edit for frmmain. Link to comment Share on other sites More sharing options...
onzinho Posted June 5, 2012 Share Posted June 5, 2012 @Justn:> im sorry im having trouble understanding the problem maybe can you explain whats going on or send me a message.. Also if you are adding just one slot you don't need to add the dd7 stuff or the edit for frmmain.I added everything correctly, but it happens, the menu "Equipmente Date" where I would add the bonus to the new item does not appear.Armor: ![](http://img402.imageshack.us/img402/7674/armora.jpg)Wing: ![](http://img252.imageshack.us/img252/1651/winge.jpg) Link to comment Share on other sites More sharing options...
Justn Posted June 5, 2012 Author Share Posted June 5, 2012 welll the easiest thing would be for you to make sure that you put "wing" above shield in the item type list Link to comment Share on other sites More sharing options...
onzinho Posted June 6, 2012 Share Posted June 6, 2012 @Justn:> welll the easiest thing would be for you to make sure that you put "wing" above shield in the item type listMy modConstants' Item constantsPublic Const ITEM_TYPE_NONE As Byte = 0Public Const ITEM_TYPE_WEAPON As Byte = 1Public Const ITEM_TYPE_ARMOR As Byte = 2Public Const ITEM_TYPE_HELMET As Byte = 3Public Const ITEM_TYPE_WING As Byte = 4Public Const ITEM_TYPE_BRAZAO As Byte = 5Public Const ITEM_TYPE_RING As Byte = 6Public Const ITEM_TYPE_BRACELET As Byte = 7Public Const ITEM_TYPE_ENCHANT As Byte = 8Public Const ITEM_TYPE_SHIELD As Byte = 9Public Const ITEM_TYPE_CONSUME As Byte = 10Public Const ITEM_TYPE_KEY As Byte = 11Public Const ITEM_TYPE_CURRENCY As Byte = 12Public Const ITEM_TYPE_SPELL As Byte = 13Added other items to test, they were all out of order panel.NONE… WING.. Key - Current = Equipment DataBrazao = ConsumeRing - Bracelet = went blankCurrency = Equipmanet DataEnchant = Spell Link to comment Share on other sites More sharing options...
Justn Posted June 6, 2012 Author Share Posted June 6, 2012 Oh I mean in the item editor also the cmbtype list make sure shield is below ur new items![](http://www.freemmorpgmaker.com/files/imagehost/pics/77b72c87563550acfc48d94534b22f0e.bmp)Cause if u click on the cmbtype u will see that frame equipment data is set to be visible if the item is a weapon and everything until u get after the shield so anything after shield in the list won't display the frame Link to comment Share on other sites More sharing options...
onzinho Posted June 6, 2012 Share Posted June 6, 2012 @Justn:> Oh I mean in the item editor also the cmbtype list make sure shield is below ur new items> > ![](http://www.freemmorpgmaker.com/files/imagehost/pics/77b72c87563550acfc48d94534b22f0e.bmp)> > Cause if u click on the cmbtype u will see that frame equipment data is set to be visible if the item is a weapon and everything until u get after the shield so anything after shield in the list won't display the frameThank you for your attention, my cmdType two item was wrong.My lack of attention here :) , more, thank you al for your help. Link to comment Share on other sites More sharing options...
Justn Posted June 6, 2012 Author Share Posted June 6, 2012 np bro glad you got it working sorry took so long just couldn't figure out what you were talking about =p Link to comment Share on other sites More sharing options...
TheRexion Posted June 9, 2012 Share Posted June 9, 2012 Were you ever able to come up with a solution? I tried, but was unable to do anything without running into a mountainload of problems. 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