summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Spilsbury <Sam@ACER-SUSE.SUSE>2007-11-17 13:37:11 +0900
committerSam Spilsbury <Sam@ACER-SUSE.SUSE>2007-11-17 13:37:11 +0900
commit420eff03822249b1174095df2882ff8e3c129359 (patch)
tree0f7cb3283d99c39c1f69e3d17c0634a583c9193e
parent21817bb2fd56dc23f146c0c637f43125a28a2e72 (diff)
downloadstars-420eff03822249b1174095df2882ff8e3c129359.tar.gz
stars-420eff03822249b1174095df2882ff8e3c129359.tar.bz2
* Add ability to change offset of stars
-rw-r--r--star.c6
-rw-r--r--star.xml.in14
2 files changed, 17 insertions, 3 deletions
diff --git a/star.c b/star.c
index 52cd54a..4472715 100644
--- a/star.c
+++ b/star.c
@@ -411,7 +411,7 @@ initiateSnowFlake (SnowScreen *ss,
SnowFlake *sf)
{
/* TODO: possibly place snowflakes based on FOV, instead of a cube. */
- int boxing = starGetScreenBoxing (ss->s->display);
+ //int boxing = starGetScreenBoxing (ss->s->display);
float init;
// speed of star
@@ -420,8 +420,8 @@ initiateSnowFlake (SnowScreen *ss,
sf->zs = mmrand(000, 200, 2000);
//TODO: possibly place stars based on FOV, instead of a cube.
- sf->x = ss->s->width * .5;
- sf->y = ss->s->height * .5;
+ sf->x = ss->s->width * .5 + starGetStarOffsetX (ss->s->display); // X Offset
+ sf->y = ss->s->height * .5 + starGetStarOffsetY (ss->s->display); // Y Offset
sf->z = mmrand(000, 0.1, 5000);
init = mmrand(0,100, 1); //init = distance to center of the screen
diff --git a/star.xml.in b/star.xml.in
index ce1dad8..ea5744e 100644
--- a/star.xml.in
+++ b/star.xml.in
@@ -57,6 +57,20 @@
<min>0</min>
<max>2000</max>
</option>
+ <option name="star_offset_x" type="int">
+ <_short>Star X Offset</_short>
+ <_long>The X point on the screen where stars should start</_long>
+ <default>0</default>
+ <min>-1000</min>
+ <max>1000</max>
+ </option>
+ <option name="star_offset_y" type="int">
+ <_short>Star Y Offset</_short>
+ <_long>The Y point on the screen where stars should start</_long>
+ <default>0</default>
+ <min>-1000</min>
+ <max>1000</max>
+ </option>
<option name="snow_over_windows" type="bool">
<_short>Stars Over Windows</_short>
<_long>Stars are drawn above windows</_long>