Main Menu


Sponsored Links

  


  
  
Web Cartoon Maker: a Fun Way to Learn C++ Contents Previous Next

Table of Contents

Copyright Information 2

Support Web Cartoon Maker 2

Table of Contents 3

Introduction 7

About Web Cartoon Maker 7

What is a Programming Language? 7

What is Debugging? 10

Formal and Natural Languages 11

Our First Cartoon 13

WCM C++ Program Structure 13

Hello World (as promised) 14

Compiling 15

Variables, Types and Operators 17

More Output 17

Variables, Types and Operators 20

Values 20

Variables 21

Assignment 21

Outputting Variables 23

Operators 25

Order of Operations 27

Operators for Characters 27

Operators for Strings 28

Functions 29

Math Functions 29

String Functions 30

System Time Functions 31

Cartoon Time Functions 31

Composition 33

Adding New Functions 33

Definition and Uses 34

Programs with Multiple Functions 35

Parameters and Arguments 35

Function Parameters and Variables are Local 36

Functions with Multiple Parameters 37

Functions with Results 37

Making Real Cartoons 38

Image Objects 38

Coordinates 40

Methods to Work with Image and Text Objects 45

Methods Unique to Text Objects 52

Methods Unique to Image Objects 54

Summary 54

Character Objects 54

Summary 60

Playing Sounds 60

A Complete Cartoon 62

Size of an Animated Cartoon 68

Camera 69

Conditionals 72

Objects as Function Parameters 72

Conditional Execution 73

Alternative Execution 73

Chained Conditionals 74

Nested Conditionals 74

Working Example 75

Fruitful Functions 76

Recursion 76

The Return Statement 78

Return Values 79

Composition 80

Overloading 81

Boolean Values 82

Boolean Variables 82

Logical (Boolean) Operators 83

Converting Bools to Strings 83

Bool Functions 84

Leap of Faith 85

Iteration or Loops 85

Iteration 85

The While Statement 85

Increment and decrement operators 86

For Loops 87

Break Statement 88

Continue Statement 89

Cartoonish Example 90

Classes and Objects 92

Introduction 92

The “Point” Class and Objects 93

Accessing instance variables 94

Operations on Objects 94

Call Pass by Value 97

Call Pass by Reference 98

Classes as Return Types 99

Constant Parameters 99

Passing Other Types by Reference 100

Member Functions or Methods 100

Converting Functions to Methods 101

Constructors 102

Initialize or Construct 104

Protected Data 104

Inheritance 107

Custom Characters 108

Introduction 108

Changing Walking Style 111

Customizing a Character's Decals 113

Changing a Decal 114

Making a new character 116

Making Advanced Characters 120

Support Web Cartoon Maker 120

References 121






Contents Previous Next
  
News

New Tales Animator Video by Alan Sturgess

Alan Sturgess shared an excellent video he made using Tales Animator! You can still download Tales Animator here. Unfortunately it is only available for Wi

...

Simple Online Character Designer

There is a prototype of simple online character designer available HERE. It is only a prototype, it does not contain many pieces yet but it can already generat

...

Book is updated

Now our book "Web Cartoon Maker: A Fun Way to Learn C++" is fully in synch with WCM 1.5! It is available for download and online reading HERE.

...

Web Cartoon Maker 1.5 is here!

Web Cartoon Maker 1.5 is finally here! You can download it HERE! Here is what was updated in version 1.5: Web Cartoon Maker Desktop Edition is now fully standal

...

read more news...


Poll