Sign in to follow this  
Followers 0
Rad

The magic "8" number!

2 posts in this topic

If $msg = $dmg_optionreset Then
        $type_normal= StringSplit("1.00,1.00,1.00,1.50,1.00,0.70,1.00,0.05",",") ;Normal
        $type_pierce= StringSplit("1.00,1.50,2.00,0.75,2.00,0.35,0.50,0.05",",") ;Pierce
        $type_magic= StringSplit("1.00,1.00,1.25,0.75,2.00,0.35,0.50,0.05",",") ;Magic
        $type_siege= StringSplit("1.00,1.50,1.00,0.50,1.00,1.50,0.50,0.05",",") ;Siege
        $type_hero= StringSplit("1.00,1.00,1.00,1.00,1.00,0.50,1.00,0.05",",")  ;Hero
        $type_chaos= StringSplit("1.00,1.00,1.00,1.00,1.00,1.00,1.00,1.00",",") ;Chaos
        $int_z=0
        While $int_z < 7
            GUICtrlSetData($cstm_input[$int_z][0],$type_normal[$int_z])
            GUICtrlSetData($cstm_input[$int_z][1],$type_pierce[$int_z])
            GUICtrlSetData($cstm_input[$int_z][2],$type_magic[$int_z])
            GUICtrlSetData($cstm_input[$int_z][3],$type_siege[$int_z])
            GUICtrlSetData($cstm_input[$int_z][4],$type_hero[$int_z])
            GUICtrlSetData($cstm_input[$int_z][5],$type_chaos[$int_z])
            $int_z=$int_z+1
        Wend
    Endif

For some reason $cstm_input is giving me an 8 for 2d array 0~5, the rest work great, but what the heck?

Share this post


Link to post
Share on other sites



$type_normal= StringSplit("1.00,1.00,1.00,1.50,1.00,0.70,1.00,0.05",",");Normal

StringSplit() returns a nine-element array where the very first element ($type_normal[0]) gives the number of following elements (8). Try changing this:

$int_z=0
While $int_z < 7
    GUICtrlSetData($cstm_input[$int_z][0],$type_normal[$int_z])
    GUICtrlSetData($cstm_input[$int_z][1],$type_pierce[$int_z])
    GUICtrlSetData($cstm_input[$int_z][2],$type_magic[$int_z])
    GUICtrlSetData($cstm_input[$int_z][3],$type_siege[$int_z])
    GUICtrlSetData($cstm_input[$int_z][4],$type_hero[$int_z])
    GUICtrlSetData($cstm_input[$int_z][5],$type_chaos[$int_z])
    $int_z=$int_z+1
Wend

to this:

For $I = 1 To 8
    GUICtrlSetData($cstm_input[$I][0], $type_normal[$I])
    GUICtrlSetData($cstm_input[$I][1], $type_pierce[$I])
    GUICtrlSetData($cstm_input[$I][2], $type_magic[$I])
    GUICtrlSetData($cstm_input[$I][3], $type_siege[$I])
    GUICtrlSetData($cstm_input[$I][4], $type_hero[$I])
    GUICtrlSetData($cstm_input[$I][5], $type_chaos[$I])
Next

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0