Jump to content

Tags and prefabs


Go to solution Solved by Josh,

Recommended Posts

Posted

Tags are being saved in the map file, and if I load the prefab like a map (File > Open) the tags load, but when objects are placed in the scene the tags are missing.

{
	"scene": {
		"entities": [
			{
				"castshadows": true,
				"collisiontype": 1,
				"extras": {},
				"friction": [
					0.5,
					0.8999999761581421
				],
				"group": "1663675869920",
				"kids": [
					{
						"castshadows": true,
						"collisiontype": 1,
						"extras": {},
						"friction": [
							0.5,
							0.8999999761581421
						],
						"matrix": [
							"0x42c80000",
							"0x0",
							"0x0",
							"0x0",
							"0x0",
							"0xb747ffff",
							"0x42c7fffe",
							"0x0",
							"0x0",
							"0xc2c7fffe",
							"0xb747ffff",
							"0x0",
							"0x0",
							"0x0",
							"0x0",
							"0x3f800000"
						],
						"model": {
							"islimb": true
						},
						"name": "Cube",
						"physicsmode": 0,
						"pickmode": 1,
						"quaternion": [
							"0x3f3504f4",
							"0x0",
							"0x0",
							"0xbf3504f2"
						],
						"reflection": true,
						"rotation": [
							"0x42b3f5df",
							"0x80000000",
							"0x0"
						],
						"scale": [
							"0x42c80000",
							"0x42c7ffff",
							"0x42c7ffff"
						],
						"tags": [
							"test2"
						],
						"uuid": "d0a578c6-4ac8-4de5-83e0-85db59a8a57b"
					}
				],
				"model": {
					"islimb": false,
					"path": "Models/test.mdl"
				},
				"name": "STATIC_MESH",
				"physicsmode": 0,
				"pickmode": 1,
				"reflection": true,
				"tags": [
					"test1"
				],
				"uuid": "bc1b377d-116b-45d8-b6dd-5eb8f8330079"
			}
		]
	}
}

 

Let's build cool stuff and have fun. :)

  • Solution
Posted

Okay, the problem is that Entity::Copy() was not copying the tags. I believe this will be fixed in the next build that goes up.

Let's build cool stuff and have fun. :)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...