It's not... I just said the keyDown command doesn't work sometimes when I click on a button (the result is delete it) until I click on a button again.How is this connected to keyDown??
Search found 11 matches
- Sun May 15, 2011 3:48 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: on keyDown problem
- Replies: 9
- Views: 6367
Re: on keyDown problem
- Sun May 15, 2011 12:13 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: on keyDown problem
- Replies: 9
- Views: 6367
Re: on keyDown problem
Hi, thanks for your answers
Your command starts: "on destroyButton" but closes with "end destroySmiley" (so I would imagine it doesn't even compile properly...)
Sorry it's a rewriting problem.
You may, as you said, be finding the problem is because of clicking with the mouse just before the time ...
Your command starts: "on destroyButton" but closes with "end destroySmiley" (so I would imagine it doesn't even compile properly...)
Sorry it's a rewriting problem.
You may, as you said, be finding the problem is because of clicking with the mouse just before the time ...
- Fri May 13, 2011 4:12 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: on keyDown problem
- Replies: 9
- Views: 6367
Re: on keyDown problem
Why do you have two "delete" handlers here?
One for delete the buttons when they are clicked and the other for delete them after a maximum displaying time.
Does it help if you change "keydown" to "keyup"?
No I've already tried it :wink:
After some tests I'm sure the "delete" command is the ...
One for delete the buttons when they are clicked and the other for delete them after a maximum displaying time.
Does it help if you change "keydown" to "keyup"?
No I've already tried it :wink:
After some tests I'm sure the "delete" command is the ...
- Fri May 13, 2011 1:27 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: on keyDown problem
- Replies: 9
- Views: 6367
Re: on keyDown problem
Hmm, I notice something can help you.
The problem happen when I delete the button being clicked.
There are two way to delete a button:
on mouseUp
if the short name of the target contains "button" then
delete the target
end if
end mouseUp
####################################
on destroyButton ...
The problem happen when I delete the button being clicked.
There are two way to delete a button:
on mouseUp
if the short name of the target contains "button" then
delete the target
end if
end mouseUp
####################################
on destroyButton ...
- Fri May 13, 2011 12:17 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: on keyDown problem
- Replies: 9
- Views: 6367
on keyDown problem
Hi again :D ,
I have another script problem I really don't understand and do my project falling behind.
on keyDown myKey
answer "test"
end keyDown
This doesn't always work...
I make a game in wich buttons appear randomly in a group and are deleted if the user click on them. Sometimes after this ...
I have another script problem I really don't understand and do my project falling behind.
on keyDown myKey
answer "test"
end keyDown
This doesn't always work...
I make a game in wich buttons appear randomly in a group and are deleted if the user click on them. Sometimes after this ...
- Fri May 06, 2011 10:24 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Global problems
- Replies: 11
- Views: 7772
Re: Global problems
It works!
Thank you all, mostly Klaus
Thank you all, mostly Klaus
- Thu May 05, 2011 10:27 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Global problems
- Replies: 11
- Views: 7772
Re: Global problems
Up!
Maybe I can solve my problem if it possible to call a function of a card in another one. You know the way to do this?
Maybe I can solve my problem if it possible to call a function of a card in another one. You know the way to do this?
- Wed May 04, 2011 2:33 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Global problems
- Replies: 11
- Views: 7772
Re: Global problems
I'm making a game with friends, my button must appear for a while and be deleted.
So in the button card I've a the script (inject with the code in my previous post):
global TTL // time to live
put 4 into TTL
// TTL down to 0 each second
on deleteTime
put TTL - 1 into TTL
send "deleteTime" to ...
So in the button card I've a the script (inject with the code in my previous post):
global TTL // time to live
put 4 into TTL
// TTL down to 0 each second
on deleteTime
put TTL - 1 into TTL
send "deleteTime" to ...
- Wed May 04, 2011 2:00 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Global problems
- Replies: 11
- Views: 7772
Re: Global problems
Oh...
That I really do is put automaticly a script in a button with the line:
set the script of the templateButton to buttonscript
and thereafter I would to modify the value of these buttons.
It would be more easy if every button would have the same name! The only way to fix is to assign a ...
That I really do is put automaticly a script in a button with the line:
set the script of the templateButton to buttonscript
and thereafter I would to modify the value of these buttons.
It would be more easy if every button would have the same name! The only way to fix is to assign a ...
- Wed May 04, 2011 1:39 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Global problems
- Replies: 11
- Views: 7772
Re: Global problems
My problem is all of the buttons get a variable with the same name (in the button script).
So when in my main card I want to check the value, I can't only do
because the script don't know which one to choose!
So when in my main card I want to check the value, I can't only do
Code: Select all
global globalVariabeValue
answer globalVariabeValue- Wed May 04, 2011 1:26 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Global problems
- Replies: 11
- Views: 7772
Global problems
Hi everybody, before to start I want you to know I'm a french student, so excuse me for my english.
I get a problem with global variables and global functions (even I don't know if this keyword can be apply for a function).
Here is the problem, I have some buttons with the same script inside, so ...
I get a problem with global variables and global functions (even I don't know if this keyword can be apply for a function).
Here is the problem, I have some buttons with the same script inside, so ...