Menu

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.

Show posts Menu

Messages - CptnRoughnight

#16
GLBasic - de / GLBasic IDE
2014-Jan-10
EDIT :

So Leute, die IDE wächst und gedeiht, habe jetzt mein erstes Projekt für Win32 komplett erstellen können. Die nächsten Punkte sind dann erstmal neuen Lexer schreiben, der angepasste CPP-Lexer von scintilla.Net ist nicht zufrieden stellend! :)

Allerdings brauch ich dann in naher Zukunft Hilfe bei den anderen Platformen, welche Argumente ich übergeben muss, welche Programme aufzurufen sind.

derzeit implementierte Features:

    - Multi Monitor Support (Abdocken der Projektmappe,Outputfenster etc.)
    - rudimentäre Code-Snippet Verwaltung (wird noch verbessert)

geplante Features :
    - voller Support für GLBasic Compiler (alle Platformen)
    - evtl. auch nativ C++ mit Crosscompilern
    - SVN Support
    - besserer "Projekt wizard"


Ich werde auf jeden Fall dran bleiben und auch bald im "internationalen" Forum posten, bin nur grad wegen Nachtschichten etwas müde im Kopf^^

- CptnRoughnight
#17
Then it takes a little longer, I'll try anyway! :)
#18
Nice! I'm waiting for it, to port it to Pandora! :) Thank you!
#19
Really great!

Would you release it for Pandora too? Can you play via net? Would be a awesome game for pandora!  :nw:
#20
Perlin is indeed intended for textures, but for example, Minecraft uses this algorhythm for the terrain generation.
First, it will determine the level of landscapes, then, in several passes the "Dungeons".

#21
:D very nice!

My PI value o.O, thats a strange mistake. .. thanks for it! :D
#22
Ahhh my fault!

for seeding, there are two arrays in the Perlin Type, with

Code (glbasic) Select

perlin.InitNoise( seed )


you can access them!
#23
Hi,

here is my Perlin Noise implementation. Feel free to use in your projects!

Code (glbasic) Select

//****************************************
//** Perlin Noise Implementatio
//** Date: 14.12.2013
//****************************************

TYPE TPerlin
d%
f#
result#
fracX#
fracY#
total#
octaves
pnum%
    per_Prim_1%[]
    per_Prim_2%[]

FUNCTION InitNoise:num%
self.d% = 0
self.f# = 0
self.result = 0
self.fracX = 0
self.fracY = 0
self.total = 0
self.octaves = 0
self.pnum% = num%

DIMDATA self.per_Prim_1%[],15731,15733,15737,15739,15749,15761,15767,15773,15787,15791,15797,15803,15809,15817,15823
DIMDATA self.per_Prim_2%[],789221,789227,789251,789311,789323,789331,789343,789367,789377,789389,789391,789407,789419,789443,789473
ENDFUNCTION


FUNCTION Noise#:n%,octave
self.d = bXOR(ASL(n,13),n)

RETURN (1.0 - (bAND((self.d * (self.d * self.d * self.per_Prim_1%[self.pnum] + self.per_Prim_2%[self.pnum]) + 1376312627),2147483647)) / 1073741824.0)
ENDFUNCTION

FUNCTION Cos_Interpolate#:a#,b#,x#
self.f# = COS(PI * x#)

self.f# = (1-self.f#) * 0.5;
RETURN a# *(1-self.f#)+b# *self.f#;
ENDFUNCTION


FUNCTION Noise2D#:x%,y%
RETURN self.Noise(x * 46349 + y * 46351, 1)
ENDFUNCTION


FUNCTION Smooth_Noise2D#:x%,y%
self.result = (self.Noise2D(x-1,y-1) + self.Noise2D(x+1,y-1) + self.Noise2D(x-1,y+1) + self.Noise2D(x+1,y+1)) / 16
self.result = self.result +( (self.Noise2D(x-1,y) + self.Noise2D(x+1,y) + self.Noise2D(x,y-1) + self.Noise2D(x,y+1)) / 8)
self.result = self.result +( self.Noise2D(x,y) / 4 )
RETURN self.result;

