Skocz do zawartości
  • 0

CobbleX


marcino934

Pytanie

Witam!

tak jak w temacie mam problem z moim skryptem na cobbleX. Problem w tym że gdy zcraftuje ten cobblex i go postawię oraz zniszczę to wypada z niego Mossy Stone Bricks i nie wypada żaden z wypisanych tutaj itemków. Próbowałem już wsysztkiego i dalej nie działa ..

Opiszę co ma się dziać w tym skrypcie.

otóż craftujemy tego cobblex'a stawiamy go i pisze nam że go postawiono.

potem gdy go niszczymy (gdy niszczymy wszystkim, ręką kilofem byle jakim to ma wypaść wylosowany itemek) ma wybrać losowy jakiś itemek i go dać graczowi,Z bloku MossyStoneBricks ma nic nie wypadać poza tymi specjalnymi itemkami. (te itemki ma dawać do eq)

Za pomoc daję "Lubię to :)" oraz miłe słowo ode mnie xd. 

oto kod:

on load:
    set {_nazwa} to "&2CobbleX"
    Recipe.new{ {_nazwa} }
    {_nazwa}.Recipe.registerIngredient{1, 64 Cobblestone}
    {_nazwa}.Recipe.registerIngredient{2, 64 Cobblestone}
    {_nazwa}.Recipe.registerIngredient{3, 64 Cobblestone}
    {_nazwa}.Recipe.registerIngredient{4, 64 Cobblestone}
    {_nazwa}.Recipe.registerIngredient{5, 64 Cobblestone}
    {_nazwa}.Recipe.registerIngredient{6, 64 Cobblestone}
    {_nazwa}.Recipe.registerIngredient{7, 64 Cobblestone}
    {_nazwa}.Recipe.registerIngredient{8, 64 Cobblestone}
    {_nazwa}.Recipe.registerIngredient{9, 64 Cobblestone}
    {_nazwa}.Recipe.registerResult{1 Mossy Stone Bricks of Unbreaking 10 named "&2CobbleX"}
    {_nazwa}.Recipe.register
options:                                          
    item.coblex: Mossy Stone Bricks
on mine Mossy Stone Bricks:
if player is holding Mossy Stone Bricks named "&2CobbleX":
set event-block to air
set {_y} to a random integer from 1 and 20
if {_y} is 1:
give player 1 emerald
send "&2Dostales przedmiot!" to player
if {_y} is 2:
give player 1 blaze rod
send "&2Dostales przedmiot!" to player
if {_y} is 3:
give player 1 gold nugget
send "&2Dostales przedmiot!" to player
if {_y} is 4:
give player 1 nether wart item
send "&2Dostales przedmiot!" to player
if {_y} is 5:
give player 1 diamond
send "&2Dostales przedmiot!" to player
if {_y} is 6:
give player 1 gold ingot
send "&2Dostales przedmiot!" to player
if {_y} is 7:
give player 1 iron ingot
send "&2Dostales przedmiot!" to player
if {_y} is 8:
give player 8 gunpowder
send "&2Dostales przedmiot!" to player
if {_y} is 9:
give player 4 slimeball
send "&2Dostales przedmiot!" to player
if {_y} is 10:
give player 16 redstone
send "&2Dostales przedmiot!" to player
if {_y} is 11:
give player 1 ender pearl
send "&2Dostales przedmiot!" to player
if {_y} is 12:
give player 8 TNT
send "&2Dostales przedmiot!" to player
if {_y} is 13:
give player 1 enchanted golden apple
send "&2Dostales przedmiot!" to player
if {_y} is 14:
give player 1 golden apple
send "&2Dostales przedmiot!" to player
if {_y} is 15:
give player 4 apple
send "&2Dostales przedmiot!" to player
if {_y} is 16:
give player 6 bone
send "&2Dostales przedmiot!" to player
if {_y} is 17:
give player 1 anvil
send "&2Dostales przedmiot!" to player
if {_y} is 18:
give player 1 chest
send "&2Dostales przedmiot!" to player
if {_y} is 19:
give player 16 redstone
send "&2Dostales przedmiot!" to player
if {_y} is 20:
give player 3 string
send "&2Dostales przedmiot!" to player
cancel event
on place of {@item.coblex}:
if player is holding Mossy Stone Bricks named "&2CobbleX":
send "&2Postawiono CobbleX !" to player

dodam także że nie wyświetlają mi się żadne errory.

Edytowane przez marcino934
Odnośnik do komentarza
https://skript.pl/temat/6353-cobblex/
Udostępnij na innych stronach

17 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0

połowa to to nie jest skrypt, tylko Java.

Poczytaj trochę poradników itp.

Dodatkowo jest całość źle wytabowana. To co mogłem to wytabowałem (TAB = tutaj 4 spacje):

