Jump to content

Problem with .getdead


Dylak

Recommended Posts

Hello

Can someone check what is wrong with my script.

I can save it but it isn't have any effect in game

scn qsz1


Begin gamemode
if (aaqszaa.getdead == 1)
rewardxp 500
endif


end

In attach i pointed what could I have done wrong

Link to comment
Share on other sites

Dylak - Hello!

As blove asks, what have you attached the script to?

If you made a unique copy of that LvlRaiderGun that must be killed for the XP points, you could attach an OnDeath script directly to them.

Something like:

scn qsz1

Begin ondeath
rewardxp 500

end

Tha would award the player 500 XP on the LvlRaiderGun death.

Make sure, if you do attach the script to them, that it's your own unique copy of LvlRaiderGun or else the script will be on all of them. :)

Call your version something new like LvlRaiderGunBrucieBonus or something.

You could even use a

If IsKiller player

In there if you wanted to only give XP if the player kills them, like so:

scn qsz1

Begin ondeath
If IsKiller player
rewardxp 500
endif

end

You can also attach your version of the script to a quest as blove says, I've not done that myself so I'll leave explaining that to blove. :)

Information on creating quests here:

http://geck.bethsoft.com/index.php/Bethsoft_Tutorial_Basic_Quest

It depends on what you want to do.

Hope this helps!

Prensa

Link to comment
Share on other sites

-Blove -I created quest but I could forgot to attach this script to it. I will check it tomorrow because i don't have access to my computer with g.e.c.k.
-Prensa - I made that script because i was trying to make script with more conditions and it din't work correctly. I found out it is fault of that part and i remove rest to check what is wrong with it. I used rewardxp because it seams to be one of the easiest functions.

 

And i have another question. I have to create a quest and attach the script to it even if i want to write a simple script which add some xp or items when all conditions are completed ?

 

Thanks both of you for quick answers

 

Edited by Dylak
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...