View Full Version : Im stuck :(
thecrackfox1983
13-05-11, 03:28 PM
I have been playing around with dizzyage all day. Im not sure where ive been staring at the screen its made me miss a simple thing but I cant climb the ivy.
I have had the ivy disabled until I place the seeds on the marker then I set the disable to 0.
All works well, as in the ivy appers and now shows but even though I have it set to climb material I cant climb it.
its set 2;
type = dynamic
material = climb
disable = yes (this i change to no in the script)
When It gets undisabled the climb just does not seem to work.
Any help would be great
thecrackfox1983
13-05-11, 06:09 PM
Dont worry yours looks alot better than the most of mine.
This is what I have got and now tried to add your part.:v2_dizzy_confused2:
Its still coming up an error.
Could you please tell me where I have gone wrong and why I have gone wrong if you can
//////////////////////////////////////////////////////////
//growing the vines
//////////////////////////////////////////////////////////
func UseObject_2026( idx )
{
if(ObjGet(idx,O_ID)==2025)
{
Message1(5,4,"YOU PLANT THE SEEDS");
Message2(4,6,"THE VINE GROWS");
MessagePop();
InventorySub(idx);
idx = ObjFind(2027);
ObjSet(idx,O_DISABLE,0);
idx = BrushFind(2027);
BrushSet(idx,B_DRAW,3);
GameCommand(CMD_REFRESH);
return;
}
else
{
DropObject(idx); //take item from inventory
}
}
Thank you very much for your time.
idx = ObjFind(2027); <------------ I think you can delete this.
ObjSet(idx,O_DISABLE,0); <--------- and this.
make sure the rope is static and Draw O in map
Remember in the script Brush is for static and Object is for dynamic.
It can't be both which is what you've put in your code.
yes, Meph is correct. :)
One of the hardest things to start with is learning the difference between Static (B_) and Dynamic (O_) objects.
thecrackfox1983
14-05-11, 06:38 AM
Yes that has worked now.
Thank you all very much for helping. I think this is starting to sink in. its slow but im getting there :)
thecrackfox1983
14-05-11, 02:56 PM
Sorry about this just stuck on the coding again.
This time I have a trigger object that I want to cause a conversation but i dont want to drop the item or it to do anything.
I know I should know this and thats why its winding me up grrrr.
I think the status needs to change but im not too sure how. This is what I have done that does not bring up the conversation :(
func ActionObject_1004() // the trigger object
{
idx = ObjFind(1004);
if(ObjGet(idx,O_STATUS)==0)
{
Message0(5,4,"THE DOOR IS LOCKED");//message dialog
ObjSet(idx,O_STATUS,1);
}
idx = OpenDialogInventory();
if(idx!=-1) UseObject(idx);
}
func UseObject_1004( idx ) //the trigger object
{
if(ObjGet(idx,O_ID)==2003) //the item 2 cause the trigger i.e. key
{
Message0(5,4,"THE LOCK IS JAMMED THIS SIDE");//message dialog
MessagePop();
return;
}
}
again many thanks for your help
I'm writing this on my phone, but that code looks fine from here.
Only thing I can suggest is that you might have set the status of obj 1004 as something other than 0 (default is 0)
EDIT:: you've missed out MessagePop from your first message, but that'll not stop it popping up (it'll just stop you exiting the message ;) )
Are you saying when you action the trigger the message wont come up?
Make sure the trigger is indeed actionable.. check it's properties.
This is the sort of thing i used.
func ActionObject_1004()
{
idx = ObjFind(1004);
if(ObjGet(idx,O_STATUS)==5)
{
idx = OpenDialogInventory();
if(idx!=-1) UseObject(idx);
return;
}
idx = ObjFind(1004);
if(ObjGet(idx,O_STATUS)==0)
{
Message1(5,4,"the door is locked");
MessagePop();
ObjSet(idx,O_STATUS,5);
}
}
func UseObject_1004( idx )
{
if(ObjGet(idx,O_ID)==2003)
{
Message0(5,4"THE LOCK IS JAMMED THIS SIDE");
MessagePop();
GameCommand(CMD_REFRESH);
return;
}
}
thecrackfox1983
14-05-11, 06:01 PM
The first message strand comes up fine.
So it says "THE DOOR IS LOCKED"
Its the second one when I want it to say. The doors locked on the other side that is not showing.
Its still not working. It lets me open the inventory but does not even let me place the key down.
if you copy and past in that code i posted and make sure the triggers properties are correct theres no reason why it shouldn't work. Delete the tigger from the map and do it again.
or
ObjSet(idx,O_STATUS,1); try changing it to a 5.. all mine in my game are fives and they work fine. i only use 1 when an object is meant to move (5 is also used in the manual)
The code, as I said, looks fine. Nothing wrong with it.
I've added the bit in red which allows you to drop an item if it's not the one you use.
The only thing I can suggest is that you're simply using the wrong item on it!
func ActionObject_1004() // the trigger object
{
idx = ObjFind(1004);
if(ObjGet(idx,O_STATUS)==0)
{
Message0(5,4,"THE DOOR IS LOCKED"); // message dialog
ObjSet(idx,O_STATUS,1);
}
idx = OpenDialogInventory();
if(idx!=-1) UseObject(idx);
}
func UseObject_1004( idx ) // the trigger object
{
if(ObjGet(idx,O_ID)==2003) // the item 2 cause the trigger i.e. key
{
Message0(5,4,"THE LOCK IS JAMMED THIS SIDE"); // message dialog
MessagePop();
return;
}
else
{
DropObject(idx);
}
}
also, quote this post to see how to display the coding as above. :)
GameCommand(CMD_REFRESH);
Meph, I don't know why you have this bit in your code, but you're not changing any Static Brushes, so you don't need it :)
Meph, I don't know why you have this bit in your code, but you're not changing any Static Brushes, so you don't need it :)
oh well, i've always had it in.
thecrackfox1983
15-05-11, 10:29 AM
Sorry I was being an idiot.
It was the right code but I for some reason put the item code in wrong :dizzy_mad:
Thank you all anyway :v2_dizzy_yahoo:
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.