Welcome, Guest. Please login or register.
Kingdoms of Ahln
Pages: [1]
  Print  
Author Topic: KAMS 0.2.2 Released  (Read 372 times)
Justin
Administrator
Citizen
*****
Posts: 189



View Profile
« on: March 02, 2009, 11:06:28 pm »

Bet you didn't see this one coming!

I forgot to add the check to see if a player is attacking themselves. That's all that is new in this release, but I wanted to get it out there.

Here's the entirety of the change:
Code:
Index: events/combat.rb
===================================================================
--- events/combat.rb (revision 157)
+++ events/combat.rb (working copy)
@@ -165,6 +165,9 @@
  elsif not target.is_a? LivingObject
  player.output "You cannot attack #{target.name}."
  false
+ elsif target == player
+ player.output "You cannot attack yourself."
+ false
  else
  true
  end

You can download it from the usual place.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by SMF 1.1.15 | SMF © 2006-2009, Simple Machines
Terra97 design by Bloc