v50 Steam/Premium information for editors
  • v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
  • Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.

Difference between revisions of "User:Sphr/test/test3"

From Dwarf Fortress Wiki
Jump to navigation Jump to search
m
Line 32: Line 32:
 
notes:
 
notes:
  
have to use subst.  how to do it inline?   
+
have to use subst.  how to do it by reference?   
  
 
Possibly order of evaluation is outside in, which prob results in <nowiki>{{subst:User:Sphr/test/test4}}</nowiki> not being evaluated first.
 
Possibly order of evaluation is outside in, which prob results in <nowiki>{{subst:User:Sphr/test/test4}}</nowiki> not being evaluated first.
  
 
:I think you're correct about evaluation order. I think this could be solved by making the [[User:Sphr/f/array2_elem]] function recieve a reference instead of trying to pass the entire array. [[User:VengefulDonut|VengefulDonut]] 13:15, 8 January 2008 (EST)
 
:I think you're correct about evaluation order. I think this could be solved by making the [[User:Sphr/f/array2_elem]] function recieve a reference instead of trying to pass the entire array. [[User:VengefulDonut|VengefulDonut]] 13:15, 8 January 2008 (EST)

Revision as of 21:07, 8 January 2008

array test:

3x3 array (row|col|data) : 3|3|a|b|c|d|e|f|g|h|i

element(0,0): 0

element(0,1): 1

element(0,2): 3

element(1,0): 3

element(1,1): a

element(1,2): b

element(2,0): c

element(2,1): d

element(2,2): e


{{:User:Sphr/test/test4}}

{{{ {{ :User:Sphr/f/inc_ {{ :User:Sphr/f/inc_ {{{1}}} }} }} }}}

element(0,0): {{:User:Sphr/f/array2_elem|0|0|{{subst:User:Sphr/test/test4}}}}

element(0,0): 0

notes:

have to use subst. how to do it by reference?

Possibly order of evaluation is outside in, which prob results in {{subst:User:Sphr/test/test4}} not being evaluated first.

I think you're correct about evaluation order. I think this could be solved by making the User:Sphr/f/array2_elem function recieve a reference instead of trying to pass the entire array. VengefulDonut 13:15, 8 January 2008 (EST)