RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
[Request] Autorun spikes?

0 Members and 1 Guest are viewing this topic.

**
Rep: +0/-0Level 64
RMRK Junior
Hey, so what I'm trying to do is to make spikes that automatically run(pop up and down) like in most games...thats no problem with the normal autorun event command but I'm having some confusion with how to make the spike damage the player 10-25 damage when he/she is touching the spikes while they are up. The variable I use for the spikes is 007

***
Rep:
Level 75
use the autonomous movement feature by the character graphic then in the main section set activate on player touch and with change health to -25 and add player step back to the end so it does not repeat till you touch it again

Spoiler for:



Spoiler for:
John 3:16: For God loved the world so much that he gave his one and only Son, so that everyone who believes in him will not perish but have eternal life

**
Rep: +0/-0Level 64
RMRK Junior
Um...I'll post how I have the script
Page 1
Code: [Select]
Direction Fix = On
Priority = Below Character
Trigger = Autorun

Events:
Wait: 120 Frames
Control Self Switch: A =ON
Page 2
Code: [Select]
Direction Fix = On
Priority = Same as Character
Trigger = Player Touch
Control Self Switch = A is on

Control Variables:[0007:Spikes] -= Random No. (10...25)
Set Move Route: Player (Wait): $> 1 Step Backward
Change HP: [], +Variable [0007:Spikes]

I don't know how to make it go back to normal(page 1) when it doesnt touch the player or when it does
« Last Edit: November 11, 2011, 03:54:33 AM by MajikalBlood »

**
Rep: +0/-0Level 64
RMRK Junior
Can anyone help me with this? This will improve my dungeons in my game

****
Rep:
Level 71
Try using player touch on the first line, and set the second to parallel process also put self switch A=OFF at the end and make sure page two has self switch A set in conditions. For auto run set parallel on the first page as well.

**
Rep: +0/-0Level 64
RMRK Junior
But see, I only know how to make it damage the player if he touches it;


 I want it to continuously change from page 1 to page 2 on a timer of 3 seconds but if the player touches while its on page 2 it damages him and if he goes across it while on page 1 nothing happens

**
Rep: +0/-0Level 64
RMRK Junior
Still no help on this...

**
Rep: +0/-0Level 64
RMRK Newbie
Hope isn't too late but here is my demo with autorun spikes using 4 variables and 2 events.
http://www.mediafire.com/?6eij73s879n9zac