Qbasicnews.com
November 14, 2019, 11:40:49 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Back to Qbasicnews.com | QB Online Help | FAQ | Chat | All Basic Code | QB Knowledge Base
 
   Home   Help Search Login Register  
Pages: [1] 2
  Print  
Author Topic: New Challenges  (Read 15954 times)
wildcard
*.*
Administrator
__/--\__
*****
Posts: 2369



« on: September 09, 2002, 07:46:04 PM »

Post your challenges here and I'll post them once the current challenge is finished.
Logged
wizardlife
Na_th_an
*****
Posts: 1456


WWW
« Reply #1 on: September 09, 2002, 10:41:39 PM »

Okay, here's the one that I sort of suggested earlier, but it's a little simplified:

Make an action game using the 640x480x16 screen mode 12. Flicker is acceptable, but only if it does not seriously inhibit gameplay. The game must have at least three basic controls: left, right, and jump. A gravity force is required to hold the player down. The game is not required to scroll either vertically or horizontally. The player sprite or visual representation must have at least two cels of animation, and there must be a criteria to 'win' and to 'lose' other than running out of time. (Falling off the screen is acceptable) The game must be fun. You may not use a library unless it is pureQB and is to provide a function like mouse control or audio. Audio is not necessary because it often doesn't work on different hardware setups and makes the file sizes much larger.

Gameplay: /10
Visuals: /10
Details: /10
Fun Factor: /10

Total: /40


The due date is November 30th. I intend to enter the contest, but have not begun mine yet. This code illustrates how to directly access the video memory is SCREEN 12:

Code:

DEFINT A-Z
DECLARE SUB pix12 (vertical%, horizontal%, c%)
DIM SHARED bitfield(7) AS INTEGER
   bitfield(0) = 128: bitfield(1) = 64: bitfield(2) = 32
   bitfield(3) = 16: bitfield(4) = 8: bitfield(5) = 4
   bitfield(6) = 2: bitfield(7) = 1

SUB pix12 (vertical%, horizontal%, c%)
   IF (vertical% < 0) OR (horizontal% < 0) THEN EXIT SUB
   IF (vertical% > 479) OR (horizontal% > 639) THEN EXIT SUB
   DEF SEG = &HA000: OUT &H3CE, 4: OUT &H3C4, 2
   P& = vertical%: P& = P& * 80 + horizontal% \ 8
   bit% = bitfield(horizontal% AND 7): bitmask% = 255 - bit%
   OUT &H3CF, 0: OUT &H3C5, 1: B% = PEEK(P&) AND bitmask%
   IF (c% AND 1) <> 0 THEN B% = B% OR bit%
   POKE P&, B%
   OUT &H3CF, 1: OUT &H3C5, 2: B% = PEEK(P&) AND bitmask%
   IF (c% AND 2) <> 0 THEN B% = B% OR bit%
   POKE P&, B%
   OUT &H3CF, 2: OUT &H3C5, 4: B% = PEEK(P&) AND bitmask%
   IF (c% AND 4) <> 0 THEN B% = B% OR bit%
   POKE P&, B%
   OUT &H3CF, 3: OUT &H3C5, 8: B% = PEEK(P&) AND bitmask%
   IF (c% AND 8) <> 0 THEN B% = B% OR bit%
   POKE P&, B%
END SUB


Good luck.  Cool
Logged

wizardlife
Na_th_an
*****
Posts: 1456


WWW
« Reply #2 on: September 09, 2002, 10:44:19 PM »

btw, I'm sick of Guru too. I want to be 'Desert Wanderer', now. Can't you make it so that once we're up to 200 posts we can change it ourselves?
Logged

LooseCaboose
I hold this place together
*****
Posts: 981



« Reply #3 on: September 10, 2002, 01:11:01 AM »

This ones a little harder, but again I have a solution I prepared earlier  Cheesy

Write a program in QB that produces its own source code when run. You may not use any of the commands for opening or reading files and all hardware stuff (peek/poke etc) is disallowed. The trivial solution (Blank qb file produces blank output doesnt count as a winner).

My solution is ten lines long, you can make the program as complex as you want but see if you can beat ten lines.  :bounce:
Logged

esus saves.... Passes to Moses, shoots, he scores!
aetherfox
Been there, done that
*****
Posts: 1071



WWW
« Reply #4 on: September 15, 2002, 10:21:09 AM »

Well, challenges seem to be quite interesting, so I have made my own...its quite a simple idea really, but possibly challenging for some people.

Make an encryption routine that encrypts a string (inputted by the user preferably), and encrypts it, and if that same routines doesn't decrypt, then a decryption routine.  Encryption should be based on a specifiec key/password.  But the trick is to have strong encryption.  So suppose I type "ttt", then i don't want to see the same letters like "aaa" (assuming "t" encrypted becomes "a"), i wanna see something different each time, like say "ahf" or whatever.

I do NOT have a solution for this yet, and I hope its possible to do Wink hahhahahaha but still, it should be fairly easy.  I will try enter myself, but I don't know if I have the time.  Deadline is next Sunday, the 22nd if I am correct.
Logged

~''i|~thrFx~|i''~-  
avinash.vora - http://www.avinashv.net
wizardlife
Na_th_an
*****
Posts: 1456


WWW
« Reply #5 on: September 15, 2002, 05:28:12 PM »

Oooh. I did this before for a secret message program. Let's see if I can re-create it... post back l8er.
Logged

wildcard
*.*
Administrator
__/--\__
*****
Posts: 2369



« Reply #6 on: September 15, 2002, 06:14:22 PM »

Just for everyones information, current challenges(ones that are to be solved) are stickies(sp?) the others aren't. I chose to sticky current ones rather than locking old ones, so that people can still post their solutions if they so desire.
Logged
mofu
Forum Regular
**
Posts: 111



WWW
« Reply #7 on: September 25, 2002, 05:10:25 PM »

Hey Wildcard,
I was just wonderng whether there will ever be any begginner challenges all the seem a bit complex. My coding is not great but I am learning new things all the time Cheesy  And I think a newbie challenge would be cool although Im not too sure how many prople will participate, cause most people here are pros :wink:
Thanks
Mofu
Logged

URL=http://mofu.qbasicnews.com][/URL]
wildcard
*.*
Administrator
__/--\__
*****
Posts: 2369



« Reply #8 on: September 25, 2002, 06:38:48 PM »

mofu: I'll work on a nice one challenging but not requiring intimate knowledge of old specs stuff ;-) I'll post it tomorrow.
Logged
Neo
Na_th_an
*****
Posts: 2150



« Reply #9 on: September 26, 2002, 06:29:00 AM »

My super-easy challenge:
Code:
Create a program which is able to calculate PI at at least 10000 decimals. ;-)


Let's see who's good at maths here...
Logged
mofu
Forum Regular
**
Posts: 111



WWW
« Reply #10 on: September 26, 2002, 09:02:28 AM »

Thanks guys Cool
Logged

URL=http://mofu.qbasicnews.com][/URL]
wildcard
*.*
Administrator
__/--\__
*****
Posts: 2369



« Reply #11 on: September 26, 2002, 11:36:40 AM »

mofu: That wasn't the one ;-) But if you can do it, thats great. I have no idea.. reproducing pi is NOT my forte.

EDIT: Forgot the NOT which changes things a bit :-)
Logged
mofu
Forum Regular
**
Posts: 111



WWW
« Reply #12 on: September 26, 2002, 04:32:44 PM »

ops  :oops:  anyway I will give it a shot :wink:  I will se what I can come up with  Cheesy  and will post 2morrow
Logged

URL=http://mofu.qbasicnews.com][/URL]
Sumo Jo
Been there, done that
*****
Posts: 1244



WWW
« Reply #13 on: October 08, 2002, 08:38:06 PM »

Here's a challenge i saw posted at qbasic.com, but no one was answering it.  The guy who said it said it would take Assembly knowledge, so i guess if you don't have it, you can't do it.  J/k.  Anyways, i don't really know how somone would do this, so it's kinda open ended.  The challenge is to write code that takes a .exe file that was converted from a .bas file and turn it back into a .bas file.

Does anyone think that they could do this?
or
Is this just an impossible/stupid challenge?

Good luck or sorry
Logged

url=http://fileanchor.com]FileAnchor[/url] - ImageAnchor - FBTK - QbasicNews - VPlanet - Various
wizardlife
Na_th_an
*****
Posts: 1456


WWW
« Reply #14 on: October 10, 2002, 12:56:29 PM »

Quote from: "SumoJo"
Here's a challenge i saw posted at qbasic.com, but no one was answering it.  The guy who said it said it would take Assembly knowledge, so i guess if you don't have it, you can't do it.  J/k.  Anyways, i don't really know how somone would do this, so it's kinda open ended.  The challenge is to write code that takes a .exe file that was converted from a .bas file and turn it back into a .bas file.

Does anyone think that they could do this?
or
Is this just an impossible/stupid challenge?

Good luck or sorry


Might be a good idea... but a decompiler is more of a project than a challenge. You would have to set some kind of parameters like a list of commands that it has to recognise and so on...
Logged

Pages: [1] 2
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!