Loading...
  OR  Zero-K Name:    Password:   

Post edit history

learning to code

To display differences between versions, select one or more edits in the list using checkboxes and click "diff selected"
Post edit history
Date Editor Before After
2/19/2024 8:48:18 AMAUrankSmokeDragon before revert after revert
2/16/2024 8:33:48 AMAUrankSmokeDragon before revert after revert
Before After
1 can someone please post an example of a for in pairs loop that edits customParamiters in unit defs... i have spent weeks reading lua tutorials and searching in the games code for examples and i have tried hundreds of things. 1 can someone please post an example of a for in pairs loop that edits customParamiters in unit defs... i have spent weeks reading lua tutorials and searching in the games code for examples and i have tried hundreds of things.
2 \n 2 \n
3 and if you will not help me then delete my account so i can never return 3 and if you will not help me then delete my account so i can never return
4 \n 4 \n
5 or dammit atleast tell me why i suck so bad at code... and i expect a few down votes while im at it.. 5 or dammit atleast tell me why i suck so bad at code... and i expect a few down votes while im at it..
6 \n 6 \n
7 i want so bad to mod this game but i spend more time trying to figure out how then actually getting the mods done 7 i want so bad to mod this game but i spend more time trying to figure out how then actually getting the mods done
8 \n 8 \n
9 for name, ud in pairs(UnitDefs) do 9 for name, ud in pairs(UnitDefs) do
10 if ud.customParams then 10 if ud.customParams then
11 for wd in pairs(ud.customParams) do 11 for wd in pairs(ud.customParams) do
12 if wd.pylonrange then 12 if wd.pylonrange then
13 wd.pylonrange = wd.pylonrange * 4 13 wd.pylonrange = wd.pylonrange * 4
14 end 14 end
15 end 15 end
16 end 16 end
17 end 17 end
18 \n 18 \n
19 .... im really on the edge man.. i think maybe i might take up drinking 19 .... im really on the edge man.. i think maybe i might take up drinking