The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
elementals
Author Message
Crusader
Master
**

Posts: 254
Likes Given: 7
Likes Received: 19 in 12 posts
Joined: Apr 2012
Reputation: 6

Erehwon New Hera

Post: #11
RE: elementals
post both of them...

if u have this:
ON=@RESOURCEFOUND
SERV.NEWNPC c_elem_earth
NEW.UPDATEX
NEW.ANIM 12
NEW.ATTACK <SRC>

u can do 2 things: first add event to the elemental like this:

new.events +e_elem_raise


and under this event u can try:
[EVENTS e_elem_raise]
on=@create
(put ur call function here)



but basically u maybe can try to do:

ON=@RESOURCEFOUND
SERV.NEWNPC c_elem_earth
call_function <NEW.UID>
NEW.ATTACK <SRC>

but it depends on how ur call function is done...that's why i told u to post it Smile
02-10-2013 01:04 AM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #12
RE: elementals
Why in the world would you ever put that function under the @create trigger? that means for every elemental ever spawned it will raise up into the air, even if it is not generated by the mining script..

[Image: 2nis46r.jpg]
02-10-2013 02:40 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Crusader
Master
**

Posts: 254
Likes Given: 7
Likes Received: 19 in 12 posts
Joined: Apr 2012
Reputation: 6

Erehwon New Hera

Post: #13
RE: elementals
well, actually not, since it add the event ONLY when the spawning occurs on resource found.

problem is, that i'm not sure if the @create is fired before the event adding or not.

In any case i'm sure u might suggest a better solution Smile
02-10-2013 03:13 AM
Find all posts by this user Like Post Quote this message in a reply
mrkarlo
Journeyman
*

Posts: 160
Likes Given: 3
Likes Received: 6 in 5 posts
Joined: Mar 2012
Reputation: 1



Post: #14
RE: elementals
okay, we have function f_raise.
Code:
ON=@Create
call f_raise
NPC=brain_monster
FAME={1000 6000}
KARMA={-3000 -3999}
COLOR=01

it would be ok?
02-10-2013 03:13 AM
Find all posts by this user Like Post Quote this message in a reply
Crusader
Master
**

Posts: 254
Likes Given: 7
Likes Received: 19 in 12 posts
Joined: Apr 2012
Reputation: 6

Erehwon New Hera

Post: #15
RE: elementals
uhm..i don't understand why u use "call"
u just need to put f_raise

but as i told u, u should post the whole f_raise function first......and if u put it inside the create like that, EVERY elemental will respawn 'raising' like mordaunt said.

Come in chat if u can Smile button chat is in the top right,
02-10-2013 03:17 AM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #16
RE: elementals
I dont understand why your using @create....

just do new.f_raise under the function that creates the creature when conditions are met.

[Image: 2nis46r.jpg]
(This post was last modified: 02-10-2013 03:41 AM by Mordaunt.)
02-10-2013 03:40 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
mrkarlo
Journeyman
*

Posts: 160
Likes Given: 3
Likes Received: 6 in 5 posts
Joined: Mar 2012
Reputation: 1



Post: #17
RE: elementals
thanks!
Code:
ON=@Create
new.f_raise
NPC=brain_monster
FAME={1000 6000}
KARMA={-3000 -3999}

right?
(This post was last modified: 02-11-2013 03:51 AM by mrkarlo.)
02-11-2013 03:51 AM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #18
RE: elementals
no!

Code:
ON=@RESOURCEFOUND
IF (<eval RAND(400)> == 200)
    SERV.NEWNPC c_elem_earth
    NEW.UPDATEX
        new.f_raise <----- here, or after new.anim possibly
    NEW.ANIM 12
    NEW.ATTACK <SRC>

[Image: 2nis46r.jpg]
(This post was last modified: 02-11-2013 04:43 AM by Mordaunt.)
02-11-2013 04:43 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
mrkarlo
Journeyman
*

Posts: 160
Likes Given: 3
Likes Received: 6 in 5 posts
Joined: Mar 2012
Reputation: 1



Post: #19
RE: elementals
oh no, with elemental comes out from the ground strange stone wall.

Here it is:

Code:
[function f_raise]
newitem=05a

and error in console: Undefined keyword 'ATTACK'

Code:
ON=@RESOURCEFOUND
IF (<eval RAND(2)> == 1)
  SERV.NEWNPC c_elem_earth
  NEW.UPDATEX
    new.f_raise
    NEW.ATTACK <SRC>
  ENDIF

This error come out when im adding f_raise to @Resourcefound
02-19-2013 07:55 AM
Find all posts by this user Like Post Quote this message in a reply
Shaklaban
Master
**

Posts: 378
Likes Given: 0
Likes Received: 1 in 1 posts
Joined: Mar 2012
Reputation: 8

DOT

Post: #20
RE: elementals
new is global reference, so it will fire on 05a item.

ON=@RESOURCEFOUND
IF (<eval RAND(2)> == 1)
SERV.NEWNPC c_elem_earth
NEW.UPDATEX
NEW.ATTACK <SRC>
new.f_raise
ENDIF

just put the f_raise under the attack
(This post was last modified: 02-19-2013 08:13 AM by Shaklaban.)
02-19-2013 08:12 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)