-
-
Notifications
You must be signed in to change notification settings - Fork 7
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
Real set variable #240
Closed
Closed
Real set variable #240
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
3e80317
move code that get vars in expression for JUMP case to separated func
Jeremi360 4e41eb6
add parser case for SET_VARIABLE analogous to JUMP case
Jeremi360 7b60521
add executer case for SET_VARIABLE analogous to JUMP case
Jeremi360 25f4a51
update tests
Jeremi360 ed6f6c3
move ASSIGNMENT to Regex Dict as it used by SET_VARIABLE and fix it r…
Jeremi360 8ec3f0e
add missing checks for Rakugo variables o it caused errors when var d…
Jeremi360 4eac92c
fix parsing Rakugo vars in Parser::get_vars_in_expression()
Jeremi360 4112646
wip
Jeremi360 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
[gd_scene load_steps=2 format=3 uid="uid://cnv3uvvte6sbc"] | ||
|
||
[ext_resource type="Script" path="res://addons/Rakugo/lib/nodes/RakuScriptDialogue.gd" id="1_ypk6u"] | ||
|
||
[node name="RakuScriptDialogue" type="Node"] | ||
script = ExtResource("1_ypk6u") | ||
raku_script = "res://Test/TestReadmeExample/TestReadmeExample.rk" | ||
auto_start = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,12 @@ | ||
a = 1 | ||
b = 2.5 | ||
a = 1 + 1 | ||
b = 5/2 | ||
c = "Hello, world !" | ||
d = a | ||
character Sy "Sylvie" | ||
Sy.life = 5 | ||
e = Sy.life | ||
e = Sy.life | ||
f = 2 | ||
f += 2 | ||
f *= 2 | ||
f /= 2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -482,4 +482,4 @@ func get_scene_script_object(scene): | |
|
||
node_idx += 1 | ||
|
||
return to_return | ||
return to_return |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rakugo.get_variable return null if variable is not found. So you do not need to use has_variable before get_variable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I made this if this way as Rakugo would crash when
get_variable()
returns null - we program it this way,push_error()
stops program no matter what is next.Rakugo-Dialogue-System/addons/Rakugo/Rakugo.gd
Lines 74 to 85 in d11e1fe