Search found 458 matches

by j_milton
Nov 21, 2010 16:28
Forum: General
Topic: Converting a Keyboard application to Touch screen
Replies: 13
Views: 1197

Re: Converting a Keyboard application to Touch screen

I undersatand that mouse fucntions in FreeBASIC is a bit hard but is there something i can use to allow me to do this with miniume distrubtion to my application? I don't think mouse in Freebasic is really harder than in any other language out there. At a minimum on the input side of things you are ...
by j_milton
Nov 20, 2010 13:34
Forum: Projects
Topic: Clasp Scripting Language for AI Enthusiasts
Replies: 45
Views: 6591

We know a lot about brains from when they go wrong.

I strongly recommend this vid.

http://www.ted.com/talks/jill_bolte_tay ... sight.html
by j_milton
Nov 18, 2010 23:23
Forum: Beginners
Topic: Arrays of images and ReDim
Replies: 3
Views: 580

Re: Arrays of images and ReDim

Kot wrote:What happens to the pictures? Are they destroyed by default or I have to use ImageDestroy to avoid memory leaks?


You need to call ImageDestroy
by j_milton
Nov 15, 2010 23:34
Forum: Beginners
Topic: Comandline-Parser
Replies: 2
Views: 639

The command options are already split apart for you, see the wiki here: http://www.freebasic.net/wiki/wikka.php?wakka=KeyPgCommand so you can write this: dim as string s dim as integer n = 1 do s = command(n) if s <> "" then print n, s n += 1 endif loop until s = "" to pr...
by j_milton
Nov 15, 2010 14:17
Forum: General
Topic: base64 encoding/decoding
Replies: 5
Views: 1013

Re: base64 encoding/decoding

vkthakur wrote:Anybody knows how to perform Base64 encoding/decoding on a file in freebasic?

Will need a little bit of translation to the freebasic dialect:
http://www.source-code.biz/snippets/vba ... er.bas.txt
by j_milton
Nov 15, 2010 13:23
Forum: Beginners
Topic: Trouble with pointers
Replies: 4
Views: 530

Ok can some one elaborate on some of the uses of pointers and how they can effect the flow of the program Sometimes you know when writing a program how much data you are going to need to store in variables, so you can use simple variables defined like this: Dim as integer x or perhaps arrays define...
by j_milton
Nov 14, 2010 19:50
Forum: General
Topic: [solved not implemented] How to use operator [] with UDT ?
Replies: 4
Views: 525

I'm pretty sure that Freebasic does not allow things like the function call or array subscript operators to be redefined. Closest in form,and fast I would think would be to write it as an array of pointers: type vector x as single y as single z as single d(0 to 2) as single Pointer Declare C...
by j_milton
Nov 14, 2010 17:13
Forum: Beginners
Topic: How to avoid nested functions?
Replies: 10
Views: 1227

I wrote up a quick and dirty benchmark with the various methods suggested so far and did repeated runs (Windows XP SP3). Just judging by eye, no hard statistics, I can't see any of the methods being significantly faster. In some runs I get up to a 30% difference in run times between the first and se...
by j_milton
Nov 14, 2010 2:51
Forum: Beginners
Topic: How to avoid nested functions?
Replies: 10
Views: 1227

Re: How to avoid nested functions?

Hello, I am playing with one of my programs, trying to make it as fast as I can. The program is processing data coming from various files, and there may be two different types of files (each type requires a different processing). I wrote two different functions, each function is specialized into pr...
by j_milton
Nov 12, 2010 2:39
Forum: Game Dev
Topic: Dungeon generation using CA
Replies: 19
Views: 6443

pretty shapes, but it seems to often generate "unreachable" areas, generally seen as a bad thing...
by j_milton
Nov 10, 2010 13:41
Forum: Projects
Topic: Clasp Scripting Language for AI Enthusiasts
Replies: 45
Views: 6591

http://en.wikipedia.org/wiki/File:Control_Systems.png http://en.wikipedia.org/wiki/Least_mean_squares_filter http://en.wikipedia.org/wiki/Steepest_descent http://en.wikipedia.org/wiki/Backpropagation http://en.wikipedia.org/wiki/SHRDLU http://en.wikipedia.org/wiki/Cyc http://en.wikipedia.org/wiki/A...
by j_milton
Nov 09, 2010 22:44
Forum: General
Topic: Inventory Control Program
Replies: 5
Views: 505

I am in the process of writing some general purpose database stuff... Save this file as "data_table.bas" #Define boolean Integer #Define FALSE 0 #Define TRUE Not FALSE #Define index Integer Type data_table Private: key_code As String attributes As String content (0 To 1008) As String '1009 s...
by j_milton
Nov 09, 2010 20:52
Forum: Beginners
Topic: C to Basic converter?
Replies: 4
Views: 2566

seems it's available commercially (No this is not spam, I have no interest in this company)
http://www.tangiblesoftwaresolutions.co ... tails.html
by j_milton
Nov 08, 2010 12:58
Forum: General
Topic: Questions About Running Total
Replies: 16
Views: 1291

I see a problem, described in that snippet: If d1 = 1 and d2 = 1 Then If d1 + d2 = 2 Then 'Two 1's rolled ' {snip} Else 'A single "1" rolled ' ' THIS CODE WILL NEVER RUN !!! ' ' {snip} EndIf Else ' {snip} EndIf It should be like: If d1 + d2 = 2 Then 'Two 1's ...
by j_milton
Nov 08, 2010 2:10
Forum: General
Topic: Questions About Running Total
Replies: 16
Views: 1291

See if this makes sense: 'Tyler Verkade 'CO 116 'Created November 5, 2010 'The Dice Game "Pig" 'Game Totals "C" is computer "H" is human Dim As Integer gtotalc, gtotalh gtotalc = 0: gtotalh = 0 'Assorted Variables Dim As Integer d1, d2, turn_finished, turn_total, c Dim ...

Go to advanced search