Programming help/tips


(Sometimes I dream of cheese ᕕ(☯෴☯)ᕗ) #1

Tips/help for people who are trying to learn programming for Thrive.

Angelscript:

C++

General Programming:

Other Languages:

  • W3Schools

    • Link: https://www.w3schools.com/
    • Price: Free
    • Platform: Web
    • Languages: HTML, CSS, Colors, Graphics, JavaScript, JSON, Python, Bootstrap, jQuery, AngularJS, SQL, XML
    • Suggested By: @blackjacksike
      That website is excellent for learning web programming. The library is not very big, but it isn’t so small neither. The library includes: HTML, CSS, Colors, Graphics, JavaScript, JSON, Python, Bootstrap, jQuery, AngularJS, SQL, XML, etc. In addition, the tutorials are very interactive. More precisely, you can try codes and have a test at the end of each lesson. To conclude, that website is web oriented and is great for learning.

Software & Tutorials [Read the description, then put your "ideas" in here]
#2

There is a few links for beginning programming here: http://thrivegame.wikidot.com/how-to-help


(Sometimes I dream of cheese ᕕ(☯෴☯)ᕗ) #3

Thanks! I’ll be sure to look at it. By the way which programmin language does Thrive use as of now?


#4

After the engine switch, C++ and AngelScript (which I chose because it is so much like C++).


(Sometimes I dream of cheese ᕕ(☯෴☯)ᕗ) #5

Do you have any direct links to sites that teach C++ or Angel Script and which one do you think is more important to learn first.


#6

AngelScript isn’t very popular so there aren’t good beginners tutorials for it (the manual is basically a reference for people who know how to program in some language and shows how everything works in AngelScript). I started with C++ but many people don’t recommend it. I would also recommend learning to program first before worrying too much about a language as it is very easy to learn new ones once you have developed the programming mindset. Python is very popular so it is a good choice to start learning programming.

I haven’t read any python tutorials (I just search every time how something works in python and go from there). But here’s a few C++ ones I’ve read and can vouch that they are pretty good (at least the parts I’ve read): http://www.cplusplus.com/doc/tutorial/ http://www.learncpp.com/ https://www.cprogramming.com/


(Johnatan Darwin) #7

I recommend learning easier programming languages and scripting languages first. (Python, Lua, HTML etc.) Starting with C++ is a mistake, as I have tried that before, just like you, but now I don’t think it’s the way you should do it. Either way, take whatever I said with a grain of salt. http://www.sololearn.com teaches Python, HTML/CSS/JS and C++ all for free with no extra subscriptions. I recommend it. Good luck :smiley:!

EDIT: Sololearn has phone apps too.


#8

This is actually a markup language, not a programming language.

I started serious programming with C++ (before that I had do some basic mainly copy-paste type stuff in Garry’s Mod WireMod expression 2). And I’ve also heard a few others, so it can be done.

I quickly checked that out and at least personally I really hate the style of quizzes they have. You should much rather make real programs that do interesting things to keep your interest. But if the sololearn style of getting points and achievements for moving forward motivates you, it seems like a good website.


(Johnatan Darwin) #9

I like sololearn: I think it’s the ultimate way to learn in my eyes. But either way, now I know HTML is a markup language then and also good job on starting C++. (I assume you also took studies at your school/high school etc.)


(Sometimes I dream of cheese ᕕ(☯෴☯)ᕗ) #10

Thanks guys, this will help alot!


(Johnatan Darwin) #11

Good luck :smiley:


#12

For anyone still curious. Try this: https://www.udemy.com/free-learn-c-tutorial-beginners/learn/v4/overview Its a pretty good tutorial with quite high video quality for the time of which it was made.


("Belgium isotope" "Achievement hunter" "King of badcalls") #13

You can also go on tutorialspoint.com


("Belgium isotope" "Achievement hunter" "King of badcalls") #14

Well, there’s the manual guide that beginners can use.

Here: https://www.angelcode.com/angelscript/documentation.html


(𝑻𝒉𝒆 𝑱𝒐𝒍𝒍𝒚 𝑬𝒎𝒑𝒆𝒓𝒐𝒓 𝒐𝒇 𝑺𝒆𝒂𝒇𝒐𝒐𝒅) #15

Did you just…

REVIVE A DED THRED???


#16

That was complete on topic and due to the low volume of posts on this forum I think it is completely fine to post in the correct thread, even if it is old, instead of making a new one.

The manual is only good for beginners to AngelScript. It isn’t a proper tutorial for programming. So everyone who is interested in learning AngelScript needs to first learn a language that has complete programming beginner tutorials and then check out the AngelScript manual to see how similar it is to languages in the C family. The wiki has some programming tutorial links here: http://thrivegame.wikidot.com/how-to-help (which I have posted already in this thread)


