On Thu, 22 May 2008 17:14:42 +0000 (UTC), kenji776 wrote:
> Thank you both for your replied, I did manage to find a
solution (the same one
> posted by JR "Bob" Dobbs). Pretty much just looks
like...
>
>
> <cfloop from="1" to="3" index="i">
> <cfset LinkResults["#i#"][1] = "Player 1's Move
ID">
> <cfset LinkResults["#i#"][2] = "Player 2's Move
ID">
> <cfset LinkResults["#i#"][3] = "Damage to player
1">
> <cfset LinkResults["#i#"][4] = "Damage to player
2">
> </cfloop>
From your values, you don't want a two-dimensional array
(which although
you're actually building LinkResults as a struct, with the
sequential
numeric keys, it's basically an array), you want an array of
structs, eg:
LinkResults
.player1.moveId
LinkResults.player1.damage
What is "i" actually counting through? IE: from 1-3 things...
which are...
what?
--
Adam