ENDFUNCTION


FUNCTION InterpolatedNoise2D#:x%,y%
self.fracX# = x - INTEGER(x)
self.fracY# = y - INTEGER(y)

RETURN self.Cos_Interpolate(self.Cos_Interpolate(self.Smooth_Noise2D(INTEGER(x#), INTEGER(y#)), self.Smooth_Noise2D(INTEGER(x#) + 1, INTEGER(y#)), self.fracX#),self.Cos_Interpolate(self.Smooth_Noise2D(INTEGER(x#), INTEGER(y#)), self.Smooth_Noise2D(INTEGER(x#) + 1, INTEGER(y#)), self.fracX#), self.fracY#)

ENDFUNCTION

FUNCTION GetPerlinNoise2D#:x#,y#,pers#,freq#,amp#,oct
self.total# = 0

FOR self.octaves = 0 TO oct
freq# = freq*2
amp# = amp*pers
self.total# = self.total# + (self.InterpolatedNoise2D(x#*freq#,y#*freq#)*amp#)
NEXT
RETURN self.total
ENDFUNCTION
ENDTYPE


edit:

and the test program :

Code (glbasic) Select

// --------------------------------- //
// Project: Perlin
// Start: Tuesday, September 10, 2013
// IDE Version: 11.171


GLOBAL map[]
GLOBAL x,y
GLOBAL p AS TPerlin

DIM map[10001]

CONSTANT PI = 3.141593
p.InitNoise(4)

FOR x= 0 TO 99
FOR y = 0 TO 99
map[x+y*100] = (p.GetPerlinNoise2D(x,y,0.8,0.1,1,5)+1)/255 * 255
DEBUG "map: "+map[x+y*100]+"\n"
NEXT
NEXT

FOR x= 0 TO 99
FOR y = 0 TO 99
DRAWRECT x*4,y*4,4,4,RGB(map[x+y*100]*200,0,0)

NEXT
NEXT

SHOWSCREEN

MOUSEWAIT


Edit : Strange PI Bug :D
#24
Here is my entry : http://repo.openpandora.org/?page=detail&app=cptngames.crapcopter

Special thanks to Ian Price! PND works fine!
#25
Welche PND benutzt du? Du musst die pandora-exe.pnd auf der Pandora ausführen.
Mfg
#26
Thanks Ian Price,  :good:

but i will try it by myself first. There is no reason that I could not learn that! ;)

If I have problems, I'll report back.

#27
Hi Leute,

Ich bin gerade in der Endphase für mein Beitrag zum "Crap Game Coding Competition 2013" und wollte nun anfangen das Spiel als einzelne PND auf der Pandora zu testen.
Sonst benutze ich immer den Umweg über die pandora-exe.pnd, weil ich weiß das die eigtl. PND nicht geht.

Jetzt die Frage: Wenn ich die PND erzeuge, was muss noch mitgeliefert werden? Im Terminal steht immer der Fehler :

Code (glbasic) Select

Starting the application ( ./pandora-exe.pnd  )           [ failed ]


Habe ich Einstellungen vergessen? Ich habe auch versucht den ganzen "distribute/pandora" Ordner zu kopieren, mit dem gleichen negativen Effekt.

Bitte um Hilfe, komme hier echt nicht weiter allein.

p.s. benutze aktuellstes GLBasic und Firmware SZ R1.55/Kernel 3.2.52


MfG
#28
Very cool software, just what i need! Thanks!
#29
First simple games with high score management. But I have ideas for a kind of online game. I'll play around a bit with the possibilities once I have fully understood the network functionality ;)
#30
The Rapsberry Pi is used as a server for my games.

This idea I wanted to implement for competition (Crap Game Competition 2013), but I've not enough time i guess.

I have many other ideas for which the Pi is suitable as a server.

Maybe i will learn html/css/php to write a homepage by myself! ;)