Archiverse Internet Archive
投稿のみ 投稿と返信
前のページ(最近)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
次のページ(過去)
返信[2]
親投稿
Stewart segludian1
Maybe try this, there is less typing.
2そうだね
プレイ済み
返信[4]
親投稿
Stewart segludian1
With a small amount of code ..... not so much. How did you make your character and map? If you made them in the smile tool editors and saved the map as layers, it isn't too bad. However just putting the map and a sprite on screen doesn't mean it will automatically have gravity, or have the sprite move around or bump into walls. You have to code that part too.
0そうだね
プレイ済み
返信[17]
親投稿
Stewart segludian1
Lesson 7: string operations. Given the string "This is a test" Write a program that prints the first four words using LEFT$, then have it print out the last 5 characters with RIGHT$. Finally use a FOR loop to write out each character in the string individually using MID$. Bonus points if you ask the user for a string to work on using INPUT. None of these should involve much time or code.
0そうだね
プレイ済み
返信[16]
親投稿
Stewart segludian1
Lesson 6: Loops Make a program that prints the numbers 1 to 10, but do it three different ways, once with a for/next loop, once with a while/wend loop, and once more with a repeat/until loop.
0そうだね
プレイ済み
返信[15]
親投稿
Stewart segludian1
plus some more code asking for celsius and printing out the farenheit equivalent. Celsius =(Farenheit - 32) * 5/9 Farenheit = (Celsius * 9/5) + 32
0そうだね
プレイ済み
返信[14]
親投稿
Stewart segludian1
Lesson 5 functions. Build two functions using DEF (we are returning a value so use parenthesis around the variable list). One function will convert temperature from Farenheit to Celsius and the other from Celsius to Farenheit. Use RETURN to send the result to the caller. There should code that asks the user for a temperature in farenheit and prints the temperature in celsius.
0そうだね
プレイ済み
返信[13]
親投稿
Stewart segludian1
Lesson 4:If then else. Building on the last lesson add code to check the age. Tell the user if they are young, old, or something inbetween based on their age. Feel free to make your own age brackets.
0そうだね
プレイ済み
返信[12]
親投稿
Stewart segludian1
Lesson 3: Type conversion of integer to string. Building on the last lesson. Add another variable an integer this time. Ask the user's age. Then print it out using STR$ to cast it to string so you can concatenate strings with +
0そうだね
プレイ済み
返信[11]
親投稿
Stewart segludian1
I can't tutor you in real time or in person, but I can give you some skill building assignments if you want. Lesson 1: Make a program that prints out "Hello World" Lesson 2: Variables and input Declare a string variable with VAR or DIM then use INPUT to ask the user their name and PRINT out Hello plus the name "Hello Stewart" for example. Warning Name$ is a reserved word, use a different variable.
0そうだね
プレイ済み
返信[19]
親投稿
Stewart segludian1
Thanks for trying the game, I am glad you liked it. Sorry the code was hard to follow. The code uses a room array setup where it lists what other rooms and in which direction you can go from each room. Likewise the items also reference what room they are in with player inventory being a fake room of sorts. There is another fake room for used up items too.
0そうだね
プレイ済み
返信[15]
親投稿
Stewart segludian1
Looks like I am too late but attached is a save and load demo. You only really get two options with save/load, a string or an array of numbers. What you want to do is save and load the state of the player and game world. For instance what do you have in your inventory, have you found the secret door in room 27, etc. It doesn't have saving and loading, but my text adventure game is: BDWE58AV
0そうだね
プレイ済み
プレイ日記
Stewart segludian1
Key: NKVEX323 I added comments ... lots of comments. I hope this code is useful to beginners. I also recommend the inventwithpython site which I adapted the code from.
3そうだね
プレイ済み
返信[5]
親投稿
Stewart segludian1
Part 3 of 3. We resize the layers and draw the tiles. Hope that isn't too much to type.
0そうだね
プレイ済み
返信[4]
親投稿
Stewart segludian1
Here is part 2 of 3. I do some sanity checks to make sure what we are reading is actually a Smile Basic Map Tool map.
0そうだね
プレイ済み
返信[3]
親投稿
Stewart segludian1
A single file is harder to load, but I do have a demo that reads it in. This is Part 1 of 3, see attached. The map loading function should be easy to reuse.
0そうだね
プレイ済み
返信[11]
親投稿
Stewart segludian1
I say let the user use either one. The extra code is fairly minimal.
0そうだね
プレイ済み
返信[15]
親投稿
Stewart segludian1
Does the version you want have wi fi built in? If not you will need a USB adapter for that too unless you plug it straight into the router (but then you would need CAT5 cable) Depending on how many devices and ports you are using, a USB hub. - A case so it doesn't short out or break any fragile connectors. I think that is everything. When I got mine, the extras were several times more than the pi.
0そうだね
プレイ済み
返信[14]
親投稿
Stewart segludian1
- HDMI cable to hook it to your TV - An SD card to act as the hard drive. - Access to a computer to prepare the SD card. If the computer doesn't have an SD card reader you will need a SD card reader for the computer. You will likely need the privileges to install software (SD formatter). See raspberrypi·org - Keyboard (USB) - Mouse (USB)
0そうだね
プレイ済み
返信[1]
親投稿
Stewart segludian1
It turns out there is already a pre-defined sprite for that. You can look at the attached code to move it around.
0そうだね
プレイ済み
返信[4]
親投稿
Stewart segludian1
Here is my take on what you are trying for, see attached. In the latest screenshot from you, you are using the wrong handles/ids for the 2nd and 3rd spscale and spofs calls. By the way, you don't need to call spscale if you are leaving things at original size. You also don't need to reprint the press A to start message in a loop. Also try to use while/wend, repeat/until, and functions not GOTO.
1そうだね
プレイ済み