Gribbleshnibit8 Posted November 7, 2014 Share Posted November 7, 2014 Check out Lutana Renamer Rifle for how to make use of the player name menu. To answer you question, which Fallout2AM sort of answered, No. You cannot call a gamemode block from a function. If you really wanted to have most of the menu in a function, you could do what they said and put the logic in a function, call the message and wait for input from the GameMode script, then pass the button value into the function to do work. The Sleep/Wait slider menu has a lot of backend game code that manages it, and I've looked at how MCM implements its slider because I was interested in using something like that in a mod I've been working on, and it turns out it was easier to build a calculator type interface than replicate sliders (MCM has over 1000 lines of xml just for the slider, which is more than any other single menu in that mod). The solution I have used in the past, when wanting the player to input a value different than fixed amounts is to show the menu multiple times, with options for +/-1,5,10,25. The other two buttons on the menu are a Cancel and Accept button, and you just reshow the menu until Cancel or Accept are pressed. I used this in my Vending Machines of the Wastes mod for the ammo machine, if you wanna go give that a look. Link to comment Share on other sites More sharing options...
Fallout2AM Posted November 8, 2014 Share Posted November 8, 2014 (edited) Can I call a gamemode block from a function you could startquest <somequest> inside the UDF, where <somequest> has a Gamemode script attached Edited November 8, 2014 by Fallout2AM Link to comment Share on other sites More sharing options...
Gribbleshnibit8 Posted November 10, 2014 Share Posted November 10, 2014 That's getting to the point of going super hacky, if that even works. At that point I would say rethink what you're trying to do and if you really even need the UDF in the first place. Unless you're reusing the same menu in many places, you probably don't need it, and if you do need menu code often, if it's all pretty much the same, consider something like this solution instead. Link to comment Share on other sites More sharing options...
Recommended Posts