bwins95 Posted January 15, 2014 Share Posted January 15, 2014 How do you ref walk a formlist? what I want to do is find all the caps in a cell and apply a shader to them. I already know how to apply shaders. Link to comment Share on other sites More sharing options...
jazzisparis Posted January 16, 2014 Share Posted January 16, 2014 Why would you need a Form List for?Insert the below segment in the script you are using. Don't run it every frame. Use a timer, or some conditions as a way to trigger it. ref rObject set rObject to GetFirstRef 31 2 0 Label 1 if IsFormValid rObject if rObject.GetIsID Caps001 rObject.PMS CapsShader endif set rObject to TeddyBear01 set rObject to GetNextRef GoTo 1 endif Link to comment Share on other sites More sharing options...
bwins95 Posted January 16, 2014 Author Share Posted January 16, 2014 Why would you need a Form List for? Insert the below segment in the script you are using. Don't run it every frame. Use a timer, or some conditions as a way to trigger it. ref rObject set rObject to GetFirstRef 31 2 0 Label 1 if IsFormValid rObject if rObject.GetIsID Caps001 rObject.PMS CapsShader endif set rObject to TeddyBear01 set rObject to GetNextRef GoTo 1 endif I was looking at this and thought that their might be a way to use formlist for single items. Unfortunately it doesn't seem to work.the if rCurrentRef.GetIsID Caps001 line seems to be the problem. This is caps part of the script. it is applied with OnEquip on a pair of glasses. set rCurrentRef to GetFirstRef 31 2 0 Label 11 if IsFormValid rCurrentRef if rCurrentRef.GetIsID Caps001 if aaaaGlowingItemsscaps == 1 if aaaaGlowingItemsscapsGreen== 1 rCurrentRef.PlayMagicShaderVisuals aaaaGlowingItemsShaderGreen elseif aaaaGlowingItemsscapsRed == 1 rCurrentRef.PlayMagicShaderVisuals aaaaGlowingItemsShaderRed elseif aaaaGlowingItemsscapsBlue == 1 rCurrentRef.PlayMagicShaderVisuals aaaaGlowingItemsShaderBlue elseif aaaaGlowingItemsscapsWhite == 1 rCurrentRef.PlayMagicShaderVisuals aaaaGlowingItemsShaderWhite elseif aaaaGlowingItemsscapsYellow == 1 rCurrentRef.PlayMagicShaderVisuals aaaaGlowingItemsShaderYellow elseif aaaaGlowingItemsscapsPink == 1 rCurrentRef.PlayMagicShaderVisuals aaaaGlowingItemsShaderPink elseif aaaaGlowingItemsscapsPurple == 1 rCurrentRef.PlayMagicShaderVisuals aaaaGlowingItemsShaderPurple elseif aaaaGlowingItemsscaps == 0 endif set rCurrentRef to TeddyBear01 set rCurrentRef to GetNextRef GoTo 11 endif endif endif Link to comment Share on other sites More sharing options...
rickerhk Posted January 18, 2014 Share Posted January 18, 2014 I don't see why it shouldn't work. You are doing the refwalk in a gamemode block, right? Not in the On equip block. A formlist would work like this: if rCurrentRef.IsInList MyFormList Link to comment Share on other sites More sharing options...
bwins95 Posted January 18, 2014 Author Share Posted January 18, 2014 (edited) I don't see why it shouldn't work. You are doing the refwalk in a gamemode block, right? Not in the On equip block. A formlist would work like this: if rCurrentRef.IsInList MyFormList I've attached my full script. the ref walking happens in the begin onequip player block. I did it this way because it was the first thing that worked. Edited January 18, 2014 by bwins95 Link to comment Share on other sites More sharing options...
Recommended Posts