Jump to content
  • 0

R> Add 10 secs respawn time after player character death


CyanZoldyck

Question


  • Group:  Members
  • Topic Count:  10
  • Topics Per Day:  0.01
  • Content Count:  31
  • Reputation:   0
  • Joined:  01/09/21
  • Last Seen:  

Hi! Is it possible to automatically add a 10 secs respawn time after player character has been killed? Is it possible to disable the "Return to last save point" and then just automatically respawn the player character to his savepoint after 10 seconds? Thank you!

image.png.1e7c412c8306c56a66ce827893cea2b1.png

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 1

  • Group:  Members
  • Topic Count:  25
  • Topics Per Day:  0.01
  • Content Count:  283
  • Reputation:   76
  • Joined:  06/13/13
  • Last Seen:  

CMIW, if you want to disable that you should modify the client, iirc I have tried to disable that long time ago but failed, so I took another approach disabling code on that responding to packet send client when player clicking menu on that. You can disable the response of that menu on src/map/clif.cpp "clif_parse_Restart"

Then about "automatically add a 10 secs respawn time after player character has been kill" you can increase the tick in code that used on pc_dead in file src/map/pc.cpp

this code would auto respawn the dead in 1 second (1000), you can alter it to your need.

sd->respawn_tid = add_timer(tick + 1000, pc_respawn_timer, sd->bl.id, 0);

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  10
  • Topics Per Day:  0.01
  • Content Count:  31
  • Reputation:   0
  • Joined:  01/09/21
  • Last Seen:  

Worked like charm. Thanks so much!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...