("Belgium isotope" "Achievement hunter" "King of badcalls") #17

Learn to code websites (the ones I know)

Tutorialspoint

Type: Free

Platform(s): Web

Link: http://www.tutorialspoint.com/

That website has a great library of tutorials from Computer Science to History. Even though there is some tutorials about history, chemistry or physics, most of the tutorials are about computers and programming. Most of programming languages are in the library: C, C++. C#, Python, HTML, CSS, Lua, JavaScript, Brainfuck, etc. The only downside is that the tutorials aren’t interactive enough, thus it might be better to have some programming experience before going into a tutorial or to use the website especially for documentation. In brief, tutorialspoint has many tutorials on most programming languages, but they aren’t so interactive (you can try codes, but you cannot have a lesson after each chapter).

W3Schools

Type: Free

Platform(s): Web

Link: https://www.w3schools.com/

That website is excellent for learning web programming. The library is not very big, but it isn’t so small neither. The library includes: HTML, CSS, Colors, Graphics, JavaScript, JSON, Python, Bootstrap, jQuery, AngularJS, SQL, XML, etc. In addition, the tutorials are very interactive. More precisely, you can try codes and have a test at the end of each lesson. To conclude, that website is web oriented and is great for learning.

SoloLearn

Type: Free

Platform(s): Web, iPhone, Android, Windows Phone and Facebook.

Link: https://www.sololearn.com/

That website is good for learning, because it is very interactive. You have many exercises in each lesson and you can try codes. However, that website has not a huge library. The library includes: C++, C#, Java, Python, Ruby, Swift, HTML, CSS, JavaScript, jQuery, PHP and SQL. In other words, SoloLearn doesn’t have many tutorials, but they are very interactive indeed.

Other learn to code websites (the ones I don’t know)

Codecademy

Type: Freemium

Platform(s): Web

Link: https://www.codecademy.com/

Tutlane

Type: Free

Platform(s): Web

Link: https://www.tutlane.com/

Tutorialsteacher

Type: Free

Platform(s): Web

Link: http://www.tutorialsteacher.com/

YouTube Channels for programming and software

thenewboston (computer & programming): https://www.youtube.com/user/thenewboston

TheHappieCat (computer & programming): https://www.youtube.com/user/TheHappieCat

TJ FREE (Software presentation): https://www.youtube.com/user/tjopen1

If you want to find an alternative software, you can go on this website: https://alternativeto.net/ .

That’s all! If you want to, you can put other sources of informations, so everybody who wants to learn programming, graphics and stuff can go on this thread and choose their own path.


Software & Tutorials [Read the description, then put your "ideas" in here]
#18

I made the first post of this thread a “wiki” post so anyone who wants to add links there, should be able to now (as long as you have been on the forum for a while to get trust levels).


("Belgium isotope" "Achievement hunter" "King of badcalls") #19
Also, if some of you (readers who are interested in programming) want to learn programming progressively on tutorialspoint, there is one tutorial called Computer Programming teaching general programming with C, Java and Python as references. When you finish this tutorial, it will suggest you these three languages as starting points (thus, you can then go from C to C++ if you want to contribute to Project Thrive).

(He who abuses the search function) #20

Well, if we’re talking about help with code anyway: I have a question. I’m currently working on a small game in Unity (as a school project). I built in a simple pathing system, where the enemies have two points (called “origins”) at either side. Every frame, a RayCast (basically a laser that gives information on whatever it hits.) of 2 units long is cast out of both origin points. The RayCastHits are lSight (what the left feeler “sees”) and rSight (the same but for the left feeler). Then, it checks whether they hit anything, or not, and turns accordingly. The code is (by head currently, I don’t have the code with me right now):

Totally not convoluted code
 if (rSight)
 {
   	if (lSight)
 	{
		if (rSight.collider = lSight)
		{
			dir = leftRightTest();	 //a function I found online that checks whether the object is on the left or right
		}
		else
		{
			dir = 0 ;				//Both see something, but it's something else, so it's safe to move straight ahead
		}
	}
	else 
	{
		dir = -1;					//There is only something on the right, so turn to the left
	}
}
else if (lSight)
{
	dir = 1;						//There is only something to the left, so turn right
}
else
{
	dir = 0; 						//Nothing is seen, so move straight ahead
}
Transform.Rotate(0, 45 * Time.deltaTime * dir); //Turn the proper direction with an RPS of 0,125

This works, but the issue is that, well, it’s ridiculously ugly. So, does anyone know if there is a way to make it less ugly? I’ve though about a for-loop, but I don’t think you can make one with multiple (boolean) variables.

(I was originally planning on posting this on “Dev Team Requirements”, since it’s kinda on-topic, but then I realized this thread exists. I could’ve also posted it on “bad code examples”, but that is a bit to off-topic)