Das etwas andere Pong
Übersicht

![]() |
SmilyBetreff: Das etwas andere Pong |
![]() Antworten mit Zitat ![]() |
---|---|---|
Hoi, hier ein wenig das ergebniss, der letzten Stunde mit Langer weile ![]() Wie das ganze Funktioniert sollte selbsterklärend sein. Das ganze ist natürlich nur ne Spielerei und war auch eine Fixe Idee von mir, ergo alles andere als Ausgereift ![]() Code: [AUSKLAPPEN] SuperStrict
' Variable, die für das Spielbalancing geändert werden können Local width:Int = 800 Local height:Int = 600 Local insets:Int = 10 Local padWidth:Int = 60 Local padHeight:Int = 10 Local defaultSpeed:Double = 2 Global flipTimer:TTimer=CreateTimer(60) 'Ab hier nichts mehr ändern Graphics width, height 'HideMouse 'Vorberrechnungen Local horizontalWay:Int = width - insets*2 Local verticalWay:Int = height-insets*2 Local way:Int = (horizontalWay+verticalWay)*2 Local midX:Int = width/2 Local midY:Int = Height/2 'init variablen Local posX:Int Local moveX:Int Local toppos:Int Local leftpos:Int Local rightpos:Int Local bottompos:Int Local ri:Int = Rand(0,359) Local ballx:Float = midX Local bally:Float = midY Local hit:Int = -1 Local hits:Int = 0 Local lock:Int Local gameend:Int Local ballSpeed:Double = defaultspeed MoveMouse midx, midy WaitMouse() MoveMouse midx, midy Repeat moveX = MouseX() -midX MoveMouse midx, midy posX = (posX + moveX + way) Mod way toppos = insets + posX rightpos = insets + posX - horizontalway bottompos = width - (insets + posX + padWidth - horizontalway - verticalway) leftpos = height - (insets + posX + padWidth - horizontalway*2 - verticalway) ballx = ballx + Cos(ri) * ballspeed bally = bally - Sin(ri) * ballspeed hit = -1 If ballx < width-insets And ballx > width-insets-padheight And bally > rightpos And bally < rightpos+padWidth Then hit = 1 If ballx > insets And ballx < insets+padheight And bally > leftpos And bally < leftpos + padwidth Then hit = 3 If bally > insets And bally < insets+padheight And ballx > toppos And ballx < toppos + padwidth Then hit = 2 If bally < height-insets And ballY > height-insets-padheight And ballx > bottompos And ballx < bottompos + padwidth Then hit = 0 If ballx < 0 Or ballx > width Or bally < 0 Or bally > height gameend = True If MouseHit(1) And gameend ballx = midx bally = midy gameend = False ballSpeed = defaultspeed hits = 0 End If If hit > -1 If lock = False lock = True ri = Rand(90*hit, 90*hit+180) ballspeed = ballspeed*1.1 hits :+ 1 End If Else lock = False End If Cls SetColor 100,100,100 SetScale 10,10 DrawText hits,width/2 - TextWidth(hits)*10/2, height/2 - TextHeight(hits)*10/2 If gameend DrawText "Ende", width/2 - TextWidth("Ende")*10/2, height/2 - (TextHeight("Ende")*15) SetScale 1,1 SetColor 255,255,255 SetViewport insets, insets, width-insets*2, height-insets*2 DrawRect toppos, insets, padWidth, padHeight DrawRect toppos-way, insets, padWidth, padHeight DrawRect width-insets-padHeight, rightpos, padHeight, padWidth DrawRect bottompos, height-insets-padHeight, padwidth, padHeight DrawRect insets, leftpos, padHeight, padWidth SetColor 0,255,0 DrawRect ballX-3, ballY-3, 6, 6 SetViewport 0,0,width,height WaitTimer flipTimer Flip 0 Until KeyHit(27) |
||
Lesestoff:
gegen Softwarepatente | Netzzensur | brain.exe | Unabhängigkeitserklärung des Internets "Wir müssen die Rechte der Andersdenkenden selbst dann beachten, wenn sie Idioten oder schädlich sind. Wir müssen aufpassen. Wachsamkeit ist der Preis der Freiheit --- Keine Zensur!" stummi.org |
![]() |
Moep |
![]() Antworten mit Zitat ![]() |
---|---|---|
Die Idee find ich Klasse ^^..
Allerdings fällt mir die Steuerung etwas schwer, aber da es ja nur ne Spielerei ist , ist das ja nich weiter schlimm^^ Mir fällts immer schwer auf kreative Dinge zu kommen, sonst würde ich wahrscheinlich ununterbrochen programmieren. ![]() mfg Moep |
||
Hardstyle Schleichwerbung:
http://www.youtube.com/user/Hackepeter42 Achtung: Suchtgefahr! moep123.ohost.de |
![]() |
Firstdeathmaker |
![]() Antworten mit Zitat ![]() |
---|---|---|
Ist echt ne coole Idee... | ||
www.illusion-games.de
Space War 3 | Space Race | Galaxy on Fire | Razoon Gewinner des BCC #57 User posted image |
![]() |
BtbN |
![]() Antworten mit Zitat ![]() |
---|---|---|
http://de.wikipedia.org/wiki/Painstation
DAS ist ein "etwas anderes" Pong! |
||
![]() |
Smily |
![]() Antworten mit Zitat ![]() |
---|---|---|
Moep hat Folgendes geschrieben: Die Idee find ich Klasse ^^..
Allerdings fällt mir die Steuerung etwas schwer, aber da es ja nur ne Spielerei ist , ist das ja nich weiter schlimm^^ Mir fällts immer schwer auf kreative Dinge zu kommen, sonst würde ich wahrscheinlich ununterbrochen programmieren. ![]() mfg Moep Du kannst gerne die Idee aufnehmen, die Steuerung und anderes Verbessern und darraus ein Brauchbares Projekt machen. ![]() Das würde mir sogar besser gefallen, als wenn das ganze in der Verseknung verschwindet ![]() |
||
Lesestoff:
gegen Softwarepatente | Netzzensur | brain.exe | Unabhängigkeitserklärung des Internets "Wir müssen die Rechte der Andersdenkenden selbst dann beachten, wenn sie Idioten oder schädlich sind. Wir müssen aufpassen. Wachsamkeit ist der Preis der Freiheit --- Keine Zensur!" stummi.org |
![]() |
Moep |
![]() Antworten mit Zitat ![]() |
---|---|---|
Mal schaun ![]() |
||
Hardstyle Schleichwerbung:
http://www.youtube.com/user/Hackepeter42 Achtung: Suchtgefahr! moep123.ohost.de |
Übersicht


Powered by phpBB © 2001 - 2006, phpBB Group