DysoForums Forum Index DysoForums
GalleryGallery   Donate to DysotopiaDonate   Dysotopia.com homepageDyso.com
SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   StatisticsStats   RegisterRegister 
 Login to check your private messagesLogin to check your private messages   LoginLogin 


Post new topic   Reply to topic    DysoForums Forum Index -> Help
View previous topic :: View next topic :: Hide signatures  
Author Message

Joined: 07 May 2003
Posts: 16

Level: 2
EXP: 6 / 8 EXP: 6 / 8 EXP: 6 / 8
PostPosted: Thu Jul 03, 2003 11:14 pm    Post subject: HELP FIRE Reply with quote

Hey can ennt one help me whit the campfire sricpt i meen were i can set it up so you need a chapfire to rest and so wood can be chapfire...
plz help
Back to top
View users profile Send private message Send email
Marquis Drayfox
PostFri 07/04/03 4:32pm
This should belong in the "Worldbuilding" Forum.

 Reply with quote
Little Teapot

Joined: 11 Sep 2002
Posts: 2332

Level: 39
EXP: 31 / 160 EXP: 31 / 160 EXP: 31 / 160
PostPosted: Sat Jul 05, 2003 2:46 am    Post subject: campfire rest tutorial Reply with quote

Ok, I am doing this about 3 more times... then I'm going to go insane and help, instead of do things for people. in order to make a dysoesque campfire rest system, you need to make 4 things: 2 scripts, and item, and a placable.

The Item:
1) Make it miscellaneous thin (size/type doesn't matter, only the tag does)
2) Christen it "Firewood" for the purposes of this tutorial. give it the Unique power: Self Only (1 charge/use) "spell" ability. give it 3 (or however many times you want to be able to use it) charges.
3) make sure the tag is "firewood" for this.

The Placable:
1) Make a placable, preferably named "Campfire". do not touch the tag/resref that comes when you name the item.
2) make it plot, unless you want it to be destroyable, and if you want it to deal damage on a click, make it usable (I'm not doing that script for you in this post)
3) make it the campfire, no ambient appearance, of course, this assumes you want the normal campfire, and not an armoire.

The Scripts: Ok, so we need the item we made to make a campfire, and we want the campfire to be near when someone rests... to do that, I put this script in the OnItemUsed Event handle in Module Properties:
//:: Name: Firewood item fired
//:: FileName: itemfirecf.nss
//:: Copyright (c) 2001 Bioware Corp.
    Sample script for making an item make a campfire.
//:: Created By: Greggus Bakus
//:: Created On: Today

void main()
    object oItem = GetItemActivated();
    object oPC = GetItemActivator();
    location lTarget = GetItemActivatedTargetLocation();
    string sTag=GetTag(oItem);
    object working;

            working = CreateObject(OBJECT_TYPE_PLACEABLE, "campfire", lTarget);
            AssignCommand(working, DelayCommand(90.0f, DestroyObject(working)));


Now to make the campfire need to be around is a simple matter, with this script in the OnRest event handle:

void main()
    object oPC = GetLastPCRested();
    object oCampfire = GetNearestObjectByTag("Campfire", oPC);
    float Distance = GetDistanceBetween(oPC, oCampfire);
    if(Distance > 10.0f)
        AssignCommand(oPC, ClearAllActions());

it's not that hard to do... I just made this in about 30-45 minutes (tested it too icon_wink.gif)
Matthijs says:
   oh ja, ik weet het zonet nog niet
Matthijs says:
   het ziet er toch wel een beetje naar uit dat we nederlands praten
Matthijs says:
   mischien moet ik dan maar eens vaker nederlands gaan praten
Matthijs says:
   kan je me ook meteen niet op al mijn spellinsfouten wijzen
There you have it! indisputable proof Solo's a fascist!!!
Back to top
View users profile Send private message Send email AIM Address MSN Messenger
PostSun 07/06/03 4:29pm
Hey thx BUT i thick you must have wright wrong becouse i can't find the (OnItemUsed Event handle in Module Properties) so what do i do...  Reply with quote
Little Teapot
PostSun 07/06/03 4:49pm
OnActivateItem event handle... sorry... heh.  Reply with quote
PostSun 07/06/03 9:07pm
TP u rule!!!!!!!  Reply with quote
Display posts from previous:   
Post new topic   Reply to topic    DysoForums Forum Index -> Help All times are GMT
Page 1 of 1

Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Powered by phpBB 2.0.2 © 2001, 2002 phpBB Group