Odd that I see FRIEND FUNCTION FILES_CREATED_BYDATE() in the HTML when I view the source of the page...
Printable View
Odd that I see FRIEND FUNCTION FILES_CREATED_BYDATE() in the HTML when I view the source of the page...
I need to clean the code up a bit, I noticed that I left some </p> tags in there that don't belong. I also noticed that the footer doesn't format properly in IE10 like it does in FireFox. For my CSS I used only one sheet to modify all the pages. It's such a small site that I didn't think that I needed one sheet per page. Where do you see the Friend... in the HTML? When I hit F12 in IE I don't see it at all, but then again for the code I'm using:
Code:<pre><code>
'Code
</code></pre>
I figured out why my footer wasn't formatting properly, it was because I had compatibility view turned on in IE.
And now that I look at my HTML some more, I don't have any extra </p> tags in there. I don't know why IE is telling me that I do.
I did a right-click on the page and did a VIEW SOURCE - from IE...
That stuff never would have made it into the HTML in the dev tool - as it was not of good format.
How so? Or how would you improve upon it?
Was it your intent to send the VB functions into the HTML source? I've never seen that - what does that do?
Oh - I'm being stupid - that's what you intended on showing on the page!!
Oops - ignore me!!!
Sorry - backs out of the room quietly...
Lol, yeah I intended to show the vb.net code on the html page. So instead of using JavaScript to parse the vb.net code and show it like this:
vb.net Code:
Dim somecode As Integer = 1 + 2 - 9 (3 * 21)
I was in the DEV TOOL - looking at the HTML and saw error messages about id's and such - wasn't even looking at the actual page as much!
Talk about not being able to see the forest for the trees!
I just realized that I missed a pun, but it's too late now.
I found a computer that my dad gave me the other day that had Win 98 with the most up to date .net framework installed on it was 1.1. Funny how PC's have since changed.
I still have a 5.25" floppy drive around here somewhere. I don't think I have any discs for it, but I do have 3.5" discs, and a computer with a drive for them.
I imagine your house has a room that resembles a mad scientist laboratory with tons of computers, laptops, and drives scattered in a way that only you know where they are.
On a side note, I've never seen a 5.25" floppy before.
Floppy would be the word to describe them - soft case...
Yeah, a lady in my office said that she use to be able to make them wave whenever she'd move them because they were so huge.
I'm working on an XNA pong game, this is what I have so far:
I'm pretty proud because I use a managed game loop and I don't use any bitmaps. So when it's all said an done it will actually compile on a Xbox 360 as well as a Windows Phone. Tomorrow I'm going to start on the logic to move the ball as well as the AI for the cpu player.Code:Option Strict On
Option Explicit On
Imports Microsoft.Xna.Framework
Imports Microsoft.Xna.Framework.Graphics
Public Class Form1
Private grafix As GraphicsDevice
Private effect As BasicEffect
Private quit As Boolean = False
Private player1 As Paddle
Private player2 As Paddle
Private ball() As Paddle
'In XNA the flow is:
'Initialize
'Load Content
'Update <> Draw - Repeat the process until finished
'Unload
'Initializes the graphics device
'This is apart of the Initialize process
Private Function InitializeGraphics(ByRef surface As PictureBox) As Boolean
Try
Dim pparam As New PresentationParameters
pparam.DeviceWindowHandle = surface.Handle
pparam.IsFullScreen = False
Dim grafixAdapt As GraphicsAdapter = GraphicsAdapter.DefaultAdapter
grafix = New GraphicsDevice(grafixAdapt, GraphicsProfile.HiDef, pparam)
InitializeGraphics = True
Catch ex As Exception
InitializeGraphics = False
End Try
End Function
'Initializes the basic effect
'This is apart of the Initialize process
Private Function InitializeEffect(ByVal graphics As GraphicsDevice) As Boolean
effect = New BasicEffect(graphics)
Try
effect.VertexColorEnabled = True
effect.Projection = Matrix.CreateOrthographicOffCenter(0, graphics.Viewport.Width, graphics.Viewport.Height, 0, 0, 1)
InitializeEffect = True
Catch ex As Exception
InitializeEffect = False
End Try
End Function
'Managed game loop set at 60FPS or it executes the code 16.6 times per millisecond
'This is apart of the Update process
Private Sub GameLoop()
grafix.Clear(Color.White)
effect.CurrentTechnique.Passes(0).Apply()
Call Draw()
grafix.Present()
Call MovePaddle()
If quit = False Then
ExecuteAfterPause(CInt(16.6), New MethodInvoker(AddressOf GameLoop))
End If
End Sub
'This draws the two players and the ball
'This is apart of the Draw process
Private Sub Draw()
grafix.DrawUserPrimitives(PrimitiveType.LineList, player1.Primative, 0, 1)
grafix.DrawUserPrimitives(PrimitiveType.LineList, player2.Primative, 0, 1)
End Sub
'This updates the location of the paddle
'This is apart of the Update process
Private Sub MovePaddle()
player1.Y_Location = PointToClient(MousePosition).Y - CInt(player1.Length / 2)
player2.Y_Location = player1.Y_Location
player1.Primative = Set2dLine(player1.X_Location, player1.Y_Location, player1.Z_Location, player1.X_Location, player1.Y_Location + player1.Length, player1.Z_Location, player1.Color)
player2.Primative = Set2dLine(player2.X_Location, player2.Y_Location, player2.Z_Location, player2.X_Location, player2.Y_Location + player2.Length, player2.Z_Location, player2.Color)
End Sub
'This starts a new game
'This is apart of the load process
Private Sub NewGame()
player1 = New Paddle
player2 = New Paddle
With player1
.Color = Color.Black
.Length = 50
.X_Location = 5
.Y_Location = CInt(pb_surface.Height / 2) - CInt(.Length / 2)
.Z_Location = 0
.Primative = Set2dLine(.X_Location, .Y_Location, .Z_Location, .X_Location, .Y_Location + .Length, .Z_Location, .Color)
End With
With player2
.Color = player1.Color
.Length = player1.Length
.X_Location = pb_surface.Width - player1.X_Location
.Y_Location = player1.Y_Location
.Z_Location = player1.Z_Location
.Primative = Set2dLine(.X_Location, .Y_Location, .Z_Location, .X_Location, .Y_Location + .Length, .Z_Location, .Color)
End With
End Sub
'This function simply draws a line
Private Function Set2dLine(ByVal x1 As Integer, ByVal y1 As Integer, ByVal z1 As Integer, _
ByVal x2 As Integer, ByVal y2 As Integer, ByVal z2 As Integer, _
ByVal color As Color) As VertexPositionColor()
Dim vertices1, vertices2 As New VertexPositionColor
vertices1.Position = New Vector3(x1, y1, z1)
vertices1.Color = color
vertices2.Position = New Vector3(x2, y2, z2)
vertices2.Color = color
Return {vertices1, vertices2}
End Function
Private Sub Form1_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
If InitializeGraphics(pb_surface) AndAlso InitializeEffect(grafix) Then
Call NewGame()
Call GameLoop()
End If
End Sub
End Class
Public Class Paddle
Private x As Integer
Public Property X_Location() As Integer
Get
Return x
End Get
Set(ByVal value As Integer)
x = value
End Set
End Property
Private y As Integer
Public Property Y_Location() As Integer
Get
Return y
End Get
Set(ByVal value As Integer)
y = value
End Set
End Property
Private z As Integer
Public Property Z_Location() As Integer
Get
Return z
End Get
Set(ByVal value As Integer)
z = value
End Set
End Property
Private _len As Integer
Public Property Length() As Integer
Get
Return _len
End Get
Set(ByVal value As Integer)
_len = value
End Set
End Property
Private _color As Color
Public Property Color() As Color
Get
Return _color
End Get
Set(ByVal value As Color)
_color = value
End Set
End Property
Public Property Primative As VertexPositionColor()
End Class
I need to figure out how to handle getting rid of all the components when the user 'x' out of the game though.
Beaver
MOAR MERMAIDS!!!
http://fc01.deviantart.net/fs26/i/20...y_KillWOLF.jpg
I've submitted three new things in the past day and a half, I've been busy!
Oh and I've also started my website on Monday too.
Jeez Louise
print ("I'm learning Python now!")
Well I feel proud of myself. In about a day I taught myself the basics of Python. I got down: declaring variables, getting input, displaying output, setting up my own functions, setting up classes, and basic IO functions.
python Code:
class person: name = "" age = 0 height_feet = 0 height_inches = 0 weight = 0 david = person david.name = "David" david.age = 22 david.height_feet = 5 david.height_inches = 10 david.weight = 165 print ("Name : " + david.name) print ("Age : " + str(david.age)) print ("Height(ft): " + str(david.height_feet)) print ("Height(in): " + str(david.height_inches)) print ("Weight : " + str(david.weight))
So - I take in the BLANK line is a CODE-BLOCK delimiter - right?
Nope, the interpreter ignores the blank line. The CODE-BLOCK delimiter is the indentation in the class. The same can be said for the loops:
python Code:
i = 0 while i < 9 i += 1 print (str(i))
Ok - that's cool - simple enough...
I knew it had to be "something" that made that CLASS definition END...
Yeah, it kind of confused me because in Visual Basic you have End and then Sub/Function/Class/Module/Etc. and in C# you wrap code in {} so I was kind of confused at first.
Still better than a semicolon.
u dis'in proper SQL?
I've done so much C++ and JavaScript in the past two years that the semi-colon is a natural for me now!