Victory Road Archive

You are viewing an archive of Victory Road.

Victory Road closed on January 8, 2018. Thank you for making us a part of your lives since 2006! Please read this thread for details if you missed it.

Technology → Some funny code

Page 1 of 1

1. SpaceMan++ said on April 3, 2009, 11:22:49 PM (-07:00)

Zoroark
288 posts

Code:
//
class Animal { }
 class Cat extends Animal { }
  class Lolcat extends Cat { }
  class Longcat extends Cat { }
   class Tacgnol extends Longcat { }
 class Pokemon extends Animal { }
 class Human extends Animal { }
  class Trainer extends Human { }
//
while (Universe.hasMoreSpaceFor(longcat)) {
	longcat.length ++;
}
//
for (Cat lolcat : lolcats) {
	you.look(lolcat);
	you.lol();
}
//
if (lolcat.isHungry()) {
	if (lolcat.canFind(Cheeseburger.class)) {
		Cheeseburger chezburgr = (Cheeseburger) lolcat.find(Cheeseburger.class);
		lolcat.eat(chezburgr);
	} else {
		lolcat.die();
	}
}
//
while (you.hasMoreIdeas()) {
	Idea idea = you.nextIdea();
	if (idea instanceof Lolcat.Idea) {
		Image lolcatimage = you.getSkills(Skill.PHOTOSHOP).makeFromIdea(idea);
		Internet.post(lolcatimage, Internet.Type.IMAGE);
	}
}
//
try {
	Bomb[] bombs = (Bomb[]) you.onHand();
	for (Bomb bomb : bombs) {
		if (you.canFind(Human.class)) {
			Human target = you.find(Human.class);
			you.throwObject(bomb, target);
		}
	}
} catch (ClassCastException e) {
	while (you.canFind(Bomb.class)) {
		you.get(you.find(Bomb.class));
	}
}
//
if (PokemonWorld.inBattle(you)) {
	Pokemon wildPkmn = you.find(Pokemon.class);
	Pokemon yourPkmn = you.getParty().getPokemon("Turtwig").send();
	while (! wildPkmn.getStatus(Pokemon.FAINT)) {
		if (wildPkmn.getHp > 0.5) {
			yourPkmn.useMove("Tackle", wildPkmn);
		} else {
			Object result = ((PokeBall) you.getBag().find("Pok\x00E9 Ball")).throwAt(wildPkmn);
			if (result != null) {
				((Pokedex) you.getItem("Pok\x00E9dex")).register(wildPkmn);
				break;
			}
		}
	}
}

2. Anthony the Lucario said on April 10, 2009, 10:00:16 AM (-07:00)

Charizard
134 posts

reminds me of Lua almost, but looks a little different

function playerEntered(newPlayer) --[[This is Lua]]
if script:findFirstChild("Password") ~= nil and script:findFirstChild("Password"):findFirstChild(" Value") == "All your base are belong to us." then
newPlayer.Humanoid.Health = 100
else
newPlayer.Humanoid.Health = 0
end
end
game.Playerslayer.added:function(playerEntered(n ewPlayer)) --[[this is a script i used on Roblox to prevent people from stealing my level]]

Page 1 of 1

User List - Contact - Privacy Statement - Lycanroc.Net