4Dimensions Forum
February 09, 2012, 08:04:15 pm *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: This forum is very active and we are here to help.
Click here to get back to the main website: http://4dimensions.org
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Script death?  (Read 1278 times)
Asmodeus
Riddler
Full Member
***
Offline Offline

Posts: 139



View Profile
« on: August 19, 2010, 05:33:29 pm »

Another question... do we have a way in script to cause a player to die?  Its probably in the website or in the 4D advanced scripting stuff, but I cant find it.  In a room command script of mine...

I tried 'eval death %actor.hitp% + 1', and %damage% %actor% %death%, but that just caused them to be stunned until an imm restores/fixes them.

so then...

I tried 'eval death %actor.hitp% + 100', and %damage% %actor% %death% , and that caused them to die, but then when they showed up in the room they get sent to after death, it kept showing the message 'Lie Still, you're dead!! :-(' and stayed like that until an imm fixed them.

So finally I tried adding the %actor.pos(resting)% to the end of the 2nd option above, but although it set actor to resting and technically worked, it sent out a syslog error that says '[ Room 30774 :: Unknown world cmd: 'Resting' ]'

So yeah, it would be sooo much simpler if there a way to just %kill% %actor%, or whatever
Logged
Fizban
Maniacal Scroder!
Administrator
Full Member
*****
Offline Offline

Posts: 182


Fizban, the Mangy Wizard

Fizban1216@hotmail.com Fizban1216
View Profile Email
« Reply #1 on: August 20, 2010, 08:17:28 am »

So finally I tried adding the %actor.pos(resting)% to the end of the 2nd option above, but although it set actor to resting and technically worked, it sent out a syslog error that says '[ Room 30774 :: Unknown world cmd: 'Resting' ]'

%actor.anything%

should never be its own line.

nop %actor.pos(resting)%

is the proper syntax

There's no actual dg-command for what you're looking to do at the moment, one could probably added, but wouldn't be able to be %kill% because mkill is actually a command already for making mobs attack something as part of a script.
Logged
Asmodeus
Riddler
Full Member
***
Offline Offline

Posts: 139



View Profile
« Reply #2 on: August 20, 2010, 10:24:35 am »

nop... i knew that

*facepalm*


It'd be cool to have a death script, whatever the command may be... i just said %kill% to make my point, but knew it probably wouldn't work... maybe %pkill% or %murder% or something?  Anyway, in the mean time, ill just do it this other way.



--yay, 100 posts--
Logged
Diandra
Administrator
Full Member
*****
Offline Offline

Posts: 123


View Profile Email
« Reply #3 on: August 20, 2010, 12:38:55 pm »

Try adding 1000 instead of 100 - at least that seems to do the trick on the bp.

eval death %actor.hitp% + 1000
%damage% %actor% %death%

Also (but it seems in your case it's a roomtrigger so you can't use it for this script), with mobtriggers you can just use mslay:

mslay %actor.name%

Hope this helps.  Smiley
Logged
Diandra
Administrator
Full Member
*****
Offline Offline

Posts: 123


View Profile Email
« Reply #4 on: August 20, 2010, 12:41:27 pm »

Ugh, I stand corrected, I also get the 'Lie still; you are DEAD!!! :-( ' for the damage thing...

Hm... surely there's a way...


Unless... wasn't there in the past some script that slowly cured people in the healing temple? Maybe it's that script that's missing to revive people in the healing temple. Or is my memory playing tricks with me?



Okay last edit this time ;-)

Here's another way to do it, in the roomtrigger you created: load a wizinvis mob - have the wizinvis mob mslay the actor - purge the wizinvis mob.
« Last Edit: August 20, 2010, 01:01:43 pm by Diandra » Logged
Asmodeus
Riddler
Full Member
***
Offline Offline

Posts: 139



View Profile
« Reply #5 on: August 20, 2010, 01:20:41 pm »

this solves everything Diandra...

...
      eval death (%actor.hitp% + 100)
      %damage% %actor% %death%
      nop %actor.pos(resting)%
...


Thanks for all the ideas though!  I had considered the invis mob, but i didnt want to make an invis mob :p
Logged
Diandra
Administrator
Full Member
*****
Offline Offline

Posts: 123


View Profile Email
« Reply #6 on: August 20, 2010, 01:29:47 pm »

Sweet, now to add this in every room in Recall. *coughs*

Thanks for the solution, it's less work than mine ;-)
Logged
Prometheus
Administrator
Sr. Member
*****
Offline Offline

Posts: 266


View Profile
« Reply #7 on: August 21, 2010, 12:05:18 am »

Rofl I did suggested something similar but teleport idlers to Twitches Smiley

Prometheus
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.13 | SMF © 2006-2011, Simple Machines LLC Valid XHTML 1.0! Valid CSS!