Advice for Future Private Server Owners and Programmers

09/27/2011 21:00 Spirited#1
Hey. So many people ask me for advice as a beginning programmer. I honestly never answered the question though, not because I was busy but because I didn't know how to word a response that illustrated how I felt until now.

-------------------------------------------------------------------------------------------------

Here's my advice for beginning owners and programmers:

1. Don't tackle the problem head-on with a solution. Analyze the problem first and try to gain an understanding of it, then divide it up into manageable pieces. Big problems are overwhelming, so break it down.

2. You will not get a perfect solution working (most of the time) for challenging problems on the first tackle. It's a trial and error process. Refine your algorithm and try again - you'll get closer and closer to getting the correct solution. Do you think the light bulb was invented on the first try?

3. Build upon the knowledge that you've already acquired. Research into new solutions and find similarities with solutions you already know from previous problems. Don't go too far outside your range of understanding.

4. Eliminate processes that don't fit the requirements of the project. You'll find yourself constantly thinking about solutions to problems or requirements in the project. It's your job as a programmer to eliminate wrong solutions and to develop a solution that will fill the requirements of the project. Make lists or excel books if it's hard to manage.

5. Thinking outside the box will get you far. Our minds are trained to limit thought and to specify rather than to generalize or expand. Most of the best ideas and solutions come from thinking outside the limits you restricted yourself to.

-------------------------------------------------------------------------------------------------

I also want to share with you my way of designing applications. It's not a new concept, but this is how you would prevent yourself from restarting your project over and over again (like I used to).

Step 1: Requirements - analyze the problem and define the problem's needs (inputs and outputs).

Step 2: Design - determine how you're going to approach and solve problems that arise.

Step 3: Implement - code and document the program. Use basic testing as you go.

Step 4: Test - test the solution and formulate algorithms that will solve the problem.

Step 5: Maintenance - fix the problems and test again. Fix bugs that you might of missed in the implementation phase.

If you don't spend enough time in the Requirements and Design phase, you're going to find yourself running into many many problems (like I have been with my previous projects). Take it slow and develop your ideas before you attempt to implement them.

-------------------------------------------------------------------------------------------------

Tips:

1. Make a chart of hierarchical Input and Output. How are classes going to be organized and fetched from different documents / namespaces?

