This wiki is out of date, use the continuation of this wiki instead

Map block copy

From FenixWiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 20:01, 17 February 2008 (edit)
Eckolin (Talk | contribs)
m
← Previous diff
Current revision (11:03, 11 July 2008) (edit) (undo)
Sandman (Talk | contribs)

 
Line 3: Line 3:
==Definition== ==Definition==
-'''INT''' map_block_copy ( <'''INT''' destinationFileID> , <'''INT''' destinationGraphID> , <'''INT''' destinationX> , <'''INT''' destinationY> , <'''INT''' originGraphID> , <'''INT''' x> , <'''INT''' y> , <'''INT''' width> , <'''INT''' height>, <'''INT''' blitflags> )+'''INT''' map_block_copy ( <'''INT''' fileID> , <'''INT''' destinationGraphID> , <'''INT''' destinationX> , <'''INT''' destinationY> , <'''INT''' originGraphID> , <'''INT''' x> , <'''INT''' y> , <'''INT''' width> , <'''INT''' height>, <'''INT''' blitflags> )
Draws ([[blit]]s) a rectangular block from one [[graphic]] onto another graphic. Draws ([[blit]]s) a rectangular block from one [[graphic]] onto another graphic.
Line 11: Line 11:
== Parameters == == Parameters ==
{| {|
-| '''INT''' destinationFileID || - The [[fileID]] of the [[file]] that holds the destination graphic.+| '''INT''' fileID || - The [[fileID]] of the [[file]] that holds the destination and origin graphics.
|- |-
| '''INT''' destinationGraphID || - The [[graphID]] of the [[graphic]] to draw on. | '''INT''' destinationGraphID || - The [[graphID]] of the [[graphic]] to draw on.
Line 21: Line 21:
| '''INT''' originGraphID || - The [[graphID]] of the [[graphic]] to draw with. | '''INT''' originGraphID || - The [[graphID]] of the [[graphic]] to draw with.
|- |-
-| '''INT''' x || - The x-axis of the upperleft corner of the origin block.+| '''INT''' x || - The x-coordinate of the upperleft corner of the origin block.
|- |-
-| '''INT''' y || - The y-axis of the upperleft corner of the origin block.+| '''INT''' y || - The y-coordinate of the upperleft corner of the origin block.
|- |-
| '''INT''' width || - The width of the block in pixels. | '''INT''' width || - The width of the block in pixels.
Line 40: Line 40:
== Errors == == Errors ==
{| {|
 +| Invalid origin graph || - The origin graph is invalid.
 +|-
 +| Invalid destination graph || - The destination graph is invalid.
 +|-
| Unsupported color depth || - The origin graphic's color depth is greater than the destination graph's. | Unsupported color depth || - The origin graphic's color depth is greater than the destination graph's.
|} |}
- 
{{Funcbox {{Funcbox
| category = Maps | category = Maps
}} }}

Current revision


Contents

[edit] Definition

INT map_block_copy ( <INT fileID> , <INT destinationGraphID> , <INT destinationX> , <INT destinationY> , <INT originGraphID> , <INT x> , <INT y> , <INT width> , <INT height>, <INT blitflags> )

Draws (blits) a rectangular block from one graphic onto another graphic.

If the entire graphic is to be blitted, map_put() or map_xput() can be used.

[edit] Parameters

INT fileID - The fileID of the file that holds the destination and origin graphics.
INT destinationGraphID - The graphID of the graphic to draw on.
INT destinationX - Where on the destination graph's x-axis to put the block.
INT destinationY - Where on the destination graph's y-axis to put the block.
INT originGraphID - The graphID of the graphic to draw with.
INT x - The x-coordinate of the upperleft corner of the origin block.
INT y - The y-coordinate of the upperleft corner of the origin block.
INT width - The width of the block in pixels.
INT height - The height of the block in pixels.
INT blitflags - What blit flags to draw the graphic with.

[edit] Returns

INT : true

[edit] Notes

Blit flags can be used to give the drawing (blitting) a special effect.

[edit] Errors

Invalid origin graph - The origin graph is invalid.
Invalid destination graph - The destination graph is invalid.
Unsupported color depth - The origin graphic's color depth is greater than the destination graph's.


Maps Functions
Graphic_info() • Map_block_copy() • Map_clear() • Map_clone() • Map_put() • Map_put_pixel() • Map_xput() • Map_xputnp() • New_map() • Save_png() • Unload_map() •
Personal tools