Ello again, my Blitz-addicted friends!!
Eres one I just can't figure ... can you put a pointer to another type IN a type?
Heres the situation .. I have a shed-load (200+) of waypoints stored in types. Rather than iterate through them all looking for an ID, since they're always read in sequence (start to finish!) it would be great if it was possible to put a pointer to the the current waypoint in the player's type. That way, I could just use AFTER to move along to the next waypoint... in theory!??!!
Anyone tried this or know if it'll work? I started out with this test code to see if it worked in principle, but my head is frazzled and I'll have to go away and think about it all a bit before carrying on!!
Eres one I just can't figure ... can you put a pointer to another type IN a type?
Heres the situation .. I have a shed-load (200+) of waypoints stored in types. Rather than iterate through them all looking for an ID, since they're always read in sequence (start to finish!) it would be great if it was possible to put a pointer to the the current waypoint in the player's type. That way, I could just use AFTER to move along to the next waypoint... in theory!??!!
Anyone tried this or know if it'll work? I started out with this test code to see if it worked in principle, but my head is frazzled and I'll have to go away and think about it all a bit before carrying on!!
Type norbert Field number End Type Type hismate Field norb.norbert End Type For i=1 To 100 a.norbert=New norbert a\number=I Next For i=1 To 4 b.hismate=New hismate b\norb=First norbert Next c=1 d.hismate=First hismate For i=1 To Rnd(10) d\norb=After d\norb Next For i=1 To 4 Print i+".."+d\norb\number d=After d Next While Not KeyHit(1) Wend