473,503 Members | 1,649 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

graphic window checker board game in vb.net

i got board working using graphic window in vb.net but no controls
adding to form. i am doing checker board game. when i clicked and moved
the peg to another location(grid). but how do i get bitmap or image to
make invisible.

here is code for moveevent:

Protected Overrides Sub OnMouseDown(ByVal e As
System.Windows.Forms.MouseEventArgs)
Me.PegPicking = True
If Me.PegPicking = True Then
g.SmoothingMode = Drawing2D.SmoothingMode.AntiAlias
DrawingUtility.DrawPeg(g, New Rectangle(Me.mPosition.X
- 15, Me.mPosition.Y - 15, 30, 30), Me.PelleteColors(0))
g.SmoothingMode = Drawing2D.SmoothingMode.HighSpeed

End If
' Invalidate()
End Sub

Protected Overrides Sub OnMouseMove(ByVal e As
System.Windows.Forms.MouseEventArgs)
' change Position to current mouse Position
Me.mPosition = New Point(e.X, e.Y)
' Repaint to Show Effect
Invalidate()
' End If
End Sub

Protected Overrides Sub OnMouseUp(ByVal e As
System.Windows.Forms.MouseEventArgs)
Me.PegPicking = True
'Inserting Pegs but only is Game is Active
Invalidate()
End Sub

the pb is mouseup event.

regards

Jul 21 '05 #1
0 1959

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1981
by: Supra | last post by:
i got board working using graphic window in vb.net but no controls adding to form. i am doing checker board game. when i clicked and moved the peg to another location(grid). but how do i get bitmap...
6
2818
by: Supra | last post by:
i got board working using graphic window in vb.net but no controls adding to form. i am doing checker board game. when i clicked and moved the peg to another location(grid). but how do i get bitmap...
0
404
by: Supra | last post by:
i got board working using graphic window in vb.net but no controls adding to form. i am doing checker board game. when i clicked and moved the peg to another location(grid). but how do i get bitmap...
2
2105
by: tshad | last post by:
I have an aspx window that is going to open a window (javascript) and display a graphic. I want to resize the window to the size of the graphic before it actually displays - how do I do that? ...
10
12535
by: sam_cit | last post by:
Hi Everyone, I'm working on developing a chess game and i decided to use c++ for its object oriented approach. I have a bass class unit and is inherited to distinct number of units (like king,...
4
20642
by: Hypnotik | last post by:
So I'm writing this program. I have the board constructed, and I'm having a problem making a move. At this point I just want to make a move, I'll work on whether it is a legal move after that. The...
1
1892
by: enp | last post by:
Hello, I am trying to create a board game in C#. I have looked into several different websites for creating a board for my game but I am unsuccessful. can somebody help me with their suggestion...
1
1322
by: nt5515 | last post by:
hey Im trying to make a game of pairs (the memory game) i have set up a grid which displays a graphic for the card back. im trying to link the edit menu to choose the graphic to be displayed. i've...
9
6253
by: ARC | last post by:
Hello all, I developed a tool a year or so ago for adding your own spell-checker to an access application. This is mainly for those using the runtime, as you can't distribute the spell-checker...
0
7319
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6979
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7449
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5570
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4998
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4666
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3149
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
730
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
373
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.