ID:181462
 
Yo I want to code in byond so bad.Where can I learn to code.Someone help me plz.
Read a basic guide on c++. The BYOND guide doesn't address the basics of programming very well. Check the reference for specific BYOND functions. Practice.
Dionlamar wrote:
Yo I want to code in byond so bad.Where can I learn to code.Someone help me plz.

Greetings,

I am not sure if you have already encountered this section of the site, but it does not hurt to reiterate. The Dream Makers is an area in which you can find articles written by various members of our community. On the right side is a list of links that can help you on your journey of learning how to program. The Getting Started and DM Guide are areas frequently suggested to newcomers. If you ever come across a problem that you cannot fix on your own, you can always ask for help on the Developer Forums. But please do note, it is highly recommended to search the forums for problems that are fairly similar to yours that have been solved.
In response to 167981728
167981728 wrote:
Read a basic guide on c++. The BYOND guide doesn't address the basics of programming very well. Check the reference for specific BYOND functions. Practice.

My magic 8-ball says that this is not necessary.

If he wants to learn the basics of programming he could do that separately.He wants to learn to code in DM,telling him to go learn c++ would obfuscate things needlessly.
In response to Master rla
The problem with the DM guide is that it doesn't address enough, the common, basic elements of OOP languages.

What someone NEEDS to understand before working in any OOP language:

-Variables/Operators
-==
-!
-||
-&&
-++
-(--)

-Loops
-While loops
-For loops
-Recursion
-Not making infinite loops

-Conditionals
-if statements
-else statements
-switch statements

-Objects/Ownership
-Objects owning variables
-Objects owning functions
-Objects inheriting variables/functions

-Functions
-Arguments
-Return statements

And a lot of other things I'm too lazy to write down. There's little point in going into the specifics of an OOP language before you understand these concepts, but the DM guide does not teach these things first. What this means is that the DM guide is not a good start for beginners.
In response to 167981728
Variables, functions, loops, and conditionals are not specific to object oriented programming (OOP). The main concepts of OOP are abstraction, encapsulation, inheritance, and polymorphism (the list is sometimes larger, it depends on who you ask).

To begin programming in DM you don't need to fully understand object oriented programming. OOP doesn't enable you to make better games, it just makes them easier to program. If you could look at the source code of all BYOND games, I'd bet that most (if not all) do not fully utilize OOP concepts.

If you want to start programming and have no experience, I suggest you start by writing programs that are useful to you. I guess its not as appropriate now that school is out, but write some programs that would help you with your math homework. These programs are generally simple but can easily grow to be more complex, and they give you an incentive to learn to program. These programs will, depending on what grade you're in and what level of math you're in, introduce you to variables, arithmetic operators, if statements, user input, and possibly loops. It's easier to build on your knowledge once you have some foundation, no matter how small.
In response to Forum_account
I was just mentioning OOP because I have not programmed in a non-OOP language so I really have no right to comment on them. This does not change the fact that you NEED to know all of these things to the fullest extent before you can program in any language.

I never said you shouldn't practice, but practicing alone is not going to properly teach a person all of these techniques.

In any event, my main point was that the DM guide is a horrible place to start. If you disagree with that, then please explain why. Otherwise, stop nitpicking my points please.
In response to 167981728
You can program in an OOP language without understanding the OOP concepts, so experience with such a language may not even give you the "right" to comment on them! =)

Most c++ tutorials will talk about the c++ syntax, c++ development environments, header files, pointers, arrays, console I/O, structs, and other things that don't relate to DM. All of this knowledge that someone new to programming would struggle to learn will be lost the instant they open Dream Maker. Not only will the knowledge be lost, but it will confuse people by giving them incorrect expectations of how things are done in DM.

The DM guide teaches DM from the perspective of learning the language in order to make a game. Because of this it emphasizes certain concepts ahead of others and might be a little bit over someone's head if they have no programming experience at all.

Neither is an ideal place to start but I'd consider the DM guide a much better starting point than a c++ tutorial. Someone with a lot of experience in many languages can easily see the difference in syntax between languages. People with less experience get bogged down in those details. The best starting point would either be DM-specific or not language-specific at all (but that would probably be too theoretical for most). Unless you have a particular c++ tutorial in mind that would show me otherwise, I wouldn't expect one to be very helpful to someone wanting to learn DM as one of their first programming languages.
In response to Forum_account
Most c++ tutorials

Perhaps you're talking about online tutorials, which are terrible and would only be read by a moron. I was talking about actual books on the subject. Any good C++ book is going to start with the basics (the things I listed) which allows you to easily ignore the other things which don't relate to DM. The DM guide is horrible. Seriously, just give that to anyone and see how well it works. It's far too long for such a simplistic language and bogs the reader down in BYOND specific functions rather than teaching the basics of programming. The BYOND reference is excellent and I can't see someone coding in BYOND without ever reading it. The DM guide is godawful and I would never recommend it to anyone.
In response to 167981728
167981728 wrote:
Any good C++ book is going to start with the basics (the things I listed) which allows you to easily ignore the other things which don't relate to DM.

To be able to determine what does or doesn't relate to DM implies that the reader has some understanding of DM.

I'd also like to know how you intend to convince complete strangers to spend $30-50 on a c++ book to help them learn DM. There are some Jedi out there that wouldn't be able to pull that off.

Edit: Considering the purpose of the thread is to recommend ways of learning DM, what books would you recommend?

