Making An RPG That Is Checking For Collisions Whenever The User Is Walking?
Aug 1, 2010
Ok I am making an RPG that is checking for collisions whenever the user is walking...Basically i made an array of points in which the user is not allowed to access and if they do try to access them it will not walk...
Public Class cityshop2010
Dim abletomove As Boolean = True
Dim moveto As Point
Dim badpoints(1) As Point
[code]....
with that code there I want to be able to say badpoints(0-50) or badpoints (0 to 50) whatever... or even badpoints(*) for any badpoint....How do i make it check all the badpoints?
I would like to make a simple application that allows to make a file or if it already exists displays a error. This is the code a use. But the problem here is that it does not always shows the error. Code:
I have been searching the internet for a few days now, looking for ways to solve my problem, but I can't find anything. What I am trying to do is make my sprite walk. The way I did this was I made multiple GIF's with my characters different movements, but when I try to switch which ones are showing by releasing an arrow key, it does not do anything. Does anyone have a solution for this? My code so far is below, but it only lets me switch to the running GIF and not to the standing one.
Well I attempted collision detection and it was only ok. First of all only the out of bounds place would work because I just made the right side of the screen make you go left etc.My moving button also goes outside of the area for a brief second before it teleports back to the bounds + 3 or w/e.Never mind all of that I guess.Could someone give me some source code for the simplest way to do collisions from all angles (like a zelda game or something...) or just up/down or left/right (like in pong).
i am trying to make a game in vb.net and so far have managed to create a sprite which is animated on key event. the only problem is it able to walk off the form out of site. i want to be able to create some sort of boundary so that when sprite position equals greater or smaller then the form width it can no longer walk in that direction, the same goes for the hight. i have tryed this myself like this
I making an "sign in" application for checking email address with username and password as input.As output it will show me msgbox with content "Your email and password are correct!" or Not.There is a code:
Code: Imports System.Net.Mail Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click[code].....
I making an "sign in" application for checking email address with username and password as input.As output it will show me msgbox with content "Your email and password are correct!" or Not.
I making an "sign in" application for checking email address with username and password from textboxes,and receiving message do username and password are correct or not.There is a code & image:
Imports System.Net.Mail Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click 'Declare variables
Dim Principal As New System.Security.Principal.WindowsPrinipal(New ystem.Security.Principal.WindowsIdentity(My.User.Name))I'm using My.User.Name in the example. I'm aware the My.User namespace has a IsInRole method, however, I well need to check a list of users and not just the current user so can't just use that or WindowsIdentity.GetCurrent. This exception is being thrown when declaring the Principal variable:"There are currently no logon servers available to service the logon request"
I have text box in my program where I need the user to enter at least six characters. They also need to include at least one alphabetic and one numeric character.My idea is to create a loop that uses the IndexOf string manipulation to check each character. I'm familiar with the IsNumeric method .
I am attempting to keep user inputs into our application as clean as possible. One way I am attempting to do this is not allowing incorrect data type in fields (not allowing alpha characters when expecting numeric values)I found and implemented the following code:
Private Sub txtSocial_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSocial.KeyPress Dim UserKeyPress As Char = e.KeyChar Dim isKey As Boolean = e.KeyChar.IsDigit(UserKeyPress)
-User Opens program -User goes to settings.(Settings has a bunch of RadioButtons) -User Customizes settings, checks certain buttons. (How would I pop up a msg when the user clicks "Ok" with out checking something? -When "Ok" is pressed, it will "save" -When settings is opened again, the same RadioButtons will be checked.
Right now, if I exit the settings form, and open it again, the radio buttons are cleared
I am currently trying to develop a chat application which will work on a LAN, however encountering problems with with adding a user through the registration form, always getting the result :: "Datatype mismatch in criteria expression" I've tried checking and cross-checking the datatypes used in both the database(its a .mdb database,, created in Microsoft Access)this is the code i am using:
dim con as new oledbconnection dim cmd as new oledbcommand Public Sub UserReg()
[code]....
everything is done,, such as opening the connection and defining teh data reader, etc as you can see from teh code(which was derived from another question but i made edits to suit my use for it)I also have problems with checking wether a user is online. obviously i will be referring to the table to do that using something like
cmd = new oledbdatacommand("SELECT * FROM Users where isOnline = "Yes") dim sdr as oledbdatareader = cmd.execute reader
whence it will show a list of all the currently "Online users" but i do not how how to quite refer to it?
In my program I've a list of "Time Zone" and I want to make one of that as the default Time Zone when an end user uses the program - ie: everytime he starts the program that Time Zone should be selected ( Of course, he should be able to select another Time Zone temporarily, but his default selection shouldn't be changed unless he wants to do so by changing the default one).
And another user should be able to make another Time Zone as his default Time Zone.
In my program, I give the Time Zones in a ComboBox as follows:
I am trying to make a user control for information received from a database but i get:The class WFUserControl can be designed, but is not the first class in the file. Visual Studio requires that designers use the first class in the file. Move the class code so that it is the first class in the file and try loading the designer again.
Do i make the user control directly and add the code? Because thats what i did.. Or are there steps to do first before creating it?
I wanted to know how I can make a stand alone exe without making the user install the application. So that the program can be ran from a disk or flash drive. Currently I can run it just fine on the PCs, I'm developing it on. But when I take it to another, that has the targeted framework, it crashes.
I would like to make a method excute right before the user get back controle of the program. No matter what chain of events happens i would like to beable to have a method is always the last thing to excute. I plan on using the method to check the form and the data on it. I have no issues righting the method, I just don't know if their is a event or some other way to make sure it is always the last thing to excute. (Sorta like a validation method) Is their an easy way to do this?
Not sure if this is the right Forum to post this question. If not guide me where to post... I have an Access database that I would like to be able to share with Multiple user cuncurently... I have seen it is being done but I am not sure how? Or may be I should be using SQL Express.
I'm making an application where a user draws a shape on a picture box( this will be saved on a bitmap image), then another user has to draw on that shape (=follow it ) . if the 2nd user goes too far from the line then an error message will appear.
for example( in case i couldn't clarify this well!)the 1st user draws a a vertical line, the 2nd user has to follow it, if-while drawing on it- he gets too far horizontally, there would be the error.
I'm currently thinking of comparing every point by the 2nd user to its equivalent in an array containing the points by the first user.
I'm making a program similar to a wordpad or whatever, but i'm having issues making the user inputs insert at the cursor position instead of at the end.. I'm running DevStudio 5 btw.
Would it be possible to make a webbrowser link to the cookies and such of any windows user account no matter which windows user account you were on. So the user would use a drop down list or something then press a button and be able to switch to another user accounts internet explorer favourites, cookies, and flash cookies, rather than having to log out and then log into another user account?
I'm making a game engine, its coming along pretty nicely, but I'm having trouble with collision detection.. This will be a platform game..I'm using GDI+ for my rendering.My rendering engine, basically draws upon a sprite class I wrote, this class is getting pumped into a collection, then I'm using a for loop to draw the images in the collection..
Code: Private Sub Form1_Paint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles Me.Paint Try For i As Integer = 1 To SCollection.Count Step 1 Dim Image As New Bitmap(DirectCast(SCollection.Item(i), clsSprite).Filename)
basically i fot a form with 5 questions u could say and i got a toolstrip with a progrss bar wat i want to do is as each question is ansered in reality by the user i want the progress bar to go up.
min value is 0 max value is 100 as ther is 5 questions as each questiion is ansered the bar shoul go up by 20 so they anser Q1 it goes up to 20 they answr Q2 it goes up to 40 until they anser the last questyion and the bar is full
I'd like to make a custom control that allows the end user to format the text, similar to an HTML or RichText control. The idea is that it will be static like a label, but allow end user to specify certain tags around words to make them bold, italic, underline, hyperlink, etc, either at design time or runtime. My question more specifically is how to best approach this. My intention is to use GDI+ methods, like DrawString, etc. But my concern is the inefficiency of having to parse the text each Paint cycle to determine which tags are present in order to use the correct font style, etc. I'm not really asking HOW to do this, but more of a hint on which architectural approach to take on this. Maybe there is already some examples of this out there?
I have a ListView with Checkboxes in vb.net and what I want to do is when the user check the checkbox, the program ignore the response of the user in checking the checkbox, instead it leaves the checkbox uncheck.