on mine Mossy Stone Bricks:
    if player is holding Mossy Stone Bricks named "&2CobbleX":
        set event-block to air
        set {_y} to a random integer from 1 and 20
    if {_y} is 1:
        give player 1 emerald
        send "&2Dostales przedmiot!" to player
    if {_y} is 2:
        give player 1 blaze rod
        send "&2Dostales przedmiot!" to player
    if {_y} is 3:
        give player 1 gold nugget
        send "&2Dostales przedmiot!" to player
    if {_y} is 4:
        give player 1 nether wart item
        send "&2Dostales przedmiot!" to player
    if {_y} is 5:
        give player 1 diamond
        send "&2Dostales przedmiot!" to player
    if {_y} is 6:
        give player 1 gold ingot
        send "&2Dostales przedmiot!" to player
    if {_y} is 7:
        give player 1 iron ingot
        send "&2Dostales przedmiot!" to player
    if {_y} is 8:
        give player 8 gunpowder
        send "&2Dostales przedmiot!" to player
     if {_y} is 9:
         give player 4 slimeball
         send "&2Dostales przedmiot!" to player
     if {_y} is 10:
        give player 16 redstone
        send "&2Dostales przedmiot!" to player
    if {_y} is 11:
        give player 1 ender pearl
        send "&2Dostales przedmiot!" to player
    if {_y} is 12:
        give player 8 TNT
        send "&2Dostales przedmiot!" to player
    if {_y} is 13:
        give player 1 enchanted golden apple
        send "&2Dostales przedmiot!" to player
    if {_y} is 14:
        give player 1 golden apple
        send "&2Dostales przedmiot!" to player
     if {_y} is 15:
        give player 4 apple
        send "&2Dostales przedmiot!" to player
    if {_y} is 16:
        give player 6 bone
        send "&2Dostales przedmiot!" to player
     if {_y} is 17:
        give player 1 anvil
        send "&2Dostales przedmiot!" to player
    if {_y} is 18:
        give player 1 chest
        send "&2Dostales przedmiot!" to player
    if {_y} is 19:
         give player 16 redstone
        send "&2Dostales przedmiot!" to player
    if {_y} is 20:
        give player 3 string
        send "&2Dostales przedmiot!" to player
    cancel event
on place of {@item.coblex}:
    if player is holding Mossy Stone Bricks named "&2CobbleX":
    send "&2Postawiono CobbleX !" to player


Inni Ci pomogą, bo ja muszę spadać

Odnośnik do komentarza
https://skript.pl/temat/6353-cobblex/#findComment-52115
Udostępnij na innych stronach

  • 0

pisałem że nie ma żadnych błędów z tabulacją itp. 

Błąd tkwi w zapisie skryptu..

(w kodzie tutaj nie widać tabulacji, przy kopiowaniu się niweluje.. ale w kodzie w pliku mam dobrze wszystko wytabulowane)

Raczej całość to jest Skrypt :) + WildsSkript....

PS ta twoja pomoc nic tutaj nie wniosła, ale dziękuję że ty jako jedyny chciałeś pomóc..

Edytowane przez marcino934
Odnośnik do komentarza
https://skript.pl/temat/6353-cobblex/#findComment-52120
Udostępnij na innych stronach

  • 0

dobrze zaraz zobaczę... Mam jedno pytanko jaka jest zmienna aby zrobić tak że u wszystkich graczy jacy są online albo offline zmienia np. {jolo.%player%} na false ?

Edit:

Jak to napisać że sprawdza lokację kopanego bloku czy jest w liście ?

napisz mi przykład :)

Edytowane przez marcino934
Odnośnik do komentarza
https://skript.pl/temat/6353-cobblex/#findComment-52374
Udostępnij na innych stronach

  • 0

Nie da się tego ominąć ;)

options:    item.cobblex: Mossy Stone Brickson load:	new recipe "CobbleX";	"CobbleX".Recipe.registerIngredient{1, 64 Cobblestone};	"CobbleX".Recipe.registerIngredient{2, 64 Cobblestone};	"CobbleX".Recipe.registerIngredient{3, 64 Cobblestone};	"CobbleX".Recipe.registerIngredient{4, 64 Cobblestone};	"CobbleX".Recipe.registerIngredient{5, 64 Cobblestone};	"CobbleX".Recipe.registerIngredient{6, 64 Cobblestone};	"CobbleX".Recipe.registerIngredient{7, 64 Cobblestone};	"CobbleX".Recipe.registerIngredient{8, 64 Cobblestone};	"CobbleX".Recipe.registerIngredient{9, 64 Cobblestone};	"CobbleX".Recipe.registerResult{1 Mossy Stone Bricks of Unbreaking 10 named "&2CobbleX"};	"CobbleX".Recipe.register{};on break of Mossy Stone Bricks:	if {cobblex.%location of event-block%} is true:		cancel event		set event-block to air		set {cobblex.%location of event-block%} to false		if chance of 5%:			give player 1 emerald			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 blaze rod			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 gold nugget			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 nether wart item			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 diamond			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 gold ingot			send "&2Dostales przedmiot!" to player			stop		if chance of 5:			give player 1 iron ingot			send "&2Dostales przedmiot!" to player			stop		if chance of 5:			give player 8 gunpowder			send "&2Dostales przedmiot!" to player			stop		if chance of 5:			give player 4 slimeball			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 16 redstone			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 ender pearl			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 8 TNT			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 enchanted golden apple			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 golden apple			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 4 apple			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 6 bone			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 anvil			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 1 chest			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 16 redstone			send "&2Dostales przedmiot!" to player			stop		if chance of 5%:			give player 3 string			send "&2Dostales przedmiot!" to player			stopon place of {@item.coblex}:	if player is holding Mossy Stone Bricks named "&2CobbleX":		set {cobblex.%location of event-block%} to true		send "&2Postawiono CobbleX !" to playeron break of {@item.cobblex}:	if {cobblex.%location of event-block%} is true:		set {cobblex.%location of event-block%} to false

Edytowane przez kondziu156
Odnośnik do komentarza
https://skript.pl/temat/6353-cobblex/#findComment-52578
Udostępnij na innych stronach

Nieaktywny
Ten temat został zamknięty. Brak możliwości dodania odpowiedzi.
  • Ostatnio przeglądający   0 użytkowników

    • Brak zarejestrowanych użytkowników przeglądających tę stronę.
×
×
  • Dodaj nową pozycję...