http://www.oxeyegames.com/wiki/index.php?title=RenderSpriteState&feed=atom&action=history
RenderSpriteState - Revision history
2024-03-29T08:55:32Z
Revision history for this page on the wiki
MediaWiki 1.16.0
http://www.oxeyegames.com/wiki/index.php?title=RenderSpriteState&diff=287&oldid=prev
Jeb: /* Example */
2009-12-27T20:35:49Z
<p><span class="autocomment">Example</span></p>
<table style="background-color: white; color:black;">
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr valign='top'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 20:35, 27 December 2009</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 20:</td>
<td colspan="2" class="diff-lineno">Line 20:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>=== Example ===</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>=== Example ===</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div><pre></div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div><pre></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;"> local a,r,g,b = 255, 255, 255, 255</ins></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> if player.isHurt then</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> if player.isHurt then</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> -- tint the player with red color</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> -- tint the player with red color</div></td></tr>
<tr><td class='diff-marker'>-</td><td style="background: #ffa; color:black; font-size: smaller;"><div> <del class="diffchange diffchange-inline">video.renderSpriteState(player.sprite, player.x, player.y, 1.0, 0, 255, 255</del>, 64, 64<del class="diffchange diffchange-inline">)</del></div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div> <ins class="diffchange diffchange-inline">g</ins>,<ins class="diffchange diffchange-inline">b = </ins>64, 64</div></td></tr>
<tr><td class='diff-marker'>-</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline"> else</del></div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div></div></td></tr>
<tr><td class='diff-marker'>-</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline"> video.renderSpriteState(player.sprite, player.x, player.y)</del></div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> end</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> end</div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;"> video.renderSpriteState(player.sprite, player.x, player.y, 1.0, 0, a, r, g, b, player.isFacingLeft)</ins></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div></pre></div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div></pre></div></td></tr>
</table>
Jeb
http://www.oxeyegames.com/wiki/index.php?title=RenderSpriteState&diff=286&oldid=prev
Jeb at 20:34, 27 December 2009
2009-12-27T20:34:34Z
<p></p>
<table style="background-color: white; color:black;">
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr valign='top'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 20:34, 27 December 2009</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 1:</td>
<td colspan="2" class="diff-lineno">Line 1:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>{{VideoMethod</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>{{VideoMethod</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>|</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>|</div></td></tr>
<tr><td class='diff-marker'>-</td><td style="background: #ffa; color:black; font-size: smaller;"><div>video.renderSpriteState(spriteId, x, y[, scale[, angle[, a, r, g, b]]])</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>video.renderSpriteState(spriteId, x, y[, scale[, angle[, a, r, g, b <ins class="diffchange diffchange-inline">[, mirrored]</ins>]]])</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>|</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>|</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Renders a sprite at the given screen position.</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Renders a sprite at the given screen position.</div></td></tr>
<tr><td colspan="2" class="diff-lineno">Line 14:</td>
<td colspan="2" class="diff-lineno">Line 14:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>{{MethodParam|g|Optional integer|The green pigment of the diffuse color, defaults to 255.}}</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>{{MethodParam|g|Optional integer|The green pigment of the diffuse color, defaults to 255.}}</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>{{MethodParam|b|Optional integer|The blue pigment of the diffuse color, defaults to 255.}}</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>{{MethodParam|b|Optional integer|The blue pigment of the diffuse color, defaults to 255.}}</div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;">{{MethodParam|mirrored|Optional boolean|Set this to true if you want the image to be flipped.}}</ins></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>|</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>|</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Returns nothing.</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Returns nothing.</div></td></tr>
</table>
Jeb
http://www.oxeyegames.com/wiki/index.php?title=RenderSpriteState&diff=126&oldid=prev
Jeb at 09:07, 9 March 2009
2009-03-09T09:07:30Z
<p></p>
<table style="background-color: white; color:black;">
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr valign='top'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 09:07, 9 March 2009</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 22:</td>
<td colspan="2" class="diff-lineno">Line 22:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> if player.isHurt then</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> if player.isHurt then</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> -- tint the player with red color</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> -- tint the player with red color</div></td></tr>
<tr><td class='diff-marker'>-</td><td style="background: #ffa; color:black; font-size: smaller;"><div> video.<del class="diffchange diffchange-inline">renderSprite</del>(player.sprite, player.x, player.y, 1.0, 0, 255, 255, 64, 64)</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div> video.<ins class="diffchange diffchange-inline">renderSpriteState</ins>(player.sprite, player.x, player.y, 1.0, 0, 255, 255, 64, 64)</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> else</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> else</div></td></tr>
<tr><td class='diff-marker'>-</td><td style="background: #ffa; color:black; font-size: smaller;"><div> video.<del class="diffchange diffchange-inline">renderSprite</del>(player.sprite, player.x, player.y)</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div> video.<ins class="diffchange diffchange-inline">renderSpriteState</ins>(player.sprite, player.x, player.y)</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> end</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div> end</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div></pre></div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div></pre></div></td></tr>
</table>
Jeb
http://www.oxeyegames.com/wiki/index.php?title=RenderSpriteState&diff=124&oldid=prev
Jeb: Created page with '{{VideoMethod | video.renderSpriteState(spriteId, x, y[, scale[, angle[, a, r, g, b]]]) | Renders a sprite at the given screen position. | {{MethodParam|spriteId|An integer|The s...'
2009-03-09T09:00:27Z
<p>Created page with '{{VideoMethod | video.renderSpriteState(spriteId, x, y[, scale[, angle[, a, r, g, b]]]) | Renders a sprite at the given screen position. | {{MethodParam|spriteId|An integer|The s...'</p>
<p><b>New page</b></p><div>{{VideoMethod<br />
|<br />
video.renderSpriteState(spriteId, x, y[, scale[, angle[, a, r, g, b]]])<br />
|<br />
Renders a sprite at the given screen position.<br />
|<br />
{{MethodParam|spriteId|An integer|The sprite ID.}}<br />
{{MethodParam|x|A number|The x coordinate for the sprite's hotspot.}}<br />
{{MethodParam|y|A number|The y coordinate for the sprite's hotspot.}}<br />
{{MethodParam|scale|Optional number|The scale of the sprite, defaults to 1.0.}}<br />
{{MethodParam|angle|Optional number|The angle (rotation) of the sprite, measured in radians. The sprite will rotate around its hotspot.}}<br />
{{MethodParam|a|Optional integer|The alpha component of the diffuse color. Use this to blend the sprite with the background.}}<br />
{{MethodParam|r|Optional integer|The red pigment of the diffuse color, defaults to 255.}}<br />
{{MethodParam|g|Optional integer|The green pigment of the diffuse color, defaults to 255.}}<br />
{{MethodParam|b|Optional integer|The blue pigment of the diffuse color, defaults to 255.}}<br />
|<br />
Returns nothing.<br />
}}<br />
=== Example ===<br />
<pre><br />
<br />
if player.isHurt then<br />
-- tint the player with red color<br />
video.renderSprite(player.sprite, player.x, player.y, 1.0, 0, 255, 255, 64, 64)<br />
else<br />
video.renderSprite(player.sprite, player.x, player.y)<br />
end<br />
<br />
</pre></div>
Jeb