Guest Posted February 26, 2011 Share Posted February 26, 2011 After following this tutorial your staff members will be able to make themselves invisible/visible with a command. **Client Side:**First, the actual command. Place this code above "Mapper Admin Commands":``` ' Visibility Case "/visible" If GetPlayerAccess(MyIndex) < ADMIN_MONITOR Then GoTo Continue frmMain.optVON.Value = True = Not frmMain.optVON.Value = True If frmMain.optVON.Value = False Then frmMain.optVOff.Value = True If frmMain.optVOff.Value = False Then frmMain.optVON.Value = True End If End If```Next, search for "Sub DrawPlayerName" and after:``` ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler```Add:```If frmMain.optVOff.Value = True Then Exit Sub``` **Formwork:**Now create two option buttons in picOptions. Name one optVOn and one optVOff, here's how I've arranged it:![](http://i.imgur.com/TIVPB.png)For the sake of convenience I've just made them all ("Visibility" label included) invisible (visible = false). Its your choice whether you make a proper option that saves and is only visible to staff.Also make sure that optVOn's value = True. You can make it so through the Properties bar. Or even add:```optVOn.value = True```to Sub Form_Load in frmMain.Finally, add this code anywhere in the frmMain code:```Private Sub optVON_Click()SendSetSprite 194End SubPrivate Sub optVOff_Click()SendSetSprite 300End Sub```You can change the '300' to anything (preferably a number higher than your current number of sprites), just don't make it ridiculously high or it'll error you in-game.And thats about it, now just use /visible to turn visibility on and off. Link to comment Share on other sites More sharing options...
Ezand Posted February 26, 2011 Share Posted February 26, 2011 Very good :) Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 Lul not really, but I thought it'd be useful for some people. Link to comment Share on other sites More sharing options...
Ezand Posted February 26, 2011 Share Posted February 26, 2011 Well to me it looks very good simple and useful ;) Link to comment Share on other sites More sharing options...
Dennys Posted February 26, 2011 Share Posted February 26, 2011 thats good, but maybe instead of changing your sprite to 300, a sprite not found, just make an invisible sprite at that number. a sprite thats all black? it could work and prevent runtime errors Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 I said you could change it to whatever fits you best. Sprite not found doesn't happen for me for some reason, but if it does happen to you then make an invisible 500th sprite or something. Link to comment Share on other sites More sharing options...
Yxxe Posted February 26, 2011 Share Posted February 26, 2011 Or you could add something to the PlayerRec maybe when the player is sent to the server, which skips drawing the players' name and sprite altogether. Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 You really don't need to over complicate stuff like that :P. Link to comment Share on other sites More sharing options...
damian666 Posted February 26, 2011 Share Posted February 26, 2011 thats not overcomplicating it, thats the best way to do it.clean and saves drawing empty sprites etc.yours works ofcourse, i wont deny that ^^Dami Link to comment Share on other sites More sharing options...
Dzastin Posted February 26, 2011 Share Posted February 26, 2011 Compile Error : Variable not defined:optVOn.Value = True Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 You need to actually make an optVOn option button. Link to comment Share on other sites More sharing options...
abcbadboy555 Posted February 26, 2011 Share Posted February 26, 2011 can someone help me? What file do you put the codes into? Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 The client source code. Link to comment Share on other sites More sharing options...
abcbadboy555 Posted February 26, 2011 Share Posted February 26, 2011 and can you tell me how to make a optVOn button? Sorry I'm a newbie…. Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 Dont worry about it man, everyones a newb at some point.First open your source, click the Forms branch, then click FrmMain.You should see something like this:![](http://I.imgur.com/feBdb.png)You basically click the option button button, and click and drag on your picOptions. You can find your picOptions by right clicking the picParty and click "Send to the back", do that until you get to picOptions and then create your option button.After that you'll need to change the name. You can change the name in the properties panel to the side, here's a pic:![](http://I.imgur.com/qvQp4.png)If you scroll down even further on the properties panel you'll find a field called "Value" click the dropdown next to it and change that into true (for OptVOn only). Link to comment Share on other sites More sharing options...
abcbadboy555 Posted February 26, 2011 Share Posted February 26, 2011 Thanks your the best! And is your game finished yet? I went to the forums, but I didn't see a download button. Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 Not finished, it's up for people to test though. Go to the News and Announcements board, you'll find a topic called 1.2.6 Release, thats where you'll find the download. Link to comment Share on other sites More sharing options...
abcbadboy555 Posted February 26, 2011 Share Posted February 26, 2011 wait….. I'm sorry for all the questions, but when you make the box for the option, how do you switch to the options panel so you can make the option? Also, where do you enter the code? All you said before was to enter it into the client thing, but I couldn't find it.... :sad: :sad: :sad: :sad: :sad: Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 Don't quite understand what you're trying to say. Link to comment Share on other sites More sharing options...
abcbadboy555 Posted February 26, 2011 Share Posted February 26, 2011 Quote!!!!!: "After following this tutorial your staff members will be able to make themselves invisible/visible with a command.Client Side:First, the actual command. Place this code above "Mapper Admin Commands": "Where do you exactly put this code? Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 Where I said you put it, above "Mapper Admin Commands" do ctrl - f "Mapper Admin Commands" into the textbox in the search, click All Project, then paste the code above. Link to comment Share on other sites More sharing options...
chuchoide Posted February 26, 2011 Share Posted February 26, 2011 Sounds nice and usefull, nice tut :D Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2011 Share Posted February 26, 2011 Thanks :D. Link to comment Share on other sites More sharing options...
abcbadboy555 Posted February 27, 2011 Share Posted February 27, 2011 hey sekaru how do you make this option only for admins? Can you find out how? Link to comment Share on other sites More sharing options...
Joyce Posted February 27, 2011 Share Posted February 27, 2011 Wouldn't it be better to add an Invisibility tag to the user UDT? And simply skip rendering the player along with it's name for anyone other then the player himself? (Or a seperate UDT not to mess up your old account data..) I'd imagine that to be a far more efficient and 'proper' way. 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