Jump to content
  • 0

Ai Error


caganitas

Question

Hi,

 

im trying to do something in AI and i keep getting erros in the NPC server as soon as AI is loaded, as if the ai.obj gets corrupted, its a huge stack(after compiling it to .obj and adding the compiled code) if i use the s0 variable but if i remove that variable and use hardcoded strings it works, this code is simple i just want to test something where i manage a string every time MENU_SELECTED is invoked.

What i expected this code to do was basically the NPC would say the string "l2Bbuffer002.htm". (no sense i know, but i cut the code to figure what was corrupting it)

The NASC code

class 1 buffer : default_npc
{
parameter:
  string fnHi = "l2Bbuffer001.htm";
  string page = "l2Bbuffer001.htm";
 
handler:

EventHandler TALKED(talker) {
myself::ShowPage(talker,fnHi);
return;
}

 

EventHandler MENU_SELECTED(ask,reply,item,action_id,s0) {
s0 = "l2Bbuffer002.htm";
myself::Say(s0);
return;
}//event
}//class
 

Edited by caganitas
Link to comment
Share on other sites

9 answers to this question

Recommended Posts

  • 0

This is the errors i get with that code, as i said its like the AI get corrupted if i use the s0 or any native string variable to do this. if i remove the s0 and use hardcoded strings it works. Im using interlude compiler and replacing the ID's with the GF ID's (im running GF), this is working fine for other variables and functions that didnt change its signature.

 

Untitled2.jpg

 

And if i use a parameter set by me i get these errors, i guess parameters cant change at run time?

 

 

 

Untitled.jpg

Edited by caganitas
Link to comment
Share on other sites

  • 0

The compiled code for that NASC after replacing the ID's is:
 

class 1 buffer : default_npc
parameter_define_begin
    string fnHi "l2Bbuffer001.htm"
    string page "l2Bbuffer001.htm"
parameter_define_end
handler 3 13    //  TALKED
    variable_begin
        "talker"
        "myself"
        "_choiceN"
        "_code"
        "_from_choice"
    variable_end

    push_event    //  myself
    push_const 784
    add
    fetch_i
    push_event    //  talker
    push_const 40
    add
    fetch_i
    push_parameter fnHi
    func_call 235012165    //  func[showPage]
    shift_sp -2
    shift_sp -1
    exit_handler
handler_end

handler 31 19    //  MENU_SELECTED
    variable_begin
        "ask"
        "reply"
        "item"
        "action_id"
        "s0"
        "myself"
        "_choiceN"
        "_code"
        "_from_choice"
    variable_end

    push_event    //  s0
    push_const 576
    add
    push_reg_sp
    fetch_iS881.    "l2Bbuffer002.htm"
    push_string S881
    assign
    shift_sp -1
    push_event    //  myself
    push_const 784
    add
    fetch_i
    push_event    //  s0
    push_const 576
    add
    fetch_i    func_call 234946622    //  func[say]
    shift_sp -1
    shift_sp -1
    exit_handler
handler_end

class_end

 

Link to comment
Share on other sites

  • 0

So let me get this straight - you not knowing shit about the language use a compiler for something completely different and replace only IDs.

Yet expect it to work like magic?

 

 

The fact that you don't register this as bad - or think "okay can't use c4 compiler" is scary.

 

 

 

Syntax looks correct per NASC - so get a GF compiler and see if the output is different.

(I'm assuming by logic - it will have to be as param syntax matches other uses of s0 in GF).

 

Most probably error is the assigning to s0 - that does not look GF alike natively.

Edited by mcbigmac
Link to comment
Share on other sites

  • 0

Well it worked for some cases and i read on another forum that the native syntax didnt change from interlude to GF only some function signature and ID's for functions/variables/handlers, and from the cases i tried it was true (which im aware doesnt make it true for every case), so i tried this case and wanted to know from those who actually have knowledge on the subject if it was the process of "converting" to a newer chronicle or just some other wrong code i had, guess i'll have to buy the GF compiler then.

 

Another question, is there any way from the MENU_SELECTED handler to know or go back to the htm page that requested it, like a variable that has that information or a function that redirects? or i just need to send that information from the htm page to the AI?

Edited by caganitas
Link to comment
Share on other sites

  • 0

People look at GF and C4 AI and see no major differences - and there aren't.

But string assigning like that could have changed, find a native example in both and check.

 

 

There's no way to know requesting html by AI - as far as i remember.

Such info is simply not saved in memory in either daemons.

Link to comment
Share on other sites

  • 0

Now that i look at it again - i'm actually confuzzled.

 

That was until i noticed this...

 

fetch_iS881.    "l2Bbuffer002.htm"

 

 

If that's not a copy paste error by you, well there's your error.

Link to comment
Share on other sites

  • 0

Now that i look at it again - i'm actually confuzzled.

 

That was until i noticed this...

 

fetch_iS881.    "l2Bbuffer002.htm"

 

 

If that's not a copy paste error by you, well there's your error.

yep your right that was it...

 

comparing to a place from compiled GF AI has an assign to s0

 

push_event    //  s0

    push_const 576            //s0

    add

    push_reg_sp

    fetch_i            //expr =

S278.    "String"

    push_string S278

    assign

    shift_sp -1

 

so yeah.... you can close the topic while i go write on a board im a dummy 200 times :D thanks again 

mcbigmac

Edited by caganitas
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.


  • Posts

    • WTB Site Developer services.
    • @TZANEEN BUY UNIVERSAL SSD CHEMICAL SOLUTION  +27833928661 in South Africa, Gauteng, KwaZulu-Natal, Limpopo, Free State, Mpumalanga, North West, Western Cape, Eastern Cape, Northern Cape, Benoni, Boksburg, Brakpan, Carletonville, Germiston, Johannesburg, Krugersdorp, Mafikeng, Pretoria, Randburg, Randfontein, Roodepoort, Soweto, Springs, Vanderbijlpark, Vereeniging, Durban,  +27833928661Empangeni, Ladysmith, Newcastle, Pietermaritzburg, Pinetown, Ulundi, Umlazi, Bethlehem, Bloemfontein, Jagersfontein, Kroonstad, Odendaalsrus, Parys, Phuthaditjhaba, Sasolburg, Virginia, Welkom, Giyani, Lebowakgomo, Musina, Phalaborwa, Polokwane, Seshego, Sibasa, Emalahleni, Nelspruit, Secunda, Standerton, Klerksdorp, Mahikeng, Mmabatho, Potchefstroom, Rustenburg, Bellville, Cape Town, Constantia, George, Hopefield, Oudtshoorn, Paarl, Simon’s Town, Stellenbosch, Swellendam, Worcester, Alice, Butterworth, East London, Graaff-Reinet, Grahamstown, King William’s Town, Mthatha, Port Elizabeth, Queenstown, Uitenhage, Zwelitsha. +27833928661 Call For Ssd Chemical Solution for Cleaning All Notes +27833928661. Please inform us immediately on Email: Kennroger77@gmail.com Or Call: +27833928661. https://Kennroger7.Blogspot.com/website https://Kennroger7.Blogspot.com/techniciankenn https://Kennroger7.blogspot.com/   We Clean all types of Currencies call  +27833928661 Ssd Solution Chemical for Cleaning Black Money Notes Call +27833928661 Ssd Solution Used to Clean all type of Blackened +27833928661, Tainted and Defaced Bank Notes  +27833928661. We Sell Ssd Chemical Solution Used to Clean All type of Black Money and any Color Currency, Stain and Defaced Bank Notes with any others equipment being bad. Our technicians are highly qualified and are always ready to handle the cleaning perfectly. Our chemical is 100% Pure. Automatic Ssd Solution for Sale +27833928661 Rustenburg, Mafikeng, Polokwane Durban/east London, Pretoria, Johannesburg, Mpumalanga. Ssd chemical Solution for Sale in Johannesburg  +27833928661 in Zimbabwe, Mozambique, Angola, Namibia, Botswana, Lesotho and Swaziland Call and Buy Ssd Chemical Solution for Defaced Banknotes +27833928661 in Mozambique, South Africa, Lesotho, Swaziland, Namibia, Angola, Botswana, Mauritius, Zambia, Zimbabwe, Mauritania, Mauritius, Congo Call For 100% Pure Ssd Chemical Solution +27833928661 in Finland and USA.   Ssd Chemical Solution for all Defaced Bank Notes in Bloemfontein +27833928661 in Johannesburg, Cape town, Polokwane, Rustenburg, Kimberley, Durban, Pietermaritzburg, Klerksdorp, Mafikeng, Belgium, Honduras, Brazil, Argentina.  +27833928661 We are Specialized in Chemistry for anti-breeze Bank Notes. We also do Chemicals Melting and Recovering of all type of bad money from black to white Call +27833928661. We also sale chemicals like tourmaline,  +27833928661 Ssd Chemical solution and many other activation powder. About Ssd Solution for cleaning black money chemical and allied product incorporated is a major manufacturer of industrial and pharmaceutical products with key specialization in the production of ssd automatic solution used in the cleaning of black money and defaced money and stained bank notes with anti -breeze quality. The ssd solution in it's full range is the best chemical in the market for cleaning anti breeze bank notes, defaced currency and marked notes. Others for damaged notes. +27833928661 Please inform us immediately on Email: Kennroger77@gmail.com or Call: +27833928661. https://Kennroger7.Blogspot.com/website https://Kennroger7.Blogspot.com/techniciankenn https://Kennroger7.blogspot.com/
    • @ (3 IN 1, WORKING 100%) SSD CHEMICAL SOLUTIONS +27833928661 AND ACTIVATION POWDER FOR CLEANING OF BLACK NOTES @BUY SSD CHEMICAL SOLUTIONS ON GOOD PRICE +27833928661, +27833928661 @ CLEANING BLACK NOTES WITH SSD CHEMICALUTUTIONS @BEST SUPPLIERS OF SSD CHEMICAL SOLUTIONS +27833928661 IN Qatar, New York, Limpopo, London, Venezuela, Chile, Sweden, Denmark, Rwanda, Oman ,, Dubai, Poland New Castle, Namibia, Botswana, Mozambique, South Africa, Limpo¬po, JORDAN, Turkey, Belgium, Saudi Arabia, Australia, Malaysia, to Johannesbu Zambia, Swaziland, Madagascar, Zimbabwe, Lesotho, Uganda, rg, Lebanon, Berhrain USA, California, Dallas, England, German, Spain, Jamaica, Brazil, Germany, Austria, Vancouver, Denmark, Hong Kong, China ,, Pretoria, Durban, Australia, Wales, France, Cairo, Namibia, Botswana, China, Norway, Sweden, Capet own, Tanzania, Northern Cape, Canada ,, Soshanguve, Pietermaritzburg Pinetown, Vaal, Polokwane Pretoria Randburg Roodepoort Rustenburg Sebokeng Soweto Springbok Stellenbosch Thohoyandou Umlazi Upington Vanderbijlpark Vereeniging Welkom Tembisa Kempton Park Port Elizabeth Bellville Boksburg Benoni Bloemfontein Cape Town Centurion Durban East London George Empangeni Katlehong Germiston Johannesburg Port Elizabeth Khayelitsha Kimberley Klerksdorp Mamelodi Mitchells Plain Mthatha Nelspruit Newcastle Witbank Eastern cape, Free State Gauteng KwaZulu-Natal Limpopo Mpumalanga Do you have black currency in form of Dollars, Pounds or Euros or any other currency? I have the most powerful and Universal cleaning chemical you are looking for. I sell SSD automatic solution, Vetrol paste 0.2A and so many others. I also have a variety of Powders needed when doing the large cleanings such as Activation powder. We specialize in cleaning all types of defaced notes, black notes, anti-breeze bank notes, stamp coated and stained currency. We melt and re-activate frozen chemicals and offer 100% cleaning for bills like dollar, euro, pounds, RANDS and transferring of colors from used note to new white bills. We offer machines for large cleaning and also deliver products to any location desired by buyers. Laboratory staff are available to demonstrate to clients how the work is done. Are you looking for: — call+27833928661 SSD Chemical Solution Chemical Solution for Cleaning Black Money call+27833928661 SSD Chemical Company SSD Chemical Solution for Cleaning Black Money SSD Preserving Company SSD Chemical Solution for Cleaning Black Money Activation Powder SSD Chemical Solution for Cleaning Black notes Active Powder Activation Powder for Cleaning Black Notes Black Money Cleaning Clean Black Money Best SSD Solution Clean Black Notes Cleaning Black Notes Cleaning Black Money PLEASE NOTE: WE ONLY DEAL IN HIGH QUALITY SSD CHEMICALS SOLUTION FOR CLEANING BLACK MONEY We are manufacturers and sellers of all sort of chemicals like SUPER AUTOMATIC SSD SOLUTION ZWV8 MODEL ACTIVATION POWDER AND REACTIVATION POWDER, ANTI AIR POWDER, MERCURY POWDER, AUTOMATED MONEY DEVELOPER MACHINES CONGEAL CHEMICAL MELTING EQUIPMENT, TEMPERATURE CONTROLLERS AND AUTOMATIC CLEANING MACHINE. WE ARE SELLING SSD CHEMICAL SOLUTION FOR CLEANING BLACK MONEY AND POWDER CALL+27833928661 purchase Best SSD Solution Clean Black Notes Dollars WE ALSO SELL CHEMICALS LIKE SSD AUTOMATIC SOLUTION FORM CLEANING BLACK DOLLARS CURRENCIES We clean all black and green money and stamped money Infinity labs pty (since 2000) *: We can help you clean your money, (+27833928661) *, we supply a high quality of the ssd solution with machi * ne and it comes with a full package of instructions and accessories. It is the ultimate anti- * breeze solution used in cleaning defaced currency. It can be referred to as black dollar etc… *. or bank stained currency. PRODUCTS AVAILABLE: * SSD SOLUTION SSD Supreme Solution SSD universal solution SSD Tourmaline solution SSD SOLUTION PK 58 SSD Topix solution SSD Castro X Oxide solution D6 SSD universal Solution D7 SSD SOLUTION PK 58 SSD MECURY DIOSINE AUTOMATIC SOLUTION SSD NSERVATION, ACTIVATION AND RE-ACTIVATION, PARACIENT POWDER, VECTROL PASTE, ZUTA S4, CASTROX OXIDE AUTOMATED MONEY DEVELOPER MACHINES CONGEAL CHEMICAL MELTING EQUIPMENTS * TEMPERATURE CONTROLLERS Our agent will meet with you in any part of the world. CALL OR WATSUPP US @+27833928661 Email: Kennroger77@gmail.com
    • World’s Best Technician for Supplying Universal Ssd Chemical Solution in Limpopo,Sasolburg,Witbank,Standarton,Secunda,Middelburg,Vanderbijlpark,Johannesburg,Secunda,Cape Town,Burgersfort, Polokwane, Thohoyandou, phalaborwa, mokopane, bochum, +27833928661lebowakgomo, mankweng, Seshego, dendron, Giyani, Lephalale, musina,Alexandra +27833928661Johannesburg Lenasia Midrand Randburg+27833928661 Roodepoort Sandton Soweto Alberton Germiston Benoni Boksburg ,rakpan Daveyton,Duduza ,edenvale ,germiston Impumelelo Isando Katlehong Kempton Park KwaThema Nigel Reiger Park Springs Tembisa Thokoza Tsakane Vosloorus Wattville Atteridgaeville Centurion Hammanskraal Irene Mamelodi Pretoria Soshanguve Boipatong Bophelong Evaton Sebokeng Sharpeville, Vereeniging,Meyerton Heidelberg Ratanda Bronkhorstspruit Ekangala Kungwini Bronberg,Cullinan Refilwe,Zithobeni ,Carletonville,Khutsong Kagiso Kromdraai KrugersdorpMagaliesburg Muldersdrift Mohlaken,Randfontein Bekkersdal,testonaria Kimberley Upington Kuruman Sprinbok Kathu Ritchie Postmasburg,Bellville Bloemfontein.+27833928661 To purchase Best SSD Chemical Solution to Clean Black Notes Dollars.WE ALSO SALE +27833928661CHEMICALS LIKE SSD AUTOMATIC SOLUTION FORM CLEANING BLACK DOLLARS CURRENCIES. I hereby use this media to inform you, that our company can clean out black deface currency, (stained money) bank notes, We have all kinds of chemicals used for cleaning of black money or stained money in currencies such as U.S Dollars, Euro, Pound, and all local currencies, even if your defaced note is 25 years old. WE SALE CHEMICALS LIKE TOURMALINE, S.S.D. Chemical / Solution , CASTRO X OXIDE, A4 AND MANY Like ACTIVATION POWDER & SSD SOLUTION FOR CLEANING BLACK MONEY Chemical and Allied product incorporated is a major manufacturer of industrial and pharmaceutical products with key specialization in the production of S.S.D Automatic solution used in the cleaning of black money , defaced money and stained bank notes with anti-breeze quality. OTHERS FOR DAMAGED NOTES, BILLS LIKE USD,EURO, POUNDS, Contact Dr.Elvis+27833928661 OR Email Kennroger77@gmail.com for more Information…Chemical Solution in Limpopo,Sasolburg,Witbank,Standarton,Secunda,Middelburg,Vanderbijlpark,Johannesburg,Secunda,Cape Town,Burgersfort, Polokwane, Thohoyandou, phalaborwa, mokopane, bochum, lebowakgomo, mankweng, Seshego, dendron, Giyani, Lephalale, musina,Alexandra Johannesburg Lenasia Midrand Randburg Roodepoort Sandton Soweto Alberton Germiston Benoni Boksburg ,rakpan Daveyton,Duduza ,edenvale ,germiston Impumelelo Isando Katlehong Kempton Park KwaThema Nigel Reiger Park Springs Tembisa Thokoza Tsakane Vosloorus Wattville Atteridgaeville Centurion Hammanskraal Irene Mamelodi Pretoria Soshanguve Boipatong Bophelong Evaton Sebokeng Sharpeville, Vereeniging,Meyerton Heidelberg Ratanda Bronkhorstspruit Ekangala Kungwini Bronberg,Cullinan Refilwe,Zithobeni ,Carletonville,Khutsong Kagiso Kromdraai KrugersdorpMagaliesburg Muldersdrift Mohlaken,Randfontein Bekkersdal,testonaria Kimberley Upington Kuruman Sprinbok Kathu Ritchie Postmasburg,Bellville Bloemfontein. To purchase Best SSD Chemical Solution to Clean Black Notes Dollars.WE ALSO SALE CHEMICALS LIKE SSD AUTOMATIC SOLUTION FORM CLEANING BLACK DOLLARS CURRENCIES. I hereby use this media to inform you, that our company can clean out black deface currency, (stained money) bank notes, We have all kinds of chemicals used for cleaning of black money or stained money in currencies such as U.S Dollars, Euro, Pound, and all local currencies, even if your defaced note is 25 years old. WE SALE CHEMICALS LIKE TOURMALINE, S.S.D. Chemical / Solution , CASTRO X OXIDE, A4 AND MANY Like ACTIVATION POWDER & SSD SOLUTION FOR CLEANING BLACK MONEY Chemical and Allied product incorporated is a major manufacturer of industrial and pharmaceutical products with key specialization in the production of S.S.D Automatic solution used in the cleaning of black money , defaced money and stained bank notes with anti-breeze quality. OTHERS FOR DAMAGED NOTES, BILLS LIKE USD,EURO, POUNDS, Contact Dr.Elvis+27833928661 OR Email Kennroger77@gmail.com for more Information… in Limpopo,Sasolburg,Witbank,Standarton,Secunda,Middelburg,Vanderbijlpark,Johannesburg,Secunda,Cape Town,Burgersfort, Polokwane, Thohoyandou, phalaborwa, mokopane, bochum, lebowakgomo, mankweng, Seshego, dendron, Giyani, Lephalale, musina,Alexandra Johannesburg Lenasia Midrand Randburg Roodepoort Sandton Soweto Alberton Germiston Benoni Boksburg ,rakpan Daveyton,Duduza ,edenvale ,germiston Impumelelo Isando Katlehong Kempton Park KwaThema Nigel Reiger Park Springs Tembisa Thokoza Tsakane Vosloorus Wattville Atteridgaeville Centurion Hammanskraal Irene Mamelodi Pretoria Soshanguve Boipatong Bophelong Evaton Sebokeng Sharpeville, Vereeniging,Meyerton Heidelberg Ratanda Bronkhorstspruit Ekangala Kungwini Bronberg,Cullinan Refilwe,Zithobeni ,Carletonville,Khutsong Kagiso Kromdraai KrugersdorpMagaliesburg Muldersdrift Mohlaken,Randfontein +27833928661Bekkersdal,testonaria Kimberley Upington Kuruman Sprinbok Kathu Ritchie Postmasburg,Bellville Bloemfontein.+27833928661 To purchase Best SSD Chemical Solution to Clean Black Notes Dollars.WE ALSO SALE CHEMICALS LIKE SSD AUTOMATIC SOLUTION FORM CLEANING BLACK DOLLARS CURRENCIES. I hereby use this media to inform you, that our company can clean out black deface currency, +27833928661(stained money) bank notes, We have all kinds of chemicals used for cleaning of black money or stained money in currencies such as U.S Dollars, Euro, Pound, and all local currencies, even if your defaced note is 25 years old.+27833928661 WE SALE CHEMICALS LIKE TOURMALINE, S.S.D. Chemical / Solution , CASTRO X OXIDE, A4 AND MANY Like ACTIVATION POWDER & SSD SOLUTION FOR CLEANING BLACK MONEY Chemical and Allied product incorporated is a major manufacturer of industrial and pharmaceutical products with key specialization in the production of S.S.D Automatic solution used in the cleaning of black money , defaced money and stained bank notes with anti-breeze quality. OTHERS FOR DAMAGED NOTES, BILLS LIKE USD,EURO, POUNDS,+27833928661 Contact Dr.Elvis +27833928661 OR Email Kennroger77@gmail.com for more Information…
    • Cleaning black money +27833928661 with ssd chemical solution  +27 833928661  vanderbijlpark- nairobi, East London Tembisa ,Cape Town Durban Johannesburg Soweto Pretoria Port Elizabeth Pietermaritzburg Benoni Vereeniging Bloemfontein Boksburg Welkom Newcastle Krugersdorp Diepsloot Botshabelo Brakpan Witbank Richards Bay Vanderbijlpark Centurion Uitenhage Roodepoort Paarl Springs Carletonville Klerksdorp Midrand Westonaria Middelburg Vryheid Orkney Kimberley eMbalenhle Nigel Mpumalanga Bhisho Randfontein DR MBONYE has powerful lottery spells to help you win the lottery jackpot and make you rich beyond your wildest dreams I have used lottery spells and won in my personal capacity.Money Spells to eradicat Change your life For information CONTACTWhatsapp +27 833928661 EMAIL: kennrogger77@gmail.com cleaning black money with ssd chemical solution in Uganda,South sudan,Kemya,South Africa,Dubai,UAE,Kuwait,Tanzanai +27 833928661 Our vision to be the leading premier high-value and high security chemicals producer in the world and offering our services to everyone who knocks at our door step. SSD CHEMICAL SOLUTIONS LTD is uniquely positioned to consistently provide high-value solutions and world-changing chemicals and services to our clients. +27 833928661 WE ARE SPECIALIZED IN CHEMISTRY FOR ANTI-BREEZE BANK NOTES. WE ALSO DO CHEMICALS MELTING AND RECOVERING OF ALL TYPE OF BAD MONEY FROM BLACK TO WHITE AS YOU CAN SEE BELOW. Anti-freezing Preparations and Prepared De-icing Fluids, SSD Solution. Vectrol paste, Tebi-Manetic solution, Defaced currency, Cleaning chemical. Darkened currency, Black coated notes, Cleaning black money, super automatic SSD solution, anti-breeze bank notes. please contact Linda for more information on +27 833928661
  • Topics

×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock