Hey guys I have a question
Moderators: Commodore, Zenith Nadir
- Zandor 12
- What has science done???
- Posts: 355
- Joined: Wed Mar 12, 2003 5:19 am
- Location: Neo Dakota
- Contact:
Hey guys I have a question
Is it possible for an object to #send itself to different labels while it's #locked? Because I'm having a lot of trouble with some animations in an RPG battle I'm working on for the game I said I'd have done four months ago but then :ssssss: happened and video killed the radio star so yeah. I know that a #locked object can't be #sent by other objects, but can it still manipulate its own code or am I going to have to take the hard route and mess with the /is by trial and/or error?
Reason and logic had led people into the horrors of war; the only route to salvation was to reject logic and embrace anarchy and the irrational.
- Dr. Dos
- OH YES! USE VINE WHIP! <3
- Posts: 1772
- Joined: Tue Mar 11, 2003 12:00 am
- Location: Washington
:bob
#zap billy
IMPORTANT CODE THAT MUST OCCUR BEFORE :BILLY HAPPENS
#restore:billy
#end
:billy
I HOPE THAT IMPORTANT CODE HAPPENED.
:billy
#end
#zap billy
IMPORTANT CODE THAT MUST OCCUR BEFORE :BILLY HAPPENS
#restore:billy
#end
:billy
I HOPE THAT IMPORTANT CODE HAPPENED.
:billy
#end
Visit the Museum of ZZT
Follow Worlds of ZZT on Twitter
Apologies for the old post you may have just read.
Follow Worlds of ZZT on Twitter
Apologies for the old post you may have just read.
- Zandor 12
- What has science done???
- Posts: 355
- Joined: Wed Mar 12, 2003 5:19 am
- Location: Neo Dakota
- Contact:
This is the code, I probably should've posted it earlier:
I cut out a lot of irrelevant stuff, the full object is almost 3kb. The point of this is that one of the enemies in the RPG battle fires a laser by #putting w purple boulders and then doing a bunch of #changes. The laser pierces through the character, by way of the character being sent to :react at just the right moment and #putting more boulders to complete THE MAGICAL ILLUSION. But for some reason, he only goes through the loop once before ending. I'm at something like 19,770 bytes so I have basically no room left, hence the loop. The #lock is because due to space I have to use some #send others:dndndndn to move objects out of the way of the laser.
...only that occurs long before the character gets hit by the laser...
Well, I've lost track of my own code. Back to ZZTAE.
Code: Select all
@You
#end
:react
#lock
#play t+++fffe
#char 153
#play --c+c-d#+d#
#put w purple boulder
#char 148
:ne
:ne
:ne
:ne
:ne
#put w purple boulder
#put w purple boulder
#zap ne
#send self:ne
:ne
#restore ne
#unlock
#end
...only that occurs long before the character gets hit by the laser...
Well, I've lost track of my own code. Back to ZZTAE.
Reason and logic had led people into the horrors of war; the only route to salvation was to reject logic and embrace anarchy and the irrational.
- Zandor 12
- What has science done???
- Posts: 355
- Joined: Wed Mar 12, 2003 5:19 am
- Location: Neo Dakota
- Contact:
It turns out that the code was working perfectly after all. I had some inivisible objects in the path of the laser, and I set them to move further into the laser when it fired instead of moving out of its way, making the laser all garbled and stuff.
This thread is now about Tetris.
I say the best version is Tetris DX
This thread is now about Tetris.
I say the best version is Tetris DX
Reason and logic had led people into the horrors of war; the only route to salvation was to reject logic and embrace anarchy and the irrational.