My Text Adventure
-
so you check for each example with "if == "'s and "elseif =="'s?
-
also in the video on line 25 "createRooms(). is that a function? and does it pretty much act like a gosub, and find that function - wherever in the code, run the lines, then return to line 25?
-
@lawyerlounge said in My Text Adenture:
also in the video on line 25 "createRooms(). is that a function? and does it pretty much act like a gosub, and find that function - wherever in the code, run the lines, then return to line 25?
That's exactly how functions work, but you can pass and return values to them
A gosub is a function with no arguments and no return value like this:
function something() /// my gosub lines are here! return void
-
This post is deleted! -
x = 0
something()function something()
while x < 2 loop
clear(black)
print( "hello world" )
update()
x += 1
sleep(1)
repeat
return voidSo that code would display "hello world" wait 1 sec, clear to black, display "hello world" again, wait 1 sec, then end?
Also how do you display code in the comments on here like you did, and when would be a scenario when you would return a value after a function? like "return x"?
-
If you add backticks (3 of these `) around your code it will
appear like this! :)
-
This post is deleted! -
This post is deleted! -
This post is deleted! -
Awesome work man!
-
Sick I love the sounds it adds to the gameplay.
-
This post is deleted! -
@Jongjungbu how do i get the demo?
-
@jetrocker7 Add @Jongjungbu as a friend on your switch (the friend code is in their post) and then go to "Friends" within the Fuze app, select Jongjungbu and you will see their shared content. Basically the same way you see anyone's shared content in Fuze
-
@Martin ohhh ok thx, i feel dumb. ;^w^
-
This post is deleted! -
@Jongjungbu oh ok. thank! 👌
-
This post is deleted! -
Right that's it I'm adding you as a friend @Jongjungbu I have to play this..
Absolutely love what you've done with the music.
-
This post is deleted!