-
August 29th, 2013, 03:23 AM
#1
Need Help with this code
last week i found this code from online game DB
0x551d000c500001c80002c8
551d = thats mean weapon enchanted level 29
0c50 = crit rate 80%
01c8 = str+200
and thats red 00 = (space)
my question.. how to make that code with VB?
i already tried for 4days, but nothing..
anybody can help me?
thanks
Regards
-
August 29th, 2013, 08:20 AM
#2
Re: Need Help with this code
I think that is Hexadecimal code ( if I'm not mistaken ). Do a search on the forums for Hex - there is a lot of info
-
August 29th, 2013, 10:59 AM
#3
Re: Need Help with this code
Not nearly enough info in the OP to even guess what he is actually trying to do. My guess would be that value is stored somewhere with a save game file or other data file and he wants to replace the data that is there with something like this.
Without more detailed info not much anyone could do to help other than suggest a search.
Need better description of what you are trying to do,
Need to know what you tried and what problem you were having
would help to have some idea of you programming knowledge
Always use [code][/code] tags when posting code.
-
August 29th, 2013, 12:36 PM
#4
Re: Need Help with this code
-
September 21st, 2013, 11:39 PM
#5
Re: Need Help with this code
try this
Code:
Option Explicit
' Created by Asymetrix 2013
' requires Multiline Text box , TXTOutput on form1
Private Type stat
Weapon As String
Code As String
Value As Integer
End Type
Private WeaponStat() As stat
Private WeaponLine As String
Private Sub Form_Load()
ReDim WeaponStat(0)
' set weapon name with its own hex code - name, item code (hex), item value in decimal
' AddWeaponStat is used to add new weapons to the array
'0x 551d 00 0c50 00 01c8 00 02c8
' [
'0x [Enchantedhexcode]1d 00 [critratehexcode]50 00 [strhexcode]c8 00 [newweaponhexcode]c8
'OR
'0x [Enchantedhexcode]1d 00 [critratehexcode]50 00 [strhexcode]c8 00 [EndOfLinehexcode]
' ]
' further breakdown ..
' [
'0x [Enchantedhexcode][29inhex] 00 [critratehexcode][80inhex] 00 [strhexcode][200inhex] 00 [newweaponhexcode][200inhex]
'OR
'0x [Enchantedhexcode][29inhex] 00 [critratehexcode][80inhex] 00 [strhexcode][200inhex] 00 [EndOfLinehexcode]
' ]
AddWeaponStat "Enchanted", "55", 29
AddWeaponStat "crit rate", "0c", 80
AddWeaponStat "str", "01", 200
AddWeaponStat "newweapon", "02", 200 ' or add EndOfLine marker AddWeaponStat "EOW", "02", 200
' add these weapons to the output string
AddWeaponLine "Enchanted"
AddWeaponLine "crit rate"
AddWeaponLine "str"
AddWeaponLine "newweapon" ' or EndOfLine marker AddWeaponLine "EOW"
TXTOutput.Text = WeaponLine
End Sub
Private Sub AddWeaponStat(ByVal WeaponName As String, ByVal WeaponCode As String, ByVal WeaponValueDec As Integer)
' set dynamic arrays to hold weapon data
WeaponStat(UBound(WeaponStat)).Weapon = WeaponName
WeaponStat(UBound(WeaponStat)).Code = WeaponCode
WeaponStat(UBound(WeaponStat)).Value = WeaponValueDec
ReDim Preserve WeaponStat(UBound(WeaponStat) + 1)
End Sub
Private Function ShowWeaponHex(WeaponName As String) As String
' Find Weapon Name and return hex code
Dim i As Integer
ShowWeaponHex = ""
For i = 0 To UBound(WeaponStat) - 1
' match weapon name
If WeaponName = WeaponStat(i).Weapon Then
ShowWeaponHex = WeaponStat(i).Code & Hex(WeaponStat(i).Value)
' lowercase
ShowWeaponHex = LCase(ShowWeaponHex)
Exit For
End If
Next i
End Function
Private Sub AddWeaponLine(WeaponName As String)
' add selected weapon to the output list
If WeaponLine = "" Then
WeaponLine = "0x" & ShowWeaponHex(WeaponName)
Else
WeaponLine = WeaponLine & "00" & ShowWeaponHex(WeaponName)
End If
End Sub
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|