{ “cells”: [ { “cell_type”: “markdown”, “metadata”: { “deletable”: false, “editable”: false, “run_control”: { “frozen”: true } }, “source”: [ “# Game Assignment Starter Coden”, “n”, “The purpose of this code is to demonstrate how to construct a structure based on a game map. In this starter code, we will assume that we have three rooms on our game map. The assignment requirements also specify that we have a fail function. Therefore, we will be creating a simple skeleton containing the following elements:n”, “* room_1n”, “* room_2n”, “* room_3n”, “* failn”, “n”, “Our map can be visualized as follows:n”, “
n”, “n”, “~~~n”, ” room_1 –> room_2 –> room_3 (win)n”, ” | |n”, ” `———-`——> failn”, “~~~n”, “n”, “
n”, “n”, “## Part 1: Building up one room at a time (no fail function)” ] }, { “cell_type”: “code”, “execution_count”: null, “metadata”: { “deletable”: false, “editable”: false }, “outputs”: [], “source”: [ “#########################################################n”, “# Constructing room_1 and calling it to start the gamen”, “#########################################################n”, “n”, “def room_1():n”, ” print(“You’re in room_1!n”)n”, ” input(‘
” ] }, { “cell_type”: “code”, “execution_count”: null, “metadata”: { “deletable”: false, “editable”: false }, “outputs”: [], “source”: [ “#########################################################n”, “# Adding room_2 and linking it to room_1n”, “#########################################################n”, “n”, “def room_1():n”, ” print(“You’re in room_1!n”)n”, ” input(‘
” ] }, { “cell_type”: “code”, “execution_count”: null, “metadata”: { “deletable”: false, “editable”: false }, “outputs”: [], “source”: [ “#########################################################n”, “# Adding room_3 and linking it to room_2n”, “#########################################################n”, “n”, “def room_1():n”, ” print(“You’re in room_1!n”)n”, ” input(‘
n”, “n”, “
n”, “n”, “
Part 2: Adding in a fail function and ways to fail
” ] }, { “cell_type”: “code”, “execution_count”: null, “metadata”: { “deletable”: false, “editable”: false }, “outputs”: [], “source”: [ “def room_1():n”, ” print(“You’re in room_1!n”)n”, ” input(‘
n”, “n”, “
n”, “n”, “
Part 3: Adding more functionality to the game
n”, “Let’s update our game as follows:n”, “n”, “* room_1n”, ” * nested conditionaln”, “* room_2n”, “* room_3n”, ” * while loopn”, “* failn”, “n”, “Our game map can be visualized as follows:n”, “
n”, “n”, “~~~n”, ” room_1 <–> room_2 <–> room_3 (win)n”, ” *nc | | *wn”, ” `———-`——> failn”, “~~~n”, “n”, “
” ] }, { “cell_type”: “code”, “execution_count”: null, “metadata”: { “deletable”: false, “editable”: false, “scrolled”: true }, “outputs”: [], “source”: [ “## Tip ##n”, “# make sure to make ample comments throughout your coden”, “n”, “n”, “def room_1():n”, ” print(“You’re in room_1!n”)n”, ” input(‘
” ] } ], “metadata”: { “kernelspec”: { “display_name”: “Python 3”, “language”: “python”, “name”: “python3” }, “language_info”: { “codemirror_mode”: { “name”: “ipython”, “version”: 3 }, “file_extension”: “.py”, “mimetype”: “text/x-python”, “name”: “python”, “nbconvert_exporter”: “python”, “pygments_lexer”: “ipython3”, “version”: “3.8.5” }, “toc”: { “base_numbering”: 1, “nav_menu”: {}, “number_sections”: false, “sideBar”: true, “skip_h1_title”: false, “title_cell”: “Table of Contents”, “title_sidebar”: “Contents”, “toc_cell”: false, “toc_position”: {}, “toc_section_display”: true, “toc_window_display”: false }, “varInspector”: { “cols”: { “lenName”: 16, “lenType”: 16, “lenVar”: 40 }, “kernels_config”: { “python”: { “delete_cmd_postfix”: “”, “delete_cmd_prefix”: “del “, “library”: “var_list.py”, “varRefreshCmd”: “print(var_dic_list())” }, “r”: { “delete_cmd_postfix”: “) “, “delete_cmd_prefix”: “rm(“, “library”: “var_list.r”, “varRefreshCmd”: “cat(var_dic_list()) ” } }, “types_to_exclude”: [ “module”, “function”, “builtin_function_or_method”, “instance”, “_Feature” ], “window_display”: false } }, “nbformat”: 4, “nbformat_minor”: 2}
…
QUALITY: 100% ORIGINAL – NO PLAGIARISM
(USA, AUS, UK & CA PhD. Writers)
CLICK HERE TO GET A PROFESSIONAL WRITER TO WORK ON THIS PAPER AND OTHER SIMILAR PAPERS
About Our Service
We are an online academic writing company that connects talented freelance writers with students in need of their services. Unlike other writing companies, our team is made up of native English speakers from countries such as the USA, UK, Canada, Australia, Ireland, and New Zealand.
Qualified Writers
- At ClassicWritersBay.com, most of our writers are degree-holding native speakers of English who are familiar with various writing styles. Our writers are proficient in many fields, including Economics, Business, Accounting, Finance, Medicine, Chemistry, Literature, Mathematics, Statistics, and many others.
- Making our customers happy is an important part of our service. So do not be surprised if you get your paper well before the deadline!
- We pay a lot of attention to ensuring that you get excellent customer service. You can contact our Customer Support Representatives 24/7. When you order from us, you can even track the progress of your paper as it is being written!
- We are attentive to the needs of our customers. Therefore, we follow all your instructions carefully so that you can get the best paper possible.
- It matters to us who writes for you, and we are serious about selecting the best candidates.
- Our writers are always learning something new, so they are familiar with the latest developments in the scientific world and can write papers with updated information and the latest findings.
Our Guarantees:
- Quality original papers that follow your instructions carefully.
- On time delivery – you get the paper before the specified deadline.
- Attentive Customer Support Representatives available 24/7.
- Complete confidentiality – we do not share you details or papers with anybody else.