FAQ

From C4 Engine Wiki

Jump to: navigation, search

There is also a less technical FAQ page.

Contents

General Questions

What language does C4 use?

The C4 Engine itself is written entirely in C++. For level design, there is a graphical scripting language built into the engine that can be used to script sequences of actions.

How complicated is C4?

If you have a fairly good grasp of C++, then using the C4 Engine should be pretty straightforward for you. The engine has a very clean programming interface, and several examples for using various features ship with the engine. The math knowledge needed to use the engine isn't really that high—if you understand how points are transformed from one coordinate system to another using a 4×4 matrix, then you're in good shape.

What documentation exists for C4?

We have a documentation library that contains per-function descriptions of the C4 Engine programming interface, and this wiki contains overviews and tutorials about various programming and art-related tasks. There is a book about C4 entitled The Beginner's Guide to the C4 Engine.

Is the C4 Engine suitable for my game?

The C4 Engine is designed to be very generic in nature, so you're definitely not restricted to just one type of game (such as FPS, RPG, or RTS). The current C4 demo is an example of a first-person shooter (FPS), but that is simply because we like those kinds of games, not because of any limitations in the engine.

The demo contains code for both a first person camera and third person camera (bind an appropriate key in the Control Settings to use it).

Does C4 have a suitable physics engine for my game?

Yes, the engine contains a full-featured built-in physics system that supports rigid body dynamics, force fields, joints, cloth simulation, and water simulation. The engine also provides standard collision detection functionality and has special support for characters and projectiles.

It is possible to disable the built-in physics system and use a third-party physics library without any performance penalty.

Is there a list of planned features?

Yes. See the Official Roadmap.

How often are updates released?

Updates to the C4 Engine occur on an irregular schedule. There can be as little as a few days between updates or as much as a couple months. Historically, we have released 5–10 updates per year.

Does C4 use any environmental audio effects?

Yes, C4 has its own built-in audio system that is capable of advanced effects such as reverberation and atmospheric attenuation. It uses a custom multithreaded software audio renderer. The engine no longer contains any support for vendor-specific libraries like EAX. This gets rid of all the headaches associated with supporting different hardware, buggy drivers, and poorly designed APIs. Furthermore, it means that the audio experience is identical on all machines, so testing across a wide spectrum of sound hardware is not necessary.

Will C4 support the Ogg audio compression format?

There are no plans to support Ogg because of the CPU expense. However, the engine supports application-defined streaming and decompression classes, so it would be easy to add by anyone who wants to use a 3rd party library.

Graphics Questions

Is it possible to disable features so that C4 runs on graphics cards older than the minimum requirements?

No. Just forget about GPUs older than a GeForce 6 or an ATI Radeon HD 2x00. And don't even think about Intel GPUs.

Why does the engine seem to be running slower than expected for me?

There are several things that could be causing the engine to run slower than it should be. First, always make sure that you have the latest drivers for your graphics card. The latest drivers for Nvidia and ATI graphics chips can be downloaded at the following locations.

Get latest Nvidia drivers

Get latest ATI drivers

You should also make sure that other drivers, such as those for your monitor and motherboard chipset, are up to date.

If you have more than one monitor connected to your computer, disabling the secondary monitor can often give you a huge speed boost. In multi-GPU configurations, turning off SLI or Crossfire can also cause a gain in performance (yes, we meant turn off).

If the engine is still running slow for you (possibly because you have one of the lower-end cards supported), then try disabling rendering features and lowering quality levels in the Graphics Options dialog. Disabling motion blur and glow effects will give you the best speed-up. On lower-end cards, make sure high quality bump mapping and parallax mapping are turned off.

Is C4 ever going to support conventional light maps?

No. The limitations of static light maps make them unsuitable for a next-generation engine. The C4 Engine has newer, more dynamic lighting features. Additionally, new algorithms and techniques are continually being explored for future versions of the C4 Engine.

Does C4 have a HDR render path? What about post processing?

C4 contains a post-processing system that enables several particular effects, including full-scene motion blur, glow and bloom, color transform, and distortion effects. High-dynamic range (HDR) support will be added in the future.

I'm seeing shadow artifacts on a model I imported. What's wrong with it, and is this a bug in C4?

This is not a bug. C4 uses a stencil shadow algorithm as one of its methods for casting shadows. All meshes must be completely closed for stencil shadows to work correctly, meaning that every edge in a mesh must be shared by two faces.

What version of OpenGL does C4 use?

C4 doesn't require a particular version of OpenGL above 1.1, but it requires the following extensions in addition to OpenGL 1.1. (Some of these became core features in OpenGL 1.2, 1.3, etc.)

GL_ARB_multitexture
GL_ARB_fragment_program
GL_ARB_vertex_program
GL_ARB_framebuffer_object
GL_ARB_packed_depth_stencil
GL_ARB_vertex_buffer_object
GL_ARB_texture_cube_map
GL_ARB_texture_rectangle
GL_ARB_texture_compression
GL_ARB_texture_border_clamp
GL_ARB_shadow
GL_EXT_blend_color
GL_EXT_blend_func_separate
GL_EXT_draw_range_elements
GL_EXT_multi_draw_arrays
GL_EXT_stencil_wrap
GL_EXT_texture3D
GL_EXT_texture_edge_clamp
GL_EXT_texture_compression_s3tc

To support terrain rendering, the OpenGL implementation needs to support either GL_NV_fragment_program_option or GL_EXT_shader_texture_lod.

For Nvidia hardware, all of these requirements are satisfied by the GeForce 6 series and higher. For ATI hardware, these requirements are satisfied by the Radeon HD 2x00 and higher.

Information about different generations of Nvidia and ATI graphics processors can be found here: Nvidia ATI

Tools Questions

How do I get the World Editor and other tools to work?

See C4 Menu.

You can also hit Ctrl-N (to open a blank world) or Ctrl-O (to open an existing world) from the main menu or most open GUI windows.

All the tools can also be accessed from the command console.

How do I import models into C4?

C4 can read the Collada format. See Collada Plugins. You can import a Collada file (with the .dae extension) by placing it inside a subfolder of the Import directory and selecting Import Scene from the World menu in the World Editor.

Are there plans to support more 3D file formats?

No other formats are officially supported at this time. You must be able to export directly to the Collada format, or convert to it somehow, in order to bring externally created models into C4. However, the World Editor supports import plugins, so it's possible to write your own plugin to read any format you want. (The official Collada importer is written as a World Editor plugin.)

Personal tools