cruelty247 wrote:
how can i make it so my variable fits in a _______ as string? panther block
block creater thing?
the $Color$ as string block turns a colour in the pallet into a hexadecimal code.
orange varaibles do not fit in it, but colour variables do.
Offline
ok i realize now what i want is a block that can turn 1-10 numbers into 1-10 a-f numbers!
Offline
johnnydean1 wrote:
true
You really like making small posts...
Offline
sparks wrote:
Gib mir auge wo chond louege, it wet jo meh als numme ksee, gib mir ohre wo chond losse, wenn mer losst den kört mer meh.
What does that mean in english?
Offline
Its a challange to find out...
And short posts are fast!
Offline
paulpsicle wrote:
sparks wrote:
Gib mir auge wo chond louege, it wet jo meh als numme ksee, gib mir ohre wo chond losse, wenn mer losst den kört mer meh.
What does that mean in english?
It's a song lyric.
♪Give me eyes with which to see things,
I want more than just to see.
Give me ears with which to hear things,
when you listen you hear more.♫
(it rhymes in swiss)
Offline
I need a help. I need to make a game using tiles. Which would be the most efficant way of doing it. E.G a varibale for each square.
It needs to be at least 25x25
Offline
johnnydean1 wrote:
I need a help. I need to make a game using tiles. Which would be the most efficant way of doing it. E.G a varibale for each square.
It needs to be at least 25x25
Maybe a list?
Offline
markyparky56 wrote:
johnnydean1 wrote:
It needs to be at least 25x25
Maybe a list?
What you want is a list of lists! But you can fake it by making a list of length 625 and looking at item number (25X)+Y+1 if you count squares from zero,
or (25(X-1) )+Y if you count squares from one.
(EDIT: Stupid Scratch blocks thingy; I thought you had to ask for that with [ b l o c k s ]!
Last edited by bharvey (2010-07-04 12:12:44)
Offline
bharvey wrote:
markyparky56 wrote:
johnnydean1 wrote:
It needs to be at least 25x25
Maybe a list?
What you want is a list of lists! :D But you can fake it by making a list of length 625 and looking at item number (25X)+Y+1 if you count squares from zero,
or (25(X-1) )+Y if you count squares from one.
(EDIT: Stupid Scratch blocks thingy; I thought you had to ask for that with [ b l o c k s ]! :(
Check off "never show smileys as icons for this post". Ex:
(((((((((((((())))))))))))))
{foo}
EDIT: But then the smileys in quoted text will go away...
Last edited by nXIII (2010-07-04 12:51:40)
Offline
I just made a <File $String$ exists?> block
Code:
|contents exists other writing temp var|
writing_ 'I exist'.
contents_ self readFile: (t1).
self writeText: (writing) toFile: (t1).
other_ self readFile: (t1).
temp_ self stringLength: (writing).
var_ self stringLength: (other).
temp_ var - temp.
temp_ temp + 1.
temp_ self letters: (temp) through: (var) of: (other).
temp = writing
ifTrue: [
exists_ true.
self clearFile: (t1).
self writeText: (contents) toFile: (t1).
]
ifFalse: [
exists_ false.
].
^ exists
Last edited by johnnydean1 (2010-07-04 14:43:43)
Offline
NEVER use a block that accesses a forum web page. This will make the views skyrocket. At the time this was posted, my forum topic was at the top of the advanced topics section with '14208 views' because of my project that notified me when there was a new post.
Offline
I have a idea. On CYOB you can insert blocks into the editor. Why not make it able to instert custom blocks?
Offline
Can any1 do a make file $String$ block?
Offline
use clear file $String$
or, if you really want, self clearFile: (t1)
Last edited by paulpsicle (2010-07-04 16:45:11)
Offline
johnnydean1 wrote:
I just made a <File $String$ exists?> block
I made a simpler one:
| t2 t3 | t2 _ self numFileLines: (t1). t3 _ t2 asString. (t3 = '') ifTrue:[^ false]. ^true
Offline