Medbot Color auto-reskin and applications to other bots
- cedarbridge
- Joined: Fri May 23, 2014 12:24 am
- Byond Username: Cedarbridge
Medbot Color auto-reskin and applications to other bots
I'm looking over the code for the medbots to see how they go about checking what color box was used to construct them so they can apply that to the final medbot. For the life of me I can't wrap my head around it. Might just be a product of trying to read code at 4am.
If whoever coded that is around could help me understand the process it uses and maybe help work out how to do the same with toolboxes, that would be swell.
If whoever coded that is around could help me understand the process it uses and maybe help work out how to do the same with toolboxes, that would be swell.
- Alipheese
- Joined: Sun May 01, 2016 12:56 pm
- Byond Username: Daturix
- Github Username: Daturix
Re: Medbot Color auto-reskin and applications to other bots
isnt it the color of the medkit used in making it?cedarbridge wrote:I'm looking over the code for the medbots to see how they go about checking what color box was used to construct them so they can apply that to the final medbot. For the life of me I can't wrap my head around it. Might just be a product of trying to read code at 4am.
If whoever coded that is around could help me understand the process it uses and maybe help work out how to do the same with toolboxes, that would be swell.
-
- Joined: Sun Oct 26, 2014 5:13 am
- Byond Username: Lzimann
- Github Username: lzimann
Re: Medbot Color auto-reskin and applications to other bots
I didn't code, but this is how they are done:cedarbridge wrote:I'm looking over the code for the medbots to see how they go about checking what color box was used to construct them so they can apply that to the final medbot. For the life of me I can't wrap my head around it. Might just be a product of trying to read code at 4am.
If whoever coded that is around could help me understand the process it uses and maybe help work out how to do the same with toolboxes, that would be swell.
When you click a medical kit with an arm, it saves the medkit type(here) in the assembly's var called skin.
When the assembly is created, it creates an overlay of that medkit, which is done here
-
- Joined: Sat Apr 19, 2014 5:19 am
- Byond Username: Gun Hog
Re: Medbot Color auto-reskin and applications to other bots
What if you made all toolboxes greyscale, and simply applied the "color" var to the toolboxes accordingly? Would that make them look to weird? You could then read the color var of the toolbox used to build the floorbot, then apply it to the newly constructed bot.
- cedarbridge
- Joined: Fri May 23, 2014 12:24 am
- Byond Username: Cedarbridge
Re: Medbot Color auto-reskin and applications to other bots
I don't think that plays nicely with shading, different colored latches, etc. That's why the medbots use the "Skin" setup instead.Gun Hog wrote:What if you made all toolboxes greyscale, and simply applied the "color" var to the toolboxes accordingly? Would that make them look to weird? You could then read the color var of the toolbox used to build the floorbot, then apply it to the newly constructed bot.
-
- Joined: Thu Sep 22, 2016 7:31 pm
- Byond Username: Doctor_Pork
- Location: Pennsylvania
Re: Medbot Color auto-reskin and applications to other bots
i would love different color floorbots one day
oranges wrote:pork, the nondescript, commoner king, literally so stealth you could just your normal name in OOC and nobody would know, long may he reign as the secret commander
Deitus wrote:If your signature is scrollable it's too long and fucking obnoxious and you should feel bad
Link to my feedback thread. Go there.
PKPenguin321 wrote:I've been had by yet another tg boondoggle
- cedarbridge
- Joined: Fri May 23, 2014 12:24 am
- Byond Username: Cedarbridge
Re: Medbot Color auto-reskin and applications to other bots
Its probably possible to just mirror the medkit code over with modifications to match the different boxes but I'm code retarded and even worse at sprite work.Doctor Pork wrote:i would love different color floorbots one day
- MisterPerson
- Board Moderator
- Joined: Tue Apr 15, 2014 4:26 pm
- Byond Username: MisterPerson
Re: Medbot Color auto-reskin and applications to other bots
Both of those are solvable problems. You can have a colored texture and a noncolored one, and you can have a gradient that includes both blacks and whites.cedarbridge wrote:I don't think that plays nicely with shading, different colored latches, etc. That's why the medbots use the "Skin" setup instead.Gun Hog wrote:What if you made all toolboxes greyscale, and simply applied the "color" var to the toolboxes accordingly? Would that make them look to weird? You could then read the color var of the toolbox used to build the floorbot, then apply it to the newly constructed bot.
I code for the code project and moderate the code sections of the forums.
Feedback is dumb and it doesn't matter
Feedback is dumb and it doesn't matter
Who is online
Users browsing this forum: No registered users