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

Dialogic.load_full_state not working #1719

Closed
GoldExperience opened this issue Sep 14, 2023 · 2 comments
Closed

Dialogic.load_full_state not working #1719

GoldExperience opened this issue Sep 14, 2023 · 2 comments
Labels
Bug 🐞 Something isn't working Planned This will be worked on soon

Comments

@GoldExperience
Copy link

The problem

Dialogic.load_full_state not working.
get error:

Invalid type in function 'add_layout_style' in base 'Node (subsystem_styles.gd)'. Cannot convert argument 1 from Nil to String.

To Reproduce

func _ready():
	var dialog = Dialogic.start("timeline")
	var save_state = Dialogic.get_full_state()
	print(save_state)
	Dialogic.load_full_state(save_state)

Expected behavior
no error.

Screenshots
image

System (please complete the following information):

  • OS: Windows11
  • Godot Version:4.1.1
  • Dialogic Version: 1.9
@Jowan-Spooner
Copy link
Member

Can confirm. Can be fixed very easily, it's just a missing default.

If you want to apply the fix localy so you don't have to wait for a new version:

change line 16 in subsystem_styles.gd to

	add_layout_style(dialogic.current_state_info.get('style', ''))

I'll make sure that this is included in the next release.

@Jowan-Spooner Jowan-Spooner added Bug 🐞 Something isn't working Planned This will be worked on soon labels Sep 15, 2023
@Jowan-Spooner Jowan-Spooner added this to the Version 2.0 (beta) milestone Sep 15, 2023
Jowan-Spooner added a commit that referenced this issue Sep 15, 2023
Jowan-Spooner added a commit that referenced this issue Sep 15, 2023
@Jowan-Spooner
Copy link
Member

I've pushed a PR with the fix above. Hope it actually fixes it for you. Feel free to try out the main branch if you want to. Will close this, but if it's not fixed, feel free to reopen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug 🐞 Something isn't working Planned This will be worked on soon
Development

No branches or pull requests

2 participants