• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.
Sign in to follow this  
Followers 0
cyril98

c# need help with libary

3 posts in this topic

hi guys i have been making a libary because i have been sick to death of using game maker
i need help with a few things

with the stealth in the game libary how do i make it so it goes up as you get closer to the enemy
is it like step MUL +1

i have been using ron pentons book to make the libary but instead of making the GSS3k im making a platform like rpg

and how do i make it so that when ever you pick a character the player becomes that character
do i make like a dummy class or use some sort of variable

and how do i utilize the functions on the keyboard
i tried to make a function called keypress

example

keypressEnter
keypressQ

and how on gods earth do i make a collision

like when a projectile collides with a oncoming foe
or when the player jumps off a building and hits the ground

and how do i make it so you can save the game by the click of a button

mind you im quite new to c#

if you want i can give you my code to look at to give you an idea of what im making
0

Share this post


Link to post
Share on other sites
There's quite a bit you need to learn before you can get into doing most of what you outlined in your post. I would suggest picking up a book on C# (since it's what you're learning, and it's a perfectly fine language) and starting with the basics and work your way up to collisions and player-characters and stealth-systems.

I know there are a lot of good tutorials out there, try searching the forum to get an idea of which ones people have found useful.

Good luck!
0

Share this post


Link to post
Share on other sites
[quote name='cyril98' timestamp='1354149000' post='5005150']
with the stealth in the game libary how do i make it so it goes up as you get closer to the enemy
is it like step MUL +1
[/quote]
That's not C# syntax, if you're trying to port over coding style from game maker.
You would need to write a function that compares player location to enemy location and calculates an arbitrary "detectable" score or percentage based on some algorithm you choose (i.e. negative linear relationship: as distance shrinks, detection grows; or exponential: large range of non-detection that rapidly increases as you get within 5 feet, etc)

[quote name='cyril98' timestamp='1354149000' post='5005150']
and how do i make it so that when ever you pick a character the player becomes that character
do i make like a dummy class or use some sort of variable
[/quote]
Some sort of variable? Almost always.
It depends on how you're defining the "player". Often the player themself is an abstract data concept, and the "player" you see in the game is just a game asset assigned to the player's input and stats. You can swap 3d models or 2d sprites out all you want if the player class has a "model" or "sprite" variable.

[quote name='cyril98' timestamp='1354149000' post='5005150']
and how do i utilize the functions on the keyboard
i tried to make a function called keypress
[/quote]
Just naming a function with the word keypress has no impact on how the compiler builds the code. You'll want to use an existing library that knows how to hook into the PC's messaging queue to intercept keyboard actions. SharpDX/SlimDX and SFML's c# wrapper all come to mind as making the keyboard available.[quote name='cyril98' timestamp='1354149000' post='5005150']
and how on gods earth do i make a collision
[/quote]
You write a physics library (not recommended) or you use an existing physics library. With where you're at, I'd honestly say just write a few simple physics-like constraints, for example ignoring a player's move command if they're trying to send their avatar through a wall. Either way you'll be busy writing some code.[quote name='cyril98' timestamp='1354149000' post='5005150']
and how do i make it so you can save the game by the click of a button
[/quote]
You write code for displaying the button, you write code that saves out whatever data you've deemed important to a "save game" file, and you call your save function inside some kind of onClick event the button owns.

Long story short: it sounds to me like you're used to an environment (game maker) where a lot of things are already written in low level code, and you're essentially scripting them contextually. C# is not a game library, it's not a framework, and it has no idea what a game, physics, keyboard, savegame, etc even ARE. It's a language that gets compiled into commands your PC understands. It's up to you to define all those things, or use a library/framework that does some of that definition for you. You made a BIG jump from game maker. NoAdmiral's point is very appropriate: if you're new to C#, you need to learn how to program in C# before tackling a game library.
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0