Topic:   Another way of using V6   (Read 21318 times)


0 Members and 1 Guest are viewing this topic.

Tireas Dragon


  • GMG Extraordinaire

  • ***


  • Posts: 1626

  • Trying to recover from my shattered screen.
Another way of using V6
« on: June 28, 2008, 10:27:31 AM »
Well I don't know about you guys but sometimes I get lost in V6's numbers and have a difficult time seeing the grid. So in order to help myself see the grid I have made the variable declared in several places like this:
gridlayout$ = ""
gridlayout$ = gridlayout$ + "1111111"
gridlayout$ = gridlayout$ + "1100001"
gridlayout$ = gridlayout$ + "1010001"
gridlayout$ = gridlayout$ + "1001001"
gridlayout$ = gridlayout$ + "1000101"
gridlayout$ = gridlayout$ + "1000011"
gridlayout$ = gridlayout$ + "1111111"

This is easier for me because now I can see the grid. It take more lines but it really helps. Especially if you want to add something somewhere.
I must be dreaming (wake up me wake up) How could this have happened. Tireas' cry when he found his computer fallen over in his chair with it's screen shattered.

Charlo


  • GMG-er

  • **


  • Posts: 451
Re: Another way of using V6
« Reply #1 on: June 28, 2008, 10:34:38 AM »
Great idea!  I agree, it is hard to see what the grid actually looks like when you're staring at a bunch of zeros and ones.   ;D

Silverwind


  • ^ This guy is amazing.

  • ****


  • Posts: 2805

  • For the glory of my maker
Re: Another way of using V6
« Reply #2 on: June 28, 2008, 11:42:19 AM »
That's a clever idea indeed. :) I've never had any problems reading or writing the code myself, but I'm sure this will make it significantly easier.
I survived the spammage of 2007

Tireas Dragon


  • GMG Extraordinaire

  • ***


  • Posts: 1626

  • Trying to recover from my shattered screen.
Re: Another way of using V6
« Reply #3 on: July 10, 2008, 09:32:37 AM »
Never mind don't use it. It doesn't work in compiled games. I have no idea why it just doesn't. Says that the string limit has exceeded 255 characters.
I must be dreaming (wake up me wake up) How could this have happened. Tireas' cry when he found his computer fallen over in his chair with it's screen shattered.

Al Staffieri


  • GMG-er

  • **

  • no avatar

  • Posts: 452

  • I love GameMaker
Re: Another way of using V6
« Reply #4 on: July 10, 2008, 07:18:26 PM »
Quote
Never mind don't use it. It doesn't work in compiled games. I have no idea why it just doesn't. Says that the string limit has exceeded 255 characters.

i just fixed a string bug for the next update, so I'll try the code with that and see what happens.

Tireas Dragon


  • GMG Extraordinaire

  • ***


  • Posts: 1626

  • Trying to recover from my shattered screen.
Re: Another way of using V6
« Reply #5 on: July 10, 2008, 08:36:51 PM »
I also encountered a bug when I was using it in run mode it seemed some sort of invisible " character was in my code I retyped the line of code but it kept on adding the " character to the end of my code. When I took out the " character that you could see it worked fine. It was an Isolated incident tho I was unable to duplicate it, with a small amount of code.
I must be dreaming (wake up me wake up) How could this have happened. Tireas' cry when he found his computer fallen over in his chair with it's screen shattered.

Al Staffieri


  • GMG-er

  • **

  • no avatar

  • Posts: 452

  • I love GameMaker
Re: Another way of using V6
« Reply #6 on: July 11, 2008, 01:31:49 AM »
Quote
I also encountered a bug when I was using it in run mode it seemed some sort of invisible " character was in my code I retyped the line of code but it kept on adding the " character to the end of my code. When I took out the " character that you could see it worked fine. It was an Isolated incident tho I was unable to duplicate it, with a small amount of code.

Yep. I saw this bug a few days ago too. I have an update coming out real soon that should fix all this stuff, but I just want to do some testing and make sure I got it right before i release it.

Tireas Dragon


  • GMG Extraordinaire

  • ***


  • Posts: 1626

  • Trying to recover from my shattered screen.
Re: Another way of using V6
« Reply #7 on: July 11, 2008, 01:46:21 AM »
Most of the problems lie in the compiled versions. Maybe when you made 399 you did something wrong with the compiler.
I must be dreaming (wake up me wake up) How could this have happened. Tireas' cry when he found his computer fallen over in his chair with it's screen shattered.