The DM guide is horrible.

A variation of that statement can be made about any programming resource (guide, tutorial, how-to, etc.). Potential readers of the DM guide have a wide range of academic backgrounds, programming experiences, and learning expectations. Some people who read the DM guide are high school graduates who have been dabbling in c++ and Java for 5 years. They read the guide expecting to learn DM's syntax and built-in features. Other people who read the guide might be 10 years old and never programmed before. They read the guide and expect to learn how to make games.

There are very few statements that can be made about DM that would be useful to both of those people. When you think about the other types of people that might be reading the guide, it becomes almost impossible to write a single statement that would give useful knowledge to everyone. In order to be useful the DM guide, like any good resource, has a narrowed scope. The DM guide might seem horrible to you because it wasn't written for you.

The lesson to learn from this is that the methods you used to learn to program are not the best methods for someone else. It's a good idea to recommend what worked for you (because that means there's a chance it might work for someone else) but don't knock something just because it didn't work for you.
In response to Forum_account
The problem with the DM guide is that it caters to both groups. It honestly should be one or the other. It would be great if the DM guide ignored explaining basic things like loops and focused on DM specific syntax. It would also be fine if it mostly ignored DM specific syntax and explained the basic procedures. Doing both at once, however, just makes it long and tedious. One would learn the syntax better by reading the reference and one would learn the basics better by reading a book on programming. By trying to combine the two the DM guide makes itself inefficient in both aspects.

Also, who says you have to buy the books? We have excellent institutions called libraries which allow you to rent them for free. Otherwise, you could download it if you're totally against paying or getting it from a library.

EDIT: On the topic of books, the most beginner friendly one I've read was Ivor Horton's beginning visual c++. In fact, I'd say it's a tad too beginner friendly.
In response to 167981728
167981728 wrote:
The problem with the DM guide is that it caters to both groups. It honestly should be one or the other. It would be great if the DM guide ignored explaining basic things like loops and focused on DM specific syntax. It would also be fine if it mostly ignored DM specific syntax and explained the basic procedures. Doing both at once, however, just makes it long and tedious. One would learn the syntax better by reading the reference and one would learn the basics better by reading a book on programming. By trying to combine the two the DM guide makes itself inefficient in both aspects.

You should enlighten us on why it'd be a DM Guide if it focused on the basic things and little to nothing to do with the syntax or linguistics of DM. That statement is ridiculous, and you've been making yourself look like a fool this entire time.

The DM Guide may not be the best resource, but I think it's a bit far-fetched to say it's terrible. If anything, it's just outdated. And plenty of people have come out stronger reading the DM Guide--I think it's mostly a matter of how you apply yourself.

Combining the "two" only makes it better, anyway. You can do nothing knowing simply the linguistics of a language (having no prior programming experience) and not how, exactly, each of the mechanisms of the language work together. The same goes for knowing the basics, but not how to use DM to utilize them. It doesn't work either way. Remember, this guide is aimed at beginners.
In response to 167981728
167981728 wrote:
One would learn the syntax better by reading the reference and one would learn the basics better by reading a book on programming.

The problem is that the basics of DM are not the same as the basics of any other language. No c++ guide will explain the relationship between objs, mobs, turfs, and areas, nor will it explain what mob/Login() is, nor will it explain what verbs are.

It would be great if the DM guide ignored explaining basic things like loops and focused on DM specific syntax.

c++ is for general purpose programming. DM is not. For this reason DM gives you a lot of built-in features. These built-in features let you use things in ways that might not be evident from only learning the syntax. For example:

Knowing the syntax of a for loop:
for(Var [as Type] [in List]) Statement
for(Init, Test, Inc) Statement

Does not make it clear that you can do this to enumerate the player's inventory:
mob/verb/inventory()
var/obj/O
usr << "You are carrying:"
for(O in usr)
usr << O.name


For this reason the focus of the DM guide might seem a little scattered but that's almost necessary.

EDIT: On the topic of books, the most beginner friendly one I've read was Ivor Horton's beginning visual c++. In fact, I'd say it's a tad too beginner friendly.

Chapter by chapter, here are the sections that might contain content that's useful to someone new to programming who wants to learn DM:
Chapter 1: nothing
Chapter 2: Calculating in C++, The Bitwise Operators: 18 pages
Chapter 3: Comparing Values, Repeating a Block of Statements: 36 pages
Chapter 4: nothing
Chapter 5: Understanding Functions, Recursive Function Calls: 11 pages
Chapter 6-8: nothing
Chapter 9: OOP Basics, Inheritance in Classes: 6 pages
Chapter 10: nothing
Chapter 11: Adding Debugging Code, Debugging a Program: 13 pages
Chapter 12-20: nothing

Chapters 7 and 8 cover useful topics but the syntax is specific to c++ so it wouldn't be useful for learning DM. At best there might be a few pages that talk about things conceptually before getting into the syntax, but most would would have trouble making that distinction.

There might be 90 useful pages in that book (which is ~1200 pages total). Chapters 2 and 3 make up more than half of those 90 pages, and most of their content is covered adequately by chapter 6 of the DM guide.

What the book does have over the DM guide is: OOP basics, recursion, and debugging. Debugging, or at least basic error interpreting, might be a useful concept for the DM guide because newbies are bound to make mistakes. The other concepts are more advanced and would be better explained in separate documents. Instead of recommending this c++ book, maybe you should write a DM-specific guide to recursion or OOP =)