Please create an account or Login! Have fun!

C2G: Difference between revisions

Jump to navigation Jump to search
26 bytes removed ,  6 February 2019
m
Formatting fixes
(Created page with "'''C2G''' files are a file extension used by Chip's Challenge 2. Despite the C2G extension, C2G files are plain text and can be edited with any text editor. While individ...")
 
m (Formatting fixes)
Line 49: Line 49:
map "AwesomeLevel.c2m"</nowiki>
map "AwesomeLevel.c2m"</nowiki>
In the example above, the text will be displayed in-game like this:
In the example above, the text will be displayed in-game like this:
<center>THE FOLLOWING LEVEL</center>
<center>
<center>USES SOME REALLY</center>
THE FOLLOWING LEVEL<br>
<center>CLEVER TRICKS AND</center>
USES SOME REALLY<br>
<center>IS GUARANTEED</center>
CLEVER TRICKS AND<br>
<center>TO BE ENJOYABLE</center>
IS GUARANTEED<br>
 
TO BE ENJOYABLE<br>
</center>HAVE FUN!</center>
&nbsp;<br>
HAVE FUN!
</center>
The text "some are also evil" is a comment and will not be displayed. After the text is displayed, the game will then load the level in the file AwesomeLevel.c2m
The text "some are also evil" is a comment and will not be displayed. After the text is displayed, the game will then load the level in the file AwesomeLevel.c2m


Line 83: Line 85:


For each inventory, "<#>" is a 4-byte number in which each byte represents a different inventory slot. Its value can be calculated as follows:
For each inventory, "<#>" is a 4-byte number in which each byte represents a different inventory slot. Its value can be calculated as follows:
  (tool 1 code OR red key count)
<nowiki>&nbsp;&nbsp;(tool 1 code OR red key count)
+ (tool 2 code OR blue key count) * 256
+ (tool 2 code OR blue key count) * 256
+ (tool 3 code OR yellow key count) * 65,536
+ (tool 3 code OR yellow key count) * 65,536
+ (tool 4 code OR green key count) * 16,777,216
+ (tool 4 code OR green key count) * 16,777,216</nowiki>
Or if you know hexadecimal, just write it out as a hex integer in little-endian order, then convert to decimal - CC2 does not read hex literals.
Or if you know hexadecimal, just write it out as a hex integer in little-endian order, then convert to decimal - CC2 does not read hex literals.


trusted-editors
4

edits

Navigation menu