Al Staffieri


  • GMG-er

  • **

  • no avatar

  • Posts: 452

  • I love GameMaker
Re: Another way of using V6
« Reply #8 on: July 11, 2008, 05:13:46 AM »
The "string limit has exceeded 255 characters" bug when adding strings together has been fixed. I'll edit this post once I check the extra " at the end of a string bug.

EDIT: The " at the end of a string bug is fixed for the next update. Yay!
« Last Edit: July 11, 2008, 07:06:05 AM by AlStaffieri »

Al Staffieri


  • GMG-er

  • **

  • no avatar

  • Posts: 452

  • I love GameMaker
Re: Another way of using V6
« Reply #9 on: July 11, 2008, 07:06:57 AM »
Quote
Most of the problems lie in the compiled versions. Maybe when you made 399 you did something wrong with the compiler.

Yeah I made a few minor changes to string handling and it turns out i really screwed some stuff up.

HarryCaray


  • GMG-er

  • **


  • Posts: 119

  • I love YaBB 1G - SP1!
Re: Another way of using V6
« Reply #10 on: July 14, 2008, 06:48:02 PM »
First did this in TNT with arrays, figured I'd try it in SC. it accomplishes what V6 does in only 30 lines of code:

Download it here

This is a 10x10 grid at 32 pixels per tile. 100 tiles in total.

Open Card
Code: [Select]
CREATESPRITE 1, "GUY"
MOVESPRITE 1,32,32
LET grid$="0000000000011111111001111111100111111110011111111001111111100111111110011111111001111111100000000000"
LET curTile=12

Key Down
Code: [Select]
SELECT CASE KEY$
CASE UPARROW$
LET tile$=MID$(grid$,curTile-10,1)
IF tile$="1" THEN
PUSHSPRITE 1, 0,-32
LET curTile=curTile-10
END IF
CASE DOWNARROW$
LET tile$=MID$(grid$,curTile+10,1)
IF tile$="1" THEN
PUSHSPRITE 1, 0,32
LET curTile=curTile+10
END IF
CASE LEFTARROW$
LET tile$=MID$(grid$,curTile-1,1)
IF tile$="1" THEN
PUSHSPRITE 1, -32,0
LET curTile=curTile-1
END IF
CASE RIGHTARROW$
LET tile$=MID$(grid$,curTile+1,1)
IF tile$="1" THEN
PUSHSPRITE 1, 32,0
LET curTile=curTile+1
END IF
END SELECT
« Last Edit: July 14, 2008, 07:00:52 PM by HarryCaray »

Tireas Dragon


  • GMG Extraordinaire

  • ***


  • Posts: 1626

  • Trying to recover from my shattered screen.
Re: Another way of using V6
« Reply #11 on: July 14, 2008, 08:25:54 PM »
Maybe 30 lines of code but your guy still moves 2 times, when you press the button once.
I must be dreaming (wake up me wake up) How could this have happened. Tireas' cry when he found his computer fallen over in his chair with it's screen shattered.

HarryCaray


  • GMG-er

  • **


  • Posts: 119

  • I love YaBB 1G - SP1!
Re: Another way of using V6
« Reply #12 on: July 14, 2008, 08:27:40 PM »
no he doesn't

Tireas Dragon


  • GMG Extraordinaire

  • ***


  • Posts: 1626

  • Trying to recover from my shattered screen.
Re: Another way of using V6
« Reply #13 on: July 14, 2008, 08:57:15 PM »
Maybe its the version cause when I load it he moves 2 times.
I must be dreaming (wake up me wake up) How could this have happened. Tireas' cry when he found his computer fallen over in his chair with it's screen shattered.

Silverwind


  • ^ This guy is amazing.

  • ****


  • Posts: 2805

  • For the glory of my maker
Re: Another way of using V6
« Reply #14 on: July 15, 2008, 03:09:59 AM »
Nice one Alias :) What's the regular size of V6 when it's striped down to do only what this one does?

EDIT:

Sorry about that Harry, I read the name wrong. I thought Alias wrote the code.

Nice one Harry!
« Last Edit: July 17, 2008, 08:06:41 AM by Silverwind »
I survived the spammage of 2007