This site requires JavaScript, please enable it in your browser!
Greenfoot
Username
Password
Remember Me?
Sign Up, Lost Password
Activity
About
Documentation
Download
Discuss
Scenarios
Discussions
You need to login to take part
Current Discussions
How can I let enemies shot in my direction?
By moraisai, with 4 replies.
Last reply by moraisai, over 10 years ago:
It works! Thank you
How can I make my actors to automatically try to reach specific objects, which they should eat to win the game?
By CSBossmann, with 6 replies.
Last reply by danpost, over 10 years ago:
What are the SharkEins objects shooting at -- I mean, if it takes one to 'see' a Robbe to 'eat' one? Anyway, you need to basically change what is in your 'move' method. You probably want that the closest Robbe object be the one the actor moves toward. That will require determining which one is closest, turning toward its location and moving. See what you can come up with, a continue discussion with issues.
How can i make a car do a loop from one side of the world to another
By dyl_fisher, with 1 reply.
Replied to by danpost, over 10 years ago:
When (or 'if') the car returns a 'getY' value of zero, set its location to (getX(), getWorld().getWidth()).
How can I show how many lifes my figure has left?
By moraisai, with 1 reply.
Replied to by danpost, over 10 years ago:
Create an Actor object, give it the image of the text you want to display and add the actor into the world (or use the 'showText' method of the World class). For a more detailed response, show what you tried, code-wise.
How can I spawn something at a specific amount of points?
By moraidai, with 3 replies.
Last reply by moraidai, over 10 years ago:
Thanks http://www.stupidedia.org/stupi/Fick_dich_ins_Knie
Change Image of a class?
By ProfessionalNoob, with 6 replies.
Last reply by Super_Hippo, over 10 years ago:
ProfessionalNoob wrote...
Thank you, but I'm wondering how I can make this so that it restricts to the card location? I want it so that you can see your own cards, but not the other persons.
<Code Omitted>
Deleting a actor
By KiwiMC1482, with 5 replies.
Last reply by danpost, over 10 years ago:
KiwiMC1482 wrote...
I'm having a little trouble with the syntax for the if statement so when backspace is pressed it removes the minim I put what you'd expect like if("backspace.equals(Greenfoot.getKey() etc but it doesn't seem to be working for me
You should copy/paste your code into your posts using the code link below the reply box. When syntax is involved, it is even more important that you show what you are actually using -- exactly.
How can I have an actor do something different on the same click?
By decadence18, with 4 replies.
Last reply by decadence18, over 10 years ago:
danpost wrote...
In my code-post above, lines 2 through 4 are supposed to be fields in the class (declared outside of any method, but still within the class brackets). Then, line 6 was only given to exemplify the following procedure for the toggling of the numbers. Throwing it all together like you did will not work because line 8 in you code will always set the value of the field to the same initial number for line 10 to deal with. By moving your lines 6 through 9 outside the method, they are only set once, when the object of the class is created. Since you only have two states and you do
How can i let the game start after a specific amount of time?
By CSBossmann, with 1 reply.
Replied to by Super_Hippo, over 10 years ago:
Create the button at the beginning. Write a method which let all other actor spawn, but don't call it yet. Either save a reference to this button and check if it is clicked, or do it in the button class.
A little Help with my project
By Neco, with 3 replies.
Last reply by Neco, over 10 years ago:
Oh CAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAARL... THanks Super_Hippo, thats what I needed ^^ Jup, already tryed the one World for every Level and every world extending one world class, but didnt get either one working good, but now I should get it ^^
How can I make a part of my World not accessible for my actors?
By CSBossmann, with 2 replies.
Last reply by CSBossmann, over 10 years ago:
Thank you! :D
How do I make turns in a chess game?
By astronomer800, with 2 replies.
Last reply by astronomer800, over 10 years ago:
Thanks. Moving the turn variable into the world subclass worked for switching turns.
CARD GAME: PAIRS
By aconal, with 3 replies.
Last reply by aconal, over 10 years ago:
It works, I´ll upload it soon. Thanks!
Hey guys, I'm a newbie to Greenfoot, teaching it to Y8 class down here in New Zealand. Hoping someone could help me...
By johansj, with 4 replies.
Last reply by johansj, over 10 years ago:
Thanks guys, I will try that out and see how we go. Cheers again J
Help on Blackjack dealer not working
By 1920, with 6 replies.
Last reply by danpost, over 10 years ago:
1920 wrote...
would I need to rewrite all the code in the World class to run the hands?
This code appears to be in an Actor subclass. I would think the general running of the hands should be done in your World subclass.
I need not say more.
587
588
589
590
591
592
593
X