蜜蜂路线图c语言思路,打蜜蜂(c语言)(Hit the bee (C language)).doc

打蜜蜂(c语言)(Hit the bee (C language))

打蜜蜂(c语言)(Hit the bee (C language))

打蜜蜂 (c语言)

# includes "stdio.h"

# includes graphics.h > <

int tanke _ size = 30, star _ size = 30;

int guan _ ka = 1; / * 1: 2: 3: blue green red light blue 4: 5: fen red 6: 7: 8: zong white light white * /

int tanke _ current _ x, tanke _ current _ y;

int tanke _ left = 20, tanke _ right = 620, tanke _ top = 20, tanke _ bottom = 450.

int fist _ star _ x, fist _ star _ y;

int zidan _ current _ x = - 1, zidan _ current _ y = - 1, zidan _ color = 4;

int mifeng _ x [6] [18], mifeng _ y [6] [18].

int mifeng _ count = 0;

void main ()

{

int i, j, k;

int first _ star _ x = 50;

int first _ star _ y = 50;

chushihuagraphics ();

rectangle (tanke _ left 1, tanke _ top 1, tanke _ right + 1, tanke _ bottom);

tanke _ current _ x = 290; tanke _ current _ y = 410.

createtanke (tanke _ current _ x, tanke _ current _ y);

/ * createstar (100100); * /

for (i = 0; i < 6; i + +)

{

for (j = 0, j < 18; j + +)

{

createstar (first _ star _ x, first _ star _ y, - 1);

mifeng _ x [i] [j] = first _ star _ x;

mifeng _ y [i] [j] = first _ star _ y; / * printf ("(% d% d)", mifeng _ x [i] [j], mifeng _ y [i] [j]); * /

first _ star _ x + = star _ size;

mifeng _ count + +;

}

first _ star _ x = 50;

first _ star _ y + = star _ size;

} / * printf ("% d", mifeng _ count); * /

startgame ();

getchar ();

}

createstar (int x, int y, int color)

{

int to _ x = x + 1, _ y = y;

int b _ x = x + 2, b _ y = y + 10.

int c _ x = x + 7, c _ y = y + 30.

int d _ x = x + 22 d _ y = y + 30.

int and _ x = x + 28, and _ y = y + 10.

int temp _ color;

time _ color = getcolor ();

if (a = = - 1)

{

setcolor (x% 8 = = 0? x + 1, x% (8);

}

else

{

setcolor (color);

}

line (_ x, _ y, c _ x, c _ y);

line (_ x, _ y, d _ x, d _ y);

line (b _ x, b _ y, d _ x, d _ y);

line (b _ x, b _ y, and _ x, and _ y);

line (c _ x, c _ y, and _ x, and _ y);

setcolor (temp _ color);

}

createtanke (int x, int y)

{

int twidth = 4, tem _ color;

tem _ color = getcolor ();

if (getcolor (). = getbkcolor ())

{

setcolor (2);

}

r

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值