Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - combatking0

Pages: 1 2 [3] 4 5
41
Projects / Grapher
« on: December 12, 2010 »
I have been developing a graphical function display program. I know there are some out there, and there may even be a few available for free, but I wanted to see if it could be done, and I have found the following to pose quite a challenge - Actionscript 2 has no mathematical evaluation function!

In JavaScript, we have eval() for converting a string containing a mathematical function into a numerical result. In Actionscript, the eval() method is used for converting a string into an object reference.

As such, I have had to build my own mathematical evaluator to make this work. So far, it recognises power (^), multiplication (*), division (/), addition (+) and subtraction (-) symbols, but it does not yet recognise brackets :( I plan to include this functionality soon.

The Y scale is currently manual. I plan to make this automatic by default, with a manual option to allow the user to zoom into view the results.

To use the program, simply run it under Windows 2000, XP, Vista or 7. Other operating systems may also work, if they support Win32 exes.
Next you must set the X and Y limits. By default, these are both set to -10 to 10.
Next you must enter at least 1 function in one of the "Y=" boxes.
For example, 0.9*x+3 would result in a linear graph.
Also, x^2-5 would result in a curved graph.

If you think this sort of thing would be useful to you, please test it out, and let me know what needs to be changed to make it more useful.

So far, I plan to add bracket recognition to the function parser, an automatic Y-Scale option, more lines on the graph output, and to re-arrange the positions of the text inputs and Plot button to make it look better. If I have missed anything, please tell me.

42
Java,JS & Flash / [FLASH] MP3 Playlist Player
« on: November 06, 2010 »
At http://barcodebattler.co.uk/jukebox I have created a working Flash MP3 Playlist Player.

If anyone is interested in the source code, or in having this on their own website, please let me know.

(update) I have updated this to V1.2 now - it has a track position slider. Youtube has one for video, so it must have been possible for audio, yet so few of the online MP3 players have them.

43
Yabasic / Teaching my son BASIC
« on: July 13, 2010 »
I have started to teach my son BASIC using our PS2. I'd use the C64, but it's in the loft and I cannot reach it :(

Still, he's learning about classic commands such as PRINT, GOTO, FOR, NEXT, IF, THEN and ENDIF.

I'm tempted to move him onto a more contemporary language as soon as he's got the hang of variables and arrays, but he's only 6.

I started coding at 7 - am I pushing him too fast?

44
General chat / It's a girl!
« on: June 19, 2010 »
My wife has had a cesarean section, so she'll be unable to perform her duties as wife for a while.

The knock on effect is that I now have to take on the role of full-time parent, so I might not be around here much for a few weeks.

Sophie (I think we've agreed on this name) was born early this morning, weighing 2lb 13oz, so they're keeping a close eye on her. She's doing well apparently, so all I need to worry about is my other two.

45
I have attempted to describe an SQL injection attack prevention mechanism for PHP enabled websites, but the forum interprets it as an SQL injection attack, so I have included the original post as a TXT file.

Does it look like something useful, as part of a wider range of security measures?

46
After seeing the amazing variety of entries, I decided to try something a bit different and combine light with water, to create a Rainbow Fountain.

Sorry for the low framereate - Flash doesn't seem to like rendering 2001 objects very quickly, otherwise I would have put a nice background in too, but it was slowing the framerate even more.

(updated)

47
I've been writing a fault & equipment database at work, and I discovered a PHP function which effectively runs an NSLookup based on the client's IP address.

The returned hostname is then checked in the database to find out which room the user is posting from, allowing the user to report a fault in their room with a single click, rather than looking for their room from a big drop-down box.

I'll put some sample code up on Tuesday when I get back into work.

The PHP command is:
$hostname = gethostbyaddr($_SERVER['REMOTE_ADDR']);

No good for internet, but great for intranet scripting.

48
Projects / Present Drop
« on: November 26, 2009 »
With all the uncertainty round at the moment, I'm hitting the Christmas coding rush early and making a festive scrolling shoot-em-up.

I've got some ideas, mainly the use of Rudolph's nose as a laser which takes 5 seconds to recharge, and Christmas pudding "bombs" which are dropped on enemies, but I'm not sure what to use as a projectile for a machine gun.

I'll have a playable demo up tomorrow night, hopefully with a full version ready for Christmas - and it will be SMF Arcade compatible :)

49
General chat / Computer parts
« on: November 22, 2009 »
Can anybody reccomend a cheap but reliable place to buy RAM?

Specifically I'm after 2* 1GB of DDR 333MHz or faster. It's for a Dell desktop motherboard. I think it has 184 pins - I'll need to count them properly.

I have bought RAM from eBay before, and it worked, but I'm not really into risk taking.

50
Challenges & Competitions / [Spooky] Pastrygeist
« on: October 31, 2009 »
According to the forum, my entry has missed the deadline. However, XILO don't update the time on their servers to account for BST/GMT changes, so as I post this it is about 11:20 at night.

I'll leave this to the discretion of the admins and mods.

Here is my entry: Try to find all 16 hidden pictures by typing in scary words.

(edit: added screen shot)

51
This was as bad as I could make it and still have something interesting.

52
Other languages / Not covered - Apple Dev SDK
« on: July 28, 2009 »
I've been given almost £2k worth of equipment and software to make iPhone and iPod Touch Apps at home. It's a shame I don't have a desk to put it all on.

I'm currently using:
A MacBook Pro with OS X 10.5.7 + USB Mouse and keyboard, as I don't like the built in devices.
A Windows Laptop to view the tutorial videos, + another USB mouse and keyboard, same reason.
32GB iPod Touch for testing my home-brew apps.

It's all set up at the foot of my bed at the moment. I'll put a picture up of it all soon.

The only problem is, I don't work from home, so I have 3 hours a day at most to learn and code. The SDK uses "Objective C" and "Cocoa" programming languages, which are quite different to anything I've used before.

Since the languages used aren't covered in any other part of the forum, I thought I'd put this here. If it's too messy, I'll understand if it is moved.

53
Java,JS & Flash / What do you use to code Flash?
« on: July 27, 2009 »
Which version of Macromedia / Adobe Flash do you use?

If it isn't one of the above, what is it called, and what version does it output?

I use Flash 8, which is installed on my laptop from work on their site license.
I also have a private copy of Flash 9, but I lack the hardware to run it.

54
Java,JS & Flash / [FLASH] Maltesers
« on: July 26, 2009 »
Some have noted that one of my contest entries looks like Maltesers.

So I took it a bit further.

55
Challenges & Competitions / [MAGNIFICATION] C60
« on: July 23, 2009 »
Here is my entry into the Magnification Challenge. It is a "3D" model of the Buckminsterfullerine molecule, or C60 as it is also known.

I think it may be the deepest magnification yet entered into the competition, which I hope counts for something :)

[edit]
I have put a comma after .:Druid:.'s name, added the .swf file and altered the depth-swapping conditions. The flickering is reduced, but still noticable. If I reduce it too much, depth-swapping will be delayed too much and it will look even stranger.

[edit 2]
Zip file fixed :)

56
Because certain other languages I'm used to currently lack features I require, I'm building a semi-complicated Java Applet to listen to the audio input (either mic or line-in) of a computer, store 0.5 seconds of data, analyze it, and return a string.

I'm having difficulty setting up a repeating counter, which should be called every 0.1 of a second. This is just a test.

Here is my code: (indented with tabs, but they haven't shown up on here)
Code: [Select]
import java.applet.*;
import java.net.*;
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
import java.io.*; // for ByteArrayOutputStream
import javax.sound.sampled.*;

public class test3 extends Applet{
public void init(){
boolean stopCapture=false;
ByteArrayOutputStream byteArrayOutputStream; // Might want to set this as a normal array
TargetDataLine targetDataLine; // Does this select the audio input?
AudioInputStream audioInputStream; // Set up an audio input stream?
SourceDataLine sourceDataLine; // Or does this select the audio input?

ActionListener recPoller = new ActionListener();
Timer poller = new Timer(100, recPoller);
poller.start();

// captureAudio(); // Calls the audio capture function

String msg="1";
}

public class dataStore{
int tmr=0;
}

public class something implements ActionListener{
public void actionPerformed(ActionEvent event){
try{
//getAppletContext().showDocument(new URL("javascript:doAlert(\"" + dataStore.tmr +"\")"));
//dataStore.tmr++;
}catch(MalformedURLException me){}
}
}

private void captureAudio(){
try{
// Write something later to catch audio data
}catch(Exception e){}
}
}
I keep getting an error saying
"test3.java:17: java.awt.event.ActionListener is abstract; cannot be instantiated"

Does anybody know what this means or how to fix it?

SUN -> :whack: <- me

57
I'm just testing the waters here - I'm not advertising anything, nor is this ready.

I have been looking into developing online multiplayer flash games. In order to be played in real time, XMLsockets are required to be used.

The lowest price I have found so far for a server which supports this is £120 per year, which is a little bit more than I am willing to pay for.

If there is enough interest, I will develop the necessary Flash and PHP templates, and rent out 150MB portions of the server space and port ranges (2000 ports each) for £5 per year per game.

If successful, we could see all sorts of types of multiplayer games available.

My question is, does this sound a reasonable price to pay to run a multiplayer online game?

58
Here is my entry into the Time Challenge, the Digital Watch Brawl.

Please enjoy.

http://barcodebattler.co.uk/SORR/DigitalWatchBrawl.zip

59
Java,JS & Flash / [Flash] 4D Earth
« on: February 09, 2009 »
I plan to recreate the Earth through the ages using Flash.

I know how to use actionscript to draw lines and polygons procedurally, but I'm not sure how to calculate the X-Y position a point at a given longitude and latitude on the surface.

To compound things, I then wish to allow the user to rotate the globe on two axis, but I'll start with the first question.

I can create the oceans seas by using a psuedo light-sourced "sphere" (a circle with a highlight imported from Fireworks). The rest of the detail will be drawn on top.

60
Projects / Asteroid Dodger
« on: January 26, 2009 »
I've been going on about this for ages, but now it's almost finished.

Please may somebody suggest a good genre of music to go with the game, or a piece of music in the public domain?
You can test it at
http://gbc.barcodebattler.co.uk/play.php?t=Asteroid_Dodger&w=640&h=512&v=8

Please ignore the Submit Score button - it isn't installed on an SMF Arcade yet.

Pages: 1 2 [3] 4 5