Jump to content
Xtreme .Net Talk

Epo

Members
  • Posts

    7
  • Joined

  • Last visited

Everything posted by Epo

  1. Epo

    C++ or C#

    Rather simple :) Which do you guys prefer for writing DX apps/games/utilities/time-wasters :) Until now I've been a devoted C++ fan (VB before that), but the more I look around, the more I see the pound sign instead of two addition signs. :) So I was just hoping to get some of your thoughts on this. What do you use? Any specific reason? Anything else you'd like to share? :)
  2. Maybe this would be a better question...how would I go about colouring in individual pixels at a time? Thanks again :)
  3. I'm pretty sure I'm referencing it properly. I went into Project->Properties and selected it (double clicked) then clicked on Ok. And System.Drawing is showing up in the References tree at the side....although....I'm not quite sure what you mean about Importing it...I'm still getting the Invalid type problem... I was trying to go for simplicity before, but here's what I'm really shootin for :) (I was hoping to get it slightly working then move onto this, but it looks like that's just making it more complicated) :) I have coordinates, X and Y. I have a continuous loop running checking (X,Y) if it is a black pixel or not. If it is a black pixel, I change it to red. The X,Y coordinates are changed by pressing keys on the keyboard. (Is the FormPaint still the way to go?) I'd also like to mention I've been using .Net for about two days now :) So thanks for being patient :) Here's my code just so you can see the minimal coding I've done (and haven't) :) Public Class Main Inherits System.Windows.Forms.Form Private Structure Player Dim X As Integer Dim Y As Integer Dim R As Integer Dim V As Integer End Structure Dim P As Player() Dim bRunning As Boolean = True Dim G As Graphics = Me.CreateGraphics() '''''''''''''' Private Sub Main_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Me.WindowState = Windows.Forms.FormWindowState.Maximized P(1).X = 100 P(1).Y = 100 P(1).V = 0 P(1).R = 0 While bRunning End While End End Sub Protected Overrides Sub OnKeyDown(ByVal e As System.Windows.Forms.KeyEventArgs) Select Case e.KeyCode Case Windows.Forms.Keys.Escape bRunning = False End Select End Sub End Class (Lines with ' marks have errors)
  4. I am trying to make a fullscreen app that will just display a Colour whenever you click on the Form. So I guess my graphics object is my main Form...I was hoping to just use GetPixel and SetPixel API's like in VB6 (those were the days) :) But I guess It's a bit different now... I tried the "Dim g as Graphics..." line but I get an error saying "Graphics" is a non-defined type...
  5. Hullo there, I've been trying to incorporate the SetPixel API into my VB app, but I have to problems: 1) "Inherits System.Drawing.Bitmap.SetPixel" does not work because Intellisense spits out that I can only have one "Inherits" per Class. It also does not appear in my Project->References box to be selected, so, I'm just wondering, am I going about it the wrong way? And what's the right way? :) 2) ...I forget...I think just the first one will do, and as soon as I get that figured out, whatever my second question was, will be fixed too :) Thanks for any insight :)
  6. Yes, that's what I meant, and thanks, I'll download that. I was sure that I installed the SDK off the CD though (when installing the program), but I guess not. Perhaps it's something else, perhaps I have no idea what I'm talking about) :) I'll check out the link and hopefully I'll be able to move past step 1 Thanks :)
  7. Just wondering what to do if the references don't show up when in Project->Add References (Using VB.Net). I installed every component of the Visual Studio .Net so, I guess I just assumed that would be included. But it does not seem to be the case. Any ideas on where I could go to get the proper files so that the References show up? Or if this doesn't make sense, tell me that too :) I've been using VB.Net for 30 minutes, so let's just say, I'm a noobie for now :) Thanks :)
×
×
  • Create New...