achillesdave Posted August 3, 2011 Share Posted August 3, 2011 (edited) I have made a test script for a magazine sorter for my mod that will place the issue on the shelf when activated. Ive got it to work by making one issue a reference and initially disabled but it only works one time. The next time I try to put the same issue in again it does not show up on the shelf. What I want to do is make the reference repeatable. Could you look at my script and offer some advice? scn AFMDisplayScript begin OnActivateif IsActionRef player == 1 if (player.GetItemCount actionformen245 == 1) AFM245.Enable Player.RemoveItem actionformen245 1 endifelse ShowMessage NoMagazinesendifendifend Edited August 3, 2011 by achillesdave Link to comment Share on other sites More sharing options...
Glenstorm Posted August 4, 2011 Share Posted August 4, 2011 I have made a test script for a magazine sorter for my mod that will place the issue on the shelf when activated. Ive got it to work by making one issue a reference and initially disabled but it only works one time. The next time I try to put the same issue in again it does not show up on the shelf. What I want to do is make the reference repeatable. Could you look at my script and offer some advice? scn AFMDisplayScript begin OnActivateif IsActionRef player == 1 if (player.GetItemCount actionformen245 == 1) AFM245.Enable Player.RemoveItem actionformen245 1 endifelse ShowMessage NoMagazinesendifendifend I'm not sure if this is your question, but are you asking for a second copy of AFM to be placed alongside the first one if the player has got two? What is AFM245? I know its a reference but where is it located? Is it on the shelf? How many similar references are there on the shelf? Link to comment Share on other sites More sharing options...
rickerhk Posted August 4, 2011 Share Posted August 4, 2011 Instead of placing a disabled magazine, try placing an X marker on the shelf, with the REF AFM245 scn AFMDisplayScript begin OnActivate if IsActionRef player == 1 if (player.GetItemCount actionformen245 == 1) AFM245.PlaceAtMe actionformen245 1 Player.RemoveItem actionformen245 1 else ShowMessage NoMagazines endif endif end Edit - or actually just leave the magazine on the shelf disabled, as it already has the REF ID. The script I posted would be the same, and would guarantee that the placeAtme magazine will have the same orientation as the disabled original. Link to comment Share on other sites More sharing options...
Recommended Posts