damage

Topics regarding Scripting with Reality Factory
Post Reply
User avatar
darksmaster923
Posts: 1857
Joined: Wed Jan 03, 2007 10:32 pm
Location: Huntington Beach, California, USA

damage

Post by darksmaster923 »

my knife does do no damage
Herp derp.
User avatar
Juutis
Posts: 1511
Joined: Thu Jan 12, 2006 12:46 pm
Location: Finland

Post by Juutis »

There could be a lot of reasons for that...
Please give us some more info, and maybe we could help then.
For starters... it would be helpful if you posted the weapon definition for your knife.
Pain is only psychological.
User avatar
darksmaster923
Posts: 1857
Joined: Wed Jan 03, 2007 10:32 pm
Location: Huntington Beach, California, USA

Post by darksmaster923 »

[Knife]
type = weapon
slot = 0
firerate = 0.4
catagory = melee
attribute = enem_health
damage = 500
altdamage = 500
ammunition = stamina
ammopershot = 2
attacksound = weapon\swishgen.wav
hitsound = weapon\slah.wav
emptysound = weapon\swishgen.wav
meleeammoactivate = true

;
; 1st person
;
viewactor = Weapon\Knife\knife.act
viewfillcolor = 128 128 128
viewambientcolor = 128 128 128
viewrotation = 310 90 0
viewoffset = 30 -30 -60
viewscale = 1
viewanimspeed = 1
viewarmanim = arm
viewidleanim = idle
viewattackanim = slash
viewaltattackanim = slash
viewhitanim = slash
viewalthitanim = slash
viewwalkanim = walk
;
; 3rd person
;
playeractor = Weapon\Knife\knife.act
playerfillcolor = 128 128 128
playerambientcolor = 128 128 128
playerrotation = 0 180 0
playerscale = 1
playerlaunchoffset = 0 0 10
playerbone = BIP01 R HAND
Herp derp.
User avatar
Juutis
Posts: 1511
Joined: Thu Jan 12, 2006 12:46 pm
Location: Finland

Post by Juutis »

Hmm... I don't see anything wrong with it.
Double check that the entity you're trying to damage has 'enem_health' attribute as health attribute.
In addition, make sure you have a couple of blank lines in the end of your weapon.ini file.

Does the weapon work correctly exept the damaging issue? Like play the animations and sounds?
Pain is only psychological.
User avatar
darksmaster923
Posts: 1857
Joined: Wed Jan 03, 2007 10:32 pm
Location: Huntington Beach, California, USA

Post by darksmaster923 »

ah. typo. its supposed to be enemy_health
Herp derp.
Post Reply