ceciroth
RPG Maker-in-Training
Posts: 11
|
Post by ceciroth on Jan 1, 2007 20:35:20 GMT -5
Hi. I'm trying to alter the Wander Script, or simply rewrite it, so that the event sometimes pauses between steps. I find that actually interacting with a constantly moving NPC event can be tough.
My thoughts on it are thus: Within the action script (I'm not familiar with action scripts per se, and it might be because of that definition that this isn't working...), I have a variable assigned with a random number between 1 and 2... if the number is 1, I give a wait command and if 2, then it simply goes back to the random movement command. This doesn't work. So, I tried to embed the actual movement within a script branch which needed a 1 to execute... the number being generated every time the script loops... This doesn't work either, as the NPC now just stands there.
Do action scripts only execute once and then store that movement in memory or do they loop? If they only store it in memory, is there any way you can think of which would allow these NPCs to pause every now and then?
Thanks!
|
|
|
Post by realitybites on Jan 2, 2007 2:14:36 GMT -5
This has been done, are own Doan, figured this out. Clicky
|
|
ceciroth
RPG Maker-in-Training
Posts: 11
|
Post by ceciroth on Jan 2, 2007 12:03:32 GMT -5
Though that is really cool, I'm thinking of the NPCs, actually. I'm looking for a way to pause the NPC's motion so that you can more easily speak with them, yet they still have random movement.
|
|
|
Post by Neo Samurai on Jan 2, 2007 12:45:31 GMT -5
Hmm... I'll give it a try. It definitely is possible, just requires more script commands than a simple "event movement" command. Besides, it's been a while since I played around with RPGM2. It might be fun.
|
|
|
Post by NASH7777 on Jan 2, 2007 13:59:42 GMT -5
The problem is that when an event tries to execute a walk and they run into a wall, the action script will stop completely until they can move how the script intended and if it's a wall that doesn't move...like most walls. then you're screwed. In order to alter the wander command what you have to use is the duplicate and remove commands and use the default wander command in conjunction. This way you can use the wander control while setting other effects based on conditions or random methods.
|
|
ceciroth
RPG Maker-in-Training
Posts: 11
|
Post by ceciroth on Jan 2, 2007 15:09:48 GMT -5
Though I'd love to be able to say that I understand what you mean, Nash, I don't. I've never worked with the duplicate and remove commands, nor do I understand how they function or how you might go about using them to add a potential pause to a wander script.
|
|
|
Post by NASH7777 on Jan 2, 2007 17:30:53 GMT -5
Duplicate allows you to create a new event on the map live in the game play in reference to the location of the event using the script. Remove get's rid of the current event
This allows me to have an event doing something then I make a new event(even the same one) and delete the current. This allows to re-start the action script, giving the chance to reset condition checks when otherwise your event's movements would have to stay in a pattern "to part/wander/etc" but now it can change. To execute this: ACTION SCRIPT BLAH BLAH Apply together call condition check action: wander
then in the called condition check, when certain conditions are made, you duplicate and remove and can apply a different event or page of the same event or even just branch of their action script.
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Mar 28, 2007 2:06:14 GMT -5
|
|