Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setting BaseScript.Enabled doesn't affect anything #334

Open
hoontee opened this issue Jul 30, 2023 · 1 comment
Open

Setting BaseScript.Enabled doesn't affect anything #334

hoontee opened this issue Jul 30, 2023 · 1 comment

Comments

@hoontee
Copy link

hoontee commented Jul 30, 2023

Critical fix needed if #277 isn't already underway. Scripts aren't disabled if setting Enabled = false.

Related: #315

@kennethloeffler
Copy link
Member

kennethloeffler commented Jul 30, 2023

This isn't going to work because Roblox Studio won't load BaseScript.Enabled. Try it out for yourself with this file where I've edited a script to have a serialized Enabled property:

<roblox
 xmlns:xmime="http://www.w3.org/2005/05/xmlmime" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.roblox.com/roblox.xsd" version="4">
	<Meta name="ExplicitAutoJoints">true</Meta>
	<External>null</External>
	<External>nil</External>
	<Item class="Script" referent="RBX0AA760BFF1DA4F63B313DEA157E76E7F">
		<Properties>
			<BinaryString name="AttributesSerialize"></BinaryString>
			<bool name="Enabled">false</bool>
			<Content name="LinkedSource"><null></null></Content>
			<string name="Name">Script</string>
			<token name="RunContext">0</token>
			<string name="ScriptGuid">{07BBB67B-65A6-4ED3-9F18-26A7182CD2AA}</string>
			<ProtectedString name="Source"><![CDATA[print("Hello world!")
]]></ProtectedString>
			<int64 name="SourceAssetId">-1</int64>
			<BinaryString name="Tags"></BinaryString>
		</Properties>
	</Item>
</roblox>

You'll end up with a script with BaseScript.Enabled set to true

@hoontee hoontee changed the title BaseScript.Enabled needs patching in order to serialize Setting BaseScript.Enabled doesn't affect anything Jul 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants