Ertzel Posted September 8, 2010 Share Posted September 8, 2010 How do you even have it setup to pick a job? Link to comment Share on other sites More sharing options...
semlemsushi Posted September 8, 2010 Author Share Posted September 8, 2010 what do you mean by picking a job. maybe he didnt understand what i said, i said that i need a code so that only a gundealer can view a certain button, and i added the Job As Byte and the other thing he said, then put the code in form_load and nongundealers can still see the button =P Link to comment Share on other sites More sharing options...
Ertzel Posted September 9, 2010 Share Posted September 9, 2010 Yes I understand what u r trying to do, but how do you even set somebody to be a gundealer?If you dont have the job set, then obv this wont work… Link to comment Share on other sites More sharing options...
Yxxe Posted September 9, 2010 Share Posted September 9, 2010 @Ertzel:> Yes I understand what u r trying to do, but how do you even set somebody to be a gundealer?> > If you dont have the job set, then obv this wont work…If _JOB_GUNDEALER As Byte = 0_ and all characters were not deleted then maybe their job has been set to 0: which means they are default Gundealer. set JOB_GUNDEALER to 1 and set a default job to 0 and see if that works. Link to comment Share on other sites More sharing options...
semlemsushi Posted September 9, 2010 Author Share Posted September 9, 2010 @Lightning:> @Ertzel:> > > Yes I understand what u r trying to do, but how do you even set somebody to be a gundealer?> > > > If you dont have the job set, then obv this wont work…> > If _JOB_GUNDEALER As Byte = 0_ and all characters were not deleted then maybe their job has been set to 0: which means they are default Gundealer. set JOB_GUNDEALER to 1 and set a default job to 0 and see if that works.I dont think I know what you're talking about. This is what it looks like in the server's and client's modConstants:```'Job ConstantsPublic Const JOB_GUNDEALER As Byte = 1Public Const JOB_BODYGUARD As Byte = 2```_JOB_GUNDEALER_ isn't set to 0, it's set to 1\. And the character didn't get deleted. Soo am I doing what your saying or what should I do? Link to comment Share on other sites More sharing options...
Yxxe Posted September 9, 2010 Share Posted September 9, 2010 Make a new character Beforehand, make sure in the character creation and character loading code that the job has been set too, otherwise of course it will not work. :) So all you need to do is find the code (server side) that writes all of the character data to a file, and write its data at the end of that file. Link to comment Share on other sites More sharing options...
semlemsushi Posted September 9, 2010 Author Share Posted September 9, 2010 Lightnings busy right now so can anyone help me? Im supposed to retrieve the character creation code and the character load code and put it at the end of the file. What file? Link to comment Share on other sites More sharing options...
Ertzel Posted September 9, 2010 Share Posted September 9, 2010 @semlemsushi:> I dont think I know what you're talking about. This is what it looks like in the server's and client's modConstants:You need a way to make someone a certain job. Without making someone have a job, then obv this wont work because no one will be a gundealer to see the button… Link to comment Share on other sites More sharing options...
Yxxe Posted September 10, 2010 Share Posted September 10, 2010 @Ertzel:> @semlemsushi:> > > I dont think I know what you're talking about. This is what it looks like in the server's and client's modConstants:> > You need a way to make someone a certain job. Without making someone have a job, then obv this wont work because no one will be a gundealer to see the button…Or as a test you could put```Player(Index).Job = JOB_GUNDEALER```in the character load. Then to test set the players' job to the default afterwards. Link to comment Share on other sites More sharing options...
semlemsushi Posted September 10, 2010 Author Share Posted September 10, 2010 okay, but im trying to figure out to make it so if ur not a gundealer, you cant see it. i know it will show up if i am gundealer, also if im not. and does the thing like GUNDEALER = 1 when u put the job constants, does 1 mean like [CLASS1] in the .ini file? Link to comment Share on other sites More sharing options...
Yxxe Posted September 10, 2010 Share Posted September 10, 2010 All you need to do is replace this:```If Player(Index).Job = JOB_GUNDEALER Then btnGunDealer.Visible = TrueEnd If```With this:```If Player(Index).Job = JOB_GUNDEALER Then btnGunDealer.Visible = TrueElseIf Player(Index).Job <> JOB_GUNDEALER Then btnGunDealer.Visible = FalseEnd If```It's not difficult, only an elseif. And no, the GUNDEALER = 1 is just assigning GUNDEALER the value of 1, there is no need for a _.ini_. Link to comment Share on other sites More sharing options...
semlemsushi Posted September 15, 2010 Author Share Posted September 15, 2010 Fuckk, nothings working no matter what it doesnt matter, the button just stays there no matter what job I am. And you said something about setting the players job…how do I do that. Link to comment Share on other sites More sharing options...
DarkSpine Posted September 15, 2010 Share Posted September 15, 2010 To set a job with these edits, do:```Player(MyIndex).Job = #```Replacing # with whatever you want to set it to.```If Player(Index).Job = JOB_GUNDEALER Then btnGunDealer.Visible = TrueElseIf Player(Index).Job <> JOB_GUNDEALER Then btnGunDealer.Visible = FalseEnd If```The above may, or may not need Index replaced with MyIndex, also Player(MyIndex).Job _might_ need to have Index, rather than MyIndex, but I'm pretty sure all client-sided stuff uses MyIndex, and server sided is Index.Also, to test what it thinks your job is, make a new label somewhere visible on frmMainGame, and name it "lblJob". Now in frmMainGame```Private Sub Form_Load```add:```lblJob.Caption = CStr(Player(MyIndex).Job)]/code]If lblJob returns the wrong number, something is definitely screwing up.~Urame``` Link to comment Share on other sites More sharing options...
Yxxe Posted September 15, 2010 Share Posted September 15, 2010 @Urame:> To set a job with these edits, do:> ```> Player(MyIndex).Job = #> ```Replacing # with whatever you want to set it to.> > ```> If Player(Index).Job = JOB_GUNDEALER Then> btnGunDealer.Visible = True> ElseIf Player(Index).Job <> JOB_GUNDEALER Then> btnGunDealer.Visible = False> End If> ```The above may, or may not need Index replaced with MyIndex, also Player(MyIndex).Job _might_ need to have Index, rather than MyIndex, but I'm pretty sure all client-sided stuff uses MyIndex, and server sided is Index.> > Also, to test what it thinks your job is, make a new label somewhere visible on frmMainGame, and name it "lblJob". Now in frmMainGame```> Private Sub Form_Load> ```add:> ```> lblJob.Caption = CStr(Player(MyIndex).Job)]/code]> > If lblJob returns the wrong number, something is definitely screwing up.> ~Urame> ```Thanks for compiling all my code, Urame (well most of it is mine). Should be easy enough to follow now. XDRegards,Lightning Link to comment Share on other sites More sharing options...
semlemsushi Posted September 16, 2010 Author Share Posted September 16, 2010 Ok I did everything you said and nothings works. I have to change the "Index" to "MyIndex" for```If Player(Index).Job = JOB_GUNDEALER Then btnGunDealer.Visible = TrueElseIf Player(Index).Job <> JOB_GUNDEALER Then btnGunDealer.Visible = FalseEnd If```to make it possible to compile. Then, nothing shows up on the label. I also don't understand what you mean by> To set a job with these edits, do:> ```> Player(MyIndex).Job = #> ```I'm thinking you have to set their job before they can see the button, but I'm totally lost, and extremely confused on how to do that.I'm going to put up a link for my source code, and It would be cool if you could take quick peek at it, skim through the codes you need to look at and see what I'm adding/not adding/doing wrong, etc.Link for Source Code: [http://www.mediafire.com/?62w6k16taahtwbb](http://www.mediafire.com/?62w6k16taahtwbb)Thanks for bearing with me guys, I know I'm a noob at this shet, and also a pain in the ass but I hope I learn to develop like you guys through the journey of making my game :cheesy: Link to comment Share on other sites More sharing options...
DarkSpine Posted September 16, 2010 Share Posted September 16, 2010 Player(MyIndex).job = 1 will set the player's job to 1.I was playing around with the source, trying to get it to send the correct variable, but for some reason it just wouldn't work…I'll prolly try more when I'm not tired xD~Urame Link to comment Share on other sites More sharing options...
semlemsushi Posted September 16, 2010 Author Share Posted September 16, 2010 okay lol thanks. im tired too gotta wake upa t 6am tomorrow for school, see yah dude. Link to comment Share on other sites More sharing options...
semlemsushi Posted September 18, 2010 Author Share Posted September 18, 2010 Can anyone still help me with this 0.0 Link to comment Share on other sites More sharing options...
Murdoc Posted September 18, 2010 Share Posted September 18, 2010 @semlemsushi:> Can anyone still help me with this 0.0I can try. When you say "job" are you looking to have seperate jobs from the starting classes? Or do you mean the jobs (aka classes) that you start the game with? Link to comment Share on other sites More sharing options...
Yxxe Posted September 18, 2010 Share Posted September 18, 2010 @semlemsushi:> Can anyone still help me with this 0.0FFS, this isnt difficult. Myself and Urame have given you alot of help and only need a basic understanding of VB6 to get it done.Regards,Lightning Link to comment Share on other sites More sharing options...
semlemsushi Posted September 18, 2010 Author Share Posted September 18, 2010 @â•‘Veneranceâ•‘:> @semlemsushi:> > > Can anyone still help me with this 0.0> > I can try. When you say "job" are you looking to have seperate jobs from the starting classes? Or do you mean the jobs (aka classes) that you start the game with?I mean the classes. I need it so that if you are a GunDealer (class 1 as it says in the classes.ini files i think) then a special button will show up. These guys are trying to help me but I stlil don't get it because i'm an ultra noob. Link to comment Share on other sites More sharing options...
Murdoc Posted September 19, 2010 Share Posted September 19, 2010 @semlemsushi:> @â•‘Veneranceâ•‘:> > > @semlemsushi:> > > > > Can anyone still help me with this 0.0> > > > I can try. When you say "job" are you looking to have seperate jobs from the starting classes? Or do you mean the jobs (aka classes) that you start the game with?> > I mean the classes. I need it so that if you are a GunDealer (class 1 as it says in the classes.ini files I think) then a special button will show up. These guys are trying to help me but I stlil don't get it because I'm an ultra noob.Well in that case, it's more simple than you probably realize. Here, do this:Add in form_load in the code for "frmMainGame":If GetPlayerClass(Index) = (the number (ie. 1, 2, 3 etc for the gundealer class goes here) btnGundealer.visible = trueEnd IfMake the button named btnGundealer, and in its properties window make sure Visible is False.Create a new char that isn't the class number, and the button shouldn't load.Good luck! Link to comment Share on other sites More sharing options...
Ertzel Posted September 19, 2010 Share Posted September 19, 2010 @semlemsushi:> I can try. When you say "job" are you looking to have seperate jobs from the starting classes? Or do you mean the jobs (aka classes) that you start the game with?I mean the classes. I need it so that if you are a GunDealer (class 1 as it says in the classes.ini files I think) then a special button will show up. These guys are trying to help me but I stlil don't get it because I'm an ultra noob.OMG… dude then ur looking for a code to make something visible according to a CLASS not job. When u said job we all assumed u where talking about something new you had in your game where players have jobs, not classes so people gave u a code on how to add this new feature but its totally pointless cuz u don't need it at all if ur just using classes.... Link to comment Share on other sites More sharing options...
semlemsushi Posted September 19, 2010 Author Share Posted September 19, 2010 @Ertzel:> [quote author=semlemsushi link=topic=64468.msg693558#msg693558> I can try. When you say "job" are you looking to have seperate jobs from the starting classes? Or do you mean the jobs (aka classes) that you start the game with?I mean the classes. I need it so that if you are a GunDealer (class 1 as it says in the classes.ini files I think) then a special button will show up. These guys are trying to help me but I stlil don't get it because I'm an ultra noob.OMG… dude then ur looking for a code to make something visible according to a CLASS not job. When u said job we all assumed u where talking about something new you had in your game where players have jobs, not classes so people gave u a code on how to add this new feature but its totally pointless cuz u don't need it at all if ur just using classes....Damnit, I thought JOBS and CLASSES were the same thing, like in some other games like MapleStory. Oh well I'll just make a new thread then, someone close this please. Link to comment Share on other sites More sharing options...
DshWinchester Posted September 19, 2010 Share Posted September 19, 2010 lol ;Dnice gotch 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