lcarens Posted April 26, 2014 Author Share Posted April 26, 2014 Good evening,I am looking for a way to prevent the player from moving while an event is in process. I considered adding a check for InEvent to the movement sub, but I would prefer to be able to toggle the movement abilities manually. How would I go about doing so?I assume I could add a switch of some type and toggle it with the Custom Script command, but I am not sure where to get started. I would prefer hints towards what I should do rather than a solution, but if someone wishes to code it for me then I won't be complaining.Another slightly off topic question is: Can I output a player variable in the Add Text command?Thanks in advance,Lcarens Link to comment Share on other sites More sharing options...
abhi2011 Posted April 26, 2014 Share Posted April 26, 2014 If you mean don't walk for specific events then make an option for each event like "Can Player Move while In Progress?" Then on client side if the player is in and event and if the event has got movement disabled then don't move. This is some air code```CanMove as byte ' 0 = No, 1 = Yes--If InEvent thenif not event.canmove = 0canplayermove = trueend ifend if ``` Link to comment Share on other sites More sharing options...
lcarens Posted April 26, 2014 Author Share Posted April 26, 2014 > If you mean don't walk for specific events then make an option for each event like "Can Player Move while In Progress?" > > Then on client side if the player is in and event and if the event has got movement disabled then don't move. This is some air codeThe problem with using InEvent is that it doesn't work for most of my events. In most of the cases that I wish for someone to not be able to move, I am using the chatbox to display text instead of the event text box. Link to comment Share on other sites More sharing options...
abhi2011 Posted April 26, 2014 Share Posted April 26, 2014 It doesn't matter how you show a certain data as long as you can set InEvent to true. When a chat message is sent and if the event has set CanMove to false then just set InEvent = true and it'll work. Just make sure the client sets it to true as well. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now