Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / - DBPro Coding Challenges -

Author
Message
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 5th Apr 2005 09:10
Make Multisync write itself and look like a pet

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 5th Apr 2005 18:13
Dang - are my triangles classed as cute?

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 5th Apr 2005 18:17
No where near as cute Unfortunately I doubt I'll be able to finish my entry I'll still post the current code if I can't

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 5th Apr 2005 18:25
why?

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 5th Apr 2005 18:28
I have kinda done no work over the holidays, so I've got to finish it all. If I do I'll try to enter

KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 6th Apr 2005 02:55
lol at least i have fish for my aquarium code although i still haven't started on the AI

My Website:

RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 6th Apr 2005 05:31
I'm back . Here's my entry.


The R2 units walk around mostly randomly looking for resources to harvest (cubes). When they have enough resources, they make a new R2 unit. The new R2 unit does the same. After a while, the R2 units run low on energy and start looking for energy (spheres) and will ignore resources until they have enough energy. If an R2 unit runs out of energy, they die and become a resource. Reources and Energy cost money. You can sell a random R2 unit for 100 money. Sometimes, there won't be a buyer for an R2 unit, so watch when you sell to see if it got sold.

Purchase Resource: Press [R]
Purchase Energy: Press [E]
Sell one R2 Unit: Press [S]

"Droids don't rip your arms off when they lose." -H. Solo
REALITY II
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 6th Apr 2005 06:14
Its quite amusing watching it go but it seems that it just walks in a straight line, occasionally turning, to find the stuff

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 6th Apr 2005 06:19


Ok, in relation to the other thread and transparent boxes - I have given up on the idea seeing as it seems impossible and am now using memblocks. Using them lots now

Few textures and tweaks mainly.

It now takes longer to have a baby ant (10s instead of 6)
When baby ant is born, parent loses 100% energy.
Baby ants are started when enery is at >200%
Status boxes now semi transparent
Mouse pointer semi transparent

opinions people?

I'm still not sure whether to make this a timed game with points allocated based on born:death ratio or to make it like Ric suggested with two clans of ants and your aim is to make the good (but inherently weaker) ones win.. Humm..

Anywho - opinons peeps?

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 6th Apr 2005 06:23
I can still force them off the edges

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 6th Apr 2005 07:23
HOW?! Lol.. What are you doing to my poor innocent breeding ants?

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 6th Apr 2005 07:24
MUA HA HA HA HA

(move the feeder off the screen foo)

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 6th Apr 2005 07:47
better?



You little bug exploiter (no pun intended)

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 6th Apr 2005 07:53
You ruined the whole thing

KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 6th Apr 2005 08:10 Edited at: 6th Apr 2005 08:14
thats rly awesome man you should continue on with that game whether not in time for deadline or not (i would do that poison idea and make different levels

<edit>
MUCH COOL i like that game lol the new textures and colors are great btw 200 fps

My Website:

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 6th Apr 2005 08:21
cool - I get about 1100fps (The amount my GFX Cost, I should expect that too )

I'm glad it runs well on others though - I was worried that it might bog down a little..

I'm sorry I ruined your fun of making all the little "ants" run away Neofish, but its not the point of the game! Duke Nukem would have sucked if the point was to make Duke run away in a girly fashion

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 6th Apr 2005 09:43
What are you talking about?! "Duke Nukem: Runs Away Screaming" is the best one!

RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 6th Apr 2005 10:20
Okay, fixed the AI a bit so the R2's run after the resources better. New camera angle.


@Neofish. Yes, they do walk in a straight line until they find a resource or energy, then turn to go pick it up. I fixed the AI a bit so they go after the resources better. The R2's have a limited sight range, so they don't go after all the resources, only the ones they "see."

@Nicholas. Like the ants! I do think some challenge is in order for it. Like this pet-sim, once the population is up, it's tough to "lose." I need something too. Not sure what though.

"Droids don't rip your arms off when they lose." -H. Solo
REALITY II
KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 6th Apr 2005 10:23 Edited at: 6th Apr 2005 10:29
Hey just wondering, does any1 here want to join my "business" it is basically for making screensavers and simple games i could use some smart people (hint hint Ric and Nicholas plz plz plz lol) you would get half of money we make (or divided by how many people join) and i will not pay obviously if you dont do anything. I already get paid for having advertisements on my site(not much yet cause not many visitors). And im planning on posting this aquarium game online as free than add a bunch of stuff and say you can have that version for like $5.00 or something good idea but again i say i doubt anyone will join lol

<edit>
what is the sign for not equal to (isn't it "<>"???)

My Website:

Ric
20
Years of Service
User Offline
Joined: 11th Jul 2004
Location: object position x
Posted: 6th Apr 2005 11:20 Edited at: 6th Apr 2005 11:27
Welcome back Rii : Damn robot - EAT MY ENERGY !!! lol - cool game, but they do seem to have a suicidal tendency to get really close to an energy blob, narrowly avoid it then die!! Could you make it so that the bots change colour (say, using set object emissive?) from green to red, to show how much energy they have left? Nice model btw!

I think I've finally decided on my pet-sim .... the idea is to race your pet against others. You will be able to give it an assortment of resources to make it race better (or worse), and you will win money from races to buy more resources. Concept is there - just need to start coding!

@Kimo - it's a great idea to try and make some money from selling a few games, but it's very difficult, given that you can download free games from all over the internet. Having said that, (and please don't take offence from this), if I did come up with any software that I think people will want to spend money on, (and who knows, I might), I'm more likely to sell it through my own website and keep the money for myself! Just the same, if people decide to buy your software, there's no reason why you should share it with anyone else! Good luck with it though.

Next to test Nick's new ant farm update .......
<edit> ...... coming along nicely.

Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 6th Apr 2005 11:25
tis lame, you cant make the ants walk off the screen

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 6th Apr 2005 18:50
Lol - tellyou want neo, how about I release a special version just for you Lemmi-ants..

@Riidii - I'm really not sure where to go with it from here (hence me spending last night tarting it up rather than working on the gameplay

Humm..

Cheers guys though

Its nice to see this thread coming back to life again

My Website:
KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 6th Apr 2005 23:07
@Nicholas
I think that you should make different levels and there are 2 different colors of ant's you have to let the other species of ants die off and keep 1 alive.

My Website:

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 6th Apr 2005 23:26
how do you mean levels?

Do you mean obstacles? Cos that'd be very hard to do - program them to avoid obstacles! Thats verging on professional level AI!

Cheers for the suggestion - but I'm not sure what you mean

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 7th Apr 2005 02:12
Quote: "Lol - tellyou want neo, how about I release a special version just for you"

yay!

Just make them curve off again

KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 7th Apr 2005 02:48
i mean like lvl one there is 5 red ants and 1 blue ant let the red live and blue die
level 2:5red 2blue
level 3:5red 3blue
level 4:5red 4blue
level 5:5red 5blue
and so on

My Website:

Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 7th Apr 2005 03:06
Blue should be the ones surviving

RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 7th Apr 2005 08:40
Okay - here's my entry (unless I get it in my head to do something new).

R2 Rancher
You are an R2 Rancher. For the most part, R2's are fairly easy to take care of. R2's are programmed to run around and collect resources. Once they have enough resources, they make a new R2 for you. All you have to do is provide them with the resources (press [R]) and energy (press [E]). You can sell off your R2's to buyers (press [S]) to make money to buy more resources and energy. In no time, you'll have a heard of R2's roaming your land. Every now and then, you should sell off a bunch of R2's just to thin out the heard, otherwise the R2's will consume all your energy and resources without making new R2's. That's the easy part.
Once you make your mark as a successful R2 Rancher (Money=1000), word gets around. Unfortunately, not all ears belong to freindly creatures. Raiders will start coming around looking to steal your R2's, energy, and resources. Fortunately, once you've established yourself as a bonified R2 Rancher, the authorities allow you to buy Drones (press [D]). Drones defend against raiders quite well. As a matter of fact, those dumb raiders haven't figured out how to beat a drone yet. Drones do need energy and use quite a bit of it, but there is no beating a drone to protect your R2 heard.

Enjoy your R2's!

"Droids don't rip your arms off when they lose." -H. Solo
REALITY II
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 7th Apr 2005 08:57
Sounds good, I might test it later

KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 7th Apr 2005 10:04
well im just getting frustrated if some1 wouldn't mind helping me on my "menu" for selling and equiping items i will give them full credit for this entry even after i put in the AI i just need help with this than i'll throw in the AI before friday and post it and whoever helped me can have the credit(cause i wanna throw some online features on there and than put it on my website thx)


My Website:

Ric
20
Years of Service
User Offline
Joined: 11th Jul 2004
Location: object position x
Posted: 7th Apr 2005 11:09 Edited at: 7th Apr 2005 11:18
That's excellent Rii - really hard once those Raiders come on. Hold on, going to have one more go ......

...... aargh!! Still find myself on a downwards spiral as soon as I hit 1000. The droids are effective, but at a cost of 500 they really hurt the pocket! Really enjoyable game, and well coded. Still would like to see the R2's changing colour from green to red so you know how much energy they have left ..... hold on, wait a mo ......



That kind of thing.

@Kimo - well, you seem to have the menu for 'Buy tank' working ok - what's the problem you're having with the other menus?

KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 7th Apr 2005 11:21
well ya alot of code but íf you hit the over button it goes to the lights menu and that wont work right and i have been working day and night(and im not the greatest coder i know it can be done better).but for specifics for the menu well the variables are labeled near the top and the menu starts at "inventory:" at line 192 if i could have some help (and be notified that help is on the way so i can start on AI and not just drop the project) it would be appreciated.

Thx,
KimoSabi

My Website:

RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 7th Apr 2005 12:42
Hey Ric. Thanks for the color add.
Yeah, the raiders get tough. I haven't beaten them myself, but I think the strategy is to get up to 900 money and a ton of R2's and resources lying around before hitting 1000. Then sell about half the R2's and get up to 2000 money. You can then buy 3 drones right off and still have 500 left for resources. At that point, I think you have a fighting chance. Save up some more money and buy a 4th and 5th drone as soon as possible while keeping your R2 population under control - not too many and not too few. Too many, and you start losing R2's which are money. Too few and you risk losing the game to a raider.

If it proves to be pretty impossible, I think the first fix would be to reduce the chance a raider will appear (around line 101). After that, I'd try reducing the cost of drones.

"Droids don't rip your arms off when they lose." -H. Solo
REALITY II
Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 7th Apr 2005 18:34
I've decided what I wanna do with my game..

Ok, you have different classes of ants.
1. Untrained - does nothing except eat (I base this one on myself )
2. Warriors - Can only attack incomming enemy (see later)
3. Breeders - When their health is above "n" they start creating baby ants that you can train into a class
4. Farmers - These patrol around and create food parcels
5. Medics - These find the closest hurt ant and try to heal it.
6. Bankers - These patrol around and give you a set number of money per second

After say 2 minutes of playing, an enemy "orb" will attack. It will come in from a random angle and start eating your ants (by moving over them). Your warrior ants cant be eaten (they dont taste nice) but they must attack and kill the enemy orb. When an orb eats an ant it gets stronger.

The money the banker ants provide is used to buy things, like houses which means you can have more ants alive Might also allow individual Ant upgrades, etc..

This could be quite a big game

Oh yeah, the save game will be online I think. Future upgrade to the game will be saving to my website. You can then go online and view your own colony, etc. Maybe edit the ants names and stuff Hehe..

How does this sound to peeps?

(I'm only gonna be able to get about 10% of that done for this compo )

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 7th Apr 2005 18:37
Can I be a class? Eats all the food and runs off the map?

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 7th Apr 2005 18:38 Edited at: 7th Apr 2005 18:39
I could make that a cheat..

Type in "NEOFISH" and all your ants run away..

@Neofish: Have you slept yet or did u do another all nighter?

My Website:
Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 7th Apr 2005 18:42
Well I tried to do another all nighter, but everyone who's touched C++ ran offline or is STILL playing UT...so I got stuck...I'm attempting to make a DBP plugin and failing

KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 7th Apr 2005 23:06
that sounds great Nicholas i really wish some1 would help me with my game btw i could make a GREAT encryption code for you to use Nicholas im working on and you can easily tweak it to totally change it

My Website:

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 7th Apr 2005 23:48
Now that would be so unbelievably usefull I think it might make the wheel obselete

I'll try to take a look at your code tonight. I would look now but I'm at work and my brains in PHP mode

My Website:
KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 8th Apr 2005 02:43
ok thx Nicholas

My Website:

Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 8th Apr 2005 02:47
Quote: "my brains in PHP mode"

and what a great mode to be in

Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 8th Apr 2005 06:38
@Kimosabi - I had a look at the code. It worked for buying a tank and a light. What exactly is wrong with it?

My Website:
KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 8th Apr 2005 08:02
well yes you can buy and sell but it just not effective enought(and the selling and equiping doesn't work right) im gonna start working on it a different way tonight unless some1 is willing to help(and it was taking forever just for that little menu)

My Website:

KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 8th Apr 2005 09:27
well here is my encryption code you can tweak it to your liking nicholas and use it on your online game

if there are any questions plz ask and PLZ PLZ COMMENT
also if you go to your darkbasic project folder and look at the txt files it makes you'll see the encryption is very wierd

My Website:

Ric
20
Years of Service
User Offline
Joined: 11th Jul 2004
Location: object position x
Posted: 8th Apr 2005 14:25 Edited at: 8th Apr 2005 14:27
@Nick - those ideas sound good. Have you considered Aardvarks? By the way, I'm the king of the all nighters, for everyone's information.

Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 8th Apr 2005 15:00
Just had another

I actually was productive this time I did 200 lines of C++ some of which I hadn't learnt before


http://dbgamezone.com/pulse / http://neofish.dbspot.com
DONT CLICK THE INTERNAL LINKS, THEY DONT WORK
Ric
20
Years of Service
User Offline
Joined: 11th Jul 2004
Location: object position x
Posted: 8th Apr 2005 16:11
Quote: "Just had another"


Two in a row? Then I must take my hat off to you.

Neofish
20
Years of Service
User Offline
Joined: 7th Apr 2004
Location: A swimming pool of coke
Posted: 8th Apr 2005 16:43
I had about a 4 hour sleep yesterday afternoon...about a week ago I did 3 in a row non stop and then slept lots


http://dbgamezone.com/pulse / http://neofish.dbspot.com
DONT CLICK THE INTERNAL LINKS, THEY DONT WORK
Nicholas Thompson
20
Years of Service
User Offline
Joined: 6th Sep 2004
Location: Bognor Regis, UK
Posted: 8th Apr 2005 18:16
During the end of my degree (when I left my dissertation to 4 days before the deadline) I managed to go for 4 days with 30 mins sleep on a not particularly comfortable chair.. I then handed my dissertation in, went home saw my bed and collapsed on it for about 14hours.. Lol.. Ahh those were the days

Kimo - That code looks interesting - I might try to tweak it as currently, it looks like it could be broken quite easily as the output is just a relatively simple forumla on the ASCII number. Its a good idea though.. I'm thinking something to do with XOR.. Got to research though.

Unfortunately last night, a combination of lack of time and motivation meant I got VERY little done (except a basic drop down menu at the top). I am also out all of tonight, so this means I have tomorrow to code my heart out

@Kimosabi - I'll put my thinking hat on for the menu system you need.. Have you ever played Counterstrike? I'm thinking something simple like the buy menu in that..
You'd have a menuID..
0 = MainMenu
1 = Tanks
2 = Lights
etc

You then have a loop that displays text with a box background.. Maybe make a function for it?
something like this:


Hows that?

Then, after you create a button you can do boundary checks to see of the mouse is in that box..

Hope it helps - its basically how I'm doing my menu (except I'm using sprites so I can play with Alpha and have drop down menu's and stuff..)

My Website:
KimoSabi
19
Years of Service
User Offline
Joined: 18th Jan 2005
Location:
Posted: 8th Apr 2005 23:04 Edited at: 8th Apr 2005 23:07
hmmmm... that sounds ok but i dont know how i would go about making all of the different stuff and plus i alread i have the stuff on the right side to buy stuff i was thinking instead when you click on the button it doesn't but it but yet i goes to another menu that basically says whether or not you own it and if you do you can use it or sell it and if you dont you can buy it but i dont know how to do that effectively(and im getting very tired)

ya you can just multiply it a few more times or add and subtract some numbers and than it is basically impossible to decode

My Website:

Login to post a reply

Server time is: 2024-11-22 04:39:52
Your offset time is: 2024-11-22 04:39:52