Game Maker Language リファレンス > 組み込み関数 用途別 > 2D グラフィック機能 > draw_button
draw_button() †
- 対応:5.3A
6.0
6.1A
7.0
- lite OK
書式 †
draw_button(x1,y1,x2,y2,up)
- x1
- 矩形領域の左上x座標
- y1
- 矩形領域の左上y座標
- x2
- 矩形領域の右下x座標
- y2
- 矩形領域の右下y座標
- up
- ボタンのON/OFFの状態を指定。trueが押されていない状態で、falseが押し込んだ状態
戻り値 †
- N/A
- なし
機能 †
(x1,y1)-(x2,y2)を対角線とする矩形領域の大きさのボタンを描画します。
引数upにtrueを指定すると、ボタンが押されていない状態で描画されます。
引数upにfalseを指定すると、ボタンが押された状態で描画されます。
詳細 †
This function will draw a very simple, rectangular "button" using the currently selected draw colour and alpha where the up argument defines how the bevelled edge effect looks, as shown in the image below:
draw_button(100, 100, 200, 150, !mouse_check_button(mb_left));
上記コードはマウスの左クリック状態に合わせてボタンの描画を切り替えています
Wiki内検索
#search(): You already view a search box
MENU
2ch
その他
最新の30件
2024-03-07
2023-08-09
2023-05-21
2023-05-20
2023-05-04
2022-10-13
2022-07-21
2022-07-02
2022-04-06
2021-11-30
2021-11-26
2021-10-03
2021-09-23
2021-08-15
2021-06-02
2021-01-23
2021-01-21
2021-01-19
2021-01-18
2021-01-16
2021-01-15
人気の10件
今日の10件
これまでの訪問者: 2173
今日の訪問者: 1
昨日の訪問者: 1
閲覧者: 2