![]() |
Help me with script, etc.
Here's my basic menu item buying script. And yes, I DO realize how long it is:
NPC Code: Okay, looks fine and stuff. Only problem is, if I have two merchants with this script in the same level, the script malfunctions and ceases to freeze the player. How can I remedy this? |
Re: Help me with script, etc.
Quote:
|
maybe add a
if (playerchats && stequals(#c,Buy from merchat 1)) { set buyingfrommerchat1; } and then at the begining of your script add this to the "if (playertcouchsme)" if (playertouchsme && buyingfrommerchat1) { and then just add an "unset buyingfrommerchat1" at the end? and then change it for each merchat or npc to buyingfrommerchat2 or whatever flag you want to use? |
Quote:
|
Quote:
i know very little..... maybe just add a name to the merchants then? and a sign that says you have say the merchants name to buy from them?? i dont know about tokenize yet so maybe Jerom is right? I wouldn't know though ;) |
Quote:
And I'm still learning how to script too(isawk). |
I think Xavier is right:
if(keydown(5)&&this.buymode=1){ message ; this.buymode = 0 enabledefmovement; hideimg 200; hideimg 201; hideimg 202; hideimg 203; hideimg 204; } if(this.buymode=0){ enabledefmovement; } take the last one because if u buy from the second merchant this buymode of the first one is 0 so u can move but number 2 siabled so you collaps :) u have used enabledefmovent before so it should be enough... |
Quote:
Second of all, I don't know if I was the only person that had trouble following the wording and bad spelling of that, so here's my interpretation(sp?): Delete the if (this.buymode==0) {enabledefmovement;}..You don't need it |
Hmmm to many thoughts (my english teacher has the same problems) ;)
|
Quote:
|
Amazing
|
dont use disable/enable movement in that script, instead just put a freezeplayer timeoutsecs; in the timeout loop, with timeoutsecs = to the length of the timeout
and make sure that when the player is not in the menu mode the timeout is not looping |
name the first guy 'fingerme joe' and the second plain old 'bob mackey'
|
| All times are GMT +2. The time now is 01:06 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.