![]() |
Triggeraction
Shakaku:
alright, can anyone tell me why when i hit the npc with the hammer, it doesn't inscrease, but when i touch it, it does?? :grrr: |
I have the same problem
Here is what I have this so far: if (actionname) setstring server.namedone,#v(namedone); message #s(server.namedone)% how would I get it to add 1 percent every time you fired the weapon which uses the triggeraction command? (I already have the triggeraction working on the weapon) |
if (actionname) {
setstring server.namedone,#v(namedone+1); message #s(server.namedone)%; } something like this or what u mean? so it would set the serverstring+1 everytime u use the item and message the new percents... (if u mean something else I misunderstood you) |
server.percentdone++;
|
Quote:
|
ok hmmm u mean something like this I think:
if (actionname) { namedone = strtofloat(#s(server.namedone))+1; setstring server.namedone,#v(namedone); message #s(server.namedone)%; } this should work like u want it =) |
Shakaku:
well it works, kinda. The triggeraction is in the hammer, so whenever i hit the npc once with the hammer, i touch it and it goes up, not when i hit it :grrr: |
um....
when the hamer does something like: triggeraction playerx+1.5+vecx(playerdir)*2,playery+2+vecy(playe rdir)*2,hammer,; and the thing u use the hammer on does: if (actionhammer) { hammered = strtofloat(#s(server.hammered))+1; setstring server.hammered,#v(hammered); message #s(server.hammered)%; } it should work... |
Quote:
if (strequals(#s,server.roastdone=100)) {hide} that's what I thought would work but it doesn't |
Shakaku:
= means assignment ==means equals, try that :D |
Quote:
#s is a messagecode..it needs an argument, and you don't need that semi-colon in gscript in the last line of a block, but you should have it there anyway...I almost wish Stefan would make it so that you do need that last semi-colon... |
Quote:
if (strtofloat(#s(server.roastdone))>=100) {hide;} this is the best way =) |
Quote:
|
ohhh yeah k this is good too ;)
u were some seconds faster then me =) |
| All times are GMT +2. The time now is 05:00 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.