[CF-Devel] object lesson

crossfire-devel-admin at archives.real-time.com crossfire-devel-admin at archives.real-time.com
Fri Jun 20 02:50:12 CDT 2003


Ok, I didn't think I was so dim witted but I guess i am...<pause for you to stop nodding> anyway I have a proposal:

I would like to propose an arch object to be created and document the procedure since I think it would save people from going through what I am going through now (lots of looking through the code and documentation trying to understand seemingly simple stuff).  I am assured it is trivial but that is once you know how it works right...I think it would be valuble anyway.  SO I am going to put forth a detailed arch object requirement and ask for a step by step procedure on how one of you fellows would implement it (not actually implement it, but all the things you would do, even the little things that are obvious -  except to non coders).  I was going to try an Randomizer, but am told this is not simple as it would appear so I am now going to put forth another arch object.

This is the object.

It is called Timer  (face is a little clock for map makers - but it will always be invisible like a creator...)

It waits for another object to trigger it.
It counts down a specified number of 'turns'
It has a setting to be silent or to display a message
It has a setting to display the message once or each interval (perhaps even, but only if it isn't hard to do, a message with a variable like a countdown...)
It triggers something else
It has a setting to reset or not

it should function like this:

player steps on a button or pulls a handle with connect '5'
timer is set to accept connect '5' and to count down from 10
timer counts down from 10 displaying a message "tick..."
timer trigers all the gates to close and a teleporter to teleport in a dragon to the room...

Now the object isn't to actually build this so much as to teach other people how it should be built.

Like:

step 1. add an entry to the define.h :  #DEFINE TIMER  125
step 2. add code to button.c ... (why - it's a button - what if it's was say a boat?)
step 3. make entry in loader.c :   (a case statement entry for say type #125?)
step 4. create arch...
other steps...?


Anyone take me up on this?  I seem to be missing some brains but I am sure I could do this myself if i could get a better grip on the way it works and perhaps with better documentation. If this object is too complex I maybe someone can suggest another one even simpler for this purpose.
  Perhaps we could even have a IRC session to step through it sometome.  I think that other people would be interested in seeing how this works too.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
     
     http://shadowknight.real-time.com/pipermail/crossfire/attachments/20030620/77408b3f/attachment.htm
     
     
    


More information about the crossfire mailing list