Forum Discussion
11 years ago
With this part I'm having a little issue:
The actual commands are working as expected (like with "h 1" or "h off" or whatever), but when I only type "h" I don't get the expected output .. and I don't understand why not. (The reason I want that is to prevent myself from forgetting that this is not a toggle)
?
lastexception.txt is not complaining about me (as it did yesterday, about my untidy whitespaces).
(I also have a feeling that the inner if is probably unnecessary as I can probably pass the bool directly somehow, I only don't want to change too many things at once)
@sims4.commands.Command('h', command_type=sims4.commands.CommandType.Live)
def headline(enable:bool=None, _connection=None):
if enable is not None:
if enable:
command = 'headlineeffects on'
sims4.commands.client_cheat(command, _connection)
else:
command = 'headlineeffects off'
sims4.commands.client_cheat(command, _connection)
else:
output("You need to turn this on or off with 't', 'true', 'on', '1', 'yes', 'y', 'enable' or 'f', 'false', 'off', '0', 'no', 'n', 'disable'")
The actual commands are working as expected (like with "h 1" or "h off" or whatever), but when I only type "h" I don't get the expected output .. and I don't understand why not. (The reason I want that is to prevent myself from forgetting that this is not a toggle)
?
lastexception.txt is not complaining about me (as it did yesterday, about my untidy whitespaces).
(I also have a feeling that the inner if is probably unnecessary as I can probably pass the bool directly somehow, I only don't want to change too many things at once)
About The Sims 4 Mods & Custom Content
Find expert tips, troubleshooting help, tutorials for mods and custom content, and The Sims 4 patch files in our forum.15,596 PostsLatest Activity: 7 days ago
Community Highlights
Recent Discussions
- 7 hours ago
- 8 hours ago
- 9 hours ago