Need help with making HowToRoblox's R15 armor system compatible with R6 mechanism

hello there again my dear peoples, I haven’t posted in here for atleast weeks, but I have to post this problem it has been going on with my game for past weeks, so I will show you the three screenshots that have circles that shows specific issues of that game, and I will share you rbxl file of the test game I made, I tried my best to make the entire script compatible with R6 mechanism, but my scripting sucks so bad that it is my limit to fix it, so I will share you the three screenshots, and I will also share you the rbxl file for you guys to possibly fix it, and I just wanna say thank you so much for attempting to help me out :face_holding_back_tears:

screenshot 1:

screenshot 2:

screenshot 3:

so here is test game place file for request you amazing peoples to help modify and fix it, I’m unsure if somebody can help me with this problem I’m having right now but it would be so awesome if someone could save me. :smile:
howtoroblox’s armor system R6 ported.rbxl (158.7 KB)

(special credit to HowToRoblox for creating the Base Armor System despite him making it R15 exclusive and letting me suffer making compatible with R6… anyway this is his youtube channel! HowToRoblox’s Youtube Channel

thank you so much for reading all of it. -mari

4 Likes

With this armor system, converting to R6 can mean a couple different things. You can simplify the system to work for R6 by removing parts not found in the R6 model, or rework it to include these R15 elements (hands, feet, etc.) to an R6 game.

The first option is what I would recommend as it still utilizes this system without changing too much. I would start fresh with the code to get rid of any edits you made, since the code isn’t actually what makes it R15.

Detailed Explination of the Problem

Using the model linked above and following all of the placement instructions you’ll notice the “ArmorPieces” folder contains subfolders with different armor locations, then a model, then the individual armor pieces themselves. These are titled things like “LeftFoot”, “RightHand”, “LeftUpperArm”, etc. All parts that don’t exist in R6.`

R6 vs R15
  • R6 is an older use character model that is comprised of 6 parts. Hence the name R6. There is a “Head”, “Left Arm”, “Right Arm”, “Left Leg”, “Right Leg”, and “Torso”.
  • R15 is the newer R model which takes the classic R6 model and breaks it up into more pieces, 15 to be exact. Containing parts like Feet, Upper & Lower Arms, Legs, and Torso.

The model names I previously mentioned are what makes the script attach them to those R15 body parts, and since only the “Head” part exists in both R15 and R6, it is the only part that would work. The solution is to rename the parts in the ArmorPieces folder to correspond with the R6 part names. However, some of them don’t exist in R6.

Solution

  1. Resizing the Armor
    So in short, your solution is to remodel the armor pieces to be R6 compatible. In the image below you can see an R6 rig (left) and the original armor pieces (right). Take the armor pieces into the workspace and resize them to cover the 5 parts (excluding the head). The parts highlighted in pink are R15 exclusive (don’t exist in R6). There will be 5 parts to cover arms, legs and the torso. But in the end it will all fit into 3 folders (Head, Legs, Torso). See next step

  2. Armor Folders
    Then take your new models and place them under the appropriate model in the ArmorPieces folder. I didn’t resize the models but here’s what the folder should look like after you’ve done that. You need to delete “Feet” and “Hands” folders.

    image

  3. Code Edits
    Head over to ArmorServer located in ServerScriptService. At the top you’ll see a table of armor types. Simply remove “Hands” and “Feet”. (Highlighted below)
    image
    .
    Then head to StarterGUI and open the local script ArmorGuiHandler. Towards the top you’ll find this list of all the buttons in the UI, delete the entire line pertaining to Hands and Feet. (Highlighted below)
    image

  4. GUI Edits
    Under the ArmorInventoryFrame > Character Frame you’ll see 5 buttons. Delete the Feet and Hands Image Buttons. The CharacterFrame should now look like this.
    image

Final Product
As you can see this works. The parts just need to be resized in order to fit the character like previously mentioned.

image

Hope this helps!

1 Like

hello there! and I’m pleased that you have responded to me! :hugs:
…but however… the torso isn’t located and welded properly, and you forgot to mention about two replacement armor types that would replace the Hands and Feet type armors… so for the first replacement of hands type armor is called “Talisman”, and second replacement of Feet type armor is called “WaistTalisman”. you have missed some of the fixes I have made for that armor system, but it is alright. let me show you the new issues I have spotted in that test game, and I will also share you the rbxl file (roblox studio place file I think) which has the today’s fixes made by me on it, but however the torso location hasn’t been fixed yet, so here is two screenshots of issues in the test game.

screenshot 1: these warning logs are assumed to be warning log that issues that armor system couldn’t find firstchild and other crappy things, I don’t seems to understand any of these :sob:

screenshot 2: I dug into details of the errors in my test game, and I saw that torso armor’s primary part doesn’t have one more extra weldconstraint that welds PRIMARY PART inside Torso Armor with R6 humanoid’s Torso, and I saw that Head Armor’s PRIMARY PART does have one more extra weldconstraint that welds it’s PRIMARY PART with R6 humanoid’s Head. and Torso doesn’t have that extra weldconstraint while it’s supposed to have that one…

and so, here is the updated rbxl file, I’m wishing you that you could find solutions from checking out the roblox place file, and for properly test it you’d have to upload the game and allow http request in that uploaded test game… and I just wanna say thank you so much for helping around :face_holding_back_tears:
howtoroblox’s armor system R6 ported.rbxl (171.4 KB)

-mari Shiel

1 Like

hello there? do you mind helping me with Fixing the Armor System if you could, thank you so much.
-mari

Hey there, sorry for the delayed response. I think if you follow my instructions above, which correctly convert this system to R6, you might find what you need. Including hands/feet in R6 in unreliable as they do not exist naturally in R6. If you want to have those parts, you should consider using R15.

1 Like

hey there again, in this day I were writing this, I tried to do productive today by trying to fix the armor system, but my poor scripting script and with help of chatGPT only made Chestplate not even get welded with player’s Torso in wrong height while it were supposed to be in previous code before fix… so I will share you the script again, so if you do mind helping me again, then I will gladly take the help, thank you :face_holding_back_tears:

so anyway here is the new code I wrote with chatgpt, I wish that someone could fix it well.

local armorpieces = game:GetService("ReplicatedStorage"):WaitForChild("ArmorPieces") --this script is modfied code of EquipArmor in ServerScriptService

function equipFunc(plr:Player, armortype:string, armor:string, plrSpawned:boolean)
	local char = plr.Character or plr.CharacterAdded:Wait()

	if char and char:FindFirstChild("Humanoid") and char.Humanoid.Health > 0 then
		local inv = plr:WaitForChild("ArmorInventory")
		local equipped = plr:WaitForChild("ArmorEquipped")
		local currentArmor = equipped:FindFirstChild(armortype) and equipped[armortype].Value

		if armorpieces:FindFirstChild(armortype) and armorpieces[armortype]:FindFirstChild(armor) then
			if currentArmor and not plrSpawned then
				local healthGain = currentArmor.Stats.Health.Value
				local speedGain = currentArmor.Stats.Speed.Value
				char.Humanoid.MaxHealth = char.Humanoid.MaxHealth - healthGain
				char.Humanoid.WalkSpeed = char.Humanoid.WalkSpeed - speedGain

				for _, armorpiece in pairs(armorpieces:GetDescendants()) do
					if armorpiece.Name == currentArmor.Name and armorpiece.Parent.Parent == armorpieces then
						armorpiece:Clone().Parent = inv
						break
					end
				end

				currentArmor:Destroy()
			end

			local newarmor = armorpieces[armortype][armor]:Clone()

			for _, pieces in pairs(newarmor:GetChildren()) do
				if pieces:IsA("Model") then
					if char:FindFirstChild(pieces.Name) then
						local pivotCFrame = char[pieces.Name].CFrame
						pieces:PivotTo(pivotCFrame)

						local wc = Instance.new("WeldConstraint")
						wc.Part0 = char[pieces.Name]
						wc.Part1 = pieces.PrimaryPart
						wc.Parent = pieces.PrimaryPart
					elseif armortype == "Torso" then --I'm trying to make this part of the script relocates and welds Chestplate Armor to torso exclusively, But I still suck at it ;-;
						pieces:PivotTo(char.Torso.CFrame + Vector3.new(0, 2, 0))

						local wc = pieces.PrimaryPart.Torsoweld
						wc.Part0 = char.Torso
						wc.Part1 = pieces.PrimaryPart
					end
				end
			end

			newarmor.Parent = char
			equipped[armortype].Value = newarmor

			if inv:FindFirstChild(armor) then
				inv[armor]:Destroy()
			end

			local newHealthGain = newarmor.Stats.Health.Value
			local newSpeedGain = newarmor.Stats.Speed.Value
			char.Humanoid.MaxHealth = char.Humanoid.MaxHealth + newHealthGain
			char.Humanoid.WalkSpeed = char.Humanoid.WalkSpeed + newSpeedGain

			if char.Humanoid.Health > char.Humanoid.MaxHealth then
				char.Humanoid.Health = char.Humanoid.MaxHealth
			end
		end
	end
end

return equipFunc

also here is screenshot of armor system test game. in the screenshot, chestplate doesn’t even get welded with player model’s Torso, and I currently doesn’t know how to fix that in any way…

anyways thanks for your help :smile: -mari

hey there again, do you mind continuing helping me with this problem that is still remaining since week ago? I posted new script that was bit modified with chatgpt but I couldn’t get proper answer of the script yet…
-mari

1 Like