2. If you want to use multiple projects for core algorithms, use the same namespace. Make a chart like above for dependency. DO NOT USE CIRCULAR DEPENDENCY!! Use one way dependency or you will run into many problems (like Impulse's NPC project in his 5165 source but much worse).

3. Use pseudocode if you're going to help someone. They won't improve much unless they build upon what they know. Also, it can be very helpful for you in organizing how you're going to design an algorithm.

4. Use "desk checks" / breakpoint tests. "Desk Check" is the term for walking through a solution (step-by-step). You can do this by setting up a breakpoint. That's how most people debug and test solutions as they implement.

5. There's nothing wrong with making diagrams for your understanding. Nobody expects you to memorize everything about your project or research. Make resources... I mean hell, I made an entire wiki to organize mine. It's more for me than anyone else.

That's all that I can think of atm about programming.

For everyone who ever asked, that's my answer and I'm not repeating it.

-------------------------------------------------------------------------------------------------

As far as making a private server goes... it's all about power management and support.

1. Don't make a server that you cannot handle. Gather support before you organize it on a VPS that you need to pay for. Don't waste your money! I've seen it happen time after time again.

2. Have fun. Don't look at it as just a business. Have fun programming and creating and have fun with your community. I don't think I have to repeat what's been said before about managing your GM powers, but I will anyways. Your GM powers don't belong on your main character if power is a problem for you.

3. Support is important. Listen to comments that your players leave for you. They took time to develop an idea for you, so spend at least a second to read it.

That's it for now.
Good luck.

Sincerely,
Fang

PS: Useful links:

Additional Explanation of pseudocode:

So let's say you have a problem. You know what the solution will be, but you don't know how to get there really. You would use pseudocode to fill that. Pseudocode literally means "fake code". It's like a proof in math. You're going through each step and explaining it in English instead of using mathematical formulas and solving it directly. It helps organize what you need to do to find the solution.
09/27/2011 21:02 BaussHacker#2
I facepalm everytime people come here and post a picture of an exception in their console, because an exception tells you WHERE the error is and WHAT the error is. If you know WHERE and WHAT an error is, then you can use common sense to FIX it, but it seems like it doesn't exist anymore.
09/27/2011 21:22 xBlackPlagu3x#3
Quote:
Originally Posted by BaussHacker View Post
I facepalm everytime people come here and post a picture of an exception in their console, because an exception tells you WHERE the error is and WHAT the error is. If you know WHERE and WHAT an error is, then you can use common sense to FIX it, but it seems like it doesn't exist anymore.
There are exceptions to that (ha get it? Exceptions!? xD) because whenever I get an error I can't solve it's because I don't understand the line of code... for example, on Impulse's 5165 it was a damn packet/pointer line of code. Luckily Fangerz did some magical humbo jumbo magic and fixed it in like 30 seconds. :facepalm:
09/27/2011 21:35 BaussHacker#4
Quote:
Originally Posted by xBlackPlagu3x View Post
There are exceptions to that (ha get it? Exceptions!? xD) because whenever I get an error I can't solve it's because I don't understand the line of code... for example, on Impulse's 5165 it was a damn packet/pointer line of code. Luckily Fangerz did some magical humbo jumbo magic and fixed it in like 30 seconds. :facepalm:
Copy the exception and paste it in Google. I will bet 10 bucks on that there is at least one fix for it, if it's not a custom exception.
09/27/2011 22:28 Spirited#5
I added a quick explanation for pseudocode. Here's a quick example though for anyone who's interested in how I do mine:

Code:
BEGIN Main void
READ configuration
DEFINE Socket Protocols (TCP/IP)
DEFINE Socket responses 
START Listening (port 9960)
09/27/2011 22:37 F i n c h i#6
This thread has been posted at 20:00, epic. :awesome:
09/27/2011 22:41 BaussHacker#7
Quote:
Originally Posted by F i n c h i View Post
This thread has been posted at 20:00, epic. :awesome:
Depends on time zones I think. It's not the same for ex. people in the U.S.
09/28/2011 00:08 Yup Stigs#8
u r c# gawd bro. thx meng. this is only like the fourth.. or twentieth.
09/28/2011 00:17 xBlackPlagu3x#9
Quote:
Originally Posted by F i n c h i View Post
This thread has been posted at 20:00, epic. :awesome:
For me it was 12:00, but your post was at 13:37. Now that's epic.
09/28/2011 02:17 CØĐ£Ř||Mã©hÍñє#10
i would say you are not the only one learning and yes anyone who wanted to learn would find his own way so please stop letting us know you are learning c sharp greating we knows you are learning i think its enough?
09/28/2011 03:28 Arco.#11
C# Prodigy here. 10/10
09/28/2011 03:44 Spirited#12
Quote:
Originally Posted by CØĐ£Ř||Mã©hÍñє View Post
i would say you are not the only one learning and yes anyone who wanted to learn would find his own way so please stop letting us know you are learning c sharp greating we knows you are learning i think its enough?
Huh? Why do you have to take everything into offense? Cut the shit. I wrote this because people asked me and it's a long response. In no way was I even thinking that this was bragging. Also, not many real programmers even go by these rules and tips. That's why I wrote it- to inform. Most of this isn't even displaying C# knowledge- it's about problem solving and approaching problems. It can be generalized into anything really.
09/28/2011 04:59 Yup Stigs#13
Kudos Dr. Gareth. These teachings will be of use on my road to enlightenment.
09/28/2011 08:21 xBlackPlagu3x#14
Quote:
Originally Posted by CØĐ£Ř||Mã©hÍñє View Post
i would say you are not the only one learning and yes anyone who wanted to learn would find his own way so please stop letting us know you are learning c sharp greating we knows you are learning i think its enough?
Almost every post from Fang I've read, you leave a nasty comment. Are you trying to be a prick? Who cares what he's doing whether it's to inform that he knows a lot of C# or General Knowledge or whether it's to try to get the E*PvP community back to what most people say, the intellectual days. Seriously lay off the flame on threads bro, it's not needed and it's bloody annoying.
09/28/2011 08:23 EviL|Shepherd#15
Quote:
Originally Posted by xBlackPlagu3x View Post
Almost every post from Fang I've read, you leave a nasty comment. Are you trying to be a prick? Who cares what he's doing whether it's to inform that he knows a lot of C# or General Knowledge or whether it's to try to get the E*PvP community back to what most people say, the intellectual days. Seriously lay off the flame on threads bro, it's not needed and it's bloody annoying.
He gets mad when his server advertisement thread winds up being a "Flame OP" thread. He whines about it...then pulls this shit. Yay hypocrites?