28-09-2008, 11:43 PM
I didn't know if I should combine the topic I posted about earlier, but at any rate here goes.
I'm updating my spells list, so when you click on a spell, you get the corresponding icon you saved with it. I can do the calling of the icon, but its the saving of the icon data that gets me.
So: Here's the code so far.
a new picture box called picIconSP
in modTypes (Client & server)
Now I updated the TCP of both Client and Server to this (Edit is at the end):
However... Nothing. I defined everything (I think) but It's not showing me the icon...)
I'm updating my spells list, so when you click on a spell, you get the corresponding icon you saved with it. I can do the calling of the icon, but its the saving of the icon data that gets me.
So: Here's the code so far.
a new picture box called picIconSP
in modTypes (Client & server)
Quote:SpellIcon As Longafter
Quote:SpellDone As Long.
Now I updated the TCP of both Client and Server to this (Edit is at the end):
Quote:Sub SendSaveSpell(ByVal SpellNum As Long)
Call SendData("savespell" & SEP_CHAR & SpellNum & SEP_CHAR & Trim$(Spell(SpellNum).Name) & SEP_CHAR & Spell(SpellNum).ClassReq & SEP_CHAR & Spell(SpellNum).LevelReq & SEP_CHAR & Spell(SpellNum).Type & SEP_CHAR & Spell(SpellNum).Data1 & SEP_CHAR & Spell(SpellNum).Data2 & SEP_CHAR & Spell(SpellNum).Data3 & SEP_CHAR & Spell(SpellNum).MPCost & SEP_CHAR & Trim$(Spell(SpellNum).Sound) & SEP_CHAR & Spell(SpellNum).Range & SEP_CHAR & Spell(SpellNum).SpellAnim & SEP_CHAR & Spell(SpellNum).SpellTime & SEP_CHAR & Spell(SpellNum).SpellDone & SEP_CHAR & Spell(SpellNum).AE & SEP_CHAR & Spell(SpellNum).Big & SEP_CHAR & Spell(SpellNum).SpellIcon & SEP_CHAR & Spell(SpellNum).Element & END_CHAR)
End Sub
afterQuote:SpellDone As Long.
I added this into frmSpellEditor:
This goes in Client's Handledata:
Quote:Spell(n).SpellIcon = Val(parse(18))This is in the server's Handledata:
Quote:Spell(Spellnum).SpellIcon = Val(SpellData(18))This is in modGameEditor:
Quote:frmSpellEditor.Hscroll1.value = Spell.SpellIconIn frmMirage:
Quote:picIconSP.picture = Spell(SpellNum)SpellIcon
However... Nothing. I defined everything (I think) but It's not showing me the icon...)