Working on a script, Surlaw helped me by setting it up, but when I go to compile it gives me an error. Can anyone help out as to why it might be messin up? I've been messing with it for a while. Different things happen based on how far away you are from the NPC in question.
if
(distance < 10)
then(heatsensorverynear)
if
(distance > 10),and, (distance < 30)
then(heatsensornear)
if
(distance > 30),and, (distance < 60)
then(heatsensormedium)
if
(distance > 60)
then(heatsensorcold)
end
Check out Red Triangle Games!
Try this:
if
(distance > 10,and,distance <30)
then(heatsensormedium)
I think it was just closing the parenthesis too early.
Super Walrus Land: Mouth Words Edition
if
(distance > 10,and,distance <30)
then(heatsensormedium)
I think it was just closing the parenthesis too early.
Super Walrus Land: Mouth Words Edition
If you do use >= and <= be sure to rewrite the numbers as:
if
(distance <= 10)
then(heatsensorverynear)
if
(distance => 11,and,distance <= 30)
then(heatsensornear)
if
(distance >= 31,and,distance <= 60)
then(heatsensormedium)
if
(distance >= 61)
then(heatsensorcold)
Super Walrus Land: Mouth Words Edition
if
(distance <= 10)
then(heatsensorverynear)
if
(distance => 11,and,distance <= 30)
then(heatsensornear)
if
(distance >= 31,and,distance <= 60)
then(heatsensormedium)
if
(distance >= 61)
then(heatsensorcold)
Super Walrus Land: Mouth Words Edition
I wrote it perfectly and then it got screwed up when I tried to post (disabling HTML, BBCode, and smilies was needed) so I just recopied it from the original post and didn't fix it this time
You're right, I was writing this without access to anything OHR related and it's been too long since I scripted much so I knew I'd miss little things.
Super Walrus Land: Mouth Words Edition
Calehay wrote:
On that same note, if you really want "greater than" or "less than," you have to use two symbols instead of one. (>> and << respectively.)
You're right, I was writing this without access to anything OHR related and it's been too long since I scripted much so I knew I'd miss little things.
Super Walrus Land: Mouth Words Edition
K, well Spoonweaver, you helped me indirectly. I had posted this error, and then Worthy helped me sort it out, but now, my Bat Radar isn't working properly.
#if (distance<2)
# story scripts for mission
if
((distance <= 5))
then(heatsensorverynear)
if
((distance >= 5),and, (distance <= 20))
then(heatsensornear)
if
((distance >= 20),and, (distance <= 40))
then(heatsensormedium)
if
((distance >= 40))
then(heatsensorcold)
Any chance this is based on something besides tiles? Because it stays bright red (verynear) until I walk WELL over 5 tiles away. Thoughts? Surlaw you wrote this puppy, any ideas on the math part earlier in the script, I didn't post it here because I didn't want to ruin the secret boss.
Check out Red Triangle Games!
#if (distance<2)
# story scripts for mission
if
((distance <= 5))
then(heatsensorverynear)
if
((distance >= 5),and, (distance <= 20))
then(heatsensornear)
if
((distance >= 20),and, (distance <= 40))
then(heatsensormedium)
if
((distance >= 40))
then(heatsensorcold)
Any chance this is based on something besides tiles? Because it stays bright red (verynear) until I walk WELL over 5 tiles away. Thoughts? Surlaw you wrote this puppy, any ideas on the math part earlier in the script, I didn't post it here because I didn't want to ruin the secret boss.
Check out Red Triangle Games!
Write a line to display the value of the distance variable on the screen so you can see what it's displaying as and let me know if the numbers look wrong. I think it just needs to be "show value (distance)" right?
Also you could try "hero pixel x (find hero whatever)" in the heat sensor scripts being called instead of just "hero x" to give yourself more precise control.
Super Walrus Land: Mouth Words Edition
Also you could try "hero pixel x (find hero whatever)" in the heat sensor scripts being called instead of just "hero x" to give yourself more precise control.
Super Walrus Land: Mouth Words Edition
The lower the values, the easier it is to see it change. But it doesn't seem to read accurately. I can send the game and script files over if need be.
Nevermind, the thing works, wonderfully now. Should make for a great dungeon mechanic.
Check out Red Triangle Games!
Nevermind, the thing works, wonderfully now. Should make for a great dungeon mechanic.
Check out Red Triangle Games!
Does anyone know if there's a command to change hero portraits like you can change hero battle and walkabout sprites? It'd be useful with the costume changes in my Batman game.
Thanks!
Check out Red Triangle Games!
Thanks!
Check out Red Triangle Games!



