Chapter 1: Developing Your First Game - Learn VB .NET Through Game Programming [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

Learn VB .NET Through Game Programming [Electronic resources] - نسخه متنی

Matthew Tagliaferri

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
توضیحات
افزودن یادداشت جدید







Chapter 1: Developing Your First Game



Overview



To Get Things Rolling right from the start, you’ll write a complete (albeit small in scope) game in this chapter. This game will consist of a single die rolling around in a black panel and an end user guessing the outcome of the die (see Appendix A, “The Basics of Visual Basic,” to create a simple project in a step-by-step fashion.




Figure 1-1: The Guess the Die Roll game in all its glory






Note


As you go through the code for this first program, you may find you don’t agree with all the design decisions made along the way or with how the code is organized. As it turns out, I’ve gone out of my way on this first program to write the code in a distinctly non-object-oriented style. I’ve done this so you’ll have a point of comparison when you rewrite the same game in Chapter 2, “Writing Your First Game, Again.” So, if you’re new to the .NET language, concentrate on the individual language elements and constructs, as well as the features of Visual Studio (VS), and pay less attention to the form and structure of this first program.




When you saw Figure 1-1 with its slick 3D-rendered die, I hope you said to yourself “Oooh, that’s pretty cool.” This book covers the VB .NET language and object-oriented development using simple games as examples. In other words, this book doesn’t teach how to develop the next Quake killer. However, a small game can still become extremely popular if it’s done well and if it’s fun to play. Done well means that the graphics, sounds, and overall design of the game are interesting, unique, funny, or all three. Funtoplay is of course a matter of opinion, so the games you write will have to at least pass your own “fun meter”—and then perhaps you can try them out on family, friends, and coworkers to get their input.


/ 106