blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
3
264
content_id
stringlengths
40
40
detected_licenses
sequencelengths
0
85
license_type
stringclasses
2 values
repo_name
stringlengths
5
140
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringclasses
905 values
visit_date
timestamp[us]date
2015-08-09 11:21:18
2023-09-06 10:45:07
revision_date
timestamp[us]date
1997-09-14 05:04:47
2023-09-17 19:19:19
committer_date
timestamp[us]date
1997-09-14 05:04:47
2023-09-06 06:22:19
github_id
int64
3.89k
681M
โŒ€
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
22 values
gha_event_created_at
timestamp[us]date
2012-06-07 00:51:45
2023-09-14 21:58:39
โŒ€
gha_created_at
timestamp[us]date
2008-03-27 23:40:48
2023-08-21 23:17:38
โŒ€
gha_language
stringclasses
141 values
src_encoding
stringclasses
34 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
2 classes
length_bytes
int64
3
10.4M
extension
stringclasses
115 values
content
stringlengths
3
10.4M
authors
sequencelengths
1
1
author_id
stringlengths
0
158
ed508889de62f794341dafae450d3e8141967b02
2d1db008579c3a955084947248f114005856e4b9
/Binary_Tree/BSF_Traversal.cpp
6c8fc72ece5b777ee2db323996ca1d68c9c7411b
[]
no_license
bkrohitkumar/Coding-Ninjas_DSA_Problems
ac705fba31f13aa3ef6177f3d4c7a89e86263bce
8453347118e64edcafb8de031bb2a9a45d688e86
refs/heads/main
2023-03-28T17:32:31.373014
2021-04-04T09:52:41
2021-04-04T09:52:41
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,077
cpp
#include <iostream> #include <queue> using namespace std; class Node { public: int data; Node *left; Node *right; Node(int d) { data = d; left = NULL; right = NULL; } }; Node *buildTree() { int d; cin >> d; if (d == -1) { return NULL; } Node *root = new Node(d); root->left = buildTree(); root->right = buildTree(); return root; } void print(Node *root) { if (root == NULL) { return; } cout << root->data << " "; print(root->left); print(root->right); } void BFS(Node *root) { queue<Node *> q; q.push(root); q.push(NULL); while (!q.empty()) { Node *f = q.front(); if(f==NULL) { cout<<endl; q.pop(); if(!q.empty()) { q.push(NULL); } } else { cout << f->data << " " << endl; q.pop(); if (f->left) { q.push(f->left); } if (f->right) { q.push(f->right); } } } return; } int main() { Node *root = buildTree(); BFS(root); }
5b88474eb72903c8b3ab4a610c4b332fc77f3a82
2c459d5850775c39a87a8db1a7182cec073f037c
/Linked List/singlelinkedlist.cpp
ef701d4419f86fe00b2ca5c162ac81278ed145ae
[]
no_license
yukti99/Data-Structures-and-Algorithms
16f02d9e314b5b08d52d15f677943a7f405ffe54
03026721aceee6dfd1b7683b524f7e225ff4446f
refs/heads/master
2022-12-27T13:10:40.740952
2020-10-12T12:14:22
2020-10-12T12:14:22
303,363,249
0
0
null
null
null
null
UTF-8
C++
false
false
4,855
cpp
#include <stdio.h> #include <conio.h> void create(); void display(); void insert(); void clean(); void insert_begin(); void insert_end(); void insert_pos(); void delete_begin(); void delete_end(); void delete_pos(); typedef struct node { int data; struct node *link; }node; node *init=NULL, *ptr, *temp; int ch; int main() { clrscr(); while(1){ printf("\n***SINGLE LINKED LIST OPERATIONS:****"); printf("\n MENU "); printf("\n---------------------------------------"); printf("\n 1.Create "); printf("\n 2.Display "); printf("\n 3.Insert "); printf("\n 4. Delete"); printf("\n 5.Exit "); printf("\n--------------------------------------\n"); printf("Enter your choice:\t"); scanf("%d",&ch); switch(ch) { case 1: create(); break; case 2: display(); break; case 3: insert(); break; case 4: clean(); break; case 5: exit(0); default: printf("\n Wrong Choice:\n"); break; } } return 0; } void create() { struct node *temp,*ptr; temp=(struct node *)malloc(sizeof(struct node)); if(temp==NULL) { printf("\nOut of Memory Space:\n"); exit(0); } printf("\nEnter the data value for the node:\t"); scanf("%d",&temp->data); temp->link=NULL; if(init==NULL) { init=temp; } else { ptr=init; while(ptr->link!=NULL) { ptr=ptr->link; } ptr->link=temp; } } void display() { struct node *ptr; if(init==NULL) { printf("\nList is empty:\n"); return; } else { ptr=init; printf("\nThe List elements are:\n"); while(ptr!=NULL) { printf("%d\t",ptr->data ); ptr=ptr->link; } } } void insert() { int ch; printf("\n1. Insert at beginning \n2. Insert at last \n3. Insert at specific location"); scanf("%d",&ch); switch(ch) { case 1: insert_begin(); break; case 2: insert_end(); break; case 3: insert_pos(); break; default: printf("Invalid choice"); } } void insert_begin() { struct node *temp; temp=(struct node *)malloc(sizeof(struct node)); if(temp==NULL) { printf("\nOut of Memory Space:\n"); return; } printf("\nEnter the data value for the node:\t" ); scanf("%d",&temp->data); temp->link =NULL; if(init==NULL) { init=temp; } else { temp->link=init; init=temp; } } void insert_end() { struct node *temp,*ptr; temp=(struct node *)malloc(sizeof(struct node)); if(temp==NULL) { printf("\nOut of Memory Space:\n"); return; } printf("\nEnter the data value for the node:\t" ); scanf("%d",&temp->data); temp->link =NULL; if(init==NULL) { init=temp; } else { ptr=init; while(ptr->link!=NULL) { ptr=ptr->link ; } ptr->link =temp; } } void insert_pos() { struct node *ptr,*temp; int i,pos; temp=(struct node *)malloc(sizeof(struct node)); if(temp==NULL) { printf("\nOut of Memory Space:\n"); return; } printf("\nEnter the position for the new node to be inserted:\t"); scanf("%d",&pos); printf("\nEnter the data value of the node:\t"); scanf("%d",&temp->data) ; temp->link=NULL; if(pos==0) { temp->link=init; init=temp; } else { for(i=0,ptr=init;ilink; if(ptr==NULL) { printf("\nPosition not found:[Handle with care]\n"); return; } } temp->link =ptr->link ; ptr->link=temp; } } void delete_begin() { struct node *ptr; if(ptr==NULL) { printf("\nList is Empty:\n"); return; } else { ptr=init; init=init->link ; printf("\nThe deleted element is :%d\t",ptr->data); free(ptr); } } void delete_end() { struct node *temp,*ptr; if(init==NULL) { printf("\nList is Empty:"); exit(0); } else if(init->link ==NULL) { ptr=init; init=NULL; printf("\nThe deleted element is:%d\t",ptr->data); free(ptr); } else { ptr=init; while(ptr->link!=NULL) { temp=ptr; ptr=ptr->link; } temp->link=NULL; printf("\nThe deleted element is:%d\t",ptr->data); free(ptr); } } void delete_pos() { int i,pos; struct node *temp,*ptr; if(init==NULL) { printf("\nThe List is Empty:\n"); exit(0); } else { printf("\nEnter the position of the node to be deleted:\t"); scanf("%d",&pos); if(pos==0) { ptr=init; init=init->link ; printf("\nThe deleted element is:%d\t",ptr->data ); free(ptr); } else { ptr=init; for(i=0;ilink ; if(ptr==NULL) { printf("\nPosition not Found:\n"); return; } } temp->link =ptr->link ; printf("\nThe deleted element is:%d\t",ptr->data); free(ptr); } } } void clean() { int choice; printf("\n1. Delete from beginning \n2. Delete from last \n3. Delete specific location"); scanf("%d",&ch); switch(ch) { case 1: delete_begin(); break; case 2: delete_end(); break; case 3: delete_pos(); break; default: printf("Invalid choice"); } }
ce507ac775504626220e395d2736ea67f6e52eb1
8dc84558f0058d90dfc4955e905dab1b22d12c08
/content/renderer/media_recorder/h264_encoder.cc
e85bc535ad6ab094ffee25f4945e0acd4f8ee4de
[ "LicenseRef-scancode-unknown-license-reference", "BSD-3-Clause" ]
permissive
meniossin/src
42a95cc6c4a9c71d43d62bc4311224ca1fd61e03
44f73f7e76119e5ab415d4593ac66485e65d700a
refs/heads/master
2022-12-16T20:17:03.747113
2020-09-03T10:43:12
2020-09-03T10:43:12
263,710,168
1
0
BSD-3-Clause
2020-05-13T18:20:09
2020-05-13T18:20:08
null
UTF-8
C++
false
false
6,976
cc
// Copyright 2017 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "content/renderer/media_recorder/h264_encoder.h" #include <string> #include "base/bind.h" #include "base/threading/thread.h" #include "base/trace_event/trace_event.h" #include "media/base/video_frame.h" #include "third_party/openh264/src/codec/api/svc/codec_app_def.h" #include "third_party/openh264/src/codec/api/svc/codec_def.h" #include "ui/gfx/geometry/size.h" using media::VideoFrame; namespace content { void H264Encoder::ISVCEncoderDeleter::operator()(ISVCEncoder* codec) { if (!codec) return; const int uninit_ret = codec->Uninitialize(); CHECK_EQ(cmResultSuccess, uninit_ret); WelsDestroySVCEncoder(codec); } // static void H264Encoder::ShutdownEncoder(std::unique_ptr<base::Thread> encoding_thread, ScopedISVCEncoderPtr encoder) { DCHECK(encoding_thread->IsRunning()); encoding_thread->Stop(); // Both |encoding_thread| and |encoder| will be destroyed at end-of-scope. } H264Encoder::H264Encoder( const VideoTrackRecorder::OnEncodedVideoCB& on_encoded_video_callback, int32_t bits_per_second, scoped_refptr<base::SingleThreadTaskRunner> task_runner) : Encoder(on_encoded_video_callback, bits_per_second, std::move(task_runner)) { DCHECK(encoding_thread_->IsRunning()); } H264Encoder::~H264Encoder() { main_task_runner_->PostTask( FROM_HERE, base::Bind(&H264Encoder::ShutdownEncoder, base::Passed(&encoding_thread_), base::Passed(&openh264_encoder_))); } void H264Encoder::EncodeOnEncodingTaskRunner( scoped_refptr<VideoFrame> frame, base::TimeTicks capture_timestamp) { TRACE_EVENT0("media", "H264Encoder::EncodeOnEncodingTaskRunner"); DCHECK(encoding_task_runner_->BelongsToCurrentThread()); const gfx::Size frame_size = frame->visible_rect().size(); if (!openh264_encoder_ || configured_size_ != frame_size) { ConfigureEncoderOnEncodingTaskRunner(frame_size); first_frame_timestamp_ = capture_timestamp; } SSourcePicture picture = {}; picture.iPicWidth = frame_size.width(); picture.iPicHeight = frame_size.height(); picture.iColorFormat = EVideoFormatType::videoFormatI420; picture.uiTimeStamp = (capture_timestamp - first_frame_timestamp_).InMilliseconds(); picture.iStride[0] = frame->stride(VideoFrame::kYPlane); picture.iStride[1] = frame->stride(VideoFrame::kUPlane); picture.iStride[2] = frame->stride(VideoFrame::kVPlane); picture.pData[0] = frame->visible_data(VideoFrame::kYPlane); picture.pData[1] = frame->visible_data(VideoFrame::kUPlane); picture.pData[2] = frame->visible_data(VideoFrame::kVPlane); SFrameBSInfo info = {}; if (openh264_encoder_->EncodeFrame(&picture, &info) != cmResultSuccess) { NOTREACHED() << "OpenH264 encoding failed"; return; } const media::WebmMuxer::VideoParameters video_params(frame); frame = nullptr; std::unique_ptr<std::string> data(new std::string); const uint8_t kNALStartCode[4] = {0, 0, 0, 1}; for (int layer = 0; layer < info.iLayerNum; ++layer) { const SLayerBSInfo& layerInfo = info.sLayerInfo[layer]; // Iterate NAL units making up this layer, noting fragments. size_t layer_len = 0; for (int nal = 0; nal < layerInfo.iNalCount; ++nal) { // The following DCHECKs make sure that the header of each NAL unit is OK. DCHECK_GE(layerInfo.pNalLengthInByte[nal], 4); DCHECK_EQ(kNALStartCode[0], layerInfo.pBsBuf[layer_len + 0]); DCHECK_EQ(kNALStartCode[1], layerInfo.pBsBuf[layer_len + 1]); DCHECK_EQ(kNALStartCode[2], layerInfo.pBsBuf[layer_len + 2]); DCHECK_EQ(kNALStartCode[3], layerInfo.pBsBuf[layer_len + 3]); layer_len += layerInfo.pNalLengthInByte[nal]; } // Copy the entire layer's data (including NAL start codes). data->append(reinterpret_cast<char*>(layerInfo.pBsBuf), layer_len); } const bool is_key_frame = info.eFrameType == videoFrameTypeIDR; origin_task_runner_->PostTask( FROM_HERE, base::Bind(OnFrameEncodeCompleted, on_encoded_video_callback_, video_params, base::Passed(&data), nullptr, capture_timestamp, is_key_frame)); } void H264Encoder::ConfigureEncoderOnEncodingTaskRunner(const gfx::Size& size) { TRACE_EVENT0("media", "H264Encoder::ConfigureEncoderOnEncodingTaskRunner"); DCHECK(encoding_task_runner_->BelongsToCurrentThread()); ISVCEncoder* temp_encoder = nullptr; if (WelsCreateSVCEncoder(&temp_encoder) != 0) { NOTREACHED() << "Failed to create OpenH264 encoder"; return; } openh264_encoder_.reset(temp_encoder); configured_size_ = size; #if DCHECK_IS_ON() int trace_level = WELS_LOG_INFO; openh264_encoder_->SetOption(ENCODER_OPTION_TRACE_LEVEL, &trace_level); #endif SEncParamExt init_params; openh264_encoder_->GetDefaultParams(&init_params); init_params.iUsageType = CAMERA_VIDEO_REAL_TIME; DCHECK_EQ(AUTO_REF_PIC_COUNT, init_params.iNumRefFrame); DCHECK(!init_params.bSimulcastAVC); init_params.uiIntraPeriod = 100; // Same as for VpxEncoder. init_params.iPicWidth = size.width(); init_params.iPicHeight = size.height(); DCHECK_EQ(RC_QUALITY_MODE, init_params.iRCMode); DCHECK_EQ(0, init_params.iPaddingFlag); DCHECK_EQ(UNSPECIFIED_BIT_RATE, init_params.iTargetBitrate); DCHECK_EQ(UNSPECIFIED_BIT_RATE, init_params.iMaxBitrate); if (bits_per_second_ > 0) { init_params.iRCMode = RC_BITRATE_MODE; init_params.iTargetBitrate = bits_per_second_; } else { init_params.iRCMode = RC_OFF_MODE; } #if defined(OS_CHROMEOS) init_params.iMultipleThreadIdc = 0; #else // Threading model: Set to 1 due to https://crbug.com/583348. init_params.iMultipleThreadIdc = 1; #endif // TODO(mcasas): consider reducing complexity if there are few CPUs available. init_params.iComplexityMode = MEDIUM_COMPLEXITY; DCHECK(!init_params.bEnableDenoise); DCHECK(init_params.bEnableFrameSkip); // The base spatial layer 0 is the only one we use. DCHECK_EQ(1, init_params.iSpatialLayerNum); init_params.sSpatialLayers[0].iVideoWidth = init_params.iPicWidth; init_params.sSpatialLayers[0].iVideoHeight = init_params.iPicHeight; init_params.sSpatialLayers[0].iSpatialBitrate = init_params.iTargetBitrate; // When uiSliceMode = SM_FIXEDSLCNUM_SLICE, uiSliceNum = 0 means auto design // it with cpu core number. init_params.sSpatialLayers[0].sSliceArgument.uiSliceNum = 0; init_params.sSpatialLayers[0].sSliceArgument.uiSliceMode = SM_FIXEDSLCNUM_SLICE; if (openh264_encoder_->InitializeExt(&init_params) != cmResultSuccess) { NOTREACHED() << "Failed to initialize OpenH264 encoder"; return; } int pixel_format = EVideoFormatType::videoFormatI420; openh264_encoder_->SetOption(ENCODER_OPTION_DATAFORMAT, &pixel_format); } } // namespace content
aeff926e5b49725dcfd1f3c85ebacfb73833d895
b6e5b4176e30175105a6f2b20cc1aacdb33d7b47
/src/frontier/StateKcut.cpp
a31637f911cd7f2979b15227e4f18fb1d90f3377
[ "MIT" ]
permissive
junkawahara/frontier
c6e5568a522089b499b4dfdbc05beb20ef9da691
4ae3eb360c96511ec5f3592b8bc85a1d8bce3aec
refs/heads/master
2021-01-17T09:14:53.470235
2020-09-02T12:54:11
2020-09-02T12:54:11
6,716,415
18
7
null
null
null
null
UTF-8
C++
false
false
3,829
cpp
// // StateKcut.cpp // // Copyright (c) 2012 -- 2016 Jun Kawahara // // Permission is hereby granted, free of charge, to any person obtaining a copy of this software // and associated documentation files (the "Software"), to deal in the Software without // restriction, including without limitation the rights to use, copy, modify, merge, publish, // distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the // Software is furnished to do so, subject to the following conditions: // // The above copyright notice and this permission notice shall be included in all copies or // substantial portions of the Software. // // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING // BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, // DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "StateKcut.hpp" #include "../frontier_lib/PseudoZDD.hpp" namespace frontier_lib { using namespace std; //************************************************************************************************* // StateKcut void StateKcut::UpdateMate(MateKcut* mate, int child_num) { Edge edge = GetCurrentEdge(); if (child_num == 0) { // Loๆžๅ‡ฆ็† ConnectComponents(mate); } else { // Hiๆžๅ‡ฆ็† mate->data.cut_weight += edge.weight; } // ้ ‚็‚นใŒใƒ•ใƒญใƒณใƒ†ใ‚ฃใ‚ขใ‹ใ‚‰ๆŠœใ‘ใ‚‹ใจใใฎๅ‡ฆ็† set<int> isolating_set; for (int i = 0; i < frontier_manager_.GetLeavingFrontierSize(); ++i) { mate_t v = frontier_manager_.GetLeavingFrontierValue(i); // ใƒ•ใƒญใƒณใƒ†ใ‚ฃใ‚ขใ‹ใ‚‰ๆŠœใ‘ใ‚‹้ ‚็‚น bool is_exist = false; for (int j = 0; j < frontier_manager_.GetNextFrontierSize(); ++j) { if (mate->frontier[v].comp == mate->frontier[frontier_manager_.GetNextFrontierValue(j)].comp) { is_exist = true; // ๆ›ดๆ–ฐๅพŒใฎใƒ•ใƒญใƒณใƒ†ใ‚ฃใ‚ขใซๅ€ค v ใ‚’ใ‚‚ใคใ‚‚ใฎใŒๅญ˜ๅœจใ™ใ‚‹ break; } } if (!is_exist) { // ๆ›ดๆ–ฐๅพŒใฎใƒ•ใƒญใƒณใƒ†ใ‚ฃใ‚ขใซๅ€ค v ใ‚’ใ‚‚ใคใ‚‚ใฎใŒๅญ˜ๅœจใ—ใชใ„ // mate_[v] ใฎๅ€คใŒๅˆๅ›žใซ็พใ‚ŒใŸใจใใ ใ‘ใ€number_of_components ใ‚’1ๅข—ๅŠ ใ•ใ›ใ‚‹ if (isolating_set.count(mate->frontier[v].comp) == 0) { isolating_set.insert(mate->frontier[v].comp); ++mate->data.number_of_components; } } } } // mate update ๅ‰ใฎ็ต‚็ซฏๅˆคๅฎšใ€‚ // 0็ต‚็ซฏใชใ‚‰ 0, 1็ต‚็ซฏใชใ‚‰ 1, ใฉใกใ‚‰ใงใ‚‚ใชใ„ๅ ดๅˆใฏ -1 ใ‚’่ฟ”ใ™ใ€‚ int StateKcut::CheckTerminalPre(MateKcut* mate, int child_num) { if (child_num == 1) { if (mate->data.cut_weight >= elimit_.second) { return 0; } else { return -1; } } else { return -1; } } // mate update ๅพŒใฎ็ต‚็ซฏๅˆคๅฎšใ€‚ // 0็ต‚็ซฏใชใ‚‰ 0, 1็ต‚็ซฏใชใ‚‰ 1, ใฉใกใ‚‰ใงใ‚‚ใชใ„ๅ ดๅˆใฏ -1 ใ‚’่ฟ”ใ™ใ€‚ int StateKcut::CheckTerminalPost(MateKcut* mate) { if (IsLastEdge()) { if (mate->data.cut_weight < elimit_.first) { return 0; } if (mate->data.cut_weight > elimit_.second) { return 0; } if (mate->data.number_of_components < component_limit_.first) { return 0; } if (mate->data.number_of_components > component_limit_.second) { return 0; } if (mate->data.number_of_components <= 1) { return 0; } else { return 1; } } else { return -1; } } } // the end of the namespace
3a173eb6fbc3f482c08cd3a420f385e0ff9392c3
7a1d3a30df5166627c4dee2198607a12fd346507
/TIMUS/DP/1658. Sum of Digits.cpp
585bb507eeacde31dbc4b07ced5e4e53d7b0c97b
[]
no_license
edu-417/Online-Judge-Solutions
a5eaad6b0a3d68f25e001cbe24f11e74bb41cb66
731b21b02192e185c69cf657c30e63e871d0fc45
refs/heads/master
2020-05-21T02:11:41.569677
2014-07-27T18:08:12
2014-07-27T18:08:12
185,853,582
0
0
null
null
null
null
UTF-8
C++
false
false
831
cpp
#include<cstdio> #include<vector> using namespace std; #define N 900 int S1,S2,C; int dp[N+5][9*N+5]; int dig[N+5][9*N+5]; void doit(){ scanf("%d%d",&S1,&S2); if(S1>900 || S2>8100 || dp[S1][S2]>100)printf("No solution\n"); else{ vector<int> num; for(int i=S1,j=S2,d=0;i>0 && j>0;i-=d,j-=d*d) d=dig[i][j],num.push_back(d); for(int i=0;i<num.size();++i)printf("%d",num[i]); printf("\n"); } } int main(){ for(int i=0;i<=N;++i) for(int j=0;j<=9*N;++j)dp[i][j]=1000; dp[0][0]=0; for(int i=0;i<=N;++i) for(int j=0;j<=9*N;++j) for(int k=1;k<=9;++k) if(i>=k && j>=k*k) if(dp[i][j]>1+dp[i-k][j-k*k])dp[i][j]=1+dp[i-k][j-k*k],dig[i][j]=k; scanf("%d",&C); for(int i=0;i<C;++i)doit(); }
b67ebc9ed618578919e955586d7feabe9e2c3da4
cb2bcb852a02fc3c0488ab86ecf99640caa51c69
/Password1.cpp
81eb08fde04b93c5168174fca2b53e974f3cb106
[]
no_license
fair1478/code101
761ba33a00d0f34a2dc6a3b27cc4349ad331a928
d704a3d1833701d7c4d12af90da550221c73117a
refs/heads/master
2023-08-10T17:26:25.168555
2021-10-03T10:59:32
2021-10-03T10:59:32
396,300,448
0
0
null
null
null
null
UTF-8
C++
false
false
1,458
cpp
#include<stdio.h> #include<string.h> char P1[100],P2[100],P3[100]; int a[10],b[10],c[10]; main() { scanf("%[^,],%[^,],%[^\n]",P1,P2,P3); if(strlen(P1)>=6&&strlen(P1)<=12) for(int i=0;i<strlen(P1);i++) { if(P1[i]>='a'&&P1[i]<='z') { a[1]=1; } else if(P1[i]>='A'&&P1[i]<='Z') { a[2]=1; } else if(P1[i]>='0'&&P1[i]<='9') { a[3]=1; } else if(P1[i]=='$'||P1[i]=='@'||P1[i]=='#') { a[4]=1; } } if(strlen(P2)>=6&&strlen(P2)<=12) for(int i=0;i<strlen(P2);i++) { if(P2[i]>='a'&&P2[i]<='z') { b[1]=1; } else if(P2[i]>='A'&&P2[i]<='Z') { b[2]=1; } else if(P2[i]>='0'&&P2[i]<='9') { b[3]=1; } else if(P2[i]=='$'||P2[i]=='@'||P2[i]=='#') { b[4]=1; } } if(strlen(P3)>=6&&strlen(P3)<=12) for(int i=0;i<strlen(P3);i++) { if(P3[i]>='a'&&P3[i]<='z') { c[1]=1; } else if(P3[i]>='A'&&P3[i]<='Z') { c[2]=1; } else if(P3[i]>='0'&&P3[i]<='9') { c[3]=1; } else if(P3[i]=='$'||P3[i]=='@'||P3[i]=='#') { c[4]=1; } } for(int i=1;i<4;i++) { a[i+1]+=a[i]; } for(int i=1;i<4;i++) { b[i+1]+=b[i]; } for(int i=1;i<4;i++) { c[i+1]+=c[i]; } if(a[4]==4) printf("%s (Kob)",P1); else if(b[4]==4) printf("%s (Romtham)",P2); else if(c[4]==4) printf("%s (Jojo)",P3); }
ac966808834e3663e322257916bdcbab28cefc0f
65e3391b6afbef10ec9429ca4b43a26b5cf480af
/EVE/converters/ConverterJSON/AliMinimalisticCaloCluster.h
e6de45c9bd6d16845396c6e4f6458a0a0d04fb18
[]
permissive
alisw/AliRoot
c0976f7105ae1e3d107dfe93578f819473b2b83f
d3f86386afbaac9f8b8658da6710eed2bdee977f
refs/heads/master
2023-08-03T11:15:54.211198
2023-07-28T12:39:57
2023-07-28T12:39:57
53,312,169
61
299
BSD-3-Clause
2023-07-28T13:19:50
2016-03-07T09:20:12
C++
UTF-8
C++
false
false
1,151
h
/// \class AliMinimalisticCaloCluster /// In this data containers basic information from calorimeters is stored. Calorime- /// ter cluster is represented as a rectangular cuboid. /// /// \author Maciej Grochowicz <[email protected]>, Warsaw University of Technology #include <iostream> #include <TObject.h> #include <TString.h> #ifndef ALIROOT_ALIMINIMALISTICCALOCLUSTER_H #define ALIROOT_ALIMINIMALISTICCALOCLUSTER_H class AliMinimalisticCaloCluster : public TObject { ClassDef(AliMinimalisticCaloCluster, 1) public: AliMinimalisticCaloCluster(float r,float phi, float eta, float phiHalfLength, float etaHalfLength, float energy); AliMinimalisticCaloCluster() : TObject() { } private: /// Coordinates of the position in space in the spherical coordinate system: Float_t fR; /// radial distance to the middle of the cluster Float_t fPhi; /// azimuthal angle Float_t fEta; /// polar angle /// Dimension of faces: Float_t fPhiHalfLength; /// width Float_t fEtaHalfLength; /// length Float_t fEnergy; /// the height of the cuboid is proportional to the measured energy }; #endif
b9d701e49e6e04246da155e6701b75c1e3c06677
51f6327de38da71ad6b5babf5395228316cb36de
/src/Slava/LoadGameUI.h
895c9e7f7f3df51b6001d261968a6f1b4868f115
[ "Apache-2.0" ]
permissive
admirf/slavagame
ec8ec68c4ffd98ab47ce8129d288882856642146
976d2f4af46f84042d422420b37d1337db3ed412
refs/heads/master
2021-01-10T14:47:24.831087
2017-11-11T14:58:44
2017-11-11T14:58:44
48,291,898
1
0
null
null
null
null
UTF-8
C++
false
false
468
h
#ifndef __LOADGAME_UI_H #define __LOADGAME_UI_H #include "UI.h" #include <vector> #include <string> #include <SFML\Graphics.hpp> namespace slava { class LoadGameUI: public virtual UI { private: std::vector<sf::Text> saveNames; std::vector<sf::RectangleShape> backShapes; sf::Text backText; sf::RectangleShape backShape; public: LoadGameUI(sf::Font&, std::string); void control(GameWorld*); void draw(sf::RenderWindow&); }; } #endif
d1d082ec7b7b6f4744e0985fc15c25892cdfe507
70695d1552407fae021205b74722b75505e02f06
/cses/graph/highscore.cpp
0bb6e9546a249d15b90574246c9c814efea38cde
[]
no_license
lanukk/cp
394c4c966b9e3c85d7222954f5726e4284d893d3
3a2ebcf20baa1b0bfb25b22761adfebe7fcbde72
refs/heads/master
2023-03-27T13:51:16.856100
2021-04-04T11:59:56
2021-04-04T11:59:56
319,751,565
0
1
null
null
null
null
UTF-8
C++
false
false
950
cpp
#include<bits/stdc++.h> using namespace std; int n; int m; vector<vector<pair<int, int>>>adj; vector<long long int>d; struct node { int a, b, w; }; #define INF 100000000000000000LL #define NINF -100000000000000000LL int main() { cin >> n >> m; adj.resize(n + 1); node e[m]; for (int i = 0 ; i < m; i++) { int x, y, wt; cin >> x >> y >> wt; adj[x].push_back({y, wt}); e[i].a = x; e[i].b = y; e[i].w = -1 * wt; } d.assign(n + 1, INF); d[1] = 0; for (int i = 0 ; i < n - 1; i++) { for (int j = 0 ; j < m; j++) { if (d[e[j].a] < INF) { d[e[j].b] = min(d[e[j].b], d[e[j].a] + e[j].w); d[e[j].b] = max(d[e[j].b], NINF); } } } for (int i = 0 ; i < n - 1; i++) { for (int j = 0 ; j < m; j++) { if (d[e[j].a] >= INF)continue; d[e[j].b] = max(d[e[j].b], NINF); if (d[e[j].b] > d[e[j].a] + e[j].w) { d[e[j].b] = NINF; } } } if (d[n] == NINF) { cout << "-1"; return 0; } cout << -1 * d[n]; }
cbf5f8b95b1797e27a241d8435e8f247521235f0
f3af166b84a1dba4219526d669a09838936de43c
/Firmware/Firmware/Serial.h
6d44473abc019e34ff2372ccd2940ceb2bd405a1
[]
no_license
RomualdRousseau/TheSPT
05ec064999c1860f5ba6d8ac7df5a26821a3476b
c4df86ab75e4c8417f2e8811fba7880e42c8a3bf
refs/heads/main
2023-05-13T05:28:11.324092
2023-05-06T23:13:39
2023-05-06T23:13:39
58,851,475
0
0
null
null
null
null
UTF-8
C++
false
false
4,191
h
#define SERIAL_BUFFER_SIZE 256 #define SERIAL_MAX_ARGS 100 #define AT 0 #define AT_LIST_MODEL 1 #define AT_GET_MODEL 2 #define AT_LOAD_MODEL 3 #define AT_SAVE_MODEL 4 #define AT_RENAME_MODEL 5 #define AT_READ_MIXER 6 #define AT_WRITE_MIXER 7 #define AT_READ_TRIM 8 #define AT_WRITE_TRIM 9 #define AT_READ_FUNC 10 #define AT_WRITE_FUNC 11 #define AT_READ_BATTERY 12 #define AT_READ_COMMAND 13 #define AT_UNKNOWN 255 void at_version(); void at_list_model(); void at_get_model(); void at_load_model(int model); void at_save_model(); void at_rename_model(char* newname); void at_read_mixer(); void at_write_mixer(char** args); void at_read_trim(); void at_write_trim(char** args); void at_read_func(); void at_write_func(char** args); void at_read_battery(); void at_read_command(); class Serial_ { public: void init(); void reset(); void process_at_command(); private: char buffer[SERIAL_BUFFER_SIZE]; int buffer_idx; int tokenize(char* s, char** argv, int* argc); void accept(int token, char** argv, int argc); }; void Serial_::init() { Serial.begin(115200); while (!Serial) { ; // wait for serial port to connect. Needed for native USB port only } } void Serial_::reset() { buffer_idx = 0; } void Serial_::process_at_command() { while (Serial.available() > 0) { char c = Serial.read(); if (c == '\n') { buffer[buffer_idx] = 0; char* argv[SERIAL_MAX_ARGS + 1]; int argc = 0; int cmd = tokenize(buffer, argv, &argc); accept(cmd, argv, argc); buffer_idx = 0; } else if (c != '\r') { buffer[buffer_idx] = c; buffer_idx = (buffer_idx + 1) % SERIAL_BUFFER_SIZE; } } } int Serial_::tokenize(char* s, char** argv, int* argc) { char** p = argv; int n = 0; char* token = strtok(s, "=,"); while (token != NULL && n < SERIAL_MAX_ARGS) { p[n++] = token; token = strtok(NULL, "=,"); } *argc = n; if (n == 0) { return AT_UNKNOWN; } if (strcmp(argv[0], "AT") == 0) { return AT; } else if (strcmp(argv[0], "AT+LSMDL") == 0) { return AT_LIST_MODEL; } else if (strcmp(argv[0], "AT+GMDL") == 0) { return AT_GET_MODEL; } else if (strcmp(argv[0], "AT+LMDL") == 0) { return AT_LOAD_MODEL; } else if (strcmp(argv[0], "AT+SMDL") == 0) { return AT_SAVE_MODEL; } else if (strcmp(argv[0], "AT+RNMDL") == 0) { return AT_RENAME_MODEL; } else if (strcmp(argv[0], "AT+RMXR") == 0) { return AT_READ_MIXER; } else if (strcmp(argv[0], "AT+WMXR") == 0) { return AT_WRITE_MIXER; } else if (strcmp(argv[0], "AT+RTRM") == 0) { return AT_READ_TRIM; } else if (strcmp(argv[0], "AT+WTRM") == 0) { return AT_WRITE_TRIM; } else if (strcmp(argv[0], "AT+RFUN") == 0) { return AT_READ_FUNC; } else if (strcmp(argv[0], "AT+WFUN") == 0) { return AT_WRITE_FUNC; } else if (strcmp(argv[0], "AT+RBAT") == 0) { return AT_READ_BATTERY; } else if (strcmp(argv[0], "AT+RCOM") == 0) { return AT_READ_COMMAND; } else { return AT_UNKNOWN; } } void Serial_::accept(int token, char** argv, int argc) { if (token == AT) { at_version(); } if (token == AT_LIST_MODEL) { at_list_model(); } if (token == AT_GET_MODEL) { at_get_model(); } if (token == AT_LOAD_MODEL && argc == 1+1) { at_load_model(atoi(argv[1])); } if (token == AT_SAVE_MODEL) { at_save_model(); } if (token == AT_RENAME_MODEL && argc == 1+1) { at_rename_model(argv[1]); } if (token == AT_READ_MIXER) { at_read_mixer(); } if (token == AT_WRITE_MIXER && argc == 1+1+8) { at_write_mixer(argv); } if (token == AT_READ_TRIM) { at_read_trim(); } if (token == AT_WRITE_TRIM && argc == 1+8) { at_write_trim(argv); } if (token == AT_READ_FUNC) { at_read_func(); } if (token == AT_WRITE_FUNC && argc == 1+8) { at_write_func(argv); } if (token == AT_READ_BATTERY) { at_read_battery(); } if (token == AT_READ_COMMAND) { at_read_command(); } }
5bcc91bac2bf641ebe947c17630c4a3586804c7a
d7ee90b1f07bf70c5fc122d8395fa564ffe6a9d3
/app/src/main/cpp/vulkan/renderpass/msaa_shader_read_renderpass.cpp
2aaf99c75bf70dc07578b8f840830fbaef45bae8
[]
no_license
joyxu/Vulkan-on-Android
8b6dd01f4185ac0cb1f34e3801c1fd51e679564f
9ab9a3e82b534a220a6ed47a361d5b59ebf8ae85
refs/heads/master
2022-01-05T13:17:44.677032
2019-02-11T05:02:24
2019-02-11T05:02:24
null
0
0
null
null
null
null
UTF-8
C++
false
false
5,994
cpp
๏ปฟ#include "msaa_shader_read_renderpass.h" #include "../vulkan_utility.h" namespace Vulkan { void MSAAShaderReadRenderPass::CreateRenderPassImpl() { const Device &device = _device; VkFormat colorFormat = getFormat(); VkSampleCountFlagBits samples = getSampleCount(); VkAttachmentDescription colorAttachment = {}; colorAttachment.format = colorFormat; colorAttachment.samples = samples; colorAttachment.loadOp = VK_ATTACHMENT_LOAD_OP_CLEAR; // After resolving the texture, we do not need to preserve it, so use DONT_CARE for storeOp here. colorAttachment.storeOp = VK_ATTACHMENT_STORE_OP_DONT_CARE; colorAttachment.stencilLoadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE; colorAttachment.stencilStoreOp = VK_ATTACHMENT_STORE_OP_DONT_CARE; colorAttachment.initialLayout = VK_IMAGE_LAYOUT_UNDEFINED; colorAttachment.finalLayout = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL; VkAttachmentDescription depthAttachment = {}; _depthFormat = FindDeviceSupportedFormat({ VK_FORMAT_D16_UNORM, VK_FORMAT_D16_UNORM_S8_UINT, VK_FORMAT_D24_UNORM_S8_UINT, VK_FORMAT_D32_SFLOAT, VK_FORMAT_D32_SFLOAT_S8_UINT }, VK_IMAGE_TILING_OPTIMAL, VK_FORMAT_FEATURE_DEPTH_STENCIL_ATTACHMENT_BIT, device.PhysicalDevice()); depthAttachment.format = _depthFormat; depthAttachment.samples = samples; depthAttachment.loadOp = VK_ATTACHMENT_LOAD_OP_CLEAR; depthAttachment.storeOp = VK_ATTACHMENT_STORE_OP_DONT_CARE; depthAttachment.stencilLoadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE; depthAttachment.stencilStoreOp = VK_ATTACHMENT_STORE_OP_DONT_CARE; depthAttachment.initialLayout = VK_IMAGE_LAYOUT_UNDEFINED; depthAttachment.finalLayout = VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL; VkAttachmentDescription resolveAttachment = {}; resolveAttachment.format = colorFormat; resolveAttachment.samples = VK_SAMPLE_COUNT_1_BIT; // loadOp is meaningless here since we will resolve to it and never render to it. resolveAttachment.loadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE; resolveAttachment.storeOp = VK_ATTACHMENT_STORE_OP_STORE; resolveAttachment.stencilLoadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE; resolveAttachment.stencilStoreOp = VK_ATTACHMENT_STORE_OP_DONT_CARE; resolveAttachment.initialLayout = VK_IMAGE_LAYOUT_UNDEFINED; resolveAttachment.finalLayout = VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL; VkAttachmentReference colorReference = {}; colorReference.attachment = 0; colorReference.layout = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL; VkAttachmentReference depthReference = {}; depthReference.attachment = 1; depthReference.layout = VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL; VkAttachmentReference resolveReference = {}; resolveReference.attachment = 2; resolveReference.layout = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL; VkSubpassDescription subpassDescription = {}; subpassDescription.pipelineBindPoint = VK_PIPELINE_BIND_POINT_GRAPHICS; subpassDescription.colorAttachmentCount = 1; subpassDescription.pColorAttachments = &colorReference; subpassDescription.pDepthStencilAttachment = &depthReference; subpassDescription.pResolveAttachments = &resolveReference; VkAttachmentDescription attachments[] = { colorAttachment, depthAttachment, resolveAttachment }; VkRenderPassCreateInfo renderPassInfo = {}; renderPassInfo.sType = VK_STRUCTURE_TYPE_RENDER_PASS_CREATE_INFO; renderPassInfo.attachmentCount = 3; renderPassInfo.pAttachments = attachments; renderPassInfo.subpassCount = 1; renderPassInfo.pSubpasses = &subpassDescription; VkSubpassDependency dependencies[] = { {}, {} }; if (device.FamilyQueues().graphics.index == device.FamilyQueues().present.index) { dependencies[0].srcSubpass = VK_SUBPASS_EXTERNAL; dependencies[0].dstSubpass = 0; dependencies[0].srcStageMask = VK_PIPELINE_STAGE_FRAGMENT_SHADER_BIT; dependencies[0].dstStageMask = VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT; dependencies[0].srcAccessMask = VK_ACCESS_SHADER_READ_BIT; dependencies[0].dstAccessMask = VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT; dependencies[0].dependencyFlags = VK_DEPENDENCY_BY_REGION_BIT; dependencies[1].srcSubpass = 0; dependencies[1].dstSubpass = VK_SUBPASS_EXTERNAL; dependencies[1].srcStageMask = VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT; dependencies[1].dstStageMask = VK_PIPELINE_STAGE_FRAGMENT_SHADER_BIT; dependencies[1].srcAccessMask = VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT; dependencies[1].dstAccessMask = VK_ACCESS_SHADER_READ_BIT; dependencies[1].dependencyFlags = VK_DEPENDENCY_BY_REGION_BIT; renderPassInfo.dependencyCount = 2; renderPassInfo.pDependencies = dependencies; } VK_CHECK_RESULT(vkCreateRenderPass(device.LogicalDevice(), &renderPassInfo, nullptr, &_renderPass)); } // class MSAAShaderReadRenderPass : public MSAARenderPass // { // public: // MSAAShaderReadRenderPass(const Device& device) : MSAARenderPass(device) {} // MSAAShaderReadRenderPassverride // { // DebugLog("MSAAShaderReadRenderPass; // vkDestroyRenderPass(_device.LogicalDevice(), _renderPass, nullptr); // _renderPass = VK_NULL_HANDLE; // } // // private: // virtual void CreateRenderPassImpl() override { CreateRenderPassFlow(VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL, VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL); } // }; }
75973450816b9bc97b1669743977e2a9353a8419
715a8eee12bdb71ce9df58e8622c6febbe00a5ac
/Tools/imgui/HeavenGate_Editor/HeavenGateWindowNodeGraph.h
54b5fce6e97784f5b10b2520d219f2a6211ccf50
[ "MIT" ]
permissive
shiki-wzx/Hippocampus
33cc27d0d5c210917cae789ad4e159c9e85e8417
775cc2114b32897f271d43b1b0a29431a6f180a6
refs/heads/master
2022-09-12T09:40:29.677986
2020-06-01T14:15:54
2020-06-01T14:15:54
null
0
0
null
null
null
null
UTF-8
C++
false
false
554
h
#pragma once #include "HeavenGateEditorBaseWindow.h" namespace HeavenGateEditor { class HeavenGateWindowNodeGraph : public HeavenGateEditorBaseWindow { WINDOW_DECLARE("Heaven Gate Editor", Window_Type::MainWindow) public: HeavenGateWindowNodeGraph(); virtual ~HeavenGateWindowNodeGraph() override; virtual void Initialize() override{} virtual void Shutdown() override{} virtual void UpdateMainWindow() override{} virtual void UpdateMenu() override {} private: }; }
20ee74516281ce1ff20a63f6d8d0bd974cb7bf69
a6a7b8742f5299e6537fa8065eff71d65132ea1a
/funny_string.cpp
a8ae2933b8e5d02bb1c229fd4911c3f0a103f12f
[]
no_license
blackenwhite/Competitive-Coding
bb25994a9ffe3c8ac1476b4b11640a01f10e36e7
c95ecfc1dfc7879c02899341083569a4e60da2f8
refs/heads/master
2021-05-19T08:23:41.785230
2020-04-02T13:12:04
2020-04-02T13:12:04
251,603,623
0
0
null
2020-03-31T12:59:16
2020-03-31T12:59:16
null
UTF-8
C++
false
false
745
cpp
#include <bits/stdc++.h> using namespace std; int charDiff(char a,char b) { return abs(a-b); } string funnyString(string s){ // Complete this function int len=s.size()-1; int flag=0; for(int i=0;i<len;i++) { int revIndex=len-i; int diff_fwd=charDiff(s[i],s[i+1]); int diff_rev=charDiff(s[revIndex],s[revIndex-1]); if(diff_fwd!=diff_rev) { flag=1; break; } } if(flag) return "Not Funny"; else return "Funny"; } int main() { int q; cin >> q; for(int a0 = 0; a0 < q; a0++){ string s; cin >> s; string result = funnyString(s); cout << result << endl; } return 0; }
82ffa5864c811bf4861f09e8ae3459d662d01167
2e72a74d760a8c14ca242df077413a9ff9699774
/src/d2_ee_ppdp_CC.cpp
b968300e464f3800741cbb8a2268ad258581a844
[]
no_license
chemiczny/automateusz_gto_d2
ba3f1bec939a135a3591d512663ee01c4aa10b0c
b4c7e0978424bf53fd4b1f67de8e65ab3373fc10
refs/heads/master
2020-03-21T15:30:46.767378
2019-05-08T14:33:56
2019-05-08T14:33:56
138,716,717
0
0
null
null
null
null
UTF-8
C++
false
false
1,973
cpp
#include "gto_d2_kit/d2_ee_ppdp_CC.hpp" #include "gto_d2_kit/d2_ee_dppp_AA.hpp" void second_derivative_ee_1121_33( const double ae, const double xA, const double yA, const double zA, const double be, const double xB, const double yB, const double zB, const double ce, const double xC, const double yC, const double zC, const double de, const double xD, const double yD, const double zD, const double* const bs, double* const d2eexx, double* const d2eexy, double* const d2eexz, double* const d2eeyx, double* const d2eeyy, double* const d2eeyz, double* const d2eezx, double* const d2eezy, double* const d2eezz) { double txx [135]= {}; double txy [135]= {}; double txz [135]= {}; double tyx [135]= {}; double tyy [135]= {}; double tyz [135]= {}; double tzx [135]= {}; double tzy [135]= {}; double tzz [135]= {}; second_derivative_ee_2111_11( ce, xC, yC, zC, de, xD, yD, zD, ae, xA, yA, zA, be, xB, yB, zB, bs, txx, txy, txz, tyx, tyy, tyz, tzx, tzy, tzz ); for( int k = 0 ; k<5; k++){ for( int l = 0 ; l<3; l++){ for( int i = 0 ; i<3; i++){ for( int j = 0 ; j<3; j++){ int destinyInd = (((i)*3+j)*5+k)*3+l; int sourceInd = (((k)*3+l)*3+i)*3+j; d2eexx[ destinyInd ] += txx[ sourceInd ]; d2eexy[ destinyInd ] += txy[ sourceInd ]; d2eexz[ destinyInd ] += txz[ sourceInd ]; d2eeyx[ destinyInd ] += tyx[ sourceInd ]; d2eeyy[ destinyInd ] += tyy[ sourceInd ]; d2eeyz[ destinyInd ] += tyz[ sourceInd ]; d2eezx[ destinyInd ] += tzx[ sourceInd ]; d2eezy[ destinyInd ] += tzy[ sourceInd ]; d2eezz[ destinyInd ] += tzz[ sourceInd ]; } } } } }
1341fa5b2ec5c2d5df619e5936b7dfaf11713241
0805b803ad608e07810af954048359c927294a0e
/bvheditor/Wml/Source/Intersection/WmlIntrCap3Cap3.cpp
33573d68141137ac5828c25e7de9a52ecb8a43d3
[]
no_license
yiyongc/BvhEditor
005feb3f44537544d66d54ab419186b73e184f57
b512e240bc7b1ad5f54fd2e77f0a3194302aab2d
refs/heads/master
2023-03-15T14:19:31.292081
2017-03-30T17:27:17
2017-03-30T17:27:17
66,918,016
0
0
null
null
null
null
UTF-8
C++
false
false
1,407
cpp
// Magic Software, Inc. // http://www.magic-software.com // http://www.wild-magic.com // Copyright (c) 2004. All Rights Reserved // // The Wild Magic Library (WML) source code is supplied under the terms of // the license agreement http://www.magic-software.com/License/WildMagic.pdf // and may not be copied or disclosed except in accordance with the terms of // that agreement. #include "WmlDistLin3Lin3.h" #include "WmlIntrCap3Cap3.h" using namespace Wml; //---------------------------------------------------------------------------- template <class Real> bool Wml::TestIntersection (const Capsule3<Real>& rkC0, const Capsule3<Real>& rkC1) { Real fSqrDist = SqrDistance<Real>(rkC0.Segment(),rkC1.Segment()); Real fRSum = rkC0.Radius() + rkC1.Radius(); Real fRSumSqr = fRSum*fRSum; return fSqrDist <= fRSumSqr; } //---------------------------------------------------------------------------- //---------------------------------------------------------------------------- // explicit instantiation //---------------------------------------------------------------------------- namespace Wml { template WML_ITEM bool TestIntersection<float> (const Capsule3<float>&, const Capsule3<float>&); template WML_ITEM bool TestIntersection<double> (const Capsule3<double>&, const Capsule3<double>&); } //----------------------------------------------------------------------------
34529f10076262213d478b90ab737349fbee0150
2cbdf96e9609ef2e04fced0594fedceff00d6eb8
/ๆœ‰้ฆฌๅ›ใธ/Chokotto_Syagekiroku/window.cpp
278fd98647a06561008f70f4ba71bb12f9ab020b
[]
no_license
takeuchiwataru/ArimaCorporation
4eaa9b6899770dc4421a6b4fcf9eb37fd43276ea
aeaac1b6e365bda65d23986a55ffc54e41ab9428
refs/heads/master
2022-04-12T20:42:18.254528
2020-02-21T07:13:49
2020-02-21T07:13:49
212,750,074
0
0
null
null
null
null
SHIFT_JIS
C++
false
false
26,381
cpp
//=========================================================================================================// // // windowๅ‡ฆ็† [window.cpp] // Author : Ryou Sugimoto // //=========================================================================================================// #include "main.h" #include "game.h" #include "input.h" //*********************************************************************************************************// // ใƒžใ‚ฏใƒญๅฎš็พฉ //*********************************************************************************************************// #define WINDOW_VERTEX_NUM (4) // ้ ‚็‚นใฎๆ•ฐ #define WINDOW_PRIMITIVE_NUM (2) // ใƒ—ใƒชใƒŸใƒ†ใ‚ฃใƒ–ใฎๆ•ฐ #define WINDOW_MAX_TEXTURE (26) #define WINDOW_TextureName0 "data/TEXTURE/press_enter.png" //ใ‚ฟใ‚คใƒˆใƒซ ใ‚จใƒณใ‚ฟใƒผใ‚ญใƒผ #define WINDOW_TextureName1 "data/TEXTURE/now loading" //NOW LOADING #define WINDOW_TextureName2 "data/TEXTURE/SELECTWINDOW.png" //Title ้›ฃๆ˜“ๅบฆ้ธๆŠž #define WINDOW_TextureName3 "data/TEXTURE/gameover.jpg" //ใ‚ฒใƒผใƒ ใ‚ชใƒผใƒใƒผ0 #define WINDOW_TextureName4 "data/TEXTURE/gameover000.png" //ใ‚ฒใƒผใƒ ใ‚ชใƒผใƒใƒผ1 #define WINDOW_TextureName5 "data/TEXTURE/gameclear_logo.png" //ใ‚ฒใƒผใƒ ใ‚ฏใƒชใ‚ขใƒญใ‚ด #define WINDOW_TextureName6 "data/TEXTURE/GameClear000.jpg" //ใ‚ฒใƒผใƒ ใ‚ฏใƒชใ‚ขBG #define WINDOW_TextureName7 "data/TEXTURE/Player002.png" //ใƒ•ใƒŠใƒƒใ‚ทใƒผ๏ผๆฎ‹ๆฉŸ #define WINDOW_TextureName8 "data/TEXTURE/START.png" //Titleใ€€STARTใƒญใ‚ด #define WINDOW_TextureName9 "data/TEXTURE/TUTORIAL001.png" //Titleใ€€TUTORIALใƒญใ‚ด #define WINDOW_TextureName10 "data/TEXTURE/END.png" //Titleใ€€๏ผฅ๏ผฎ๏ผคใƒญใ‚ด #define WINDOW_TextureName11 "data/TEXTURE/Easy.png" //Titleใ€€๏ผฅ๏ผก๏ผณ๏ผนใƒญใ‚ด #define WINDOW_TextureName12 "data/TEXTURE/Normal.png" //Titleใ€€NORMALใƒญใ‚ด #define WINDOW_TextureName13 "data/TEXTURE/Hard.png" //Titleใ€€๏ผจ๏ผก๏ผฒ๏ผคใƒญใ‚ด #define WINDOW_TextureName14 "data/TEXTURE/Lunatic.png" //Titleใ€€LUNATICใƒญใ‚ด #define WINDOW_TextureName15 "data/TEXTURE/pause100.png" //PAUSEๆž  #define WINDOW_TextureName16 "data/TEXTURE/pause000.png" //PAUSEใƒญใ‚ด #define WINDOW_TextureName17 "data/TEXTURE/pause001.png" //PAUSEใƒญใ‚ด #define WINDOW_TextureName18 "data/TEXTURE/pause002.png" //PAUSEใƒญใ‚ด #define WINDOW_TextureName19 "data/TEXTURE/Guard000.png" //GUARDใ€€ไฝฟ็”จ็Šถๆ…‹ #define WINDOW_TextureName20 "data/TEXTURE/Guard001.png" //GUARDใ€€ใƒใƒฃใƒผใ‚ธๆธˆใฟ #define WINDOW_TextureName21 "data/TEXTURE/FontWindow.png" //FONTใฎใŸใ‚ใฎๆž  #define WINDOW_TextureName22 "data/TEXTURE/BOSS003.png" //Gameใƒœใ‚น #define WINDOW_TextureName23 "data/TEXTURE/BOSS_Change004.png" //Gameใƒœใ‚นMODEChangeๆ™‚ #define WINDOW_TextureName24 "" //ใƒžใƒ†ใƒชใ‚ขใƒซใฎ่‰ฒ #define MAX_WINDOW (24) // windowใฎๆœ€ๅคงๆ•ฐ #define HALFEXPLOSION (30) //***************************************************************************** // ๆง‹้€ ไฝ“ๅฎš็พฉ //***************************************************************************** typedef struct { D3DXVECTOR3 pos; //ไฝ็ฝฎ D3DXCOLOR col; int nLengthX; int nLengthY; int nType; float fSteep; //่ง’ๅบฆ WINDOWSTATE state; WINDOWUSE use; int nCounterState[2]; //ใ‚จใƒใƒŸใƒผใฎ็Šถๆ…‹็ฎก็†็”จ bool bUse; }Window; //*********************************************************************************************************// // ใ‚ฐใƒญใƒผใƒใƒซๅค‰ๆ•ฐ //*********************************************************************************************************// LPDIRECT3DTEXTURE9 g_pTextureWindow[WINDOW_MAX_TEXTURE] = {}; // ใƒ†ใ‚ฏใ‚นใƒใƒฃใธใฎใƒใ‚คใƒณใ‚ฟ LPDIRECT3DVERTEXBUFFER9 g_pVtxBuffWindow = NULL; // ้ ‚็‚นใƒใƒƒใƒ•ใ‚กใธใฎใƒใ‚คใƒณใ‚ฟ Window g_aWindow[MAX_WINDOW]; //=========================================================================================================// // * ่ƒŒๆ™ฏใฎๆ็”ปๅ‡ฆ็†1 ๅˆๆœŸๅŒ–ๅ‡ฆ็† //=========================================================================================================// void InitWindow(void) { LPDIRECT3DDEVICE9 pDevice; pDevice = GetDevice(); int nCntWindow; // ๅผพใฎๆƒ…ๅ ฑใฎๅˆๆœŸๅŒ– for (nCntWindow = 0; nCntWindow < MAX_WINDOW; nCntWindow++) { //g_aWindow[nCntWindow].pos = { 0.0f, 0.0f, 0.0f }; //g_aWindow[nCntWindow].nLengthX = 0; //g_aWindow[nCntWindow].nLengthY = 0; //g_aWindow[nCntWindow].nType = 0; //g_aWindow[nCntWindow].col = { 1.0f, 1.0f, 1.0f, }; g_aWindow[nCntWindow].bUse = false; } D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName0, &g_pTextureWindow[0]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName1, &g_pTextureWindow[1]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName2, &g_pTextureWindow[2]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName3, &g_pTextureWindow[3]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName4, &g_pTextureWindow[4]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName5, &g_pTextureWindow[5]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName6, &g_pTextureWindow[6]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName7, &g_pTextureWindow[7]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName8, &g_pTextureWindow[8]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName9, &g_pTextureWindow[9]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName10, &g_pTextureWindow[10]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName11, &g_pTextureWindow[11]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName12, &g_pTextureWindow[12]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName13, &g_pTextureWindow[13]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName14, &g_pTextureWindow[14]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName15, &g_pTextureWindow[15]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName16, &g_pTextureWindow[16]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName17, &g_pTextureWindow[17]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName18, &g_pTextureWindow[18]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName19, &g_pTextureWindow[19]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName20, &g_pTextureWindow[20]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName21, &g_pTextureWindow[21]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName22, &g_pTextureWindow[22]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName23, &g_pTextureWindow[23]); D3DXCreateTextureFromFile(pDevice, WINDOW_TextureName24, &g_pTextureWindow[24]); //้ ‚็‚นBUFFERใฎ็”Ÿๆˆ pDevice->CreateVertexBuffer(sizeof(VERTEX_2D) * WINDOW_VERTEX_NUM * MAX_WINDOW, //็ขบไฟใ™ใ‚‹BUFFERใฎใ‚ตใ‚คใ‚บ D3DUSAGE_WRITEONLY, FVF_VERTEX_2D, //้ ‚็‚นใƒ•ใ‚ฉใƒผใƒžใƒƒใƒˆ D3DPOOL_MANAGED, &g_pVtxBuffWindow, NULL); VERTEX_2D *pVtx; //้ ‚็‚นๆƒ…ๅ ฑใธใฎใƒใ‚คใƒณใ‚ฟ //้ ‚็‚นBUFFERใ‚’ใƒญใƒƒใ‚ฏใ—ใ€้ ‚็‚นๆƒ…ๅ ฑใธใฎใƒใ‚คใƒณใ‚ฟใ‚’ๅ–ๅพ— g_pVtxBuffWindow->Lock(0, 0, (void**)&pVtx, 0); for (nCntWindow = 0; nCntWindow < MAX_WINDOW; nCntWindow++) { //้ ‚็‚นๅบงๆจ™ใฎ่จญๅฎš pVtx[nCntWindow * 4].pos = D3DXVECTOR3(0, 0, 0.0f); pVtx[nCntWindow * 4 + 1].pos = D3DXVECTOR3(0, 0, 0.0f); pVtx[nCntWindow * 4 + 2].pos = D3DXVECTOR3(0, 0, 0.0f); pVtx[nCntWindow * 4 + 3].pos = D3DXVECTOR3(0, 0, 0.0f); pVtx[nCntWindow * 4].rhw = 1.0f; pVtx[nCntWindow * 4 + 1].rhw = 1.0f; pVtx[nCntWindow * 4 + 2].rhw = 1.0f; pVtx[nCntWindow * 4 + 3].rhw = 1.0f; //ใ‚ซใƒฉใƒผ่จญๅฎš pVtx[nCntWindow * 4].col = D3DCOLOR_RGBA(0, 0, 0, 255); // A = ้€ๆ˜Žๅบฆ pVtx[nCntWindow * 4 + 1].col = D3DCOLOR_RGBA(0, 0, 0, 255); pVtx[nCntWindow * 4 + 2].col = D3DCOLOR_RGBA(0, 0, 0, 255); pVtx[nCntWindow * 4 + 3].col = D3DCOLOR_RGBA(0, 0, 0, 255); //ใƒ†ใ‚ฏใ‚นใƒใƒฃๅบงๆจ™่จญๅฎš pVtx[nCntWindow * 4].tex = D3DXVECTOR2(0.0f, 0.0f); pVtx[nCntWindow * 4 + 1].tex = D3DXVECTOR2(1.0f, 0.0f); pVtx[nCntWindow * 4 + 2].tex = D3DXVECTOR2(0.0f, 1.0f); pVtx[nCntWindow * 4 + 3].tex = D3DXVECTOR2(1.0f, 1.0f); } //้ ‚็‚นBUFFERใ‚’ใ‚ขใƒณใƒญใƒƒใ‚ฏใ™ใ‚‹ g_pVtxBuffWindow->Unlock(); } //=========================================================================================================// // * ่ƒŒๆ™ฏใฎๆ็”ปๅ‡ฆ็†2 ็ต‚ไบ†ๅ‡ฆ็† //=========================================================================================================// void UninitWindow(void) {//ใƒ†ใ‚ฏใ‚นใƒใƒฃใฎ็ ดๆฃ„ int nCntTexture; for (nCntTexture = 0; nCntTexture < WINDOW_MAX_TEXTURE; nCntTexture++) { if (g_pTextureWindow[nCntTexture] != NULL) { g_pTextureWindow[nCntTexture]->Release(); g_pTextureWindow[nCntTexture] = NULL; } } if (g_pVtxBuffWindow != NULL) { g_pVtxBuffWindow->Release(); g_pVtxBuffWindow = NULL; } } //=========================================================================================================// // * ่ƒŒๆ™ฏใฎๆ็”ปๅ‡ฆ็†3 ๆ›ดๆ–ฐๅ‡ฆ็† //=========================================================================================================// void UpdateWindow(void) { int nCntWindow; static float fStealth = 0.02f; VERTEX_2D *pVtx; //้ ‚็‚นๆƒ…ๅ ฑใธใฎใƒใ‚คใƒณใ‚ฟ PLAYER *pPlayer; pPlayer = GetPlayer(); //้ ‚็‚นBUFFERใ‚’ใƒญใƒƒใ‚ฏใ—ใ€้ ‚็‚นๆƒ…ๅ ฑใธใฎใƒใ‚คใƒณใ‚ฟใ‚’ๅ–ๅพ— g_pVtxBuffWindow->Lock(0, 0, (void**)&pVtx, 0); for (nCntWindow = 0; nCntWindow < MAX_WINDOW; nCntWindow++) { if (g_aWindow[nCntWindow].bUse == true && g_aWindow[nCntWindow].state != WINDOWSTATE_NORMAL) { switch (g_aWindow[nCntWindow].state) { case WINDOWSTATE_STEALTH://่จญๅฎšใ•ใ‚ŒใŸ้€ๆ˜Žๅบฆใ‹ใ‚‰ๆ˜Žใ‚‹ใใชใ‚Š255ใง้€šๅธธใซใชใ‚‹ g_aWindow[nCntWindow].col.a += 0.012f; if (GetKeyboardTrigger(DIK_RETURN) == true || GetKeyboardTrigger(DIK_UP) == true || GetKeyboardTrigger(DIK_DOWN) == true || GetKeyboardTrigger(DIK_Z) == true || g_aWindow[nCntWindow].col.a >= 1.0f) {//ใ‚ญใƒผๅ…ฅๅŠ›ใงใ‚นใ‚ญใƒƒใƒ— g_aWindow[nCntWindow].col.a = 1.0f; g_aWindow[nCntWindow].state = WINDOWSTATE_NORMAL; } break; case WINDOWSTATE_FADEIN: //Stealthใฎๆ—ฉ้€ใ‚Šใชใ— g_aWindow[nCntWindow].col.a += 0.012f; if (g_aWindow[nCntWindow].col.a >= 1.0f) { g_aWindow[nCntWindow].col.a = 1.0f; g_aWindow[nCntWindow].state = WINDOWSTATE_NORMAL; } break; case WINDOWSTATE_FADEOUT://่จญๅฎšใ•ใ‚ŒใŸ้€ๆ˜Žๅบฆใ‹ใ‚‰ๆš—ใใชใ‚Š0ใงๆถˆใˆใ‚‹ g_aWindow[nCntWindow].col.a -= 0.01f; if (g_aWindow[nCntWindow].col.a <= 0.0f) { g_aWindow[nCntWindow].col.a = 0.0f; g_aWindow[nCntWindow].bUse = false; } break; case WINDOWSTATE_FLASH://็‚นๆป…ใง่กจ็คบ g_aWindow[nCntWindow].nCounterState[0]++; if (g_aWindow[nCntWindow].nCounterState[1] % 2 == 0 && g_aWindow[nCntWindow].nCounterState[0] % 45 == 0) { g_aWindow[nCntWindow].col.a = 1.0f; g_aWindow[nCntWindow].nCounterState[1]++; } else if (g_aWindow[nCntWindow].nCounterState[0] % 45 == 0) { g_aWindow[nCntWindow].col.a = 0.0f; g_aWindow[nCntWindow].nCounterState[1]++; } break; case WINDOWSTATE_SELECTON://SELECTๅ‡ฆ็†ใงไฝฟ็”จใ•ใ‚Œใ€้ธๆŠžใ•ใ‚Œใฆใ„ใ‚‹ใจใ g_aWindow[nCntWindow].col.r += fStealth; g_aWindow[nCntWindow].col.g += fStealth; g_aWindow[nCntWindow].col.b += fStealth; if (g_aWindow[nCntWindow].col.r >= 1.0f || g_aWindow[nCntWindow].col.r <= 0.22f) {//ๆ˜Žใ‚‹ใ•ใŒๆœ€ๅคง, ๆœ€ๅฐใซใชใฃใŸใ‚‰ๅ่ปข fStealth *= -1.0f; } break; case WINDOWSTATE_SELECTOFF://SELECTๅ‡ฆ็†ใงไฝฟ็”จใ•ใ‚Œใ€้ธๆŠžใ•ใ‚Œใฆใ„ใชใ„ใจใ g_aWindow[nCntWindow].col.r = 0.23f; g_aWindow[nCntWindow].col.g = 0.23f; g_aWindow[nCntWindow].col.b = 0.23f; break; case WINDOWSTATE_GUARDON: //GUARDไฝฟ็”จ็Šถๆ…‹ g_aWindow[nCntWindow].pos = D3DXVECTOR3(pPlayer[0].pos.x, pPlayer[0].pos.y + PLAYER_POSY3, 0.0f); g_aWindow[nCntWindow].fSteep -= 0.05f; if (g_aWindow[nCntWindow].nCounterState[0] != 0) { g_aWindow[nCntWindow].nCounterState[0]--; if (g_aWindow[nCntWindow].nCounterState[0] == 0) { g_aWindow[nCntWindow].col.r = 1.0f; g_aWindow[nCntWindow].col.g = 1.0f; g_aWindow[nCntWindow].col.b = 1.0f; } } break; case WINDOWSTATE_GUARDOFF: g_aWindow[nCntWindow].fSteep -= 0.02f; g_aWindow[nCntWindow].pos = D3DXVECTOR3(pPlayer[0].pos.x, pPlayer[0].pos.y + PLAYER_POSY3, 0.0f); if (g_aWindow[nCntWindow].col.a != 0.4f) { g_aWindow[nCntWindow].col.a += 0.02f; if (g_aWindow[nCntWindow].col.a > 0.399f) { g_aWindow[nCntWindow].col.a = 0.4f; } } break; case WINDOWSTATE_ENEMYCHANGE_FLOW: if (g_aWindow[nCntWindow].nCounterState[0] == 0) {//ๅทฆใ‹ใ‚‰ๅณใซๆตใ‚ŒใชใŒใ‚‰่กจ็คบ g_aWindow[nCntWindow].col.a += 0.05f; g_aWindow[nCntWindow].pos.x += 20.0f; if (g_aWindow[nCntWindow].col.a >= 1.0f) { g_aWindow[nCntWindow].col.a = 1.0f; g_aWindow[nCntWindow].nCounterState[0] = 1; } } else {//ๆ™‚้–“็ตŒ้Žใง g_aWindow[nCntWindow].nCounterState[0]++; if (g_aWindow[nCntWindow].nCounterState[0] > 60) {//ใ•ใ‚‰ใซๆ™‚้–“็ตŒ้Žใง g_aWindow[nCntWindow].col.a -= 0.029f; g_aWindow[nCntWindow].pos.x += 8.0f; if (g_aWindow[nCntWindow].col.a <= 0.0f) {//ๅณใซๆตใ‚ŒใชใŒใ‚‰ๆถˆใˆใ‚‹ g_aWindow[nCntWindow].col.a = 0.0f; g_aWindow[nCntWindow].bUse = false; } } } break; case WINDOWSTATE_ENEMYCHANGE_ZOOM: if (g_aWindow[nCntWindow].nCounterState[0] == 0) {//ๅทฆใ‹ใ‚‰ๅณใซๆตใ‚ŒใชใŒใ‚‰่กจ็คบ g_aWindow[nCntWindow].col.a += 0.05f; g_aWindow[nCntWindow].pos.x += 20.0f; if (g_aWindow[nCntWindow].col.a >= 1.0f) { g_aWindow[nCntWindow].col.a = 1.0f; g_aWindow[nCntWindow].nCounterState[0] = 1; } } else {//ๆ™‚้–“็ตŒ้Žใง g_aWindow[nCntWindow].nCounterState[0]++; if (g_aWindow[nCntWindow].nCounterState[0] > 60) {//ใ•ใ‚‰ใซๆ™‚้–“็ตŒ้Žใง g_aWindow[nCntWindow].col.a -= 0.029f; g_aWindow[nCntWindow].nLengthX += 3; g_aWindow[nCntWindow].nLengthY += 3; if (g_aWindow[nCntWindow].col.a <= 0.0f) {//ใ‚บใƒผใƒ ใ—ใชใŒใ‚‰ๆถˆใˆใ‚‹ g_aWindow[nCntWindow].col.a = 0.0f; g_aWindow[nCntWindow].bUse = false; } } } break; } pVtx[nCntWindow * 4].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x + (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY) + (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX), g_aWindow[nCntWindow].pos.y - (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX) + (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY), 0.0f); pVtx[nCntWindow * 4 + 1].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x + (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY) - (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX), g_aWindow[nCntWindow].pos.y + (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX) + (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY), 0.0f); pVtx[nCntWindow * 4 + 2].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x - (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY) + (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX), g_aWindow[nCntWindow].pos.y - (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX) - (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY), 0.0f); pVtx[nCntWindow * 4 + 3].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x - (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY) - (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX), g_aWindow[nCntWindow].pos.y + (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX) - (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY), 0.0f); pVtx[nCntWindow * 4].col = g_aWindow[nCntWindow].col; // A = ้€ๆ˜Žๅบฆ pVtx[nCntWindow * 4 + 1].col = g_aWindow[nCntWindow].col; pVtx[nCntWindow * 4 + 2].col = g_aWindow[nCntWindow].col; pVtx[nCntWindow * 4 + 3].col = g_aWindow[nCntWindow].col; } } //้ ‚็‚นBUFFERใ‚’ใ‚ขใƒณใƒญใƒƒใ‚ฏใ™ใ‚‹ g_pVtxBuffWindow->Unlock(); } //=========================================================================================================// // * ่ƒŒๆ™ฏใฎๆ็”ปๅ‡ฆ็†4 ๆ็”ปๅ‡ฆ็† //=========================================================================================================// void DrawWindow(void) { LPDIRECT3DDEVICE9 pDevice; int nCntWindow; // ใƒ‡ใƒใ‚คใ‚นใฎๅ–ๅพ— pDevice = GetDevice(); // ้ ‚็‚นใƒใƒƒใƒ•ใ‚กใ‚’ใƒ‡ใƒใ‚คใ‚นใฎใƒ‡ใƒผใ‚ฟใ‚นใƒˆใƒชใƒผใƒ ใซใƒใ‚คใƒณใƒ‰ pDevice->SetStreamSource(0, g_pVtxBuffWindow, 0, sizeof(VERTEX_2D)); // ้ ‚็‚นใƒ•ใ‚ฉใƒผใƒžใƒƒใƒˆใฎ่จญๅฎš pDevice->SetFVF(FVF_VERTEX_2D); //pDevice->DrawPrimitive(D3DPT_TRIANGLESTRIP, 0, PRIMITIVE_NUM); // ใƒใƒชใ‚ดใƒณใฎๆ็”ป for (nCntWindow = 0; nCntWindow < MAX_WINDOW; nCntWindow++) { if (g_aWindow[nCntWindow].bUse == true) { // ใƒ†ใ‚ฏใ‚นใƒใƒฃใฎ่จญๅฎš pDevice->SetTexture(0, g_pTextureWindow[g_aWindow[nCntWindow].nType]); pDevice->DrawPrimitive(D3DPT_TRIANGLESTRIP, nCntWindow * 4, WINDOW_PRIMITIVE_NUM); } } } //============================================================================= // ๅผพใฎ่จญๅฎšๅ‡ฆ็† //============================================================================= void SetWindow(D3DXVECTOR3 pos, D3DXCOLOR col, int nLengthX, int nLengthY, int nType, int nCntUse, int nEnemy, WINDOWSTATE state, WINDOWUSE use) { int nCntWindow; VERTEX_2D *pVtx; //้ ‚็‚นๆƒ…ๅ ฑใธใฎใƒใ‚คใƒณใ‚ฟ //้ ‚็‚นBUFFERใ‚’ใƒญใƒƒใ‚ฏใ—ใ€้ ‚็‚นๆƒ…ๅ ฑใธใฎใƒใ‚คใƒณใ‚ฟใ‚’ๅ–ๅพ— g_pVtxBuffWindow->Lock(0, 0, (void**)&pVtx, 0); for (nCntWindow = 1; nCntWindow < MAX_WINDOW; nCntWindow++) { if (use == WINDOWUSE_GUARD) { nCntWindow = 0; if (g_aWindow[nCntWindow].bUse == true) { break; } } if (g_aWindow[nCntWindow].bUse == false) { g_aWindow[nCntWindow].pos = pos; g_aWindow[nCntWindow].nLengthX = nLengthX; g_aWindow[nCntWindow].nLengthY = nLengthY; g_aWindow[nCntWindow].nType = nType; g_aWindow[nCntWindow].state = state; g_aWindow[nCntWindow].use = use; g_aWindow[nCntWindow].nCounterState[0] = nCntUse; g_aWindow[nCntWindow].nCounterState[1] = 1; g_aWindow[nCntWindow].bUse = true; g_aWindow[nCntWindow].fSteep = D3DX_PI; /*pVtx[nCntWindow * 4].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x - g_aWindow[nCntWindow].nLengthX, g_aWindow[nCntWindow].pos.y - g_aWindow[nCntWindow].nLengthY, 0.0f); pVtx[nCntWindow * 4 + 1].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x + g_aWindow[nCntWindow].nLengthX, g_aWindow[nCntWindow].pos.y - g_aWindow[nCntWindow].nLengthY, 0.0f); pVtx[nCntWindow * 4 + 2].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x - g_aWindow[nCntWindow].nLengthX, g_aWindow[nCntWindow].pos.y + g_aWindow[nCntWindow].nLengthY, 0.0f); pVtx[nCntWindow * 4 + 3].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x + g_aWindow[nCntWindow].nLengthX, g_aWindow[nCntWindow].pos.y + g_aWindow[nCntWindow].nLengthY, 0.0f);*/ pVtx[nCntWindow * 4].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x + (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY) + (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX), g_aWindow[nCntWindow].pos.y - (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX) + (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY), 0.0f); pVtx[nCntWindow * 4 + 1].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x + (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY) - (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX), g_aWindow[nCntWindow].pos.y + (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX) + (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY), 0.0f); pVtx[nCntWindow * 4 + 2].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x - (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY) + (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX), g_aWindow[nCntWindow].pos.y - (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX) - (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY), 0.0f); pVtx[nCntWindow * 4 + 3].pos = D3DXVECTOR3(g_aWindow[nCntWindow].pos.x - (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY) - (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX), g_aWindow[nCntWindow].pos.y + (sinf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthX) - (cosf(g_aWindow[nCntWindow].fSteep) * g_aWindow[nCntWindow].nLengthY), 0.0f); g_aWindow[nCntWindow].col = col; pVtx[nCntWindow * 4].col = col; // A = ้€ๆ˜Žๅบฆ pVtx[nCntWindow * 4 + 1].col = col; pVtx[nCntWindow * 4 + 2].col = col; pVtx[nCntWindow * 4 + 3].col = col; if (use == WINDOWUSE_ENEMY) {//ใƒ†ใ‚ฏใ‚นใƒใƒฃๅบงๆจ™่จญๅฎš pVtx[nCntWindow * 4].tex = D3DXVECTOR2((nEnemy % 2) * 0.5f, (nEnemy / 2) * 0.2f); pVtx[nCntWindow * 4 + 1].tex = D3DXVECTOR2((nEnemy % 2) * 0.5f + 0.5f, (nEnemy / 2) * 0.2f); pVtx[nCntWindow * 4 + 2].tex = D3DXVECTOR2((nEnemy % 2) * 0.5f, (nEnemy / 2) * 0.2f + 0.2f); pVtx[nCntWindow * 4 + 3].tex = D3DXVECTOR2((nEnemy % 2) * 0.5f + 0.5f, (nEnemy / 2) * 0.2f + 0.2f); } else {//ใƒ†ใ‚ฏใ‚นใƒใƒฃๅบงๆจ™่จญๅฎš pVtx[nCntWindow * 4].tex = D3DXVECTOR2(0.0f, 0.0f); pVtx[nCntWindow * 4 + 1].tex = D3DXVECTOR2(1.0f, 0.0f); pVtx[nCntWindow * 4 + 2].tex = D3DXVECTOR2(0.0f, 1.0f); pVtx[nCntWindow * 4 + 3].tex = D3DXVECTOR2(1.0f, 1.0f); } break; } } //้ ‚็‚นBUFFERใ‚’ใ‚ขใƒณใƒญใƒƒใ‚ฏใ™ใ‚‹ g_pVtxBuffWindow->Unlock(); } //============================================================================= // windowใฎ็ ดๅฃŠ //============================================================================= void BreakWindow(void) {//ๅ…จใ‚ฆใ‚ฃใƒณใƒ‰ใ‚ฆ็ ดๆฃ„ int nCntWindow; for (nCntWindow = 0; nCntWindow < MAX_WINDOW; nCntWindow++) { if (g_aWindow[nCntWindow].bUse == true) { g_aWindow[nCntWindow].bUse = false; } } } //============================================================================= // ๆฎ‹ๆฉŸ็ ดๅฃŠ //============================================================================= bool BreakAirport(void) {//ๆฎ‹ๆฉŸใŒๆฎ‹ใฃใฆใ„ใ‚Œใฐtrue bool bRespawn = false; int nCntWindow; for (nCntWindow = MAX_WINDOW; nCntWindow > 0; nCntWindow--) { if (g_aWindow[nCntWindow - 1].bUse == true && g_aWindow[nCntWindow - 1].use == WINDOWUSE_RESIDUALAIRPORT && g_aWindow[nCntWindow - 1].state == WINDOWSTATE_NORMAL) { g_aWindow[nCntWindow - 1].state = WINDOWSTATE_FADEOUT; bRespawn = true; break; } } return bRespawn; } //============================================================================= // ้ธๆŠžๅ‡ฆ็† //============================================================================= void SelectWindow(int nNumber) { int nCntWindow; for (nCntWindow = 0; nCntWindow < MAX_WINDOW; nCntWindow++) { if (g_aWindow[nCntWindow].use == WINDOWUSE_SELECT && g_aWindow[nCntWindow].bUse == true) { if (g_aWindow[nCntWindow].nCounterState[0] == nNumber) { g_aWindow[nCntWindow].state = WINDOWSTATE_SELECTON; } else { g_aWindow[nCntWindow].state = WINDOWSTATE_SELECTOFF; } } } } //============================================================================= // ๆŒ‡ๅฎšใ—ใŸwindowๅˆ†็ ดๅฃŠ //============================================================================= void BackWindow(int nNumber) { int nCntWindow; //windowใ‚’ๆ•ฐใˆใ‚‹ int nBreak = nNumber; //nNumberใ„ใ˜ใฃใŸใ‚‰ใฉใ†ใชใ‚‹ใ‹ใ‚ใ‹ใ‚‰ใ‚“ใ—... for (nCntWindow = MAX_WINDOW; nCntWindow > 0; nCntWindow--) {//ๆœ€ๅคงใงใ‚‚ๅ…จ้ƒจ็ต‚ใ‚ใฃใŸใ‚‰็ต‚ไบ† if (g_aWindow[nCntWindow - 1].bUse == true) {//ๅพŒใ‚ใ‹ใ‚‰่ฆ‹ใฆtrueใซใชใฃใจใ‚‹ใ‚„ใคใ‚’ๆฎบใ™ g_aWindow[nCntWindow - 1].bUse = false; nBreak--; if (nBreak < 1) {//0ไปฅไธ‹ใซใชใฃใŸใ‚‰็ต‚ใ‚ใ‚Š break; } } } } //============================================================================= // ๆŒ‡ๅฎšใ—ใŸwindowๅˆ†็ ดๅฃŠ //============================================================================= void ChangeGuard(int nUse) { int nCntWindow; //windowใ‚’ๆ•ฐใˆใ‚‹ for (nCntWindow = 0; nCntWindow < MAX_WINDOW; nCntWindow++) {//ๆœ€ๅคงใงใ‚‚ๅ…จ้ƒจ็ต‚ใ‚ใฃใŸใ‚‰็ต‚ไบ† if (g_aWindow[nCntWindow].bUse == true && g_aWindow[nCntWindow].use == WINDOWUSE_GUARD) {//GUARDใฎใƒใƒชใ‚ดใƒณใฎ็Šถๆ…‹ๅค‰ๆ›ด if (nUse == 0) {//GUARDๆˆๅŠŸ g_aWindow[nCntWindow].col.r = 1.0f; g_aWindow[nCntWindow].col.g = 0.99f; g_aWindow[nCntWindow].col.b = 0.03f; g_aWindow[nCntWindow].nCounterState[0] = 5; } else if (nUse == 1) { g_aWindow[nCntWindow].state = WINDOWSTATE_GUARDON; g_aWindow[nCntWindow].nLengthX = 32; g_aWindow[nCntWindow].nLengthY = 32; g_aWindow[nCntWindow].col.a = 0.85f; g_aWindow[nCntWindow].nType = 19; } else if(nUse == 2) { g_aWindow[nCntWindow].bUse = false; } } } } //============================================================================= // 50้Ÿณ่กจ็คบใฎๆž ็งปๅ‹•ๅ‡ฆ็† //============================================================================= void FontWindowMove(int nWide, int nHeight) { int nCntWindow; for (nCntWindow = 0; nCntWindow < MAX_WINDOW; nCntWindow++) { if (g_aWindow[nCntWindow].use == WINDOWUSE_FONT) { if (nHeight == 5) {//ใฒใ‚‰ ใ‚ซใƒŠ ็ต‚ใ‚ใ‚Šใฎๅ ดๅˆ g_aWindow[nCntWindow].nLengthY = SCREEN_HEIGHT / 30; g_aWindow[nCntWindow].pos.y = 4.9f * SCREEN_HEIGHT * 0.118f + SCREEN_HEIGHT * 0.281f; if (nWide == 0) { g_aWindow[nCntWindow].nLengthX = SCREEN_WIDTH / 20; g_aWindow[nCntWindow].pos.x = SCREEN_WIDTH * 0.505f; } else if (nWide == 1) { g_aWindow[nCntWindow].nLengthX = SCREEN_WIDTH / 20; g_aWindow[nCntWindow].pos.x = SCREEN_WIDTH * 0.608f; } else if (nWide == 2) { g_aWindow[nCntWindow].nLengthX = SCREEN_WIDTH / 17; g_aWindow[nCntWindow].pos.x = SCREEN_WIDTH * 0.7305f; } } else {//ใฒใ‚‰ ใ‚ซใƒŠ ็ต‚ใ‚ใ‚Š ไปฅๅค– g_aWindow[nCntWindow].nLengthX = SCREEN_WIDTH / 38; g_aWindow[nCntWindow].nLengthY = SCREEN_HEIGHT / 16; g_aWindow[nCntWindow].pos.x = nWide * SCREEN_WIDTH * 0.0525f + SCREEN_WIDTH * 0.2365f; g_aWindow[nCntWindow].pos.y = nHeight * SCREEN_HEIGHT * 0.118f + SCREEN_HEIGHT * 0.2815f; } } } }
f9cf0c3ef5faade3ca0a7c8cea87df0e7b4db9d7
8dc84558f0058d90dfc4955e905dab1b22d12c08
/third_party/blink/renderer/core/loader/image_loader.cc
e599c1a10c2dc5bc4b62a1b5ffa4de0fb474f4b1
[ "LGPL-2.0-only", "BSD-2-Clause", "LGPL-2.1-only", "LicenseRef-scancode-unknown-license-reference", "BSD-3-Clause", "LGPL-2.0-or-later", "GPL-1.0-or-later", "MIT", "Apache-2.0" ]
permissive
meniossin/src
42a95cc6c4a9c71d43d62bc4311224ca1fd61e03
44f73f7e76119e5ab415d4593ac66485e65d700a
refs/heads/master
2022-12-16T20:17:03.747113
2020-09-03T10:43:12
2020-09-03T10:43:12
263,710,168
1
0
BSD-3-Clause
2020-05-13T18:20:09
2020-05-13T18:20:08
null
UTF-8
C++
false
false
32,213
cc
/* * Copyright (C) 1999 Lars Knoll ([email protected]) * (C) 1999 Antti Koivisto ([email protected]) * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010 Apple Inc. All rights * reserved. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public License * along with this library; see the file COPYING.LIB. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, * Boston, MA 02110-1301, USA. */ #include "third_party/blink/renderer/core/loader/image_loader.h" #include <memory> #include <utility> #include "third_party/blink/public/platform/modules/fetch/fetch_api_request.mojom-shared.h" #include "third_party/blink/public/platform/web_client_hints_type.h" #include "third_party/blink/public/platform/web_url_request.h" #include "third_party/blink/renderer/bindings/core/v8/exception_state.h" #include "third_party/blink/renderer/bindings/core/v8/script_controller.h" #include "third_party/blink/renderer/bindings/core/v8/v8_binding_for_core.h" #include "third_party/blink/renderer/core/dom/document.h" #include "third_party/blink/renderer/core/dom/element.h" #include "third_party/blink/renderer/core/dom/events/event.h" #include "third_party/blink/renderer/core/dom/increment_load_event_delay_count.h" #include "third_party/blink/renderer/core/frame/local_frame.h" #include "third_party/blink/renderer/core/frame/settings.h" #include "third_party/blink/renderer/core/frame/use_counter.h" #include "third_party/blink/renderer/core/html/cross_origin_attribute.h" #include "third_party/blink/renderer/core/html/html_image_element.h" #include "third_party/blink/renderer/core/html/parser/html_parser_idioms.h" #include "third_party/blink/renderer/core/layout/layout_image.h" #include "third_party/blink/renderer/core/layout/layout_video.h" #include "third_party/blink/renderer/core/layout/svg/layout_svg_image.h" #include "third_party/blink/renderer/core/probe/core_probes.h" #include "third_party/blink/renderer/core/svg/graphics/svg_image.h" #include "third_party/blink/renderer/platform/bindings/microtask.h" #include "third_party/blink/renderer/platform/bindings/script_state.h" #include "third_party/blink/renderer/platform/bindings/v8_per_isolate_data.h" #include "third_party/blink/renderer/platform/loader/fetch/fetch_parameters.h" #include "third_party/blink/renderer/platform/loader/fetch/memory_cache.h" #include "third_party/blink/renderer/platform/loader/fetch/resource_fetcher.h" #include "third_party/blink/renderer/platform/loader/fetch/resource_loading_log.h" #include "third_party/blink/renderer/platform/weborigin/security_origin.h" #include "third_party/blink/renderer/platform/weborigin/security_policy.h" namespace blink { static ImageLoader::BypassMainWorldBehavior ShouldBypassMainWorldCSP( ImageLoader* loader) { DCHECK(loader); DCHECK(loader->GetElement()); if (loader->GetElement()->GetDocument().GetFrame() && loader->GetElement() ->GetDocument() .GetFrame() ->GetScriptController() .ShouldBypassMainWorldCSP()) return ImageLoader::kBypassMainWorldCSP; return ImageLoader::kDoNotBypassMainWorldCSP; } class ImageLoader::Task { public: static std::unique_ptr<Task> Create(ImageLoader* loader, UpdateFromElementBehavior update_behavior, ReferrerPolicy referrer_policy) { return std::make_unique<Task>(loader, update_behavior, referrer_policy); } Task(ImageLoader* loader, UpdateFromElementBehavior update_behavior, ReferrerPolicy referrer_policy) : loader_(loader), should_bypass_main_world_csp_(ShouldBypassMainWorldCSP(loader)), update_behavior_(update_behavior), referrer_policy_(referrer_policy), weak_factory_(this) { ExecutionContext& context = loader_->GetElement()->GetDocument(); probe::AsyncTaskScheduled(&context, "Image", this); v8::Isolate* isolate = V8PerIsolateData::MainThreadIsolate(); v8::HandleScope scope(isolate); // If we're invoked from C++ without a V8 context on the stack, we should // run the microtask in the context of the element's document's main world. if (!isolate->GetCurrentContext().IsEmpty()) { script_state_ = ScriptState::Current(isolate); } else { script_state_ = ToScriptStateForMainWorld( loader->GetElement()->GetDocument().GetFrame()); DCHECK(script_state_); } request_url_ = loader->ImageSourceToKURL(loader->GetElement()->ImageSourceURL()); } void Run() { if (!loader_) return; ExecutionContext& context = loader_->GetElement()->GetDocument(); probe::AsyncTask async_task(&context, this); if (script_state_->ContextIsValid()) { ScriptState::Scope scope(script_state_.get()); loader_->DoUpdateFromElement(should_bypass_main_world_csp_, update_behavior_, request_url_, referrer_policy_); } else { loader_->DoUpdateFromElement(should_bypass_main_world_csp_, update_behavior_, request_url_, referrer_policy_); } } void ClearLoader() { loader_ = nullptr; script_state_ = nullptr; } base::WeakPtr<Task> GetWeakPtr() { return weak_factory_.GetWeakPtr(); } private: WeakPersistent<ImageLoader> loader_; BypassMainWorldBehavior should_bypass_main_world_csp_; UpdateFromElementBehavior update_behavior_; scoped_refptr<ScriptState> script_state_; ReferrerPolicy referrer_policy_; KURL request_url_; base::WeakPtrFactory<Task> weak_factory_; }; ImageLoader::ImageLoader(Element* element) : element_(element), image_complete_(true), loading_image_document_(false), suppress_error_events_(false) { RESOURCE_LOADING_DVLOG(1) << "new ImageLoader " << this; } ImageLoader::~ImageLoader() = default; void ImageLoader::Dispose() { RESOURCE_LOADING_DVLOG(1) << "~ImageLoader " << this << "; has pending load event=" << pending_load_event_.IsActive() << ", has pending error event=" << pending_error_event_.IsActive(); if (image_content_) { image_content_->RemoveObserver(this); image_content_ = nullptr; image_resource_for_image_document_ = nullptr; delay_until_image_notify_finished_ = nullptr; } } void ImageLoader::DispatchDecodeRequestsIfComplete() { // If the current image isn't complete, then we can't dispatch any decodes. // This function will be called again when the current image completes. if (!image_complete_) return; bool is_active = GetElement()->GetDocument().IsActive(); // If any of the following conditions hold, we either have an inactive // document or a broken/non-existent image. In those cases, we reject any // pending decodes. if (!is_active || !GetContent() || GetContent()->ErrorOccurred()) { RejectPendingDecodes(); return; } LocalFrame* frame = GetElement()->GetDocument().GetFrame(); for (auto& request : decode_requests_) { // If the image already in kDispatched state or still in kPEndingMicrotask // state, then we don't dispatch decodes for it. So, the only case to handle // is if we're in kPendingLoad state. if (request->state() != DecodeRequest::kPendingLoad) continue; Image* image = GetContent()->GetImage(); frame->GetChromeClient().RequestDecode( frame, image->PaintImageForCurrentFrame(), WTF::Bind(&ImageLoader::DecodeRequestFinished, WrapCrossThreadWeakPersistent(this), request->request_id())); request->NotifyDecodeDispatched(); } } void ImageLoader::DecodeRequestFinished(uint64_t request_id, bool success) { // First we find the corresponding request id, then we either resolve or // reject it and remove it from the list. for (auto* it = decode_requests_.begin(); it != decode_requests_.end(); ++it) { auto& request = *it; if (request->request_id() != request_id) continue; if (success) request->Resolve(); else request->Reject(); decode_requests_.erase(it); break; } } void ImageLoader::RejectPendingDecodes(UpdateType update_type) { // Normally, we only reject pending decodes that have passed the // kPendingMicrotask state, since pending mutation requests still have an // outstanding microtask that will run and might act on a different image than // the current one. However, as an optimization, there are cases where we // synchronously update the image (see UpdateFromElement). In those cases, we // have to reject even the pending mutation requests because conceptually they // would have been scheduled before the synchronous update ran, so they // referred to the old image. for (auto* it = decode_requests_.begin(); it != decode_requests_.end();) { auto& request = *it; if (update_type == UpdateType::kAsync && request->state() == DecodeRequest::kPendingMicrotask) { ++it; continue; } request->Reject(); it = decode_requests_.erase(it); } } void ImageLoader::Trace(blink::Visitor* visitor) { visitor->Trace(image_content_); visitor->Trace(image_resource_for_image_document_); visitor->Trace(element_); visitor->Trace(decode_requests_); } void ImageLoader::SetImageForTest(ImageResourceContent* new_image) { DCHECK(new_image); SetImageWithoutConsideringPendingLoadEvent(new_image); } void ImageLoader::ClearImage() { SetImageWithoutConsideringPendingLoadEvent(nullptr); } void ImageLoader::SetImageForImageDocument(ImageResource* new_image_resource) { DCHECK(loading_image_document_); DCHECK(new_image_resource); DCHECK(new_image_resource->GetContent()); image_resource_for_image_document_ = new_image_resource; SetImageWithoutConsideringPendingLoadEvent(new_image_resource->GetContent()); // |image_complete_| is always true for ImageDocument loading, while the // loading is just started. // TODO(hiroshige): clean up the behavior of flags. https://crbug.com/719759 image_complete_ = true; } void ImageLoader::SetImageWithoutConsideringPendingLoadEvent( ImageResourceContent* new_image_content) { DCHECK(failed_load_url_.IsEmpty()); ImageResourceContent* old_image_content = image_content_.Get(); if (new_image_content != old_image_content) { if (pending_load_event_.IsActive()) pending_load_event_.Cancel(); if (pending_error_event_.IsActive()) pending_error_event_.Cancel(); UpdateImageState(new_image_content); if (new_image_content) { new_image_content->AddObserver(this); } if (old_image_content) { old_image_content->RemoveObserver(this); } } if (LayoutImageResource* image_resource = GetLayoutImageResource()) image_resource->ResetAnimation(); } static void ConfigureRequest( FetchParameters& params, ImageLoader::BypassMainWorldBehavior bypass_behavior, Element& element, const ClientHintsPreferences& client_hints_preferences) { if (bypass_behavior == ImageLoader::kBypassMainWorldCSP) params.SetContentSecurityCheck(kDoNotCheckContentSecurityPolicy); CrossOriginAttributeValue cross_origin = GetCrossOriginAttributeValue( element.FastGetAttribute(HTMLNames::crossoriginAttr)); if (cross_origin != kCrossOriginAttributeNotSet) { params.SetCrossOriginAccessControl( element.GetDocument().GetSecurityOrigin(), cross_origin); } if (client_hints_preferences.ShouldSend( mojom::WebClientHintsType::kResourceWidth) && IsHTMLImageElement(element)) params.SetResourceWidth(ToHTMLImageElement(element).GetResourceWidth()); } inline void ImageLoader::DispatchErrorEvent() { // There can be cases where DispatchErrorEvent() is called when there is // already a scheduled error event for the previous load attempt. // In such cases we cancel the previous event (by overwriting // |pending_error_event_|) and then re-schedule a new error event here. // crbug.com/722500 pending_error_event_ = PostCancellableTask( *GetElement()->GetDocument().GetTaskRunner(TaskType::kDOMManipulation), FROM_HERE, WTF::Bind(&ImageLoader::DispatchPendingErrorEvent, WrapPersistent(this), WTF::Passed(IncrementLoadEventDelayCount::Create( GetElement()->GetDocument())))); } inline void ImageLoader::CrossSiteOrCSPViolationOccurred( AtomicString image_source_url) { failed_load_url_ = image_source_url; } inline void ImageLoader::ClearFailedLoadURL() { failed_load_url_ = AtomicString(); } inline void ImageLoader::EnqueueImageLoadingMicroTask( UpdateFromElementBehavior update_behavior, ReferrerPolicy referrer_policy) { std::unique_ptr<Task> task = Task::Create(this, update_behavior, referrer_policy); pending_task_ = task->GetWeakPtr(); Microtask::EnqueueMicrotask( WTF::Bind(&Task::Run, WTF::Passed(std::move(task)))); delay_until_do_update_from_element_ = IncrementLoadEventDelayCount::Create(element_->GetDocument()); } void ImageLoader::UpdateImageState(ImageResourceContent* new_image_content) { image_content_ = new_image_content; if (!new_image_content) { image_resource_for_image_document_ = nullptr; image_complete_ = true; } else { image_complete_ = false; } delay_until_image_notify_finished_ = nullptr; } void ImageLoader::DoUpdateFromElement(BypassMainWorldBehavior bypass_behavior, UpdateFromElementBehavior update_behavior, const KURL& url, ReferrerPolicy referrer_policy, UpdateType update_type) { // FIXME: According to // http://www.whatwg.org/specs/web-apps/current-work/multipage/embedded-content.html#the-img-element:the-img-element-55 // When "update image" is called due to environment changes and the load // fails, onerror should not be called. That is currently not the case. // // We don't need to call clearLoader here: Either we were called from the // task, or our caller updateFromElement cleared the task's loader (and set // pending_task_ to null). pending_task_.reset(); // Make sure to only decrement the count when we exit this function std::unique_ptr<IncrementLoadEventDelayCount> load_delay_counter; load_delay_counter.swap(delay_until_do_update_from_element_); Document& document = element_->GetDocument(); if (!document.IsActive()) return; AtomicString image_source_url = element_->ImageSourceURL(); ImageResourceContent* new_image_content = nullptr; if (!url.IsNull() && !url.IsEmpty()) { // Unlike raw <img>, we block mixed content inside of <picture> or // <img srcset>. ResourceLoaderOptions resource_loader_options; resource_loader_options.initiator_info.name = GetElement()->localName(); ResourceRequest resource_request(url); if (update_behavior == kUpdateForcedReload) { resource_request.SetCacheMode(mojom::FetchCacheMode::kBypassCache); resource_request.SetPreviewsState(WebURLRequest::kPreviewsNoTransform); } if (referrer_policy != kReferrerPolicyDefault) { resource_request.SetHTTPReferrer(SecurityPolicy::GenerateReferrer( referrer_policy, url, document.OutgoingReferrer())); } // Correct the RequestContext if necessary. if (IsHTMLPictureElement(GetElement()->parentNode()) || !GetElement()->FastGetAttribute(HTMLNames::srcsetAttr).IsNull()) { resource_request.SetRequestContext( WebURLRequest::kRequestContextImageSet); } else if (IsHTMLObjectElement(GetElement())) { resource_request.SetRequestContext(WebURLRequest::kRequestContextObject); } else if (IsHTMLEmbedElement(GetElement())) { resource_request.SetRequestContext(WebURLRequest::kRequestContextEmbed); } bool page_is_being_dismissed = document.PageDismissalEventBeingDispatched() != Document::kNoDismissal; if (page_is_being_dismissed) { resource_request.SetHTTPHeaderField(HTTPNames::Cache_Control, "max-age=0"); resource_request.SetKeepalive(true); resource_request.SetRequestContext(WebURLRequest::kRequestContextPing); } // Plug-ins should not load via service workers as plug-ins may have their // own origin checking logic that may get confused if service workers // respond with resources from another origin. // https://w3c.github.io/ServiceWorker/#implementer-concerns if (GetElement()->IsHTMLElement() && ToHTMLElement(GetElement())->IsPluginElement()) { resource_request.SetSkipServiceWorker(true); } FetchParameters params(resource_request, resource_loader_options); ConfigureRequest(params, bypass_behavior, *element_, document.GetClientHintsPreferences()); if (update_behavior != kUpdateForcedReload && document.GetFrame()) document.GetFrame()->MaybeAllowImagePlaceholder(params); new_image_content = ImageResourceContent::Fetch(params, document.Fetcher()); // If this load is starting while navigating away, treat it as an auditing // keepalive request, and don't report its results back to the element. if (page_is_being_dismissed) new_image_content = nullptr; ClearFailedLoadURL(); } else { if (!image_source_url.IsNull()) { // Fire an error event if the url string is not empty, but the KURL is. DispatchErrorEvent(); } NoImageResourceToLoad(); } ImageResourceContent* old_image_content = image_content_.Get(); if (old_image_content != new_image_content) RejectPendingDecodes(update_type); if (update_behavior == kUpdateSizeChanged && element_->GetLayoutObject() && element_->GetLayoutObject()->IsImage() && new_image_content == old_image_content) { ToLayoutImage(element_->GetLayoutObject())->IntrinsicSizeChanged(); } else { if (pending_load_event_.IsActive()) pending_load_event_.Cancel(); // Cancel error events that belong to the previous load, which is now // cancelled by changing the src attribute. If newImage is null and // has_pending_error_event_ is true, we know the error event has been just // posted by this load and we should not cancel the event. // FIXME: If both previous load and this one got blocked with an error, we // can receive one error event instead of two. if (pending_error_event_.IsActive() && new_image_content) pending_error_event_.Cancel(); UpdateImageState(new_image_content); UpdateLayoutObject(); // If newImage exists and is cached, addObserver() will result in the load // event being queued to fire. Ensure this happens after beforeload is // dispatched. if (new_image_content) { new_image_content->AddObserver(this); } if (old_image_content) { old_image_content->RemoveObserver(this); } } if (LayoutImageResource* image_resource = GetLayoutImageResource()) image_resource->ResetAnimation(); } void ImageLoader::UpdateFromElement(UpdateFromElementBehavior update_behavior, ReferrerPolicy referrer_policy) { AtomicString image_source_url = element_->ImageSourceURL(); suppress_error_events_ = (update_behavior == kUpdateSizeChanged); if (update_behavior == kUpdateIgnorePreviousError) ClearFailedLoadURL(); if (!failed_load_url_.IsEmpty() && image_source_url == failed_load_url_) return; if (loading_image_document_ && update_behavior == kUpdateForcedReload) { // Prepares for reloading ImageDocument. // We turn the ImageLoader into non-ImageDocument here, and proceed to // reloading just like an ordinary <img> element below. loading_image_document_ = false; image_resource_for_image_document_ = nullptr; ClearImage(); } // Prevent the creation of a ResourceLoader (and therefore a network request) // for ImageDocument loads. In this case, the image contents have already been // requested as a main resource and ImageDocumentParser will take care of // funneling the main resource bytes into |image_content_|, so just create an // ImageResource to be populated later. if (loading_image_document_) { ResourceRequest request(ImageSourceToKURL(element_->ImageSourceURL())); request.SetFetchCredentialsMode( network::mojom::FetchCredentialsMode::kOmit); ImageResource* image_resource = ImageResource::Create(request); image_resource->SetStatus(ResourceStatus::kPending); image_resource->NotifyStartLoad(); SetImageForImageDocument(image_resource); return; } // If we have a pending task, we have to clear it -- either we're now loading // immediately, or we need to reset the task's state. if (pending_task_) { pending_task_->ClearLoader(); pending_task_.reset(); // Here we need to clear delay_until_do_update_from_element to avoid causing // a memory leak in case it's already created. delay_until_do_update_from_element_ = nullptr; } KURL url = ImageSourceToKURL(image_source_url); if (ShouldLoadImmediately(url)) { DoUpdateFromElement(kDoNotBypassMainWorldCSP, update_behavior, url, referrer_policy, UpdateType::kSync); return; } // Allow the idiom "img.src=''; img.src='.." to clear down the image before an // asynchronous load completes. if (image_source_url.IsEmpty()) { ImageResourceContent* image = image_content_.Get(); if (image) { image->RemoveObserver(this); } image_content_ = nullptr; image_resource_for_image_document_ = nullptr; delay_until_image_notify_finished_ = nullptr; } // Don't load images for inactive documents. We don't want to slow down the // raw HTML parsing case by loading images we don't intend to display. Document& document = element_->GetDocument(); if (document.IsActive()) EnqueueImageLoadingMicroTask(update_behavior, referrer_policy); } KURL ImageLoader::ImageSourceToKURL(AtomicString image_source_url) const { KURL url; // Don't load images for inactive documents. We don't want to slow down the // raw HTML parsing case by loading images we don't intend to display. Document& document = element_->GetDocument(); if (!document.IsActive()) return url; // Do not load any image if the 'src' attribute is missing or if it is // an empty string. if (!image_source_url.IsNull()) { String stripped_image_source_url = StripLeadingAndTrailingHTMLSpaces(image_source_url); if (!stripped_image_source_url.IsEmpty()) url = document.CompleteURL(stripped_image_source_url); } return url; } bool ImageLoader::ShouldLoadImmediately(const KURL& url) const { // We force any image loads which might require alt content through the // asynchronous path so that we can add the shadow DOM for the alt-text // content when style recalc is over and DOM mutation is allowed again. if (!url.IsNull()) { Resource* resource = GetMemoryCache()->ResourceForURL( url, element_->GetDocument().Fetcher()->GetCacheIdentifier()); if (resource && !resource->ErrorOccurred()) return true; } return (IsHTMLObjectElement(element_) || IsHTMLEmbedElement(element_)); } void ImageLoader::ImageChanged(ImageResourceContent* content, CanDeferInvalidation, const IntRect*) { DCHECK_EQ(content, image_content_.Get()); if (image_complete_ || !content->IsLoading() || delay_until_image_notify_finished_) return; Document& document = element_->GetDocument(); if (!document.IsActive()) return; delay_until_image_notify_finished_ = IncrementLoadEventDelayCount::Create(document); } void ImageLoader::ImageNotifyFinished(ImageResourceContent* resource) { RESOURCE_LOADING_DVLOG(1) << "ImageLoader::imageNotifyFinished " << this << "; has pending load event=" << pending_load_event_.IsActive(); DCHECK(failed_load_url_.IsEmpty()); DCHECK_EQ(resource, image_content_.Get()); // |image_complete_| is always true for entire ImageDocument loading for // historical reason. // DoUpdateFromElement() is not called and SetImageForImageDocument() // is called instead for ImageDocument loading. // TODO(hiroshige): Turn the CHECK()s to DCHECK()s before going to beta. if (loading_image_document_) CHECK(image_complete_); else CHECK(!image_complete_); image_complete_ = true; delay_until_image_notify_finished_ = nullptr; // Update ImageAnimationPolicy for image_content_. if (image_content_) image_content_->UpdateImageAnimationPolicy(); UpdateLayoutObject(); if (image_content_ && image_content_->HasImage()) { Image& image = *image_content_->GetImage(); if (image.IsSVGImage()) { SVGImage& svg_image = ToSVGImage(image); // SVG's document should be completely loaded before access control // checks, which can occur anytime after ImageNotifyFinished() // (See SVGImage::CurrentFrameHasSingleSecurityOrigin()). // We check the document is loaded here to catch violation of the // assumption reliably. svg_image.CheckLoaded(); svg_image.UpdateUseCounters(GetElement()->GetDocument()); } } DispatchDecodeRequestsIfComplete(); if (loading_image_document_) { CHECK(!pending_load_event_.IsActive()); return; } if (resource->ErrorOccurred()) { pending_load_event_.Cancel(); base::Optional<ResourceError> error = resource->GetResourceError(); if (error && error->IsAccessCheck()) CrossSiteOrCSPViolationOccurred(AtomicString(error->FailingURL())); // The error event should not fire if the image data update is a result of // environment change. // https://html.spec.whatwg.org/multipage/embedded-content.html#the-img-element:the-img-element-55 if (!suppress_error_events_) DispatchErrorEvent(); return; } CHECK(!pending_load_event_.IsActive()); pending_load_event_ = PostCancellableTask( *GetElement()->GetDocument().GetTaskRunner(TaskType::kDOMManipulation), FROM_HERE, WTF::Bind(&ImageLoader::DispatchPendingLoadEvent, WrapPersistent(this), WTF::Passed(IncrementLoadEventDelayCount::Create( GetElement()->GetDocument())))); } LayoutImageResource* ImageLoader::GetLayoutImageResource() { LayoutObject* layout_object = element_->GetLayoutObject(); if (!layout_object) return nullptr; // We don't return style generated image because it doesn't belong to the // ImageLoader. See <https://bugs.webkit.org/show_bug.cgi?id=42840> if (layout_object->IsImage() && !ToLayoutImage(layout_object)->IsGeneratedContent()) return ToLayoutImage(layout_object)->ImageResource(); if (layout_object->IsSVGImage()) return ToLayoutSVGImage(layout_object)->ImageResource(); if (layout_object->IsVideo()) return ToLayoutVideo(layout_object)->ImageResource(); return nullptr; } void ImageLoader::UpdateLayoutObject() { LayoutImageResource* image_resource = GetLayoutImageResource(); if (!image_resource) return; // Only update the layoutObject if it doesn't have an image or if what we have // is a complete image. This prevents flickering in the case where a dynamic // change is happening between two images. ImageResourceContent* cached_image_content = image_resource->CachedImage(); if (image_content_ != cached_image_content && (image_complete_ || !cached_image_content)) image_resource->SetImageResource(image_content_.Get()); } bool ImageLoader::HasPendingEvent() const { // Regular image loading is in progress. if (image_content_ && !image_complete_ && !loading_image_document_) return true; if (pending_load_event_.IsActive() || pending_error_event_.IsActive()) return true; return false; } void ImageLoader::DispatchPendingLoadEvent( std::unique_ptr<IncrementLoadEventDelayCount> count) { if (!image_content_) return; CHECK(image_complete_); if (GetElement()->GetDocument().GetFrame()) DispatchLoadEvent(); // Checks Document's load event synchronously here for performance. // This is safe because DispatchPendingLoadEvent() is called asynchronously. count->ClearAndCheckLoadEvent(); } void ImageLoader::DispatchPendingErrorEvent( std::unique_ptr<IncrementLoadEventDelayCount> count) { if (GetElement()->GetDocument().GetFrame()) GetElement()->DispatchEvent(Event::Create(EventTypeNames::error)); // Checks Document's load event synchronously here for performance. // This is safe because DispatchPendingErrorEvent() is called asynchronously. count->ClearAndCheckLoadEvent(); } bool ImageLoader::GetImageAnimationPolicy(ImageAnimationPolicy& policy) { if (!GetElement()->GetDocument().GetSettings()) return false; policy = GetElement()->GetDocument().GetSettings()->GetImageAnimationPolicy(); return true; } ScriptPromise ImageLoader::Decode(ScriptState* script_state, ExceptionState& exception_state) { // It's possible that |script_state|'s context isn't valid, which means we // should immediately reject the request. This is possible in situations like // the document that created this image was already destroyed (like an img // that comes from iframe.contentDocument.createElement("img") and the iframe // is destroyed). if (!script_state->ContextIsValid()) { exception_state.ThrowDOMException(kEncodingError, "The source image cannot be decoded."); return ScriptPromise(); } UseCounter::Count(GetElement()->GetDocument(), WebFeature::kImageDecodeAPI); auto* request = new DecodeRequest(this, ScriptPromiseResolver::Create(script_state)); Microtask::EnqueueMicrotask( WTF::Bind(&DecodeRequest::ProcessForTask, WrapWeakPersistent(request))); decode_requests_.push_back(request); return request->promise(); } void ImageLoader::ElementDidMoveToNewDocument() { if (delay_until_do_update_from_element_) { delay_until_do_update_from_element_->DocumentChanged( element_->GetDocument()); } if (delay_until_image_notify_finished_) { delay_until_image_notify_finished_->DocumentChanged( element_->GetDocument()); } ClearFailedLoadURL(); ClearImage(); } // Indicates the next available id that we can use to uniquely identify a decode // request. uint64_t ImageLoader::DecodeRequest::s_next_request_id_ = 0; ImageLoader::DecodeRequest::DecodeRequest(ImageLoader* loader, ScriptPromiseResolver* resolver) : request_id_(s_next_request_id_++), resolver_(resolver), loader_(loader) {} void ImageLoader::DecodeRequest::Resolve() { resolver_->Resolve(); loader_ = nullptr; } void ImageLoader::DecodeRequest::Reject() { resolver_->Reject(DOMException::Create( kEncodingError, "The source image cannot be decoded.")); loader_ = nullptr; } void ImageLoader::DecodeRequest::ProcessForTask() { // We could have already processed (ie rejected) this task due to a sync // update in UpdateFromElement. In that case, there's nothing to do here. if (!loader_) return; DCHECK_EQ(state_, kPendingMicrotask); state_ = kPendingLoad; loader_->DispatchDecodeRequestsIfComplete(); } void ImageLoader::DecodeRequest::NotifyDecodeDispatched() { DCHECK_EQ(state_, kPendingLoad); state_ = kDispatched; } void ImageLoader::DecodeRequest::Trace(blink::Visitor* visitor) { visitor->Trace(resolver_); visitor->Trace(loader_); } } // namespace blink
f01a98462ef60f53efe5e4dab49ba76dc3ae0039
10584072606f3d579bb8f2e2945cbb37cf8e6153
/brass.h
6cdb0d35f9fa003259c9cc11f80040bf79c69f12
[]
no_license
ChangeXuan/learn-Cpp
1647eeab981a98b533ffe3064b8dd01c3ad373ab
071b99895e3fd82d980a5c6958d80a3e33ce969c
refs/heads/master
2021-01-20T03:34:41.617955
2017-04-27T05:00:11
2017-04-27T05:00:11
89,557,304
0
0
null
null
null
null
UTF-8
C++
false
false
945
h
// // Created by Day on 2017/4/20. // #ifndef LEARNCPP_BRASS_H #define LEARNCPP_BRASS_H #include <string> class Brass { private: std::string fullName; long accName; double balance; public: Brass(const std::string &s="no",long an = -1,double bal=0.0); void depositF(double amt); double balanceF() const; virtual void withDraw(double amt); virtual void viewAcct() const; virtual ~Brass(); }; class BrassPlus :Brass { private: double maxLoan; double rate; double owesBank; public: BrassPlus(const std::string &s = "no",long an=-1, double bal=0.0, double ml=500, double r = 0.11125); BrassPlus(const Brass &ba,double ml=500,double r=0.11125); void resetMax(double m) {maxLoan = m;}; void resetRate(double r) {rate = r;}; void resetOwes() {owesBank = 0;}; virtual void viewAcct() const; virtual void withDraw(double amt); }; #endif //LEARNCPP_BRASS_H
[ "YourEmailAddress" ]
YourEmailAddress
7282cf26ce9a21d5ae1b82b2ec3b38c737e210ba
780d572d764882799ffc613728b2f20476877d5f
/src/C_project_linux/threads_hello.cpp
5ce9d96b850784aa732df78e700150c1eb184e46
[]
no_license
leemengwei/friction_compensation
342e8d4634be61df389b56b6356dbf529ce08f60
cd8214116f47c8a948bc8b9cf34778c77dca1170
refs/heads/master
2022-12-19T06:26:46.359163
2020-09-18T10:33:10
2020-09-18T10:33:10
200,638,123
0
0
null
null
null
null
UTF-8
C++
false
false
809
cpp
#include <iostream> // ๅฟ…้กป็š„ๅคดๆ–‡ไปถ #include <pthread.h> using namespace std; #define NUM_THREADS 5 // ็บฟ็จ‹็š„่ฟ่กŒๅ‡ฝๆ•ฐ void* say_hello(void* args) { cout << "Hello Runoob๏ผ" << endl; return 0; } int main() { // ๅฎšไน‰็บฟ็จ‹็š„ id ๅ˜้‡๏ผŒๅคšไธชๅ˜้‡ไฝฟ็”จๆ•ฐ็ป„ pthread_t tids[NUM_THREADS]; for(int i = 0; i < NUM_THREADS; ++i) { //ๅ‚ๆ•ฐไพๆฌกๆ˜ฏ๏ผšๅˆ›ๅปบ็š„็บฟ็จ‹id๏ผŒ็บฟ็จ‹ๅ‚ๆ•ฐ๏ผŒ่ฐƒ็”จ็š„ๅ‡ฝๆ•ฐ๏ผŒไผ ๅ…ฅ็š„ๅ‡ฝๆ•ฐๅ‚ๆ•ฐ int ret = pthread_create(&tids[i], NULL, say_hello, NULL); if (ret != 0) { cout << "pthread_create error: error_code=" << ret << endl; } } //็ญ‰ๅ„ไธช็บฟ็จ‹้€€ๅ‡บๅŽ๏ผŒ่ฟ›็จ‹ๆ‰็ป“ๆŸ๏ผŒๅฆๅˆ™่ฟ›็จ‹ๅผบๅˆถ็ป“ๆŸไบ†๏ผŒ็บฟ็จ‹ๅฏ่ƒฝ่ฟ˜ๆฒกๅๅบ”่ฟ‡ๆฅ๏ผ› pthread_exit(NULL); }
fe4c8704c0ce57a28d0e3bfbc6bc61839fcf927f
3841f7991232e02c850b7e2ff6e02712e9128b17
/ๅฐๆตชๅบ•ๆณฅๆฒ™ไธ‰็ปด/EV_Xld/jni/src/EV_Spatial3DDataset_CSharp/wrapper/modelcacheutility_wrapper.cpp
d6154dc1049a7cf2a7e1929c7ac6a339eb6fb6a2
[]
no_license
15831944/BeijingEVProjects
62bf734f1cb0a8be6fed42cf6b207f9dbdf99e71
3b5fa4c4889557008529958fc7cb51927259f66e
refs/heads/master
2021-07-22T14:12:15.106616
2017-10-15T11:33:06
2017-10-15T11:33:06
null
0
0
null
null
null
null
UTF-8
C++
false
false
18,199
cpp
/* This file is produced by the P/Invoke AutoWrapper Utility Copyright (c) 2012 by EarthView Image Inc */ #include "spatial3ddataset/modelcacheutility.h" namespace EarthView { namespace World { namespace Spatial { namespace GeoDataset { } } } } namespace EarthView { namespace World { namespace Spatial3D { namespace Dataset { extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_clearDataset_ev_bool_EVString_EVString_ev_bool(_in const char* datasourceName, _in const char* datasetName, _in ev_bool bTemplDataset ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::clearDataset(datasourceName1, datasetName1, bTemplDataset); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_writeDatasetModel_ev_bool_EVString_EVString_EVString_IFeature_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in const EarthView::World::Spatial::GeoDataset::IFeature* pMeshFeature, _in const void* thumbTextures, _in const void* origTextures, _in const void* cubeTextures, _in const void* materials, _in const void* progs, _in const void* gpus, _in const void* skeletons, _in const void* animation ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::writeDatasetModel(datasourceName1, datasetName1, octCode1, pMeshFeature, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)thumbTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)origTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)cubeTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)materials, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)progs, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)gpus, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)skeletons, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)animation); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_writeTemplDBModel_ev_bool_EVString_EVString_EVString_IFeature_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in const EarthView::World::Spatial::GeoDataset::IFeature* pMeshFeature, _in const void* thumbTextures, _in const void* origTextures, _in const void* cubeTextures, _in const void* materials, _in const void* progs, _in const void* gpus, _in const void* skeletons, _in const void* animation ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::writeTemplDBModel(datasourceName1, datasetName1, octCode1, pMeshFeature, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)thumbTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)origTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)cubeTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)materials, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)progs, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)gpus, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)skeletons, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)animation); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_writeTemplEntity_ev_bool_EVString_EVString_EVString_IFeature(_in const char* datasourceName, _in const char* datasetName, _in const char* code, _in const EarthView::World::Spatial::GeoDataset::IFeature* pMeshFeature ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string code1 = code; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::writeTemplEntity(datasourceName1, datasetName1, code1, pMeshFeature); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_deleteDatasetModel_ev_bool_EVString_EVString_EVString_ev_uint32(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in ev_uint32 id ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::deleteDatasetModel(datasourceName1, datasetName1, octCode1, id); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_deleteTemplDBModel_ev_bool_EVString_EVString_EVString_ev_uint32(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in ev_uint32 id ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::deleteTemplDBModel(datasourceName1, datasetName1, octCode1, id); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_deleteTemplEntity_ev_bool_EVString_EVString_ev_uint32(_in const char* datasourceName, _in const char* datasetName, _in ev_uint32 id ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::deleteTemplEntity(datasourceName1, datasetName1, id); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_updateDatasetEntityInfo_ev_bool_EVString_EVString_EVString_IFeature(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in const EarthView::World::Spatial::GeoDataset::IFeature* pMeshFeature ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::updateDatasetEntityInfo(datasourceName1, datasetName1, octCode1, pMeshFeature); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_updateTemplDatasetEntityInfo_ev_bool_EVString_EVString_EVString_IFeature(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in const EarthView::World::Spatial::GeoDataset::IFeature* pMeshFeature ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::updateTemplDatasetEntityInfo(datasourceName1, datasetName1, octCode1, pMeshFeature); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_updateTemplDBInfo_ev_bool_EVString_EVString_IFeature(_in const char* datasourceName, _in const char* datasetName, _in const EarthView::World::Spatial::GeoDataset::IFeature* pMeshFeature ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::updateTemplDBInfo(datasourceName1, datasetName1, pMeshFeature); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_readDatasetModel_ev_bool_CEntityDataset_EVString_ev_uint32_IFeature_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector(_in EarthView::World::Spatial3D::Dataset::CEntityDataset* pDataset, _in const char* octCode, _in ev_uint32 id, _out EarthView::World::Spatial::GeoDataset::IFeature*& pMeshFeature, _out void* thumbTextures, _out void* origTextures, _out void* cubeTextures, _out void* materials, _out void* progs, _out void* gpus, _out void* skeletons, _out void* animation ) { EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::readDatasetModel(pDataset, octCode1, id, pMeshFeature, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)thumbTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)origTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)cubeTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)materials, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)progs, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)gpus, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)skeletons, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)animation); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_readTemplDBModel_ev_bool_CMeshTemplateDataset_EVString_EVString_EVString_ev_uint32_IFeature_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector_FeatureVector(_in EarthView::World::Spatial3D::Dataset::CMeshTemplateDataset* pDataset, _in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in ev_uint32 id, _out EarthView::World::Spatial::GeoDataset::IFeature*& pMeshFeature, _out void* thumbTextures, _out void* origTextures, _out void* cubeTextures, _out void* materials, _out void* progs, _out void* gpus, _out void* skeletons, _out void* animatio ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::readTemplDBModel(pDataset, datasourceName1, datasetName1, octCode1, id, pMeshFeature, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)thumbTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)origTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)cubeTextures, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)materials, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)progs, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)gpus, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)skeletons, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)animatio); return objXXXX; } extern "C" EV_DLL_EXPORT EarthView::World::Spatial::GeoDataset::IFeature* _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_readTemplEntity_IFeature_CEntityDataset_ev_uint32_EVString(_in EarthView::World::Spatial3D::Dataset::CEntityDataset* pDataset, _in ev_uint32 id, _in const char* code ) { EarthView::World::Core::ev_string code1 = code; EarthView::World::Spatial::GeoDataset::IFeature* objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::readTemplEntity(pDataset, id, code1); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_readDatasetModelOrigTexture_ev_bool_EVString_EVString_EVString_FeatureVector_TextureStreamVector(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in const void* origFeatureVec, _out void* imgTextures ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::readDatasetModelOrigTexture(datasourceName1, datasetName1, octCode1, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)origFeatureVec, *(EarthView::World::Spatial3D::Dataset::TextureStreamVector*)imgTextures); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_readTemplDatasetOrigTexture_ev_bool_EVString_EVString_EVString_FeatureVector_TextureStreamVector(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in const void* origFeatureVec, _out void* texStreams ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::readTemplDatasetOrigTexture(datasourceName1, datasetName1, octCode1, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)origFeatureVec, *(EarthView::World::Spatial3D::Dataset::TextureStreamVector*)texStreams); return objXXXX; } extern "C" EV_DLL_EXPORT ev_uint32 _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_readMeshTemplID_ev_uint32_EVString_EVString_ev_uint32(_in const char* datasourceName, _in const char* datasetName, _in ev_uint32 meshInstID ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; ev_uint32 objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::readMeshTemplID(datasourceName1, datasetName1, meshInstID); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_readDatasetAniDataStream_ev_bool_EVString_EVString_EVString_ev_uint32_MemoryDataStreamPtr(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in ev_uint32 meshID, _out void* stream ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::readDatasetAniDataStream(datasourceName1, datasetName1, octCode1, meshID, *(EarthView::World::Core::MemoryDataStreamPtr*)stream); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_readTemplAniDataStream_ev_bool_EVString_EVString_ev_uint32_MemoryDataStreamPtr(_in const char* datasourceName, _in const char* datasetName, _in ev_uint32 meshID, _out void* stream ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::readTemplAniDataStream(datasourceName1, datasetName1, meshID, *(EarthView::World::Core::MemoryDataStreamPtr*)stream); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_writeDatasetModelOrigTexture_ev_bool_EVString_EVString_EVString_FeatureVector(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in const void* origFeatureVec ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::writeDatasetModelOrigTexture(datasourceName1, datasetName1, octCode1, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)origFeatureVec); return objXXXX; } extern "C" EV_DLL_EXPORT ev_bool _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_writeTemplDatasetOrigTexture_ev_bool_EVString_EVString_EVString_FeatureVector(_in const char* datasourceName, _in const char* datasetName, _in const char* octCode, _in const void* origFeatureVec ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Core::ev_string octCode1 = octCode; ev_bool objXXXX = EarthView::World::Spatial3D::Dataset::CModelCacheUtility::writeTemplDatasetOrigTexture(datasourceName1, datasetName1, octCode1, *(EarthView::World::Spatial3D::Dataset::FeatureVector*)origFeatureVec); return objXXXX; } extern "C" EV_DLL_EXPORT void _stdcall EarthView_World_Spatial3D_Dataset_CModelCacheUtility_updateAltitudeMode_void_EVString_EVString_EVDatasetType_EVAltitudeMode_ev_real64(_in const char* datasourceName, _in const char* datasetName, _in int type, _in int altitudeMode, _in ev_real64 altitudeValue ) { EarthView::World::Core::ev_string datasourceName1 = datasourceName; EarthView::World::Core::ev_string datasetName1 = datasetName; EarthView::World::Spatial3D::Dataset::CModelCacheUtility::updateAltitudeMode(datasourceName1, datasetName1, (EarthView::World::Spatial::GeoDataset::EVDatasetType)type, (EarthView::World::Spatial::Utility::EVAltitudeMode)altitudeMode, altitudeValue); } } } } }
504451b46ba373fd7eec171bd6f53df29a1f7bbd
b19f30140cef064cbf4b18e749c9d8ebdd8bf27f
/D3DGame_181008_045_2_Blend/Executes/TestAnimation.h
482e2252717aebf55ab772eb304e07bb9f731a6f
[]
no_license
evehour/SGADHLee
675580e199991916cf3134e7c61749b0a0bfa070
0ebbedf5d0692b782e2e5f9a372911c65f98ddc4
refs/heads/master
2020-03-25T13:22:42.597811
2019-01-03T07:05:54
2019-01-03T07:05:54
143,822,128
0
0
null
null
null
null
UTF-8
C++
false
false
279
h
#pragma once #include "Execute.h" class TestAnimation : public Execute { public: TestAnimation(ExecuteValues* values); ~TestAnimation(); void Update(); void PreRender(); void Render(); void PostRender(); void ResizeScreen(){} private: class GameAnimModel* kachujin; };
f9fdc9856317d96fbadd6a33b775f9c0c8d8e2fd
0c21f1b2bd0f0060391cadc0fd707eb03a9f0527
/ZelusEngine/src/Renderer/renderable_factory/gl_renderable_factory.cpp
a427601878b885448827c5da3267457eda42a050
[]
no_license
MatthewCrankshaw/ZelusEngine
65d93221f85d32677fbafe0199c71a451a3460be
0c4020b29090c46ce9333ab9934a6a468a3e0373
refs/heads/master
2021-06-27T07:06:32.838239
2021-01-03T10:09:40
2021-01-03T10:09:40
260,053,536
2
0
null
null
null
null
UTF-8
C++
false
false
419
cpp
#include "gl_renderable_factory.h" Ref<Renderable> GLRenderableFactory::CreateCube() const { Ref<Renderable> cube(new GLCube()); return cube; } Ref<Renderable> GLRenderableFactory::CreateModel(std::string path) const { Ref<GLRenderable> model(new GLModel(path)); return model; } Ref<Renderable> GLRenderableFactory::CreateRectangle() const { Ref<GLRenderable> rectangle(new GLRectangle()); return rectangle; }
b1a2dc2e5a09e5edcaf0488e0e6ff2a24bafaa06
ec50845a0dbd6bb879a3e0d12c886472ef7a83da
/source/rectangle.cpp
81378d6f018e4868446d9e1ecc71146e6a0b985a
[ "MIT" ]
permissive
Montag55/programmiersprachen-aufgabenblatt-2
dc7b294c9712c336f83dcc2123c7a05d8412e7d5
d1e82d9e5c96361bf203f86b74f6b754905016ca
refs/heads/master
2021-01-18T13:20:32.876809
2016-05-08T10:11:45
2016-05-08T10:11:45
57,286,508
0
0
null
2016-04-28T09:05:24
2016-04-28T09:05:23
null
UTF-8
C++
false
false
1,694
cpp
#include "rectangle.hpp" #include "vec2.hpp" #include <cmath> #include "mat2.hpp" #include "window.hpp" #include "color.hpp" Rectangle::Rectangle(): m_h{3.0f}, m_b{2.0f}, m_c{1.0f, 1.0f, 1.0f}, m_pul{Vec2()} {} Rectangle::Rectangle(float h, float b, Color const& c, Vec2 const& pul): m_h{h}, m_b{b}, m_c{c}, m_pul{pul} {} //Getter float Rectangle::hight() const{ return m_h; } float Rectangle::breite() const{ return m_b; } Color Rectangle::color() const{ return m_c; } Vec2 Rectangle::startpunkt() const{ return m_pul; } //Setter void Rectangle::hight(float h){ m_h = h; } void Rectangle::breite(float b){ m_b = b; } void Rectangle::color(Color const& c){ m_c = c; } void Rectangle::startpunkt(Vec2 const& pul){ m_pul = pul; } //Rechteck Umfang float Rectangle::circumference() const{ return 2*(hight()+breite()); } //Rechteckflรคche float Rectangle::area() const{ return hight()*breite(); } //Draw Rectangle void Rectangle::draw(Window const& win, Color const& c)const{ win.draw_line(startpunkt().x, startpunkt().y, startpunkt().x, startpunkt().y + hight(), c.m_r,c.m_g,c.m_b); win.draw_line(startpunkt().x, startpunkt().y, startpunkt().x + breite(), startpunkt().y, c.m_r,c.m_g,c.m_b); win.draw_line(startpunkt().x, startpunkt().y + hight(), startpunkt().x + breite(), startpunkt().y + hight(), c.m_r,c.m_g,c.m_b); win.draw_line(startpunkt().x + breite(), startpunkt().y, startpunkt().x + breite(), startpunkt().y + hight(), c.m_r,c.m_g,c.m_b); } //is_inside bool Rectangle::is_inside(Vec2 const& p)const{ if(startpunkt().x<=p.x && startpunkt().y<=p.y && startpunkt().x + breite()>=p.x && startpunkt().y+hight()>=p.y){ return true; } return false; }
7f9269b8a5f11a607f01e66ba69a4cbaac5e0d23
a35086ad6458bf62366f552c5d3e30d8438224f9
/host/p2p_bandwidth/src/bandwidth.cpp
3b3ea21f69d5492f77dbaba09234d71f7258096d
[ "LicenseRef-scancode-warranty-disclaimer", "Apache-2.0" ]
permissive
kapil2099/Vitis_Accel_Examples
6d785ee8c085aeb7123a8e24decee7d9e39fd3d6
05f898ab0fb808421316fad9fb7dd862d92eb623
refs/heads/master
2021-03-24T08:46:36.522388
2020-11-25T19:13:55
2020-11-25T19:13:55
247,535,193
0
0
NOASSERTION
2020-03-15T19:18:46
2020-03-15T19:18:46
null
UTF-8
C++
false
false
731
cpp
/** * Copyright (C) 2020 Xilinx, Inc * * Licensed under the Apache License, Version 2.0 (the "License"). You may * not use this file except in compliance with the License. A copy of the * License is located at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the * License for the specific language governing permissions and limitations * under the License. */ extern "C" { void bandwidth(unsigned int *buffer0) { // Intentional empty kernel as this example doesn't require actual // kernel to work. } }
87ad5bd8d361f771f25e0d57e173ba6613f984d8
f856ad2e96263a38a6c717eca995f8a3f66b3f2f
/src/common/cpu.cpp
c59c7b9c9b3af073c8770b51d4e93b8188a995b2
[ "BSD-3-Clause", "LicenseRef-scancode-unknown-license-reference", "BSL-1.0", "Apache-2.0", "BSD-2-Clause", "MIT" ]
permissive
xiake-1024/Pebble
befaee5868905fb804c50d895e80d3489d464200
283310f67f5b30adaed5a21df97f706560b3617f
refs/heads/master
2022-12-09T14:24:51.785830
2020-09-26T03:05:05
2020-09-26T03:05:05
296,327,254
0
0
NOASSERTION
2020-09-17T13:00:05
2020-09-17T13:00:04
null
UTF-8
C++
false
false
3,289
cpp
/* * Tencent is pleased to support the open source community by making Pebble available. * Copyright (C) 2016 THL A29 Limited, a Tencent company. All rights reserved. * Licensed under the MIT License (the "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * http://opensource.org/licenses/MIT * Unless required by applicable law or agreed to in writing, software distributed under the License * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express * or implied. See the License for the specific language governing permissions and limitations under * the License. * */ #include <errno.h> #include <linux/limits.h> #include <stdint.h> #include <stdio.h> #include <string.h> #include <sys/types.h> #include <unistd.h> #include "common/cpu.h" namespace pebble { // /proc/pid/statๅญ—ๆฎตๅฎšไน‰ struct pid_stat_fields { int64_t pid; char comm[PATH_MAX]; char state; int64_t ppid; int64_t pgrp; int64_t session; int64_t tty_nr; int64_t tpgid; int64_t flags; int64_t minflt; int64_t cminflt; int64_t majflt; int64_t cmajflt; int64_t utime; int64_t stime; int64_t cutime; int64_t cstime; // ... }; // /proc/stat/cpuไฟกๆฏๅญ—ๆฎตๅฎšไน‰ struct cpu_stat_fields { char cpu_label[16]; int64_t user; int64_t nice; int64_t system; int64_t idle; int64_t iowait; int64_t irq; int64_t softirq; // ... }; long long GetCurCpuTime() { char file_name[64] = { 0 }; snprintf(file_name, sizeof(file_name), "/proc/%d/stat", getpid()); FILE* pid_stat = fopen(file_name, "r"); if (!pid_stat) { return -1; } pid_stat_fields result; int ret = fscanf(pid_stat, "%ld %s %c %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld", &result.pid, result.comm, &result.state, &result.ppid, &result.pgrp, &result.session, &result.tty_nr, &result.tpgid, &result.flags, &result.minflt, &result.cminflt, &result.majflt, &result.cmajflt, &result.utime, &result.stime, &result.cutime, &result.cstime); fclose(pid_stat); if (ret <= 0) { return -1; } return result.utime + result.stime + result.cutime + result.cstime; } long long GetTotalCpuTime() { char file_name[] = "/proc/stat"; FILE* stat = fopen(file_name, "r"); if (!stat) { return -1; } cpu_stat_fields result; int ret = fscanf(stat, "%s %ld %ld %ld %ld %ld %ld %ld", result.cpu_label, &result.user, &result.nice, &result.system, &result.idle, &result.iowait, &result.irq, &result.softirq); fclose(stat); if (ret <= 0) { return -1; } return result.user + result.nice + result.system + result.idle + result.iowait + result.irq + result.softirq; } float CalculateCurCpuUseage(long long cur_cpu_time_start, long long cur_cpu_time_stop, long long total_cpu_time_start, long long total_cpu_time_stop) { long long cpu_result = total_cpu_time_stop - total_cpu_time_start; if (cpu_result <= 0) { return 0; } return (sysconf(_SC_NPROCESSORS_ONLN) * 100.0f *(cur_cpu_time_stop - cur_cpu_time_start)) / cpu_result; } } // namespace pebble
9fd3896fdc694552ec85234a58de937e00a1fa3d
0cb85cd0c88a9b9f0cca4472742c2bf9febef2d8
/Prague/CodeGen/idlc/idl/types.cpp
25ae0891158aa7e3452267d2b78ad806f969bd19
[]
no_license
seth1002/antivirus-1
9dfbadc68e16e51f141ac8b3bb283c1d25792572
3752a3b20e1a8390f0889f6192ee6b851e99e8a4
refs/heads/master
2020-07-15T00:30:19.131934
2016-07-21T13:59:11
2016-07-21T13:59:11
null
0
0
null
null
null
null
UTF-8
C++
false
false
704
cpp
#include "types.hpp" #include <algorithm> #include <boost/algorithm/string.hpp> namespace idl { std::string NamePath::str() const { if (_path.size() == 0) { return std::string(); } Names::const_iterator i = _path.begin(), end = _path.end(); std::string result = *i; ++i; for (; i != end; ++i) { result += '.'; result += *i; } return result; } NamePath NamePath::make(const std::string& str) { std::vector<std::string> names; boost::split(names, str, boost::is_any_of("."), boost::token_compress_on); NamePath result; std::copy(names.begin(), names.end(), std::back_inserter(result._path)); return result; } } //namespace idl
9192151f2c8aa8a31144613592597b322dc6c880
ed732bc02b26591e0f8c22c9646feb9c136e87ee
/custom-packages/winver/winver/SystemInfo.h
adcb85aa93f3edde76d799e7cf27f015bb3e9e0e
[]
no_license
daniel-1964/msys2
b44cec5a4a5b46030b2ee04e918edaf3aec3d83d
89b20346ceaebda63e0f2b1673168f45c0652bf4
refs/heads/master
2023-03-27T01:39:04.728495
2021-03-28T17:05:17
2021-03-28T17:37:06
277,585,038
0
0
null
null
null
null
UTF-8
C++
false
false
7,452
h
/** * copyright (c) 2005 - 2010 Marius Bancila * http://www.mariusbancila.ro * http://www.mariusbancila.ro/blog * http://www.codexpert.ro * http://www.codeguru.com * http://www.sharparena.com */ /** * SystemInfo.h: interface for the SystemInfo class. */ #include <Windows.h> #if (defined(__MINGW32__) || defined(__CYGWIN__)) #ifndef PRODUCT_EDUCATION #define PRODUCT_EDUCATION 0x00000079 #endif #ifndef PRODUCT_EDUCATION_N #define PRODUCT_EDUCATION_N 0x0000007A #endif #ifndef PRODUCT_ENTERPRISE_S #define PRODUCT_ENTERPRISE_S 0x0000007D #endif #ifndef PRODUCT_ENTERPRISE_S_N #define PRODUCT_ENTERPRISE_S_N 0x0000007E #endif #ifndef PRODUCT_ENTERPRISE_S_EVALUATION #define PRODUCT_ENTERPRISE_S_EVALUATION 0x00000081 #endif #ifndef PRODUCT_ENTERPRISE_S_N_EVALUATION #define PRODUCT_ENTERPRISE_S_N_EVALUATION 0x00000082 #endif #ifndef PRODUCT_MOBILE_ENTERPRISE #define PRODUCT_MOBILE_ENTERPRISE 0x00000085 #endif #endif /** * Known Windows versions */ enum WindowsVersion { Windows, /**< Pre-Windows 95 version */ Windows32s, /**< Win32s API */ Windows95, /**< Windows 95 (oiginal) */ Windows95OSR2, /**< Windows 95 0SR2 */ Windows98, /**< Windows 98 */ Windows98SE, /**< Windows 98 Second Edition */ WindowsMillennium, /**< Windows Milenium */ WindowsNT351, /**< Windows NT 4.51 */ WindowsNT40, /**< Windows NT 4.0 WorkStation */ WindowsNT40Server, /**< Windows NT 4.0 Server */ Windows2000, /**< Windows 2000 */ WindowsXP, /**< Windows XP */ WindowsXPProfessionalx64, /**< Windows XP Professionnal X64 */ WindowsHomeServer, /**< Windows Home Server */ WindowsServer2003, /**< Windows 2003 Server */ WindowsServer2003R2, /**< Windows 2003 Server R2 */ WindowsVista, /**< Windows Vista */ WindowsServer2008, /**< Windows 2008 Server */ Windows7, /**< Windows 7 */ WindowsServer2008R2, /**< Windows 2008 Server R2 */ Windows8, /**< Windows 8 */ WindowsServer2012, /**< Windows 2012 Server */ Windows8_1, /**< Windows 8.1 */ WindowsServer2012R2, /**< Windows 2008 Server R2 */ Windows10, /**< Windows 10 */ WindowsServer2016 /**< Windows 2016 Server */ }; /** * Known Windows Editions */ enum WindowsEdition { EditionUnknown, Workstation, Server, AdvancedServer, Home, Ultimate, HomeBasic, HomePremium, Enterprise, HomeBasic_N, Business, StandardServer, DatacenterServer, SmallBusinessServer, EnterpriseServer, Starter, DatacenterServerCore, StandardServerCore, EnterpriseServerCore, EnterpriseServerIA64, Business_N, WebServer, ClusterServer, HomeServer, StorageExpressServer, StorageStandardServer, StorageWorkgroupServer, StorageEnterpriseServer, ServerForSmallBusiness, SmallBusinessServerPremium, HomePremium_N, Enterprise_N, Ultimate_N, WebServerCore, MediumBusinessServerManagement, MediumBusinessServerSecurity, MediumBusinessServerMessaging, ServerFoundation, HomePremiumServer, ServerForSmallBusiness_V, StandardServer_V, DatacenterServer_V, EnterpriseServer_V, DatacenterServerCore_V, StandardServerCore_V, EnterpriseServerCore_V, HyperV, StorageExpressServerCore, StorageStandardServerCore, StorageWorkgroupServerCore, StorageEnterpriseServerCore, Starter_N, Professional, Professional_N, SBSolutionServer, ServerForSBSolution, StandardServerSolutions, StandardServerSolutionsCore, SBSolutionServer_EM, ServerForSBSolution_EM, SolutionEmbeddedServer, SolutionEmbeddedServerCore, SmallBusinessServerPremiumCore, EssentialBusinessServerMGMT, EssentialBusinessServerADDL, EssentialBusinessServerMGMTSVC, EssentialBusinessServerADDLSVC, ClusterServer_V, Embedded, Starter_E, HomeBasic_E, HomePremium_E, Professional_E, Enterprise_E, Ultimate_E, EnterpriseEvaluation, MultipointStandardServer, MultipointPremiumServer, StandardEvaluationServer, DatacenterEvaluationServer, EnterpriseNEvaluation, EmbeddedAutomotive, EmbeddedIndustryA, Thinpc, EmbeddedA, EmbeddedIndustry, EmbeddedE, EmbeddedIndustryE, EmbeddedIndustryAE, StorageWorkgroupEvaluationServer, StorageStandardEvaluationServer, CoreArm, CoreN, CoreCountrySpecific, CoreSingleLanguage, Core, ProfessionalWmc, MobileCore, Education, EducationN, EnterpriseS, EnterpriseSN, EnterpriseSEvaluation, EnterpriseSNEvaluation, MobileEnterprise }; class SystemInfo { WindowsVersion m_nWinVersion; WindowsEdition m_nWinEdition; TCHAR m_szServicePack[32]; TCHAR m_szReleaseId[5]; TCHAR m_szReleaseName[128]; TCHAR m_szCSDBuildNumber[6]; TCHAR m_szRegisteredOwner[128]; TCHAR m_szRegisteredOrganization[128]; TCHAR m_szProductId[32]; TCHAR m_szEncodedProductId[30]; DWORD m_dwUBR; OSVERSIONINFOEX m_osvi; SYSTEM_INFO m_SysInfo; BOOL m_bOsVersionInfoEx; private: void DetectWindowsVersion(); void DetectWindowsEdition(); void DetectWindowsServicePack(); void DetectCurrentVersionKeys(); DWORD DetectProductInfo(); void EncodeProductId(LPBYTE lpbDigitalProductId); public: SystemInfo(); virtual ~SystemInfo(); /** * returns the windows version (mnemonic) */ WindowsVersion GetWindowsVersion() const; /** * returns the windows version (string) */ const char *GetWindowsVersionName() const; /** * returns the windows edition (mnemonic) */ WindowsEdition GetWindowsEdition() const; /** * returns the windows edition (string) */ const char *GetWindowsEditionName() const; /** * true if NT platform */ bool IsNTPlatform() const; /** * true is Windows platform */ bool IsWindowsPlatform() const; /** * true is Win32s platform */ bool IsWin32sPlatform() const; /** * returns major version */ DWORD GetMajorVersion() const; /** * returns minor version */ DWORD GetMinorVersion() const; /** * returns build number */ DWORD GetBuildNumber() const; /** * returns platform ID */ DWORD GetPlatformID() const; /** * additional information about service pack */ const char *GetServicePackInfo() const; /** * Returns Windows 10 Release ID */ const char *GetReleaseId() const; /** * Returns Windows 10 Release Name if known */ const char *GetReleaseName() const; /** * Returns CSD Build Number */ const char *GetCSDBuildNumber() const; /** * Returns Registered Owner */ const char *GetRegisteredOwner() const; /** * Returns Registered Organization */ const char *GetRegisteredOrganization() const; /** * Returns Product ID */ const char *GetProductId() const; /** * Returns Encoded Product ID */ const char *GetEncodedProductId() const; /** * Teturns CSDBuildNumber or Windows 10 UBR */ DWORD GetUBR() const; /** * true if platform is 32-bit */ bool Is32bitPlatform() const; /** * true if platform is 64-bit */ bool Is64bitPlatform() const; };
4f54623b9123efd113c0b5a70c1faa0158c58a0a
d4d5a0bc519294e4b3f312048dd52cf9264b7e29
/POJ/1426/13030021_AC_157ms_408kB.cpp
8397253a3c84a621bab8380d290a93db2f828277
[]
no_license
imhdx/My-all-code-of-Vjudge-Judge
fc625f83befbaeda7a033fd271fd4f61d295e807
b0db5247db09837be9866f39b183409f0a02c290
refs/heads/master
2020-04-29T08:16:24.607167
2019-07-24T01:17:15
2019-07-24T01:17:15
175,981,455
0
0
null
null
null
null
UTF-8
C++
false
false
358
cpp
#include<stdio.h> int n; int flag=0; long long int qq; void dfs(long long int aa) { if (!(aa>=1&&aa<9223372036854775807)) return ; if (flag==1) return ; if (aa%n==0) {flag=1;qq=aa;return ;} dfs(aa*10); dfs(aa*10+1); return ; } int main() { while (scanf("%d",&n)!=EOF) { if (n==0) break; flag=0; dfs(1); printf("%lld\n",qq); } return 0; }
f2f1d203faf4489b2d20e6e0a7ada1ae412fcc22
9cae11cba0eff57107531b609ee53ffeca5ecfa0
/Ember/src/Ember/Application.h
b061ff7778c841215a4cf61ea93114300dfa244a
[ "Apache-2.0" ]
permissive
khalidHsoliman/Ember
721a4426a00eef51dec4aa2b8dc86ebc935f7449
4631dd0f7b56e7472dbce148bf2d9bf5680e8950
refs/heads/master
2020-04-25T08:15:28.727299
2019-06-30T22:04:11
2019-06-30T22:04:11
172,641,301
1
0
null
null
null
null
UTF-8
C++
false
false
834
h
#pragma once #include "Core.h" #include "Window.h" #include "Ember/LayerStack.h" #include "Ember/Events/Event.h" #include "Ember/Events/ApplicationEvent.h" #include "Ember/ImGui/ImGuiLayer.h" namespace Ember { class EMBER_API Application { public: Application( ); virtual ~Application( ); void Run( ); void OnEvent( Event& e ); void PushLayer( Layer* layer ); void PushOverlay( Layer* layer ); inline Window& GetWindow( ) { return *m_Window; } inline static Application& Get( ) { return *s_Instance; } private: bool OnWindowClose( WindowCloseEvent& e ); std::unique_ptr<Window> m_Window; ImGuiLayer* m_ImGuiLayer; bool m_Running = true; LayerStack m_LayerStack; private: static Application* s_Instance; }; // To be defined in CLIENT Application* CreateApplication( ); }
cd7434b9f5bd64f760e08efc170d5372f91b2d74
4e413b3ec7be8727dd4fc76675b9a9e21a9595f5
/src/Util.cpp
0e5d67eb73f31b5d940b539b60659810b629da50
[]
no_license
Cendukka/SlotMachine
c2069bbabab25b6496b6279ec6ee544f3072b0ce
f6bc7951895eb42c53535ae5ca2a931ad7f53ead
refs/heads/master
2020-12-19T02:29:23.459386
2020-02-16T02:42:19
2020-02-16T02:42:19
235,592,958
1
0
null
null
null
null
UTF-8
C++
false
false
4,926
cpp
#include "Util.h" #include "GLM/gtc/constants.hpp" #include "GLM/gtx/norm.hpp" const float Util::EPSILON = glm::epsilon<float>(); const float Util::Deg2Rad = glm::pi<float>() / 180.0f; const float Util::Rad2Deg = 180.0f / glm::pi<float>(); Util::Util() { } Util::~Util() { } /** * Returns -1.0 if the value is less than 0 and 1.0 if the value is greater than 0 */ float Util::sign(float value) { return (value < 0.0f) ? -1.0f : 1.0f; } /** * This method confines the value provided between min and max and returns the result * */ float Util::clamp(float value, float min, float max) { if (value < min) { value = min; } else if (value > max) { value = max; } return value; } /** * Clamps a value between 0 and 1 and returns the result * */ float Util::clamp01(float value) { float result = 0.0f; if (value < 0.0f) { result = 0.0f; } else if (value > 1.0f) { result = 1.0f; } else { result = value; } return result; } /** * Returns the Euclidian distance of vecA and vecB */ float Util::distance(glm::vec2 vecA, glm::vec2 vecB) { float x = vecB.x - vecA.x; float y = vecB.y - vecA.y; return sqrt((x * x) + (y * y)); } /** * Returns the Squared Euclidian distance of vecA and vecB * No Square Root */ float Util::squaredDistance(glm::vec2 vecA, glm::vec2 vecB) { float x = vecB.x - vecA.x; float y = vecB.y - vecA.y; return (x * x) + (y * y); } /** * Returns the magnitude of a vec2 * */ float Util::magnitude(glm::vec2 vec) { float x = vec.x; float y = vec.y; return sqrt((x * x) + (y * y)); } /** * Returns the squared Magnitude of a vec2 * No Square Root */ float Util::squaredMagnitude(glm::vec2 vec) { float x = vec.x; float y = vec.y; return (x * x) + (y * y); } glm::vec2 Util::limitMagnitude(glm::vec2 vector, float magnitude) { float length = Util::magnitude(vector); if (length > magnitude) { float limiter = magnitude / length; vector.x *= limiter; vector.y *= limiter; return vector; } else { return vector; } } /** * Performs Linear Interpolation between and b * at some t value betwee 0 and 1 * */ float Util::lerp(float a, float b, float t) { return a + (b - a) * Util::clamp01(t); } /** * Lerps between a and b at some t value - unclamped. * */ float Util::lerpUnclamped(float a, float b, float t) { return a + (b - a) * t; } /** * Same as Lerp but makes sure the values interpolate correctly when they wrap around 360 degrees. * */ float Util::lerpAngle(float a, float b, float t) { float num = Util::repeat(b - a, 360.0); if (num > 180.0f) { num -= 360.0f; } return a + num * Util::clamp01(t); } /** * Loops the value t, so that it is never larger than length and never smaller than 0. * */ float Util::repeat(float t, float length) { return Util::clamp(t - glm::floor(t / length) * length, 0.0f, length); } float Util::RandomRange(float min, float max) { return min + static_cast <float> (rand()) / (static_cast <float> (RAND_MAX / (max - min))); } /** * This Utility function checks to see if a number is very small (close to EPSILON) * If so, it changes the value to 0.0; */ float Util::Sanitize(float value) { if ((value >= -Util::EPSILON) && (value <= Util::EPSILON)) { value = 0.0; } return value; } /** * This method computes the minimum values for x and y from vecA and vecB * and returns them in dest or returns the result in a new vec2 * */ glm::vec2 Util::min(glm::vec2 vecA, glm::vec2 vecB) { glm::vec2 dest; dest.x = glm::min(vecA.x, vecB.x); dest.y = glm::min(vecA.y, vecB.y); return dest; } /** * This method computes the maximum values of x and y from vecA and vecB * and returns the result in dest or returns the result as a new vec2 * */ glm::vec2 Util::max(glm::vec2 vecA, glm::vec2 vecB) { glm::vec2 dest; dest.x = glm::max(vecA.x, vecB.x); dest.y = glm::max(vecA.y, vecB.y); return dest; } /** * Negates the x and y components of a vec2 and returns them in a new vec2 object * */ glm::vec2 Util::negate(glm::vec2 vec) { glm::vec2 dest; dest.x = -vec.x; dest.y = -vec.y; return dest; } /** * Returns the inverse x and y components of src vec2 and returns them in a new vec2 object * */ glm::vec2 Util::inverse(glm::vec2 vec) { glm::vec2 dest; dest.x = 1.0 / vec.x; dest.y = 1.0 / vec.y; return dest; } /** * Normalizes vec2 and stores the result in a new vec2 object * */ glm::vec2 Util::normalize(glm::vec2 vec) { glm::vec2 dest; float x = vec.x; float y = vec.y; float length = (x * x) + (y * y); if (length > 0) { length = 1.0 / sqrt(length); dest.x = vec.x * length; dest.y = vec.y * length; } return dest; } /** * Returns the angle in degrees between from and to. */ float Util::angle(glm::vec2 from, glm::vec2 to) { return acos(Util::clamp(Util::dot(Util::normalize(from), Util::normalize(to)), -1.0f, 1.0f)) * 57.29578f; } /** * Dot Product of two vectors. */ float Util::dot(glm::vec2 lhs, glm::vec2 rhs) { return lhs.x * rhs.x + lhs.y * rhs.y; }
0c0f2f24ae4be52831ab9a8262ebe7eca76a1857
d61d05748a59a1a73bbf3c39dd2c1a52d649d6e3
/chromium/content/browser/accessibility/browser_accessibility_auralinux.cc
ad27587491c0a0b33995245fbf75c038df87a1ea
[ "BSD-3-Clause" ]
permissive
Csineneo/Vivaldi
4eaad20fc0ff306ca60b400cd5fad930a9082087
d92465f71fb8e4345e27bd889532339204b26f1e
refs/heads/master
2022-11-23T17:11:50.714160
2019-05-25T11:45:11
2019-05-25T11:45:11
144,489,531
5
4
BSD-3-Clause
2022-11-04T05:55:33
2018-08-12T18:04:37
null
UTF-8
C++
false
false
1,993
cc
// Copyright (c) 2015 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "content/browser/accessibility/browser_accessibility_auralinux.h" #include "content/browser/accessibility/browser_accessibility_manager.h" #include "ui/accessibility/platform/ax_platform_node_auralinux.h" namespace content { BrowserAccessibilityAuraLinux* ToBrowserAccessibilityAuraLinux( BrowserAccessibility* obj) { DCHECK(!obj || obj->IsNative()); return static_cast<BrowserAccessibilityAuraLinux*>(obj); } // static BrowserAccessibility* BrowserAccessibility::Create() { return new BrowserAccessibilityAuraLinux(); } BrowserAccessibilityAuraLinux::BrowserAccessibilityAuraLinux() { node_ = static_cast<ui::AXPlatformNodeAuraLinux*>( ui::AXPlatformNode::Create(this)); } BrowserAccessibilityAuraLinux::~BrowserAccessibilityAuraLinux() { DCHECK(node_); node_->Destroy(); } ui::AXPlatformNodeAuraLinux* BrowserAccessibilityAuraLinux::GetNode() const { return node_; } gfx::NativeViewAccessible BrowserAccessibilityAuraLinux::GetNativeViewAccessible() { DCHECK(node_); return node_->GetNativeViewAccessible(); } void BrowserAccessibilityAuraLinux::OnDataChanged() { BrowserAccessibility::OnDataChanged(); DCHECK(node_); node_->DataChanged(); } void BrowserAccessibilityAuraLinux::UpdatePlatformAttributes() { GetNode()->UpdateHypertext(); } bool BrowserAccessibilityAuraLinux::IsNative() const { return true; } base::string16 BrowserAccessibilityAuraLinux::GetText() const { return GetNode()->AXPlatformNodeAuraLinux::GetText(); } ui::AXPlatformNode* BrowserAccessibilityAuraLinux::GetFromNodeID(int32_t id) { if (!instance_active()) return nullptr; BrowserAccessibility* accessibility = manager_->GetFromID(id); if (!accessibility) return nullptr; return ToBrowserAccessibilityAuraLinux(accessibility)->GetNode(); } } // namespace content
be17cca568c8843f97145426404c8e4fae1d4642
928eef42d591c84714b24326f7cbda32fe63d06e
/hmi_point_skins/control/manager/manager.h
069696e29433e12577001308f224131967eeac72
[]
no_license
ubuntu11/ProjectLibrary
2b11d9bbecd40edd0c40b07e705c1f0af0265526
896c85041818fb8796cbb354b9e300dc4fd8214e
refs/heads/main
2023-07-17T00:31:30.335801
2021-09-02T01:24:45
2021-09-02T01:24:45
null
0
0
null
null
null
null
UTF-8
C++
false
false
7,512
h
๏ปฟ#ifndef MANAGER_H #define MANAGER_H #include "../telltale/telltalesScreen.h" #include "../gauge/GaugeScreen.h" #include "hmi_share.h" class QTimer; class QByteArray; class QObject; class QQuickView; class QThread; class ManagerCustomTimer; class MyShareMemory; class Worker; class Manager : public CBaseScreen, public CSingleton<Manager> { Q_OBJECT friend class CSingleton<Manager>; Q_ENUMS(qmlPowerMode) Q_ENUMS(autoCheck_Status) Q_ENUMS(qmlNaviMapMode) Q_ENUMS(THEME_SETTING) Q_PROPERTY(int receiveCtrlPowerMode READ receiveCtrlPowerMode WRITE setReceiveCtrlPowerMode NOTIFY receiveCtrlPowerModeChanged) Q_PROPERTY(double digitSpeedValue READ getdigitSpeedValue WRITE setdigitSpeedValue NOTIFY digitSpeedValueChanged) Q_PROPERTY(bool hmiVisible READ hmiVisible WRITE setHmiVisible NOTIFY hmiVisibleChanged) Q_PROPERTY(bool rotationSpeedWarning READ rotationSpeedWarning WRITE setRotationSpeedWarning NOTIFY rotationSpeedWarningChanged) Q_PROPERTY(bool hmiScreenState READ hmiScreenState WRITE setHmiScreenState NOTIFY hmiScreenStateChanged) Q_PROPERTY(bool enterAnimStart READ enterAnimStart WRITE setEnterAnimStart NOTIFY enterAnimStartChanged) Q_PROPERTY(bool isLoaderOver READ isLoaderOver WRITE setIsLoaderOver NOTIFY isLoaderOverChanged) Q_PROPERTY(bool isCharging READ isCharging WRITE setIsCharging NOTIFY isChargingChanged) Q_PROPERTY(QVariant navigationMapMod READ navigationMapMod WRITE setNavigationMapMod NOTIFY navigationMapModChanged) Q_PROPERTY(QVariant themeSetting READ themeSetting WRITE setThemeSetting NOTIFY themeSettingChanged) public: enum qmlPowerMode {// ็”ตๆบ QML_POWERMODE_ANIMATION = 0, // Opening QML_POWERMODE_D1, QML_POWERMODE_D2, QML_POWERMODE_D3, }; enum autoCheck_Status{ // ่‡ชๆฃ€ AUTOCHECK_INIT = 0, // ๅˆๅง‹ๅ€ผ AUTOCHECK_START, // ่‡ชๆฃ€ๅผ€ๅง‹ AUTOCHECK_END // ่‡ชๆฃ€็ป“ๆŸ }; enum qmlNaviMapMode{ SMALL_MAP = 0, //ๅฐๅœฐๅ›พ BIG_MAP, //ๅคงๅœฐๅ›พ AR_MAP, //ARๅœฐๅ›พ MAP_MODE_MAX }; enum THEME_SETTING { NONE = 0x00, //ไธŠไธ€ๆฌก้ป˜่ฎคๅ€ผ COMFORT, //่ˆ’้€‚ไธป้ข˜ ECO,//็ปๆตŽไธป้ข˜ SPORT ,//่ฟๅŠจไธป้ข˜ INDIVIDUAL, //่‡ชๅฎšไน‰ไธป้ข˜ MAXTHEM }; virtual void startControl(); Manager(); ~Manager(); void createCtrl(QQuickView *view); void requstAllEEPROMDATAon1stPowerUp(void); void handleAutoCheck(); Worker * m_worker; int receiveCtrlPowerMode() const { return m_receiveCtrlPowerMode; } double getdigitSpeedValue() const { return m_digitSpeedValue; } bool hmiVisible() const { return m_hmiVisible; } bool rotationSpeedWarning() const { return m_rotationSpeedWarning; } bool hmiScreenState() const { return m_hmiScreenState; } bool enterAnimStart() const { return m_enterAnimStart; } bool isLoaderOver() const { return m_isLoaderOver; } bool isCharging() const { return m_isCharging; } QVariant navigationMapMod() const { return m_navigationMapMod; } QVariant themeSetting() const { return m_themeSetting; } signals: void receiveDateFromOtherProcessSignal(QString name, QVariant value); void receiveCtrlPowerModeChanged(int receiveCtrlPowerMode); void digitSpeedValueChanged(double digitSpeedValue); void hmiVisibleChanged(bool hmiVisible); void rotationSpeedWarningChanged(bool rotationSpeedWarning); void hmiScreenStateChanged(bool hmiScreenState); void enterAnimStartChanged(bool enterAnimStart); void isLoaderOverChanged(bool isLoaderOver); void isChargingChanged(bool isCharging); void navigationMapModChanged(QVariant navigationMapMod); void themeSettingChanged(QVariant themeSetting); public slots: void qmlPrintLog(QString log); void qmlPrintValueLog(QString key,QString value); void get_timeout10ms(); void get_timeout100ms(); void get_timeout500ms(); void sendToOtherCtrlP(QString message_key, QVariant message_value); void sendToOtherProcessP(QString name, QVariant value); void receiveDateFromOtherProcess(QString data); void notify_cluster_manager(QString state); void selfReceiveDateFromOtherProcessSignal(QString name, QVariant value); void setReceiveCtrlPowerMode(int receiveCtrlPowerMode) { if (m_receiveCtrlPowerMode == receiveCtrlPowerMode) return; m_receiveCtrlPowerMode = receiveCtrlPowerMode; emit receiveCtrlPowerModeChanged(m_receiveCtrlPowerMode); } void setdigitSpeedValue(double digitSpeedValue) { if (m_digitSpeedValue == digitSpeedValue) return; m_digitSpeedValue = digitSpeedValue; emit digitSpeedValueChanged(m_digitSpeedValue); } void setHmiVisible(bool hmiVisible) { if (m_hmiVisible == hmiVisible) return; m_hmiVisible = hmiVisible; emit hmiVisibleChanged(m_hmiVisible); } void setRotationSpeedWarning(bool rotationSpeedWarning) { if (m_rotationSpeedWarning == rotationSpeedWarning) return; m_rotationSpeedWarning = rotationSpeedWarning; emit rotationSpeedWarningChanged(m_rotationSpeedWarning); } void setHmiScreenState(bool hmiScreenState) { if (m_hmiScreenState == hmiScreenState) return; m_hmiScreenState = hmiScreenState; emit hmiScreenStateChanged(m_hmiScreenState); } void setEnterAnimStart(bool enterAnimStart) { if (m_enterAnimStart == enterAnimStart) return; m_enterAnimStart = enterAnimStart; emit enterAnimStartChanged(m_enterAnimStart); } void setIsLoaderOver(bool isLoaderOver) { if (m_isLoaderOver == isLoaderOver) return; g_loaderOver = m_isLoaderOver = isLoaderOver; emit isLoaderOverChanged(m_isLoaderOver); // handleAutoCheck(); } void setIsCharging(bool isCharging) { if (m_isCharging == isCharging) return; m_isCharging = isCharging; emit isChargingChanged(m_isCharging); } void setNavigationMapMod(QVariant navigationMapMod) { if (m_navigationMapMod == navigationMapMod) return; m_navigationMapMod = navigationMapMod; emit navigationMapModChanged(m_navigationMapMod); } void setThemeSetting(QVariant themeSetting) { if (m_themeSetting == themeSetting) return; m_themeSetting = themeSetting; emit themeSettingChanged(m_themeSetting); } private: QQuickView* m_view; int m_receiveCtrlPowerMode; TelltalesControl* _TelltalesControl; GaugeControl* _GaugeControl; MyShareMemory* _MyShareMemory; double m_digitSpeedValue; bool m_hmiVisible; bool m_rotationSpeedWarning; bool m_hmiScreenState; bool m_enterAnimStart; void updatePointScreen(); bool m_isLoaderOver; bool g_loaderOver; // HMICustomTimer* acTimer; bool m_isCharging; QVariant m_navigationMapMod; QVariant m_themeSetting; }; Q_DECLARE_METATYPE(Manager::qmlPowerMode) Q_DECLARE_METATYPE(Manager::autoCheck_Status) #endif // MANAGER_H
b32fa1f6eb22bb956259256ffa49fcda7d38165b
5456502f97627278cbd6e16d002d50f1de3da7bb
/storage/browser/quota/quota_client.h
5eb0d32f89d104c34553d3b75aec89a8e2faf411
[ "BSD-3-Clause" ]
permissive
TrellixVulnTeam/Chromium_7C66
72d108a413909eb3bd36c73a6c2f98de1573b6e5
c8649ab2a0f5a747369ed50351209a42f59672ee
refs/heads/master
2023-03-16T12:51:40.231959
2017-12-20T10:38:26
2017-12-20T10:38:26
null
0
0
null
null
null
null
UTF-8
C++
false
false
3,049
h
// Copyright 2013 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef STORAGE_BROWSER_QUOTA_QUOTA_CLIENT_H_ #define STORAGE_BROWSER_QUOTA_QUOTA_CLIENT_H_ #include <stdint.h> #include <list> #include <set> #include <string> #include "base/callback.h" #include "storage/browser/storage_browser_export.h" #include "storage/common/quota/quota_types.h" #include "url/gurl.h" namespace storage { // An abstract interface for quota manager clients. // Each storage API must provide an implementation of this interface and // register it to the quota manager. // All the methods are assumed to be called on the IO thread in the browser. class STORAGE_EXPORT QuotaClient { public: typedef base::Callback<void(int64_t usage)> GetUsageCallback; typedef base::Callback<void(const std::set<GURL>& origins)> GetOriginsCallback; typedef base::Callback<void(QuotaStatusCode status)> DeletionCallback; virtual ~QuotaClient() {} enum ID { kUnknown = 1 << 0, kFileSystem = 1 << 1, kDatabase = 1 << 2, kAppcache = 1 << 3, kIndexedDatabase = 1 << 4, kServiceWorkerCache = 1 << 5, kServiceWorker = 1 << 6, kAllClientsMask = -1, }; virtual ID id() const = 0; // Called when the quota manager is destroyed. virtual void OnQuotaManagerDestroyed() = 0; // Called by the QuotaManager. // Gets the amount of data stored in the storage specified by // |origin_url| and |type|. // Note it is safe to fire the callback after the QuotaClient is destructed. virtual void GetOriginUsage(const GURL& origin_url, StorageType type, const GetUsageCallback& callback) = 0; // Called by the QuotaManager. // Returns a list of origins that has data in the |type| storage. // Note it is safe to fire the callback after the QuotaClient is destructed. virtual void GetOriginsForType(StorageType type, const GetOriginsCallback& callback) = 0; // Called by the QuotaManager. // Returns a list of origins that match the |host|. // Note it is safe to fire the callback after the QuotaClient is destructed. virtual void GetOriginsForHost(StorageType type, const std::string& host, const GetOriginsCallback& callback) = 0; // Called by the QuotaManager. // Note it is safe to fire the callback after the QuotaClient is destructed. virtual void DeleteOriginData(const GURL& origin, StorageType type, const DeletionCallback& callback) = 0; virtual bool DoesSupport(StorageType type) const = 0; }; // TODO(dmikurube): Replace it to std::vector for efficiency. typedef std::list<QuotaClient*> QuotaClientList; } // namespace storage #endif // STORAGE_BROWSER_QUOTA_QUOTA_CLIENT_H_
81fed43d4e4ba75093784bdb6f3163af1f353a1e
0518e53526c214da6142d940c42a428ec7d58122
/CWE-119/source_files/1493/Figure2-9-windows.cpp
635748c01f06b3a366aa453f175bcc78445d0393
[ "Apache-2.0" ]
permissive
Adam-01/VulDeePecker
eb03cfa2b94d736b1cba17fb1cdcb36b01e18f5e
98610f3e116df97a1e819ffc81fbc7f6f138a8f2
refs/heads/master
2023-03-21T07:37:26.904949
2020-11-17T19:40:13
2020-11-17T19:40:13
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,283
cpp
/* * * Copyright (c) 2005 Carnegie Mellon University. * All rights reserved. * Permission to use this software and its documentation for any purpose is hereby granted, * provided that the above copyright notice appear and that both that copyright notice and * this permission notice appear in supporting documentation, and that the name of CMU not * be used in advertising or publicity pertaining to distribution of the software without * specific, written prior permission. * * CMU DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES * OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL CMU BE LIABLE FOR ANY SPECIAL, INDIRECT OR * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, RISING OUT OF OR IN * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ #include <iostream> bool IsPasswordOkay(void) { char Password[12]; gets(Password); if (!strcmp(Password, "goodpass")) return(true); else return(false); } void main() { bool PwStatus; puts("Enter password:"); PwStatus = IsPasswordOkay(); if (PwStatus == false){ puts("Access denied"); exit(-1); } else puts("Access granted"); }
[ "็Ž‹่‹่ฒ" ]
็Ž‹่‹่ฒ
54d73055a239b76d428aa4d099f671e1f69fc3c3
b38a71daf368c26414bc89925a33917842e0504e
/include/morton/morton.h
8bdff74b63b3700e525f8f474f42e7096a4f9c1a
[ "MIT" ]
permissive
tmpvar/rawkit
6884f4f9f5d97bed03350361ac24eb493dbc3e2b
0dee2bdf9e11e9033988a0d9d1e52603263c6aca
refs/heads/master
2023-06-19T15:44:19.770373
2021-11-01T23:30:45
2021-11-01T23:31:34
286,560,098
15
0
MIT
2020-10-08T23:11:33
2020-08-10T19:19:46
C++
UTF-8
C++
false
false
5,056
h
#pragma once // This file will always contain inline functions which point to the fastest Morton encoding/decoding implementation // IF you just want to use the fastest method to encode/decode morton codes, include this header. // If you want to experiment with alternative methods (which might be slower, all depending on hardware / your data set) // check the individual headers below. #include "morton2D.h" #include "morton3D.h" #if defined(__BMI2__) || (defined(__AVX2__) && defined(_MSC_VER)) #include "morton_BMI.h" #elif defined(__AVX512BITALG__) #include "morton_AVX512BITALG.h" #endif namespace libmorton { // Functions under this are stubs which will always point to fastest implementation at the moment //----------------------------------------------------------------------------------------------- // ENCODING #if defined(__BMI2__) || (defined(__AVX2__) && defined(_MSC_VER)) inline uint_fast32_t morton2D_32_encode(const uint_fast16_t x, const uint_fast16_t y) { return m2D_e_BMI<uint_fast32_t, uint_fast16_t>(x, y); } inline uint_fast64_t morton2D_64_encode(const uint_fast32_t x, const uint_fast32_t y) { return m2D_e_BMI<uint_fast64_t, uint_fast32_t>(x, y); } inline uint_fast32_t morton3D_32_encode(const uint_fast16_t x, const uint_fast16_t y, const uint_fast16_t z) { return m3D_e_BMI<uint_fast32_t, uint_fast16_t>(x, y, z); } inline uint_fast64_t morton3D_64_encode(const uint_fast32_t x, const uint_fast32_t y, const uint_fast32_t z) { return m3D_e_BMI<uint_fast64_t, uint_fast32_t>(x, y, z); } #elif defined(__AVX512BITALG__) inline uint_fast32_t morton2D_32_encode(const uint_fast16_t x, const uint_fast16_t y) { return m2D_e_BITALG<uint_fast32_t, uint_fast16_t>(x, y); } inline uint_fast64_t morton2D_64_encode(const uint_fast32_t x, const uint_fast32_t y) { return m2D_e_BITALG<uint_fast64_t, uint_fast32_t>(x, y); } inline uint_fast32_t morton3D_32_encode(const uint_fast16_t x, const uint_fast16_t y, const uint_fast16_t z) { return m3D_e_BITALG<uint_fast32_t, uint_fast16_t>(x, y, z); } inline uint_fast64_t morton3D_64_encode(const uint_fast32_t x, const uint_fast32_t y, const uint_fast32_t z) { return m3D_e_BITALG<uint_fast64_t, uint_fast32_t>(x, y, z); } #else inline uint_fast32_t morton2D_32_encode(const uint_fast16_t x, const uint_fast16_t y) { return m2D_e_sLUT<uint_fast32_t, uint_fast16_t>(x, y); } inline uint_fast64_t morton2D_64_encode(const uint_fast32_t x, const uint_fast32_t y) { return m2D_e_sLUT<uint_fast64_t, uint_fast32_t>(x, y); } inline uint_fast32_t morton3D_32_encode(const uint_fast16_t x, const uint_fast16_t y, const uint_fast16_t z) { return m3D_e_sLUT<uint_fast32_t, uint_fast16_t>(x, y, z); } inline uint_fast64_t morton3D_64_encode(const uint_fast32_t x, const uint_fast32_t y, const uint_fast32_t z) { return m3D_e_sLUT<uint_fast64_t, uint_fast32_t>(x, y, z); } #endif // DECODING #if defined(__BMI2__) || (defined(__AVX2__) && defined(_MSC_VER)) inline void morton2D_32_decode(const uint_fast32_t morton, uint_fast16_t& x, uint_fast16_t& y) { m2D_d_BMI<uint_fast32_t, uint_fast16_t>(morton, x, y); } inline void morton2D_64_decode(const uint_fast64_t morton, uint_fast32_t& x, uint_fast32_t& y) { m2D_d_BMI<uint_fast64_t, uint_fast32_t>(morton, x, y); } inline void morton3D_32_decode(const uint_fast32_t morton, uint_fast16_t& x, uint_fast16_t& y, uint_fast16_t& z) { m3D_d_BMI<uint_fast32_t, uint_fast16_t>(morton, x, y, z); } inline void morton3D_64_decode(const uint_fast64_t morton, uint_fast32_t& x, uint_fast32_t& y, uint_fast32_t& z) { m3D_d_BMI<uint_fast64_t, uint_fast32_t>(morton, x, y, z); } #elif defined(__AVX512BITALG__) inline void morton2D_32_decode(const uint_fast32_t morton, uint_fast16_t& x, uint_fast16_t& y) { m2D_d_BITALG<uint_fast32_t, uint_fast16_t>(morton, x, y); } inline void morton2D_64_decode(const uint_fast64_t morton, uint_fast32_t& x, uint_fast32_t& y) { m2D_d_BITALG<uint_fast64_t, uint_fast32_t>(morton, x, y); } inline void morton3D_32_decode(const uint_fast32_t morton, uint_fast16_t& x, uint_fast16_t& y, uint_fast16_t& z) { m3D_d_BITALG<uint_fast32_t, uint_fast16_t>(morton, x, y, z); } inline void morton3D_64_decode(const uint_fast64_t morton, uint_fast32_t& x, uint_fast32_t& y, uint_fast32_t& z) { m3D_d_BITALG<uint_fast64_t, uint_fast32_t>(morton, x, y, z); } #else inline void morton2D_32_decode(const uint_fast32_t morton, uint_fast16_t& x, uint_fast16_t& y) { m2D_d_sLUT<uint_fast32_t, uint_fast16_t>(morton, x, y); } inline void morton2D_64_decode(const uint_fast64_t morton, uint_fast32_t& x, uint_fast32_t& y) { m2D_d_sLUT<uint_fast64_t, uint_fast32_t>(morton, x, y); } inline void morton3D_32_decode(const uint_fast32_t morton, uint_fast16_t& x, uint_fast16_t& y, uint_fast16_t& z) { m3D_d_sLUT<uint_fast32_t, uint_fast16_t>(morton, x, y, z); } inline void morton3D_64_decode(const uint_fast64_t morton, uint_fast32_t& x, uint_fast32_t& y, uint_fast32_t& z) { m3D_d_sLUT<uint_fast64_t, uint_fast32_t>(morton, x, y, z); } #endif }
dedf2936c43bfbc38e7884450d15fdf235c9eb42
6d1f7dda09282da41e49b57a93757f7320446a3c
/include/threads.hpp
60eff494b7e386578e621e08676de7f898e373ea
[]
no_license
yuan-xiong/xy-opencv-opencl
9c097122c4119d8d65b124a986dbe6214dd2b299
bc73459f33afe9857d0e24a386d77b8842adc142
refs/heads/master
2023-03-29T03:55:33.129624
2021-03-31T07:03:40
2021-03-31T07:04:14
347,586,763
0
0
null
null
null
null
UTF-8
C++
false
false
96
hpp
#include <thread> const int M = 1000 * 1000; const int N = 1000; void threadCallback(int *i);
bcf4a211d7d8d290a6b44058975525d6507fdc7e
61f81f1d0c79a06ea7acfbfabd8c76bd4a5355e0
/OpenWAM/Source/Boundaries/BoundaryCondition.cpp
3b32a967e42ba73847a98f3e529da289a6553143
[]
no_license
Greeeder/Program
8e46d46fea6afd61633215f4e8f6fd327cc0731f
b983df23d18a7d05a7fab693e7a9a3af067d48a5
refs/heads/master
2020-05-21T22:15:32.244096
2016-12-02T08:38:05
2016-12-02T08:38:08
63,854,561
3
0
null
null
null
null
UTF-8
C++
false
false
4,472
cpp
/* --------------------------------------------------------------------------------*\ ==========================| \\ /\ /\ // O pen | OpenWAM: The Open Source 1D Gas-Dynamic Code \\ | X | // W ave | \\ \/_\/ // A ction | CMT-Motores Termicos / Universidad Politecnica Valencia \\/ \// M odel | ---------------------------------------------------------------------------------- License This file is part of OpenWAM. OpenWAM is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. OpenWAM is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenWAM. If not, see <http://www.gnu.org/licenses/>. \*--------------------------------------------------------------------------------*/ /** * \file BoundaryCondition.cpp * \author Francisco Jose Arnau <[email protected]> * \author Luis Miguel Garcia-Cuevas Gonzalez <[email protected]> * * \section LICENSE * * This file is part of OpenWAM. * * OpenWAM is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * OpenWAM is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with OpenWAM. If not, see <http://www.gnu.org/licenses/>. * * \section DESCRIPTION * This file defines a basic boundary condition. */ #include "BoundaryCondition.hpp" TBoundaryCondition::TBoundaryCondition() { FCurrentTime = 0.; FPressure = 1E5; FSpeed = 0.; FSpeedOfSound = __cons::ARef; FTemperature = __cons::TRef; FFlux_0.setZero(3, 1); } TBoundaryCondition::TBoundaryCondition(const Pipe_ptr & pipe_0, nmPipeEnd pipe_end): TBoundaryCondition() { FPipe_0 = pipe_0.get(); FCurrentTime = pipe_0->getCurrentTime(); FPipeEnd_0 = pipe_end; if(FPipeEnd_0 == nmLeft) { FCell_0 = 0; } else { FCell_0 = pipe_0->getPressure().cols() - 1; } } TBoundaryCondition::TBoundaryCondition(const TFlowObject_ptr & pipe_0, nmPipeEnd pipe_end) : TBoundaryCondition() { FlowObj = pipe_0.get(); FCurrentTime = pipe_0->getCurrentTime(); FPipeEnd_0 = pipe_end; if (FPipeEnd_0 == nmLeft) { FCell_0 = 0; } else { FCell_0 = pipe_0->getNin() - 1; } } TBoundaryCondition::TBoundaryCondition(const TFlowObject_ptr & zerod, int con_id) : TBoundaryCondition() { FlowObj = zerod.get(); FCurrentTime = zerod->getCurrentTime(); FCon_Index = con_id; } TBoundaryCondition::~TBoundaryCondition() {} double TBoundaryCondition::getArea() const { return FArea; } double TBoundaryCondition::getBeta() const { return FBeta; } double TBoundaryCondition::getEnthalpyFlow() const { return FFlux_0(2) * getArea(); } double TBoundaryCondition::getEntropy() const { return FEntropy; } double TBoundaryCondition::getLambda() const { return FLambda; } double TBoundaryCondition::getMassFlow() const { return FFlux_0(0) * getArea(); } double TBoundaryCondition::getPressure() const { return FPressure; } double TBoundaryCondition::getSpeed() const { return FSpeed; } double TBoundaryCondition::getTemperature() const { return FTemperature; } void TBoundaryCondition::setBeta(double beta) { FBeta = beta; } void TBoundaryCondition::setEntropy(double entropy) { FEntropy = entropy; } void TBoundaryCondition::setLambda(double lambda) { FLambda = lambda; } void TBoundaryCondition::computePTUFromCharacteristics(double t, double dt) { FCurrentTime = t; updateBCCharacteristics(t, dt); /* TODO: Gamma(T)! */ double g = __Gamma::G; FSpeedOfSound = (getLambda() + getBeta()) / 2. * __cons::ARef; FSpeed = (getLambda() - getBeta()) / __Gamma::G1(g) * __cons::ARef; FPressure = __units::BarToPa(pow(FSpeedOfSound / __cons::ARef / FEntropy, __Gamma::G4(g))); FTemperature = pow2(FSpeedOfSound) / g / __R::Air; }
44d29115a4178a8615ed9dd06107d7906cf2b64e
0abb6aef68b81b6d616658e408ee2979a6104798
/3053.cpp
35e00b29e71385caa7df7fb7d20fef4e6545251b
[]
no_license
seongwpa/PS
c44b44691a4038dc326a9198d373629f86bf6dc6
3f77020becf5eb989cc146b63d550b461af02dbd
refs/heads/master
2022-10-08T20:39:09.352637
2020-06-08T08:21:15
2020-06-08T08:21:15
270,530,344
0
0
null
null
null
null
UTF-8
C++
false
false
190
cpp
#define _CRT_SECURE_NO_WARNINGS #include<stdio.h> #define PI 3.14159265358979323 int main() { int n; double sq; scanf("%d", &n); sq = 2 * n*n; printf("%f\n%f", n*n*PI, sq); }
f61e2c7bb871f18f6d0089a1ce8f722c72edf5b6
85a38fa6429d34781af6ff828913ac9cb8e3fcd2
/IR_Sensor/IR_Sensor.ino
8f3eca90d50dc67956fa012cfc3f94ccfcda24ec
[]
no_license
dhappleg/RollerBottle
27063840ea8273156d01d0580341e3d79cb848e7
05c4e91f0934241b24eedad51ebf6ee4774e628b
refs/heads/master
2021-05-12T02:37:27.997968
2018-12-06T15:40:42
2018-12-06T15:40:42
117,595,488
0
0
null
null
null
null
UTF-8
C++
false
false
5,746
ino
#include <LiquidCrystal.h> #define _HALL_SENSOR_ 0 // on interrupt 1 pin 3 #define _MODE_ 9 #define _PLUS_ 10 #define _MINUS_ 11 #define _MAX_SPIN_SPEED_ 120 // used for blinking the LED on pin 13 int ledOn = 0; volatile byte rpmCount; unsigned int rpm = 0; int mode = 0; int oldDispTime = 0; unsigned long lastInputTime = 0; int previousPlus = 0; int previousMinus = 0; int desiredSpinSpeed = 60; int mappedRPM = 6; unsigned long timeOld; int loopCounter = 0; // declare LCD Device LiquidCrystal lcd(13, 12, 4, 5, 6, 7); /* * used for the stepper motor */ void enableTimer() { noInterrupts(); TCCR0A = 0;// set entire TCCR0A register to 0 TCCR0B = 0;// same for TCCR0B TCNT0 = 0;//initialize counter value to 0 // set compare match register for 2khz increments OCR0A = 124;// = (16*10^6) / (2000*64) - 1 (must be <256) // turn on CTC mode TCCR0A |= (1 << WGM01); // Set CS01 and CS00 bits for 64 prescaler TCCR0B |= (1 << CS01) | (1 << CS00); // enable timer compare interrupt TIMSK0 |= (1 << OCIE0A); interrupts(); } ISR(TIMER0_COMPA_vect) { digitalWrite(8, HIGH); digitalWrite(8, LOW); } void setup() { Serial.begin(115200); // setup display for output/clear it lcd.begin(16, 2); lcd.print("Initializing..."); pinMode(8, OUTPUT); pinMode(LED_BUILTIN, OUTPUT); pinMode(_MODE_, INPUT); pinMode(_PLUS_, INPUT); pinMode(_MINUS_, INPUT); //enableTimer(); attachInterrupt(_HALL_SENSOR_, irInterrupt, FALLING); rpm = 0; timeOld = 0; delay(1000); } void loop() { rpmCalculation(); pollingLoop(); if( ((millis() - lastInputTime) > 5000) && (lastInputTime != 0) ) { lastInputTime = 0; mode = 0; } if(oldDispTime > 2000) { oldDispTime = 0; update_display(); } //if(loopCounter > 9) { //loopCounter = 0; //digitalWrite(8, HIGH); // delayMicroseconds(10); //delayMicroseconds(90); // digitalWrite(8, LOW); //} /*mappedRPM = desiredSpinSpeed; if(loopCounter <= 1) { digitalWrite(8, HIGH); } else { if(loopCounter > mappedRPM) { digitalWrite(8, LOW); loopCounter = 0; } } loopCounter++; */ //delayMicroseconds(90); loopCounter++; oldDispTime++; } void rpmCalculation() { detachInterrupt(_HALL_SENSOR_); rpm = 30*1000/(millis() - timeOld) * rpmCount; timeOld = millis(); rpmCount = 0; attachInterrupt(_HALL_SENSOR_, irInterrupt, FALLING); } void irInterrupt() { //toggleOnBoardLED(); rpmCount++; } void toggleOnBoardLED() { (ledOn == 1) ? digitalWrite(LED_BUILTIN, HIGH) : digitalWrite(LED_BUILTIN, LOW); (ledOn == 1) ? ledOn = 0 : ledOn = 1; } /* * Poll the buttons and control the LCD display */ void pollingLoop() { // listen for mode button if( (millis() - lastInputTime) > 470) { if(digitalRead(_MODE_) == 1) { lastInputTime = millis(); // set last input if(mode >= 1) { mode = 0; } mode += 1; } // listen for increase button if(digitalRead(_PLUS_) == 1) { previousPlus++; lastInputTime = millis(); // set last input switch(mode) { case 1: // increase the desired spin speed if(previousPlus >= 5) { desiredSpinSpeed += 10; } else { desiredSpinSpeed += 1; } if (desiredSpinSpeed >= _MAX_SPIN_SPEED_) { desiredSpinSpeed = _MAX_SPIN_SPEED_; } break; // case 2: // increasing the desired tilt speed // desiredTiltSpeed += 1; // if(desiredTiltSpeed > _MAX_TILT_SPEED_) { // desiredTiltSpeed = _MAX_TILT_SPEED_; // } // break; // case 3: // increasing the desired tilt angle // desiredTiltAngle += 1; // if(desiredTiltAngle > _MAX_TILT_ANGLE_) { // desiredTiltAngle = _MAX_TILT_ANGLE_; // } // break; } } else { previousPlus = 0; } // listen for decrease button if(digitalRead(_MINUS_) == 1) { previousMinus++; lastInputTime = millis(); // set last input switch(mode) { case 1: // set spin speed if (previousMinus >= 5) { desiredSpinSpeed -=10; } else { desiredSpinSpeed -= 1; } if(desiredSpinSpeed < 0) { desiredSpinSpeed = 0; } break; // case 2: // decreasing the desired tilt speed // desiredTiltSpeed -=1; // if(desiredTiltSpeed < 0) { // desiredTiltSpeed = 0; // } // break; // // case 3: // decreasing the desired tilt angle // desiredTiltAngle -= 1; // if(desiredTiltAngle < 0) { // desiredTiltAngle = 0; // } // break; } } else { previousMinus = 0; } } } /* * Update the display to the current mode that is being used */ void update_display() { lcd.clear(); switch(mode) { case 0: // running/sensing mode lcd.print("RPM:"); lcd.setCursor(5, 0); lcd.print((String) rpm); lcd.setCursor(0,1); lcd.print("DEG:"); lcd.setCursor(5,1); lcd.print("--.-"); lcd.print((char)223); // degree symbol break; case 1: // update speed mode lcd.print("Desired RPM"); lcd.setCursor(0,1); lcd.print((String) desiredSpinSpeed); break; // case 2: // update tilt speed mode // lcd.print("Desired Tilt CPM"); // lcd.setCursor(0,1); // lcd.print((String) desiredTiltSpeed); // break; // // case 3: // update tilt angle // lcd.print("Desired Tilt Angle"); // lcd.setCursor(0,1); // lcd.print((String) desiredTiltAngle); // lcd.print((char)223); // degree symbol // break; } //delay(470); }
21c81b2fd01ea17645eb3388f13f1b524b5dc6cc
1f6b279a16bbd11f34a025b6af81e8924411d682
/S_LIFsynapse.hpp
5a5ae9cf65d6b9ed8f2b32d2bcf4515ad26bd16a
[]
no_license
hamborger/lifk
e200e23f31cb812100f301cd215bb708b17aa77f
cda3d982eaa1154cb89c193c4d6063f4f0db9517
refs/heads/master
2021-01-20T04:32:41.527605
2015-03-24T10:33:05
2015-03-24T10:33:05
31,659,593
0
0
null
null
null
null
UTF-8
C++
false
false
3,338
hpp
/* synapse/S_DefaultSynapse.hpp - Default non-specialized synapse with last spike logic Copyright (C) 2014 Pranav Kulkarni, Collins Assisi Lab, IISER, Pune <[email protected]> This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. */ #ifndef INCLUDED_S_LIFSYNAPSE_HPP #define INCLUDED_S_LIFSYNAPSE_HPP #include "my_data_store.hpp" #include "core/engine.hpp" #include <cmath> namespace insilico { class S_LIFsynapse { public: static void ode_set(const state_type& variables, state_type& dxdt, const double t, int index) { //cout<<"SYNAPSE CLASS:\n"; //debug int g1_index = engine::synapse_index(index, "g1"); int g2_index = engine::synapse_index(index, "g2"); double g1 = variables[g1_index]; double g2 = variables[g2_index]; // synapse logic for delay for recently spiked neuron double xt = 0.0; double delay = engine::synapse_value(index, "delay"); int neuron_index = engine::synapse_value(index, "pre"); double last_spike = engine::neuron_value(neuron_index, "last_spike"); double spiked = engine::neuron_value(neuron_index, "spike"); double thresh = engine::synapse_value(index, "thresh"); if (std::ceil(spiked) == std::ceil(thresh)){ engine::neuron_value(neuron_index, "last_spike",t); } double utilized_spike = engine::synapse_value(index, "us"); std::vector<double> stlist = data_store::spike_time_list[neuron_index]; for(double time : stlist) { if(t - time >= 5.0 && utilized_spike < time) { xt = 1.0; engine::synapse_value(index,"us", time); break; } } /*if ((t - last_spiked > delay) && (spiked == 1)){ //if((t - last_spiked) <= delay){ xt = 1.0; } else xt = 0.0; */ //cout<<"time:"<<t<<"\tindex:"<<index<<"\tneuron_index:"<<neuron_index<<"\tNumber of spikes:"<<spiked<<endl; //debug // constants from file double tau_psp = engine::synapse_value(index, "tau_psp"); double gsyn = engine::synapse_value(index, "gsyn"); // ODE set //cout<<"time:"<<t<<"\tg1:"<<g1<<"\tg2:"<<g2<<"\tf(g1,g2):"<<-(2*tau_psp*g2+g1-gsyn*xt)/(tau_psp*tau_psp)<<endl; //debug //cout<<g1<<","<<g2<<","<<-(2*tau_psp*g2+g1-gsyn*xt)/(tau_psp*tau_psp)<<"\n"; //debug dxdt[g1_index] = g2; dxdt[g2_index] =-(2*tau_psp*g2+g1-gsyn*xt)/(tau_psp*tau_psp); /*if (xt==1){ //cout<<"time:"<<t<<"\tindex:"<<index<<"\tneuron_index:"<<neuron_index<<"\tbow-wow (Activated):"<<xt<<endl; //debug } else*/ //cout<<"time:"<<t<<"\tindex:"<<index<<"\tneuron_index:"<<neuron_index<<"\tmeow (Not Activated):"<<xt<<endl; //debug } // function ode_set }; // class S_LIFsynapse } // insilico #endif
41d0b02550b395c70ddd74b031b468a729ab14c8
7b8ff457116a7fb4c12fd54db562e2d0395d1daa
/shumi/competive_programing/tree.cpp
1fba9806742dac1d6ee7676e111f1d7f63bd14dd
[]
no_license
jecht1014/book
852a7dd0cac0fc0a5a83341cd5d90c5286e7d33d
77d775166979739a68f6771434b50d8213abe95f
refs/heads/master
2023-03-05T12:26:08.337948
2023-02-25T12:56:27
2023-02-25T12:56:27
205,245,904
0
1
null
null
null
null
UTF-8
C++
false
false
9,048
cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; class Node { public: vector<int> children; vector<int> edge_value; int value; int parent; }; class Tree { public: int root; int node_num; vector<Node> node; Tree(vector<vector<int>> edge, int r) { root = r; node_num = edge.size(); node = vector<Node>(edge.size()); queue<int> v; v.push(root); node[root].parent = -1; int edge_num = 0; while(!v.empty()) { int tyoten = v.front(); node[tyoten].value = tyoten; v.pop(); for (int i = 0; i < edge[tyoten].size(); i++) { int child = edge[tyoten][i]; if (child != node[tyoten].parent) { node[tyoten].children.push_back(child); node[tyoten].edge_value.push_back(edge_num); edge_num++; node[child].parent = tyoten; v.push(child); } } } } // ้‡ใฟไป˜ใ่พบๆœ‰ Tree(vector<vector<int>> edge, vector<vector<long long>> w, int r) { root = r; node_num = edge.size(); node = vector<Node>(edge.size()); queue<int> v; v.push(root); node[root].parent = -1; while(!v.empty()) { int tyoten = v.front(); node[tyoten].value = tyoten; v.pop(); for (int i = 0; i < edge[tyoten].size(); i++) { int child = edge[tyoten][i]; if (child != node[tyoten].parent) { node[tyoten].children.push_back(child); node[tyoten].edge_value.push_back(w[tyoten][i]); node[child].parent = tyoten; v.push(child); } } } } }; // 2ใคใฎ้ ‚็‚นใ‚’ๅ…ฅๅŠ›ใจใ—ใฆไธŽใˆใ‚‹ใ“ใจใงใ€ๆœ€่ฟ‘ๅ…ฑ้€š็ฅ–ๅ…ˆ(lca)ใ‚’ๆฑ‚ใ‚ใ‚‹ int lca(Tree tree, pair<int, int> uv) { if (uv.first == tree.root || uv.second == tree.root) return tree.root; else { set<int> parent_set{uv.first}; int parent = uv.first; while(parent != tree.root) { parent = tree.node[parent].parent; parent_set.insert(parent); } parent = uv.second; while(parent != tree.root) { if (parent_set.count(parent)) return parent; parent = tree.node[parent].parent; } } } // ใƒซใƒผใƒˆใ‹ใ‚‰้ ‚็‚นใพใงใฎ่พบใฎ็ดฏ็ฉๅ’Œ(่ซ–็†ๅ’Œ) vector<set<pair<int, int>>> tree_edge_partial_set(Tree tree) { vector<set<pair<int, int>>> partial_set(tree.node_num); queue<Node> value; value.push(tree.node[tree.root]); queue<set<pair<int, int>>> value_set; value_set.push(set<pair<int, int>>({})); while(!value.empty()) { Node v = value.front(); set<pair<int, int>> v_set = value_set.front(); value.pop(); value_set.pop(); partial_set[v.value] = v_set; for (int i = 0; i < v.children.size(); i++) { value.push(tree.node[v.children[i]]); set<pair<int, int>> v_set_c(v_set); v_set_c.insert(make_pair(v.value, v.children[i])); value_set.push(v_set_c); } } return partial_set; } // ไธŠใฎbitsetใƒใƒผใ‚ธใƒงใƒณ vector<bitset<59>> tree_edge_partial_set2(Tree tree) { vector<bitset<59>> partial_set(tree.node_num); queue<Node> value; value.push(tree.node[tree.root]); queue<bitset<59>> value_set; value_set.push(bitset<59>(0)); while(!value.empty()) { Node v = value.front(); bitset<59> v_set = value_set.front(); value.pop(); value_set.pop(); partial_set[v.value] = v_set; for (int i = 0; i < v.children.size(); i++) { value.push(tree.node[v.children[i]]); bitset<59> v_set_c(v_set); v_set_c[v.edge_value[i]] = 1; value_set.push(v_set_c); } } return partial_set; } // ใƒซใƒผใƒˆใ‹ใ‚‰้ ‚็‚นใพใงใซ้€šใ‚‹้ ‚็‚นใฎ็ดฏ็ฉๅ’Œ(่ซ–็†ๅ’Œ) vector<set<int>> tree_vertex_partial_set(Tree tree) { vector<set<int>> partial_set(tree.node_num); queue<Node> value; value.push(tree.node[tree.root]); queue<set<int>> value_set; value_set.push(set<int>({tree.root})); while(!value.empty()) { Node v = value.front(); set<int> v_set = value_set.front(); value.pop(); value_set.pop(); partial_set[v.value] = v_set; for (int i = 0; i < v.children.size(); i++) { value.push(tree.node[v.children[i]]); set<int> v_set_c(v_set); v_set_c.insert(v.children[i]); value_set.push(v_set_c); } } return partial_set; } // ๅ…ฅๅŠ›ใฎnodeใจๅ…จใฆใฎnodeใฎ่ท้›ขใ‚’ๅน…ๅ„ชๅ…ˆๆŽข็ดขใง่จˆ็ฎ—ใ™ใ‚‹้–ขๆ•ฐ vector<int> tree_dist_bfs(Tree tree, Node node) { vector<int> dist(tree.node_num, -1); queue<pair<int, Node>> que; que.push(make_pair(0, node)); while(!que.empty()) { pair<int, Node> p = que.front(); que.pop(); dist[p.second.value] = p.first; // ่ฆชใƒŽใƒผใƒ‰ใฎๆŽข็ดข // ่ฆชใŒใ„ใชใใฆๆœชๆŽข็ดขใฎๅ ดๅˆ if (p.second.parent != -1) if (dist[p.second.parent] == -1) que.push(make_pair(p.first+1, tree.node[p.second.parent])); // ๅญใƒŽใƒผใƒ‰ใฎๆŽข็ดข for (int i = 0; i < p.second.children.size(); i++) if (dist[p.second.children[i]] == -1) que.push(make_pair(p.first+1, tree.node[p.second.children[i]])); } return dist; } // uniou-findๆœจ ็ตŒ่ทฏๅœง็ธฎใฎใฟ struct UnionFind { vector<int> par; // par[i]:iใฎ่ฆชใฎ็•ชๅท ๆ นใฎใจใใฏpar[i]=i //ๆœ€ๅˆใฏๅ…จใฆใŒๆ นใงใ‚ใ‚‹ใจใ—ใฆๅˆๆœŸๅŒ– UnionFind(int N) : par(N) { for(int i = 0; i < N; i++) par[i] = i; } // ใƒ‡ใƒผใ‚ฟxใŒๅฑžใ™ใ‚‹ๆœจใฎๆ นใ‚’ๅ†ๅธฐใงๅพ—ใ‚‹๏ผšroot(x) = {xใฎๆœจใฎๆ น} int root(int x) { if (par[x] == x) return x; return par[x] = root(par[x]); } // xใจyใฎๆœจใ‚’ไฝตๅˆ void unite(int x, int y) { int rx = root(x); int ry = root(y); if (rx == ry) return; par[rx] = ry; } // 2ใคใฎใƒ‡ใƒผใ‚ฟx, yใŒๅฑžใ™ใ‚‹ๆœจใŒๅŒใ˜ใชใ‚‰trueใ‚’่ฟ”ใ™ bool same(int x, int y) { return root(x) == root(y); } }; // Range Minimum Query const ll INF = 1e15; struct RMQ { int leaf_node_num; vector<ll> node_value; RMQ(int input_num) { leaf_node_num = 1; while (leaf_node_num < input_num) leaf_node_num *= 2; for (int i = 0; i < 2*leaf_node_num-1; i++) node_value.push_back(INF); } // k็•ช็›ฎใฎๅ€คใ‚’aใซๅค‰ๆ›ด void update(int k, ll a) { k += leaf_node_num-1; node_value[k] = a; // rootใซๅ‘ใ‹ใฃใฆ้กใฃใฆๆ›ดๆ–ฐ while (k > 0) { k = (k-1) / 2; node_value[k] = min(node_value[k*2+1], node_value[k*2+2]); } } // ๅŒบ้–“[a, b)ใฎๆœ€ๅฐๅ€คใ‚’ๆฑ‚ใ‚ใ‚‹ // ๅพŒใ‚ใฎ3ใคใฎๅผ•ๆ•ฐใฏ่จˆ็ฎ—็”จใฎๅผ•ๆ•ฐ // kใฏ็ฏ€็‚น็•ชๅทใงๆœ€ๅˆใฏrootใ‚’ๅ‘ผใณๅ‡บใ™ใŸใ‚0 // l, rใฏ็ฏ€็‚นkใŒ[l, r)ใซๅฏพๅฟœใ—ใฆใ„ใ‚‹ใ“ใจใ‚’็คบใ™ // ใ‚ˆใฃใฆๆœ€ๅˆใฏquery(a, b, 0, 0, n)ใงๅ‘ผใณๅ‡บใ™ ll query(int a, int b, int k=0, int l=0, int r=-1) { // ๆœ€ๅˆใฎใ‚ฏใ‚จใƒชใฎใจใ if (r == -1) r = leaf_node_num; // [a, b)ใจ[r, l)ใŒไธ€ๅˆ‡้‡ใชใฃใฆใ„ใชใ„ใจใ if (r <= a || b <= l) return INF; // [r, l)ใ‚’[a, b)ใŒใ™ในใฆๅซใ‚“ใงใ„ใ‚‹ใจใ if (a <= l && r <= b) return node_value[k]; else { // ใใ†ใงใชใ„ใจใใฏๅญใƒŽใƒผใƒ‰ใฎๆœ€ๅฐๅ€ค ll vl = query(a, b, k*2 + 1, l, (l+r) / 2); ll vr = query(a, b, k*2 + 2, (l+r) / 2, r); return min(vl, vr); } } }; // Binary Indexed Tree struct BIT { int N; vector<int> values; // [1,n] BIT(int n) : values(n+1, 0) { N = n; } int sum(int i) { int s = 0; while (i > 0) { s += values[i]; i -= i & -i; // ไธ€็•ชไธ‹ใฎไฝใฎ1ใ‚’0ใซๅค‰ใˆใ‚‹ } return s; } void add(int i, int x) { while (i <= N) { values[i] += x; i += i & -i; } } }; int main() { //int n = 3; vector<vector<int>> hen{{1}, {0, 2}, {1}}; Tree tree(hen, 0); for (int i = 0; i < tree.node.size(); i++) { cout << tree.node[i].parent << endl; } vector<int> v_dist = tree_dist_bfs(tree, tree.node[0]); }
cc06d3180a52dceb332ab826e288b78135d856ed
95c367e58a79fd5a933dc0a2043adadccec5630c
/ColladaMaya/DaePhysicsSceneLibrary.cpp
dc21ec84b1460a282247760a225157a27aa83b3c
[ "MIT" ]
permissive
fl4re/COLLADAMobu
cf06fa2462d6655407ebc0502a6f25c7274dee84
4a81bec2b1d98b23311f13255fd9182c570a9b3d
refs/heads/master
2020-05-24T02:34:55.534671
2017-04-12T16:06:28
2017-04-12T16:06:28
84,808,624
0
0
null
2017-04-12T22:13:17
2017-03-13T09:35:38
C++
UTF-8
C++
false
false
1,798
cpp
/* Copyright (C) 2005-2007 Feeling Software Inc. Portions of the code are: Copyright (C) 2005-2007 Sony Computer Entertainment America MIT License: http://www.opensource.org/licenses/mit-license.php */ #include "StdAfx.h" #include <maya/MFnAttribute.h> #include "FCDocument/FCDLibrary.h" #include "FCDocument/FCDPhysicsScene.h" #include "TranslatorHelpers/CDagHelper.h" DaePhysicsSceneLibrary::DaePhysicsSceneLibrary(DaeDoc* pDoc) : DaeBaseLibrary(pDoc) { } void DaePhysicsSceneLibrary::Import() { FCDPhysicsSceneLibrary* library = CDOC->GetPhysicsSceneLibrary(); for (size_t i = 0; i < library->GetEntityCount(); ++i) { FUAssert(i == 0, MGlobal::displayWarning( MString("Multiple physics scenes not supported.")); break;); FCDPhysicsScene* scene = library->GetEntity(i); if (scene->GetUserHandle() == NULL) ImportScene(scene); } } void DaePhysicsSceneLibrary::ImportScene(FCDPhysicsScene* scene) { MStatus status; MGlobal::executeCommand("nxLazilyCreateSolverAndDebug"); MFnDependencyNode solverFn(CDagHelper::GetNode("nxRigidSolver1"), &status); if (status) { const FMVector3& gravity = scene->GetGravity(); const FMVector3& gDir = gravity.Normalize(); MVector gravityDirection(gDir.x, gDir.y, gDir.z); MStatus plugStatus; MPlug plug; plug = solverFn.findPlug(MString("gravityDirection"), &plugStatus); if (plugStatus) { CDagHelper::SetPlugValue(plug, MVector(gravityDirection)); } plug = solverFn.findPlug(MString("gravityMagnitude"), &plugStatus); if (plugStatus) { CDagHelper::SetPlugValue(plug, gravity.Length()); } plug = solverFn.findPlug(MString("stepSize"), &plugStatus); if (plugStatus) { CDagHelper::SetPlugValue(plug, scene->GetTimestep()); } } }
[ "steve314@bdddf8b5-0515-0410-9f3b-db498dd10dd0" ]
steve314@bdddf8b5-0515-0410-9f3b-db498dd10dd0
f421beff24bae8c871ca765f3d485d966d1e7051
6fa2c6f379311a1ba7599536f0703339068ec617
/libs/asio/http/request_handler.hpp
ec67c0d7e60ac1c5dd13ae1d02f37133b88b9437
[]
no_license
itirbit/parallel_cpp
3dcf9ea565930df84e1f703cbf070aefc6dca26a
a343602fb3d365833e1230c0866cfe9739352dc3
refs/heads/master
2023-02-28T05:38:38.031111
2021-02-06T14:15:10
2021-02-06T14:15:10
290,796,193
0
0
null
null
null
null
UTF-8
C++
false
false
463
hpp
#pragma once #include <string> namespace http{ namespace server{ struct reply; struct request; class request_handler { public: request_handler(const request_handler&) = delete; request_handler& operator=(const request_handler&) = delete; explicit request_handler(const std::string& doc_root); void handle_request(const request& req, reply& rep); private: std::string doc_root_; static bool url_decode(const std::string& in, std::string& out); }; } }
a84bbed6ba385ea5632ba3d0f9978a81ea208ffe
05fd3ac0e61f5eee408578a264d5e05a2f43aa83
/assembler.cpp
53a350564f203b9f68f6863261d626ed2936053f
[]
no_license
3x1l3/cpsc4600-project
087a3155e5e7381790b3bfe8a1191c22ca61eda0
09d4047a2d2dc4a9e23cf5a009ce9c84b41c9824
refs/heads/master
2020-05-05T06:23:49.779743
2012-04-21T05:11:58
2012-04-21T05:11:58
32,120,000
0
0
null
null
null
null
UTF-8
C++
false
false
6,684
cpp
// Implementation of the assembler class. using namespace std; #include <iostream> #include "assembler.h" #include <fstream> // Simple constructor. Assembler::Assembler(istream &in, ostream &out) { currentAddress = 0; for (int i = 0; i < MAXLABEL; i++) labelTable[i] = 0; insource = &in; outsource = &out; } // Default destructor. Assembler::~Assembler() { } // The first pass of the assmebler. This just builds the labelTable. // Don't translate just yet. void Assembler::firstPass() { // Start at address 0 (not 1 as I had previously thought) currentAddress = 0; string nextop; (*insource) >> nextop; // Loop until we find the ENDPROG operation. for (;;) { // Record the current address in the label table. if (nextop == "DEFADDR") { int index; (*insource) >> index; labelTable[index] = currentAddress; (*insource) >> nextop; } // Record the associated value in the label table. else if (nextop == "DEFARG") { int index, value; (*insource) >> index >> value; labelTable[index] = value; (*insource) >> nextop; } // Stop when we find ENDPROG. else if (nextop == "ENDPROG") return; else if (nextop == "ARROW" || nextop == "ASSIGN" || nextop == "BAR" || nextop == "CONSTANT" || nextop == "FI" || nextop == "READ" || nextop == "WRITE") { // Skip one machine words. (*insource) >> nextop; (*insource) >> nextop; currentAddress += 2; } else if (nextop == "CALL" || nextop == "INDEX" || nextop == "PROC" || nextop == "PROG" || nextop == "VARIABLE") { // Skip two machine words. (*insource) >> nextop; (*insource) >> nextop; (*insource) >> nextop; currentAddress += 3; } else { // just get the next machine word. (*insource) >> nextop; currentAddress++; } } } // The second pass of the assembler. Here we actually translate operations // to their opcodes. void Assembler::secondPass(string sourceASM) { string nextop; bool exit = false; stringstream asmCode; asmCode << sourceASM; insource = &asmCode; // Loop until ENDPROG. for (;;) { if (nextop == "ADD") { (*outsource) << 0 << endl;; currentAddress++; } else if (nextop == "AND") { (*outsource) << 1 << endl;; currentAddress++; } else if (nextop == "ARROW") { (*outsource) << 2 << endl;; int temp; (*insource) >> temp; // Output the absolute jump address. (*outsource) << labelTable[temp] << endl; currentAddress += 2; } else if (nextop == "ASSIGN") { (*outsource) << 3 << endl; int temp; (*insource) >> temp; (*outsource) << temp << endl; currentAddress += 2; } else if (nextop == "BAR") { (*outsource) << 4 << endl; int temp; (*insource) >> temp; (*outsource) << labelTable[temp] << endl; currentAddress += 2; } else if (nextop == "CALL") { (*outsource) << 5 << endl; int temp; (*insource) >> temp; (*outsource) << temp << endl; (*insource) >> temp; (*outsource) << labelTable[temp] << endl; currentAddress += 3; } else if (nextop == "CONSTANT") { (*outsource) << 6 << endl; int temp; (*insource) >> temp; (*outsource) << temp << endl; currentAddress += 2; } else if (nextop == "DIVIDE") { (*outsource) << 7 << endl; currentAddress++; } else if (nextop == "ENDPROC") { (*outsource) << 8 << endl; currentAddress++; } else if (nextop == "ENDPROG") { (*outsource) << 9 << endl; break; } else if (nextop == "EQUAL") { (*outsource) << 10 << endl; currentAddress++; } else if (nextop == "FI") { (*outsource) << 11 << endl; int temp; (*insource) >> temp; (*outsource) << temp << endl; currentAddress += 2; } else if (nextop == "GREATER") { (*outsource) << 12 << endl; currentAddress++; } else if (nextop == "INDEX") { (*outsource) << 13 << endl; int temp; (*insource) >> temp; (*outsource) << temp << endl; (*insource) >> temp; (*outsource) << temp << endl; currentAddress += 3; } else if (nextop == "LESS") { (*outsource) << 14 << endl; currentAddress++; } else if (nextop == "MINUS") { (*outsource) << 15 << endl; currentAddress++; } else if (nextop == "MODULO") { (*outsource) << 16 << endl; currentAddress++; } else if (nextop == "MULTIPLY") { (*outsource) << 17 << endl; currentAddress++; } else if (nextop == "NOT") { (*outsource) << 18 << endl; currentAddress++; } else if (nextop == "OR") { (*outsource) << 19 << endl; currentAddress++; } else if (nextop == "PROC") { (*outsource) << 20 << endl; int temp; (*insource) >> temp; (*outsource) << labelTable[temp] << endl; (*insource) >> temp; (*outsource) << labelTable[temp] << endl; currentAddress += 3; } else if (nextop == "PROG") { (*outsource) << 21 << endl; int temp; (*insource) >> temp; (*outsource) << labelTable[temp] << endl; (*insource) >> temp; (*outsource) << labelTable[temp] << endl; currentAddress += 3; } else if (nextop == "READ") { (*outsource) << 22 << endl; int temp; (*insource) >> temp; (*outsource) << temp << endl; currentAddress += 2; } else if (nextop == "SUBTRACT") { (*outsource) << 23 << endl; currentAddress++; } else if (nextop == "VALUE") { (*outsource) << 24 << endl; currentAddress++; } else if (nextop == "VARIABLE") { (*outsource) << 25 << endl; int temp; (*insource) >> temp; (*outsource) << temp << endl; (*insource) >> temp; (*outsource) << temp << endl; currentAddress += 3; } else if (nextop == "WRITE") { (*outsource) << 26 << endl; int temp; (*insource) >> temp; (*outsource) << temp << endl; currentAddress += 2; } else if (nextop == "DEFADDR") { int temp; (*insource) >> temp; } else if (nextop == "DEFARG") { int temp1, temp2; (*insource) >> temp1 >> temp2; } else { // We should never see this message. if(!(*insource).eof() && nextop != "")cerr << "Assembler encountered unknown operator \"" << nextop << "\"\n"; //exit = true; } if(!exit) { (*insource) >> nextop; } if((*insource).eof()) return; // cout << "got: " << nextop << endl; } }
[ "[email protected]@b6dedcac-f8b6-b7c9-e359-98e7ae5e6d10" ]
[email protected]@b6dedcac-f8b6-b7c9-e359-98e7ae5e6d10
ad2bb44e3f6259599ea7bc69fc4b7222370f70c1
eea40680ec60ca06a39feb32435bf60e85f08f16
/include/FL/Fl_Menu_.H
30163907a9417f024a2add70ca41f90cab055721
[ "MIT" ]
permissive
nextdynamics/IotaSlicer
928faa12dcea3493c13ba50e83ce9026f5c6ecaa
287d47100f62e6c966c9db3ed4c50dfbf7a6039e
refs/heads/master
2020-06-04T08:02:56.374012
2018-10-30T23:04:22
2018-10-30T23:04:22
null
0
0
null
null
null
null
UTF-8
C++
false
false
7,383
h
// // "$Id: Fl_Menu_.H 12816 2018-03-31 17:29:23Z greg.ercolano $" // // Menu base class header file for the Fast Light Tool Kit (FLTK). // // Copyright 1998-2016 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this // file is missing or damaged, see the license at: // // http://www.fltk.org/COPYING.php // // Please report all bugs and problems on the following page: // // http://www.fltk.org/str.php // /* \file Fl_Menu_ widget . */ #ifndef Fl_Menu__H #define Fl_Menu__H #ifndef Fl_Widget_H #include "Fl_Widget.H" #endif #include "Fl_Menu_Item.H" /** Base class of all widgets that have a menu in FLTK. Currently FLTK provides you with Fl_Menu_Button, Fl_Menu_Bar, and Fl_Choice. The class contains a pointer to an array of structures of type Fl_Menu_Item. The array may either be supplied directly by the user program, or it may be "private": a dynamically allocated array managed by the Fl_Menu_. When the user clicks a menu item, value() is set to that item and then: - If the Fl_Menu_Item has a callback set, that callback is invoked with any userdata configured for it. (The Fl_Menu_ widget's callback is NOT invoked.) - For any Fl_Menu_Items that \b don't have a callback set, the Fl_Menu_ widget's callback is invoked with any userdata configured for it. The callback can determine which item was picked using value(), mvalue(), item_pathname(), etc. The line spacing between menu items can be controlled with the global setting Fl::menu_linespacing(). */ class FL_EXPORT Fl_Menu_ : public Fl_Widget { Fl_Menu_Item *menu_; const Fl_Menu_Item *value_; protected: uchar alloc; // flag indicates if menu_ is a dynamic copy (=1) or not (=0) uchar down_box_; Fl_Font textfont_; Fl_Fontsize textsize_; Fl_Color textcolor_; int item_pathname_(char *name, int namelen, const Fl_Menu_Item *finditem, const Fl_Menu_Item *menu=0) const; public: Fl_Menu_(int,int,int,int,const char * =0); ~Fl_Menu_(); int item_pathname(char *name, int namelen, const Fl_Menu_Item *finditem=0) const; const Fl_Menu_Item* picked(const Fl_Menu_Item*); const Fl_Menu_Item* find_item(const char *name); const Fl_Menu_Item* find_item(Fl_Callback*); int find_index(const char *name) const; int find_index(const Fl_Menu_Item *item) const; int find_index(Fl_Callback *cb) const; /** Returns the menu item with the entered shortcut (key value). This searches the complete menu() for a shortcut that matches the entered key value. It must be called for a FL_KEYBOARD or FL_SHORTCUT event. If a match is found, the menu's callback will be called. \return matched Fl_Menu_Item or NULL. */ const Fl_Menu_Item* test_shortcut() {return picked(menu()->test_shortcut());} void global(); /** Returns a pointer to the array of Fl_Menu_Items. This will either be the value passed to menu(value) or the private copy. \sa size() -- returns the size of the Fl_Menu_Item array. \b Example: How to walk the array: \code for ( int t=0; t<menubar->size(); t++ ) { // walk array of items const Fl_Menu_Item &item = menubar->menu()[t]; // get each item fprintf(stderr, "item #%d -- label=%s, value=%s type=%s\n", t, item.label() ? item.label() : "(Null)", // menu terminators have NULL labels (item.flags & FL_MENU_VALUE) ? "set" : "clear", // value of toggle or radio items (item.flags & FL_SUBMENU) ? "Submenu" : "Item"); // see if item is a submenu or actual item } \endcode */ const Fl_Menu_Item *menu() const {return menu_;} void menu(const Fl_Menu_Item *m); void copy(const Fl_Menu_Item *m, void* user_data = 0); int insert(int index, const char*, int shortcut, Fl_Callback*, void* = 0, int = 0); int add(const char*, int shortcut, Fl_Callback*, void* = 0, int = 0); // see src/Fl_Menu_add.cxx /** See int Fl_Menu_::add(const char* label, int shortcut, Fl_Callback*, void *user_data=0, int flags=0) */ int add(const char* a, const char* b, Fl_Callback* c, void* d = 0, int e = 0) { return add(a,fl_old_shortcut(b),c,d,e); } /** See int Fl_Menu_::insert(const char* label, int shortcut, Fl_Callback*, void *user_data=0, int flags=0) */ int insert(int index, const char* a, const char* b, Fl_Callback* c, void* d = 0, int e = 0) { return insert(index,a,fl_old_shortcut(b),c,d,e); } int add(const char *); int size() const ; void size(int W, int H) { Fl_Widget::size(W, H); } void clear(); int clear_submenu(int index); void replace(int,const char *); void remove(int); /** Changes the shortcut of item \p i to \p s. */ void shortcut(int i, int s) {menu_[i].shortcut(s);} /** Sets the flags of item i. For a list of the flags, see Fl_Menu_Item. */ void mode(int i,int fl) {menu_[i].flags = fl;} /** Gets the flags of item i. For a list of the flags, see Fl_Menu_Item. */ int mode(int i) const {return menu_[i].flags;} /** Returns a pointer to the last menu item that was picked. */ const Fl_Menu_Item *mvalue() const {return value_;} /** Returns the index into menu() of the last item chosen by the user. It is zero initially. */ int value() const {return value_ ? (int)(value_-menu_) : -1;} int value(const Fl_Menu_Item*); /** The value is the index into menu() of the last item chosen by the user. It is zero initially. You can set it as an integer, or set it with a pointer to a menu item. The set routines return non-zero if the new value is different than the old one. */ int value(int i) {return value(menu_+i);} /** Returns the title of the last item chosen. */ const char *text() const {return value_ ? value_->text : 0;} /** Returns the title of item i. */ const char *text(int i) const {return menu_[i].text;} /** Gets the current font of menu item labels. */ Fl_Font textfont() const {return textfont_;} /** Sets the current font of menu item labels. */ void textfont(Fl_Font c) {textfont_=c;} /** Gets the font size of menu item labels. */ Fl_Fontsize textsize() const {return textsize_;} /** Sets the font size of menu item labels. */ void textsize(Fl_Fontsize c) {textsize_=c;} /** Get the current color of menu item labels. */ Fl_Color textcolor() const {return textcolor_;} /** Sets the current color of menu item labels. */ void textcolor(Fl_Color c) {textcolor_=c;} /** This box type is used to surround the currently-selected items in the menus. If this is FL_NO_BOX then it acts like FL_THIN_UP_BOX and selection_color() acts like FL_WHITE, for back compatibility. */ Fl_Boxtype down_box() const {return (Fl_Boxtype)down_box_;} /** See Fl_Boxtype Fl_Menu_::down_box() const */ void down_box(Fl_Boxtype b) {down_box_ = b;} /** For back compatibility, same as selection_color() */ Fl_Color down_color() const {return selection_color();} /** For back compatibility, same as selection_color() */ void down_color(unsigned c) {selection_color(c);} void setonly(Fl_Menu_Item* item); }; #endif // // End of "$Id: Fl_Menu_.H 12816 2018-03-31 17:29:23Z greg.ercolano $". //
f7ad0b58a03bd4373446f692f407ded752548761
6fe397cf09d9da1abf05c9433a801b7c05d99784
/AVL OOP/Temp/IFunction.cpp
3ff1f3cdabbbc8ee866c8915a205a59948d4ae06
[]
no_license
LengdonB/Pipelined-AVL
8e1cc304e3b8052895899c8a70e1d0b23d8085b7
3bb2b1dbe56253b2999e96901be5e732ce25424f
refs/heads/master
2023-01-11T17:42:30.155248
2020-11-10T06:44:34
2020-11-10T06:44:34
241,437,609
0
0
null
null
null
null
UTF-8
C++
false
false
42
cpp
#include "IFunction.h" #include<iostream>
f332676cb3781d2248ec2e31a61d182e398e4f2e
1475af3c0426503d16212f85748ee8b0ac85b0c8
/vktIOwriter.cpp
94ee4afe6bb0a9beae3e99392fe97bee6f5bc52e
[]
no_license
Manigandanmps/VTKFileFormat
60c23500eb9f8d54a5ffa036c3f4365b435e43f9
957fdbcc3fb47994ac6556912619e3d165e9d90d
refs/heads/master
2023-07-01T18:47:22.711490
2021-08-09T20:53:37
2021-08-09T20:53:37
394,423,233
0
0
null
null
null
null
UTF-8
C++
false
false
7,146
cpp
#include <iostream> #include <fstream> #include <vector> #include <math.h> struct Point3D{ double x; double y; double z; //Constructor for 3D Point Point3D(double _x, double _y, double _z) { x = _x; y = _y; z = _z; } ~Point3D(){} //Function to get X, Y and Z double getX() { return x; } double getY() { return y; } double getZ() { return z; } }; /*DATASET STRUCTURED_POINTS DIMENSIONS nx ny nz ORIGIN xyz SPACING sx sy sz*/ void WriteStructuredPoints( float nx, float ny, float nz, float x, float y, float z, float sx, float sy, float sz) { float Nx = nx, Ny = ny, Nz = nz; float X = x, Y = y, Z = z; float Sx = sx, Sy = sy, Sz = sz; std::ofstream file; file.open("StructuredPiont.vtk"); file << "# vtk DataFile Version 3.0" <<std::endl; file << "Volume example " <<std::endl; file << "ASCII" <<std::endl; file << "DATASET STRUCTURED_POINTS "<<std::endl; file << "DIMENSIONS" << " " <<Nx <<" "<<Ny <<" "<<Nz<<std::endl; file << "SPACING" << " " <<Sx <<" "<<Sy <<" "<<Sz<<std::endl; file << "ORIGIN" << " " <<x <<" "<<y <<" "<<z<<std::endl; file.close(); } void WriteStructuredGrid (float nx, float ny, float nz, int n, std::vector<Point3D> &pv, std::vector<float> &sv) { float Nx = nx, Ny = ny, Nz = nz; std::ofstream file; file.open("StructuredGrid.vtk"); file << "# vtk DataFile Version 3.0" <<std::endl; file << "Volume example" <<std::endl; file << "ASCII" <<std::endl; file << "DATASET STRUCTURED_GRID "<<std::endl; file << "DIMENSIONS" << " " <<Nx <<" "<<Ny <<" "<<Nz<<std::endl; file << "POINTS" <<" "<< n << " "<< "float" <<std::endl; // for (int i = 0; i < pv; i++) // { // file << pv.at(i).getX() << " " <<pv.at(i).getY() << " "<<pv.at(i).getZ()<< std::endl; // } for (auto &x: pv) file << x.getX() <<" " << x.getY() <<" "<< x.getZ()<< std::endl; file << "POINT_DATA" << " " << n << std::endl; file << "SCALARS sample_scalars float 1"<<std::endl; file << "LOOKUP_TABLE default"<<std::endl; for (auto &x :sv) file << x <<std::endl; file.close(); } void WriteRectilinearGrid(float nx, float ny, float nz, int n, std::vector<Point3D> &pv, std::vector<float> &sv) { float Nx = nx, Ny = ny, Nz = nz; std::ofstream file; file.open("RectilinearGrid.vtk"); file << "# vtk DataFile Version 3.0" <<std::endl; file << "Volume example" <<std::endl; file << "ASCII" <<std::endl; file << "DATASET RECTILINEAR_GRID"<<std::endl; file << "DIMENSIONS" << " " <<n <<" "<<n <<" "<<n<<std::endl; file << "X_COORDINATES" <<" "<< n << " "<< "float" <<std::endl; // for (int i = 0; i < pv; i++) // { // file << pv.at(i).getX() << " " <<pv.at(i).getY() << " "<<pv.at(i).getZ()<< std::endl; // } for (auto &x: pv) file << x.getX() <<" " ; std::cout << std::endl; std::cout << std::endl; file << "Y_COORDINATES" <<" "<< n << " "<< "float" <<std::endl; for (auto &x: pv) file << x.getY() <<" " ; std::cout << std::endl; std::cout << std::endl; std::cout << std::endl; file << "Z_COORDINATES" <<" "<< n << " "<< "float" <<std::endl; for (auto &x: pv) file << x.getZ() <<" " ; std::cout << std::endl; std::cout << std::endl; std::cout << std::endl; // file << "POINT_DATA" << " " << n << std::endl; // file << "SCALARS sample_scalars float 1"<<std::endl; // file << "LOOKUP_TABLE default"<<std::endl; // for (auto &x :sv) // file << x <<std::endl; file.close(); } float circle (Point3D m, Point3D cm, float r_) { Point3D cm_(cm); std::vector<float> sv; float r = r_; float sq_r = r*r; float ref; Point3D x(m); ref = (pow((x.getX() - cm.getX()),2)) + (pow((x.getY() - cm.getY()),2)) + (pow((x.getZ() - cm.getZ()),2)); if (sq_r > ref ) { return 1; } else { return 0; } } float square (Point3D m, Point3D cm, float r_) { Point3D cm_(cm); std::vector<float> sv; float r = r_; float sq_r = r*r; float ref; Point3D x(m); ref = (abs((x.getX() - cm.getX()) + (x.getY() - cm.getY()) + (x.getZ() - cm.getZ()))) + (abs((x.getX() - cm.getX()) - (x.getY() - cm.getY()) - (x.getZ() - cm.getZ()))) ; if (sq_r > ref ) { return 1; } else { return 0; } } float triangle_area (Point3D a, Point3D b, Point3D c) { Point3D a_(a), b_(b), c_(c); float dX, dY, dZ; dX = 0.5 *(abs(a_.getY()*(b_.getZ() - c_.getZ()) - (b_.getY()*(a_.getZ() - c_.getZ())) + (c_.getY()*(a_.getZ() - b_.getZ())))); dY = 0.5 *(abs(a_.getZ()*(b_.getX() - c_.getX()) - (b_.getZ()*(a_.getX() - c_.getX())) + (c_.getZ()*(a_.getX() - b_.getX())))); dZ = 0.5 *(abs(a_.getX()*(b_.getY() - c_.getY()) - (b_.getX()*(a_.getY() - c_.getY())) + (c_.getX()*(a_.getY() - b_.getY())))); float area = sqrt((pow(dX,2)) + (pow(dY,2)) + (pow(dZ,2))); return area; } float inside_triangle(Point3D a, Point3D b, Point3D c, Point3D d) { float A = triangle_area(a, b, c); float A1 = triangle_area(a, b, d); float A2 = triangle_area (a, c, d); float A3 = triangle_area(b, c, d); float A_sum = A1 + A2 + A3; if (A == A_sum) { return 1.0; } else { return 0.0; } } int main() { std::cout <<"vkt IO Writer " << std::endl; /*For 2D Nz = 1*/ std::vector<Point3D> input_points; float nx = 100.0f, ny =100.0f, nz = 1.0f; //domain size float sx = 0.5f, sy = 0.5f, sz = 1.0f; //Spacing size float n = (nx/sx)*(ny/sy)*(nz/sz); //total no of points; std :: cout << "Creating cartesian mesh is started......." <<std::endl; for (float z = 0.0; z < nz; z += sz) { for (float y = 0.0; y < ny ; y += sy) { for (float x = 0.0; x < nx ; x += sx) { // Point3D temp; std :: cout <<x << " " <<y <<" " << z <<std::endl; Point3D temp(x, y, z); input_points.push_back(temp); } } } std :: cout << "Creating cartesian mesh is done......." <<std::endl; std::vector<float> sv; float j; Point3D cm_(50,50,0); float r_= 15.0; Point3D a(20, 20, 0), b(70, 20, 0), c(60, 50, 0); for (auto &x: input_points) { Point3D m(x.getX(), x.getY(), x.getZ()); j = circle(m, cm_, r_); // j = square(m, cm_, r_ ); j = inside_triangle(a, b, c, m); sv.push_back(j); } // WriteStructuredPoints(10, 5, 1, 0, 0, 0, 1, 1, 1); //DIMENSIONS nx ny nz, ORIGIN xyz SPACING sx sy sz WriteStructuredGrid(nx, ny, nz, n, input_points, sv ); // WriteRectilinearGrid(nx, ny, nz, n, input_points, sv); // Point3D a(3, 8, 1), b(-4, 2, 1), c(5, 1, 2); // float area = triangle_area(a, b, c); // std::cout << "Triangle area: " << " " <<area <<std::endl; return 0; }
54c0afc78b693b1ab9aa8d1496c6f1f13579eabd
2d96ea3e11530a0a1dc776c36f42ca6c11d123ae
/main.cpp
00d47882110c149f674a76a62470cff309eeb754
[]
no_license
devbit-iot-devices/low-level-blinky
91401b11bf97fd22fb08c57bb652a238be263d59
bcae9828ef836d6bd80c20e7ef229b1970e5a16f
refs/heads/master
2022-08-10T18:17:26.044838
2020-05-18T07:28:19
2020-05-18T07:28:19
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,055
cpp
// includes low level peripheral definitions #include "stm32l476xx.h" /** * Waits for an approximate number of milliseconds, this function blocks the CPU * * @param milliseconds to wait */ void approx_wait(uint32_t milliseconds) { for (uint32_t j = 0; j < milliseconds; j++) { for (volatile uint32_t i = 0; i < 4000; i++) ; } } int main() { //Green led of the NUCLEO-L476RG is connected to PA5 //Enable GPIOA peripheral in the AHB2ENR: set bit 0 RCC->AHB2ENR |= 1; // GPIOA_MODER set GP output mode: reset bit 11 & set bit 10 GPIOA->MODER &= ~(1<<11); GPIOA->MODER |= 1 << 10; // GPIOA_OTYPER pushpull: default after reset // GPIOA_OSPEEDR low speed: default after reset // GPIOA_PUPDR no pull-up / no pull-down: default after reset while (true) { //GPIOA_BSRR set pin 5: set bit 5 GPIOA->BSRR |= 1<< 5; approx_wait(500); //GPIOA_BSRR reset pin 5: set bit 21 GPIOA->BSRR |= 1 << 21; approx_wait(500); } }
a1e3048f5a6ab090a194b15e2c041e8511118ee3
238adff3be9baa4cf54cc063c9cea277f8e289a2
/packages/react-native/ReactCommon/react/renderer/components/text/BaseTextShadowNode.cpp
2c62256527291ed4d6edb035b5f2d5b44fdfec2f
[ "MIT", "CC-BY-4.0", "CC-BY-NC-SA-4.0", "CC-BY-SA-4.0" ]
permissive
facebook/react-native
e7c418db82563907b3564d81d505b3125b3a6cc7
041f459d8c674f6817e0ac1851be49c435d53089
refs/heads/main
2023-09-04T01:53:34.965255
2023-09-02T23:23:34
2023-09-02T23:23:34
29,028,775
131,047
32,710
MIT
2023-09-14T21:49:45
2015-01-09T18:10:16
Java
UTF-8
C++
false
false
2,823
cpp
/* * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ #include "BaseTextShadowNode.h" #include <react/renderer/components/text/RawTextProps.h> #include <react/renderer/components/text/RawTextShadowNode.h> #include <react/renderer/components/text/TextProps.h> #include <react/renderer/components/text/TextShadowNode.h> #include <react/renderer/core/TraitCast.h> #include <react/renderer/mounting/ShadowView.h> namespace facebook::react { inline ShadowView shadowViewFromShadowNode(const ShadowNode &shadowNode) { auto shadowView = ShadowView{shadowNode}; // Clearing `props` and `state` (which we don't use) allows avoiding retain // cycles. shadowView.props = nullptr; shadowView.state = nullptr; return shadowView; } void BaseTextShadowNode::buildAttributedString( const TextAttributes &baseTextAttributes, const ShadowNode &parentNode, AttributedString &outAttributedString, Attachments &outAttachments) { for (const auto &childNode : parentNode.getChildren()) { // RawShadowNode auto rawTextShadowNode = traitCast<const RawTextShadowNode *>(childNode.get()); if (rawTextShadowNode != nullptr) { auto fragment = AttributedString::Fragment{}; fragment.string = rawTextShadowNode->getConcreteProps().text; fragment.textAttributes = baseTextAttributes; // Storing a retaining pointer to `ParagraphShadowNode` inside // `attributedString` causes a retain cycle (besides that fact that we // don't need it at all). Storing a `ShadowView` instance instead of // `ShadowNode` should properly fix this problem. fragment.parentShadowView = shadowViewFromShadowNode(parentNode); outAttributedString.appendFragment(fragment); continue; } // TextShadowNode auto textShadowNode = traitCast<const TextShadowNode *>(childNode.get()); if (textShadowNode != nullptr) { auto localTextAttributes = baseTextAttributes; localTextAttributes.apply( textShadowNode->getConcreteProps().textAttributes); buildAttributedString( localTextAttributes, *textShadowNode, outAttributedString, outAttachments); continue; } // Any *other* kind of ShadowNode auto fragment = AttributedString::Fragment{}; fragment.string = AttributedString::Fragment::AttachmentCharacter(); fragment.parentShadowView = shadowViewFromShadowNode(*childNode); fragment.textAttributes = baseTextAttributes; outAttributedString.appendFragment(fragment); outAttachments.push_back(Attachment{ childNode.get(), outAttributedString.getFragments().size() - 1}); } } } // namespace facebook::react
ee97233ebc61953191237c32662ef8a6e587f669
7ae5fc27c0f5ba5a7a923a37484eadf744ef0bd9
/src/log.h
03747c8c2bb7738abf9ce17ab9fb4e3caf5056a1
[]
no_license
unpluggedcoder/SpamIPCheck
4c6e1402e000cfc50d78762865b892b0468ad4be
0a30196e83d484199ab16824d00d96729927fefd
refs/heads/master
2020-12-31T02:42:38.983006
2015-05-14T11:56:23
2015-05-14T11:56:23
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,969
h
#ifndef LOG_H #define LOG_H #include <string> #include <ostream> #include <fstream> #include <memory> class noncopyable { protected: #if defined(__cplusplus) && __cplusplus >= 201103L noncopyable() = default; ~noncopyable() = default; #else noncopyable() {} ~noncopyable() {} #endif #if defined(__cplusplus) && __cplusplus >= 201103L noncopyable( const noncopyable& ) = delete; noncopyable& operator=( const noncopyable& ) = delete; #else private: // emphasize the following members are private noncopyable( const noncopyable& ); noncopyable& operator=( const noncopyable& ); #endif }; template<typename T> class Singleton: public noncopyable { public: static T & getInstance() { static T t; //assert(! detail::singleton_wrapper< T >::m_is_destroyed); use(_instance); return static_cast<T &>(t); } private: static void use(T const &) {} static T& _instance; }; template<class T> T & Singleton<T>::_instance = Singleton<T>::getInstance(); class Log: public Singleton<Log> { public: Log(); ~Log(); void Log_Init(const std::string& path); void Log_Info(const std::string & strText,const char * file, const char * func, const int line); void Log_Warning(const std::string & strText,const char * file, const char * func, const int line); void Log_Error(const std::string & strText,const char * file, const char * func, const int line); private: //static writelog(const std::string &line); std::ofstream _file; std::ostream _out; }; #ifdef DEBUG #define LOG_INFO(msg) Log::getInstance().Log_Info(msg, __FILE__, __FUNCTION__, __LINE__) #define LOG_WARNING(msg) Log::getInstance().Log_Warning(msg, __FILE__, __FUNCTION__, __LINE__) #define LOG_ERROR(msg) Log::getInstance().Log_Error(msg, __FILE__, __FUNCTION__, __LINE__) #else #define LOG_INFO(msg) #define LOG_WARNING(msg) #define LOG_ERROR(msg) #endif #endif // LOG_H
e706918cfdb5bff0854870973dcdf11eaf7aba76
f4d1d40826b55e6beacb7a1684aebfa23b9430aa
/Semester-5/C++/chess/Chess.cpp
74b142af6ba920ad223ab5e911a57220b94ef4a3
[]
no_license
Andrei-Loginov/University
3d1c493a669f5cdadd94fdb89e073fb880c62a40
4bb9be97a18f80f47b83ff11019487e634b675e1
refs/heads/main
2023-08-11T06:50:55.321421
2021-10-09T16:32:19
2021-10-09T16:32:19
388,731,707
0
0
null
null
null
null
UTF-8
C++
false
false
16,716
cpp
#include "Chess.h" const std::string head = " A B C D E F G H"; const std::string left[] = { "1 ", "2 ", "3 ", "4 ", "5 ", "6 ", "7 ", "8 " }; bool operator==(const std::pair<int, int>& left, const std::pair<int, int>& right) { return (left.first == right.first && left.second == right.second); } Chess::Chess() { for (size_t i = 0; i < 8; ++i) { board[1][i].type = P; board[6][i].type = P; board[0][i].colour = board[1][i].colour = white; board[7][i].colour = board[6][i].colour = black; } board[0][0].type = board[0][7].type = board[7][0].type = board[7][7].type = R; board[0][1].type = board[0][6].type = board[7][1].type = board[7][6].type = N; board[0][2].type = board[0][5].type = board[7][2].type = board[7][5].type = B; board[0][3].type = board[7][3].type = Q; board[0][4].type = board[7][4].type = K; } Chess::Chess(const std::string& game) { std::stringstream stream(game); std::string s; for (int i = 7; i >= 0; --i) for (int j = 0; j < 8; ++j) { stream >> s; board[i][j] = { static_cast<COLOUR>(int(s[0])) , static_cast<PIECE>(int(s[1])) }; if (board[i][j].type == K) { if (board[i][j].colour == white) whiteKing = { i, j }; else blackKing = { i, j }; } } check(); } Chess::Chess(const char* fname) { std::ifstream stream(fname); std::string s; for (int i = 7; i >= 0; --i) for (int j = 0; j < 8; ++j) { stream >> s; board[i][j] = { static_cast<COLOUR>(int(s[0])) , static_cast<PIECE>(int(s[1])) }; if (board[i][j].type == K) { if (board[i][j].colour == white) whiteKing = { i, j }; else blackKing = { i, j }; } } stream.close(); check(); } Chess::Chess(const Chess& item): turn(item.turn), CheckWhite(item.CheckWhite), CheckBlack(item.CheckBlack), whiteKing(item.whiteKing), blackKing(item.blackKing) { for (int i = 0; i < 8; ++i) for (int j = 0; j < 8; ++j) board[i][j] = item.board[i][j]; } void Chess::check() { CheckBlack = CheckWhite = false; for (int i = 0; i < 8; ++i) for (int j = 0; j < 8; ++j) { if (board[i][j].type != K) { if (board[i][j].colour == white) { bool temp = turn; turn = true; if (attack({ i ,j }, blackKing)) CheckBlack = true; turn = temp; }else { bool temp = turn; turn = false; if (attack({ i ,j }, whiteKing)) CheckWhite = true; turn = temp; } } } } bool Chess::move(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (curr.first == dest.first && curr.second == dest.second) return false; if ((turn && board[curr.first][curr.second].colour != white) || (!turn && board[curr.first][curr.second].colour != black)) return false; switch (board[curr.first][curr.second].type) { case P: return pawnMove(curr, dest); break; case R: return rookMove(curr, dest); break; case N: return knightMove(curr, dest); break; case Q: return queenMove(curr, dest); break; case K: return kingMove(curr, dest); break; case B: return bishopMove(curr, dest); break; default: return false; } } bool Chess::attack(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (curr.first == dest.first && curr.second == dest.second) return false; if ((turn && board[curr.first][curr.second].colour != white) || (!turn && board[curr.first][curr.second].colour != black)) return false; switch (board[curr.first][curr.second].type) { case P: return pawnAttack(curr, dest); break; case R: return rookAttack(curr, dest); break; case N: return knightAttack(curr, dest); break; case Q: return queenAttack(curr, dest); break; case K: return kingAttack(curr, dest); break; case B: return bishopAttack(curr, dest); break; default: return false; } } bool Chess::pawnMove(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (curr.second != dest.second) return false; if (board[dest.first][dest.second].colour != none) return false; if (turn) { if (dest.first - curr.first == 1) return tryMove(curr, dest); else if (dest.first - curr.first == 2) { if (curr.first != 1) return false; if (board[2][dest.second].colour != none) return false; if (tryMove(curr, dest)) { en_passant = dest; return true; } } else return false; } else { if (dest.first - curr.first == -1) return tryMove(curr, dest); else if (dest.first - curr.first == -2) { if (curr.first != 6) return false; if (board[5][dest.second].colour != none) return false; if (tryMove(curr, dest)) { en_passant = dest; return true; } } else return false; } return false; } bool Chess::pawnAttack(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { bool fl = false, e_p = false; CELL current = board[curr.first][curr.second], destination = board[dest.first][dest.second]; if (abs(curr.second - dest.second) == 1) { if (destination.colour != current.colour && destination.colour != empty) { int multiplier = (turn) ? 1 : -1; if (dest.first - curr.first == multiplier) fl = true; } else { if (curr.first == en_passant.first && dest.second == en_passant.second) fl = e_p = true; } } if (fl) { if (destination.type != K) { board[dest.first][dest.second] = current; if (!e_p) { board[curr.first][curr.second] = nothing; } else { board[curr.first][curr.second] = nothing; board[en_passant.first][en_passant.second] = nothing; } check(); if ((turn && CheckWhite) || (!turn && CheckBlack)) { if (!e_p) board[dest.first][dest.second] = destination; else { board[dest.first][dest.second] = nothing; board[en_passant.first][en_passant.second].colour = (fl) ? black : white; board[en_passant.first][en_passant.second].type = P; } board[curr.first][curr.second] = current; check(); fl = false; } } else return true; } return fl; } bool Chess::knightMove(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (board[dest.first][dest.second].colour == none) { //std::cout << abs(curr.first - dest.first) << " " << abs(curr.second - dest.second) << "\n"; if ((abs(curr.first - dest.first) == 2 && abs(curr.second - dest.second) == 1) || (abs(curr.first - dest.first) == 1 && abs(curr.second - dest.second) == 2)) { return tryMove(curr, dest); } return false; } return false; } bool Chess::knightAttack(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { CELL current = board[curr.first][curr.second], destination = board[dest.first][dest.second]; if (current.colour != destination.colour && destination.colour != none) { if ((abs(curr.first - dest.first) == 2 && abs(curr.second - dest.second) == 1) || (abs(curr.first - dest.first) == 1 && abs(curr.second - dest.second) == 2)) { if (destination.type != K) { return tryMove(curr, dest); } else return true; } return false; } return false; } bool Chess::rookMove(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (curr.first != dest.first && curr.second != dest.second) return false; CELL current = board[curr.first][curr.second], destination = board[dest.first][dest.second]; if (destination.colour != none) return false; int mult_rows = 0, mult_cols = 0; if (curr.first == dest.first) mult_cols = (curr.second < dest.second) ? 1 : -1; else mult_rows = (curr.first < dest.first) ? 1 : -1; for (int i = 1; !(curr.first + i * mult_rows == dest.first && curr.second + i * mult_cols == dest.second); ++i) if (board[curr.first + i * mult_rows][curr.second + i * mult_cols].colour != none) return false; return tryMove(curr, dest); } bool Chess::rookAttack(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (curr.first != dest.first && curr.second != dest.second) return false; CELL current = board[curr.first][curr.second], destination = board[dest.first][dest.second]; if (destination.colour == none || destination.colour == current.colour) return false; int mult_rows = 0, mult_cols = 0; if (curr.first == dest.first) mult_cols = (curr.second < dest.second) ? 1 : -1; else mult_rows = (curr.first < dest.first) ? 1 : -1; for (int i = 1; !(curr.first + i * mult_rows == dest.first && curr.second + i * mult_cols == dest.second); ++i) if (board[curr.first + i * mult_rows][curr.second + i * mult_cols].colour != none) return false; if (destination.type == K) return true; return tryMove(curr, dest); } bool Chess::bishopMove(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (board[dest.first][dest.second].colour != none) return false; if (abs(curr.first - dest.first) != abs(curr.second - dest.second)) return false; int mult_rows = (dest.first - curr.first > 0) ? 1 : -1; int mult_cols = (dest.second - curr.second > 0) ? 1 : -1; //std::cout << "mults: " << mult_rows << " " << mult_cols << "\n"; for (int i = 1; !(curr.first + i * mult_rows == dest.first && curr.second + i * mult_cols == dest.second); ++i) if (board[curr.first + i * mult_rows][curr.second + i * mult_cols].colour != none) return false; return tryMove(curr, dest); } bool Chess::bishopAttack(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (abs(curr.first - dest.first) != abs(curr.second - dest.second)) return false; CELL current = board[curr.first][curr.second], destination = board[dest.first][dest.second]; if (destination.colour == none || destination.colour == current.colour) return false; int mult_rows = (dest.first - curr.first > 0) ? 1 : -1; int mult_cols = (dest.second - curr.second > 0) ? 1 : -1; for (int i = 1; !(curr.first + i * mult_rows == dest.first && curr.second + i * mult_cols == dest.second); ++i) if (board[curr.first + i * mult_rows][curr.second + i * mult_cols].colour != none) return false; if (destination.type == K) return true; return tryMove(curr, dest); } bool Chess::queenMove(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { return (rookMove(curr, dest) || bishopMove(curr, dest)); } bool Chess::queenAttack(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { return (rookAttack(curr, dest) || bishopAttack(curr, dest)); } bool Chess::kingMove(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { std::ofstream fout("some.txt", std::ios_base::trunc); if (board[dest.first][dest.second].colour != none) return false; if (abs(curr.first - dest.first) > 1 || abs(curr.second - dest.second) > 1) return false; if (curr.first == whiteKing.first && curr.second == whiteKing.second) { if (abs(dest.first - blackKing.first) < 2 && abs(dest.second - blackKing.second) < 2) return false; } else if (abs(dest.first - whiteKing.first) < 2 && abs(dest.second - whiteKing.second) < 2) return false; if (curr == whiteKing) whiteKing = dest; else if (curr == blackKing) blackKing = dest; else return false; fout << "turn " << turn << "\n"; if (tryMove(curr, dest)) { return true; } if (dest == whiteKing) whiteKing = curr; else blackKing = curr; return false; fout.close(); } bool Chess::kingAttack(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { if (abs(curr.first - dest.first) > 1 || abs(curr.second - dest.second) > 1) return false; CELL current = board[curr.first][curr.second], destination = board[dest.first][dest.second]; if (destination.colour == none || destination.colour == current.colour) return false; if (curr.first == whiteKing.first && curr.second == whiteKing.second) { if (abs(dest.first - blackKing.first) < 2 && abs(dest.second - blackKing.second) < 2) return false; } else if (abs(dest.first - whiteKing.first) < 2 && abs(dest.second - whiteKing.second) < 2) return false; if (tryMove(curr, dest)) { if (curr.first == whiteKing.first && curr.second == blackKing.second) whiteKing = dest; else blackKing = dest; return true; } return false; } bool Chess::tryMove(const std::pair<int, int>& curr, const std::pair<int, int>& dest) { CELL current = board[curr.first][curr.second], destination = board[dest.first][dest.second]; board[dest.first][dest.second] = current; board[curr.first][curr.second] = nothing; check(); if ((turn && CheckWhite) || (!turn && CheckBlack)) { board[dest.first][dest.second] = destination; board[curr.first][curr.second] = current; check(); return false; } return true; } void Chess::e_pCheck(){ if (en_passant.first != -1) { if ((turn && board[en_passant.first][en_passant.second].colour != white) || (!turn && board[en_passant.first][en_passant.second].colour != black)) en_passant = { -1, -1 }; } } step_results Chess::make_step(const std::string& str) { check(); int row, col; if (str == "-1") { if (turn) std::cout << "Black wins\n"; else std::cout << "White win\n"; return static_cast<step_results>(2); } if (str == "file") { to_file("output.txt"); return static_cast<step_results>(3); } int t = correct_str(str); if (t != 0) { std::pair<int, int> curr, dest; if (t == 1 || t == 3) { curr = { int(str[1]) - int('1'), int(str[0]) - int('a') }; dest = { int(str[4]) - int('1'), int(str[3]) - int('a') }; if (board[curr.first][curr.second].type != P) return static_cast<step_results>(0); } else if (t == 2 || t == 4) { curr = { int(str[2]) - int('1'), int(str[1]) - int('a') }; dest = { int(str[5]) - int('1'), int(str[4]) - int('a') }; if (int(board[curr.first][curr.second].type) != int(str[0])) return static_cast<step_results>(0); } if (curr.first == dest.first && curr.second == dest.second) return static_cast<step_results>(0); if ((turn && board[curr.first][curr.second].colour != white) || (!turn && board[curr.first][curr.second].colour != black)) return static_cast<step_results>(0); if (t > 2) { if (attack(curr, dest)) { e_pCheck(); turn = !turn; return static_cast<step_results>(1); } else return static_cast < step_results>(0); } else if (move(curr, dest)) { e_pCheck(); turn = !turn; return static_cast < step_results>(1); } else return static_cast < step_results>(0); } else return static_cast < step_results>(0); /* if (str == "-1") { return (turn ? 2 : 3); } else { int row_c, col_c, row_d, col_d; int t = correct_str(str); std::cout << t << " = t\n"; if (t == 1 || t == 3) { row_c = int(str[1]) - int('1'); col_c = int(str[0]) - int('a'); if (board[row_c][col_c].type != P) return 0; row_d = int(str[4]) - int('1'); col_d = int(str[3]) - int('a'); } else if (t == 2 || t == 4) { row_c = int(str[2]) - int('1'); col_c = int(str[1]) - int('a'); std::cout << int(str[0]) << " " << board[row_c][col_c].type << "\n"; if (int(board[row_c][col_c].type) != int(str[0])) return 0; row_d = int(str[5]) - int('1'); col_d = int(str[4]) - int('a'); } else return 0; if ((turn && board[row_c][col_c].colour != white) || (!turn && board[row_c][col_c].colour != black)) return 0; if (t == 1 || t == 2) if (move({ row_c, col_c }, { row_d, col_d })) { e_pCheck(); turn = !turn; check(); return 1; } if (t == 3 || t == 4) if (attack({ row_c, col_c }, { row_d, col_d })) { e_pCheck(); turn = !turn; check(); return 1; } //std::cout << str << " " << row_c << " " << col_c << " " << row_d << " " << col_d << "\n"; return 0; }*/ } int Chess::correct_str(const std::string& str) { //std::cout << str[0] << " " << str[1] << " " << str[2] << " " << str[3] << " " << str[4] << "\n"; if (str.length() > 6) return 0; if (str[0] >= 'a' && str[0] <= 'h') { if (str[1] >= '1' && str[1] <= '8' && str[3] >= 'a' && str[3] <= 'h' && str[4] >= '1' && str[4] <= '8') if (str[2] == '-') return 1; else if (str[2] == 'x') return 3; } else if (str[0] == 'N' || str[0] == 'R' || str[0] == 'B' || str[0] == 'Q' || str[0] == 'K') { if (correct_str(str.substr(1, 5)) == 1) return 2; else if (correct_str(str.substr(1, 5)) == 3) return 4; } return 0; } std::ostream& operator<<(std::ostream& stream, const Chess& game) { //stream << head << "\n"; for (int i = 7; i >= 0; stream << "\n", --i) { //stream << left[i]; for (int j = 0; j < 8; ++j) stream << char(game.board[i][j].colour) << char(game.board[i][j].type) << " "; } return stream; } void Chess::to_file(const char* fname) const { std::ofstream fout(fname); fout << *this; fout.close(); } void Chess::print() const{ for (int i = 7; i >= 0; --i) for (int j = 0; j < 8; ++j) ColorPrint(3 * j, 7-i, F_L_WHITE, "%c%c ", char(board[i][j].colour), char(board[i][j].type)); } /*void Chess::test() { std::cout << CheckWhite << " " << CheckBlack << "\n"; turn = false; std::cout << move({ 7, 4 }, { 6, 4 }) << "\n"; std::cout << *this << "\n"; }*/
3c0621eacb18d6fad00a14b6331f1f5a3e630437
957c1698bd897989d99b0e938940b0509972bcf1
/src/webServerHandlers.hpp
27fe6c6c3354edf41956f9b64fd4b526d0f62fb7
[]
no_license
krozhkov/wifi_thermometer
0006907bdd1d8ecd0ac2ed4c53a267acdd21e53e
afe6b5972c119493a7ad6dd655019827d95029de
refs/heads/master
2021-01-11T15:28:26.509336
2017-01-30T21:15:54
2017-01-30T21:15:54
80,354,288
0
0
null
null
null
null
UTF-8
C++
false
false
231
hpp
#ifndef _WEB_SERVER_HANDLERS_H_ #define _WEB_SERVER_HANDLERS_H_ #include <Arduino.h> #include <ESP8266WebServer.h> namespace web { extern ESP8266WebServer server; void initWebServer(); } #endif /* _WEB_SERVER_HANDLERS_H_ */
b6e908c47d8e4f23bd354ed28717e03ea2df0ce0
3e4852221de7e4c7ac719c58b78d42b5dc763de4
/src/Execute.h
e88119e5ffd3e6d511a5abcf5b710d46b5e70bcf
[]
no_license
HASH4114/GL
eb8a58ecb956c0344e6d977752662db7b0dc76fd
f5609c6b389966c611a26f32ddd5e0c495a67674
refs/heads/master
2016-09-05T14:33:22.614956
2015-03-30T15:36:09
2015-03-30T15:36:09
31,585,056
0
0
null
null
null
null
UTF-8
C++
false
false
319
h
#ifndef EXECUTE_H #define EXECUTE_H #include <map> #include "Symbols.h" #include "Symbol.h" class Execute { public: Execute(Symbol* p); static std::map<std::string, int> exec_variables; static std::map<std::string, const int> exec_const; void run(); private: Symbol* top; }; #endif
17f62f30014fa8c65f2ea88ec41c45499769906d
8833ddc47f46c20c9336ade7e17910f020ac3c81
/third-party/CLI11/examples/prefix_command.cpp
dcf4f7ff323eb2a7bb09f6b2394fa66d4d63b5ae
[ "BSD-2-Clause", "BSD-3-Clause" ]
permissive
boschmitt/losys
342c0cfa942b7ebe628d1a0253842e8a62c46fbb
0092c559fa8f771121e6ddeb59eae12421b14cd4
refs/heads/master
2019-07-19T08:28:07.205860
2017-11-13T15:30:41
2017-11-13T15:30:41
108,244,920
1
0
null
null
null
null
UTF-8
C++
false
false
745
cpp
#include "CLI/CLI.hpp" int main(int argc, char **argv) { CLI::App app("Prefix command app"); app.prefix_command(); std::vector<int> vals; app.add_option("--vals,-v", vals)->expected(1); std::vector<std::string> more_comms; try { more_comms = app.parse(argc, argv); } catch(const CLI::ParseError &e) { return app.exit(e); } std::cout << "Prefix:"; for(int v : vals) std::cout << v << ":"; std::cout << std::endl << "Remaining commands: "; // Perfer to loop over from beginning, not "pop" order std::reverse(std::begin(more_comms), std::end(more_comms)); for(auto com : more_comms) std::cout << com << " "; std::cout << std::endl; return 0; }
350e848b0d87cfeb50bab43b2bd61af875ee2c1d
daca927aabb36f6a7d6519b0bb39558c02d2f2d3
/src/ECS/Components/HitboxComponent.h
4ff8d9c5dfec5e5e6efa47a19d04aa82f27d1278
[]
no_license
Luceurre/Bomberman
b4391369f5f3af894fdff77bb554dc07d4ccec9e
647da300c15422dd2e966f2306c18bc22e6f8d5b
refs/heads/master
2022-11-05T17:26:44.051039
2020-06-18T00:19:14
2020-06-18T00:19:14
270,341,424
0
0
null
null
null
null
UTF-8
C++
false
false
2,206
h
// // Created by pglandon on 6/1/20. // #ifndef BOMBERMAN_HITBOXCOMPONENT_H #define BOMBERMAN_HITBOXCOMPONENT_H #include "Components.h" class TrueHitboxComponent; // An upgrade of the Position Component, where we add a width and height. // dependencies: Position. // JUST FOR DRAWING!!! class HitboxComponent : public Component { public: int width, height; PositionComponent* positionComponent; inline HitboxComponent(int w, int h) : width(w), height(h) { positionComponent = nullptr; } inline HitboxComponent() : HitboxComponent(0, 0) { } inline void init() override { if (!entity->hasComponent<PositionComponent>()) { warn("using default Position."); entity->addComponents<PositionComponent>(); } if (!entity->hasComponent<TrueHitboxComponent>()) { entity->addComponents<TrueHitboxComponent>(width, height); } positionComponent = &entity->getComponent<PositionComponent>(); } }; // For physics (because assets hitboxes != physics hitboxes...) class TrueHitboxComponent : public Component { public: // Shifting from top left by default! int shiftx, shifty, width, height; PositionComponent* positionComponent; HitboxComponent* hitboxComponent; inline TrueHitboxComponent(int w, int h, int sx, int sy) { shiftx = sx; shifty = sy; width = w; height = h; positionComponent = nullptr; } inline TrueHitboxComponent(int w, int h) : TrueHitboxComponent(w, h, 0, 0) { } inline void init() override { if (!entity->hasComponent<PositionComponent>()) { entity->addComponents<PositionComponent>(); warn("default position"); } positionComponent = &entity->getComponent<PositionComponent>(); } inline SDL_Rect getHitbox() { return SDL_Rect{positionComponent->posX + shiftx, positionComponent->posY + shifty, width, height}; } inline SDL_Rect getHitbox(int vx, int vy) { return SDL_Rect{positionComponent->posX + shiftx + vx, positionComponent->posY + shifty + vy, width, height}; } }; #endif //BOMBERMAN_HITBOXCOMPONENT_H
ae96fefdda8780b19dbad57da9fb208e2f447092
6a6487cb64424d4ccdc05d3bb6607e8976517a80
/ARM/m3/CBwork/AES/Rijndael.h
6c989a0c4bbae621dda5bbbb9a870120749aa170
[]
no_license
trueman1990/VistaModels
79d933a150f80166c9062294f4725b812bb5d4fc
5766de72c844a9e14fa65cb752ea81dfd6e7c42a
refs/heads/master
2021-06-08T22:02:32.737552
2017-01-23T16:10:23
2017-01-23T16:10:23
null
0
0
null
null
null
null
UTF-8
C++
false
false
6,160
h
//Rijndael.h #ifndef __RIJNDAEL_H__ #define __RIJNDAEL_H__ #include <cstring> using namespace std; //Rijndael (pronounced Reindaal) is a block cipher, designed by Joan Daemen and Vincent Rijmen as a candidate algorithm for the AES. //The cipher has a variable block length and key length. The authors currently specify how to use keys with a length //of 128, 192, or 256 bits to encrypt blocks with al length of 128, 192 or 256 bits (all nine combinations of //key length and block length are possible). Both block length and key length can be extended very easily to // multiples of 32 bits. //Rijndael can be implemented very efficiently on a wide range of processors and in hardware. //This implementation is based on the Java Implementation used with the Cryptix toolkit found at: //http://www.esat.kuleuven.ac.be/~rijmen/rijndael/rijndael.zip //Java code authors: Raif S. Naffah, Paulo S. L. M. Barreto //This Implementation was tested against KAT test published by the authors of the method and the //results were identical. class CRijndael { public: //Operation Modes //The Electronic Code Book (ECB), Cipher Block Chaining (CBC) and Cipher Feedback Block (CFB) modes //are implemented. //In ECB mode if the same block is encrypted twice with the same key, the resulting //ciphertext blocks are the same. //In CBC Mode a ciphertext block is obtained by first xoring the //plaintext block with the previous ciphertext block, and encrypting the resulting value. //In CFB mode a ciphertext block is obtained by encrypting the previous ciphertext block //and xoring the resulting value with the plaintext. enum { ECB=0, CBC=1, CFB=2 }; private: enum { DEFAULT_BLOCK_SIZE=16 }; enum { MAX_BLOCK_SIZE=32, MAX_ROUNDS=14, MAX_KC=8, MAX_BC=8 }; //Auxiliary Functions //Multiply two elements of GF(2^m) static int Mul(int a, int b) { return (a != 0 && b != 0) ? sm_alog[(sm_log[a & 0xFF] + sm_log[b & 0xFF]) % 255] : 0; } //Convenience method used in generating Transposition Boxes static int Mul4(int a, char b[]) { if(a == 0) return 0; a = sm_log[a & 0xFF]; int a0 = (b[0] != 0) ? sm_alog[(a + sm_log[b[0] & 0xFF]) % 255] & 0xFF : 0; int a1 = (b[1] != 0) ? sm_alog[(a + sm_log[b[1] & 0xFF]) % 255] & 0xFF : 0; int a2 = (b[2] != 0) ? sm_alog[(a + sm_log[b[2] & 0xFF]) % 255] & 0xFF : 0; int a3 = (b[3] != 0) ? sm_alog[(a + sm_log[b[3] & 0xFF]) % 255] & 0xFF : 0; return a0 << 24 | a1 << 16 | a2 << 8 | a3; } public: //CONSTRUCTOR CRijndael(); //DESTRUCTOR virtual ~CRijndael(); //Expand a user-supplied key material into a session key. // key - The 128/192/256-bit user-key to use. // chain - initial chain block for CBC and CFB modes. // keylength - 16, 24 or 32 bytes // blockSize - The block size in bytes of this Rijndael (16, 24 or 32 bytes). void MakeKey(char const* key, char const* chain, int keylength=DEFAULT_BLOCK_SIZE, int blockSize=DEFAULT_BLOCK_SIZE); private: //Auxiliary Function void Xor(char* buff, char const* chain) { if(false==m_bKeyInit) NULL; //throw exception(sm_szErrorMsg1); for(int i=0; i<m_blockSize; i++) *(buff++) ^= *(chain++); } //Convenience method to encrypt exactly one block of plaintext, assuming //Rijndael's default block size (128-bit). // in - The plaintext // result - The ciphertext generated from a plaintext using the key void DefEncryptBlock(char const* in, char* result); //Convenience method to decrypt exactly one block of plaintext, assuming //Rijndael's default block size (128-bit). // in - The ciphertext. // result - The plaintext generated from a ciphertext using the session key. void DefDecryptBlock(char const* in, char* result); public: //Encrypt exactly one block of plaintext. // in - The plaintext. // result - The ciphertext generated from a plaintext using the key. void EncryptBlock(char const* in, char* result); //Decrypt exactly one block of ciphertext. // in - The ciphertext. // result - The plaintext generated from a ciphertext using the session key. void DecryptBlock(char const* in, char* result); void Encrypt(char const* in, char* result, size_t n, int iMode=ECB); void Decrypt(char const* in, char* result, size_t n, int iMode=ECB); //Get Key Length int GetKeyLength() { if(false==m_bKeyInit) NULL; //throw exception(sm_szErrorMsg1); return m_keylength; } //Block Size int GetBlockSize() { if(false==m_bKeyInit) NULL; //throw exception(sm_szErrorMsg1); return m_blockSize; } //Number of Rounds int GetRounds() { if(false==m_bKeyInit) NULL; //throw exception(sm_szErrorMsg1); return m_iROUNDS; } void ResetChain() { memcpy(m_chain, m_chain0, m_blockSize); } public: //Null chain static char const* sm_chain0; private: static const int sm_alog[256]; static const int sm_log[256]; static const char sm_S[256]; static const char sm_Si[256]; static const int sm_T1[256]; static const int sm_T2[256]; static const int sm_T3[256]; static const int sm_T4[256]; static const int sm_T5[256]; static const int sm_T6[256]; static const int sm_T7[256]; static const int sm_T8[256]; static const int sm_U1[256]; static const int sm_U2[256]; static const int sm_U3[256]; static const int sm_U4[256]; static const char sm_rcon[30]; static const int sm_shifts[3][4][2]; //Error Messages static char const* sm_szErrorMsg1; static char const* sm_szErrorMsg2; //Key Initialization Flag bool m_bKeyInit; //Encryption (m_Ke) round key int m_Ke[MAX_ROUNDS+1][MAX_BC]; //Decryption (m_Kd) round key int m_Kd[MAX_ROUNDS+1][MAX_BC]; //Key Length int m_keylength; //Block Size int m_blockSize; //Number of Rounds int m_iROUNDS; //Chain Block char m_chain0[MAX_BLOCK_SIZE]; char m_chain[MAX_BLOCK_SIZE]; //Auxiliary private use buffers int tk[MAX_KC]; int a[MAX_BC]; int t[MAX_BC]; }; #endif // __RIJNDAEL_H__
4e78807d2943444e94bb5fbe6c2f03f50f88a491
90c95fd7a5687b1095bf499892b8c9ba40f59533
/sprout/functional/shift_right.hpp
454f767240c9ea7f0414fa1e9fac8af4f457bd85
[ "BSL-1.0" ]
permissive
CreativeLabs0X3CF/Sprout
af60a938fd12e8439a831d4d538c4c48011ca54f
f08464943fbe2ac2030060e6ff20e4bb9782cd8e
refs/heads/master
2021-01-20T17:03:24.630813
2016-08-15T04:44:46
2016-08-15T04:44:46
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,173
hpp
/*============================================================================= Copyright (c) 2011-2016 Bolero MURAKAMI https://github.com/bolero-MURAKAMI/Sprout Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) =============================================================================*/ #ifndef SPROUT_FUNCTIONAL_SHIFT_RIGHT_HPP #define SPROUT_FUNCTIONAL_SHIFT_RIGHT_HPP #include <utility> #include <sprout/config.hpp> #include <sprout/utility/forward.hpp> #include <sprout/functional/transparent.hpp> namespace sprout { // // shift_right // template<typename T = void> struct shift_right; template<> struct shift_right<void> : public sprout::transparent<> { public: template<typename T, typename U> SPROUT_CONSTEXPR decltype(std::declval<T>() >> std::declval<U>()) operator()(T&& x, U&& y) const SPROUT_NOEXCEPT_IF_EXPR(std::declval<T>() >> std::declval<U>()) { return SPROUT_FORWARD(T, x) >> SPROUT_FORWARD(U, y); } }; } // namespace sprout #endif // #ifndef SPROUT_FUNCTIONAL_SHIFT_RIGHT_HPP
6f9fb505f2e3f8e69916f37022360859796c903e
4bcee8419c29bfcef6bfb8ca9a17b26ad8f16ef8
/rpm/3/3.2.cpp
6447afbb54613e98a83053964ba135e53c27fd40
[]
no_license
SMAK-OPERATOR/cp
21f23d69fa98ac9fe6fdcf351df9bb8161b8e03e
545d93ad2c7ecb148208528dace58bda62aa41d8
refs/heads/master
2023-01-04T08:50:39.471089
2020-11-02T13:14:26
2020-11-02T13:14:26
272,426,318
0
0
null
null
null
null
UTF-8
C++
false
false
4,690
cpp
// ะžะฟะธัะฐั‚ัŒ ัั‚ั€ัƒะบั‚ัƒั€ัƒ ั ะธะผะตะฝะตะผ WORKER, ัะพะดะตั€ะถะฐั‰ัƒัŽ ัะปะตะดัƒัŽั‰ะธะต ะฟะพะปั: ั„ะฐะผะธะปะธั ะธ ะธะฝะธั†ะธะฐะปั‹ ั€ะฐะฑะพั‚ะฝะธะบะฐ; ะฝะฐะทะฒะฐะฝะธะต ะทะฐะฝะธะผะฐะตะผะพะนฬ† ะดะพะปะถะฝะพัั‚ะธ; ะณะพะด ะฟะพัั‚ัƒะฟะปะตะฝะธั ะฝะฐ ั€ะฐะฑะพั‚ัƒ. // ะะฐะฟะธัะฐั‚ัŒ ะฟั€ะพะณั€ะฐะผะผัƒ, ะฒั‹ะฟะพะปะฝััŽั‰ัƒัŽ ัะปะตะดัƒัŽั‰ะธะต ะดะตะธฬ†ัั‚ะฒะธั: // โ€ข ะฒะฒะพะด ั ะบะปะฐะฒะธะฐั‚ัƒั€ั‹ ะดะฐะฝะฝั‹ั… ะฒ ะผะฐััะธะฒ; // โ€ข ะทะฐะฟะธัะธ ะดะพะปะถะฝั‹ ะฑั‹ั‚ัŒ ั€ะฐะทะผะตั‰ะตะฝั‹ ะฟะพ ะฐะปั„ะฐะฒะธั‚ัƒ; // โ€ข ะฒั‹ะฒะพะด ะฝะฐ ะดะธัะฟะปะตะธฬ† ั„ะฐะผะธะปะธะธฬ† ั€ะฐะฑะพั‚ะฝะธะบะพะฒ, ั‡ะตะธฬ† ัั‚ะฐะถ ั€ะฐะฑะพั‚ั‹ ะฒ ะพั€ะณะฐะฝะธะทะฐั†ะธะธ ะฟั€ะตะฒั‹ัˆะฐะตั‚ ะทะฝะฐั‡ะตะฝะธะต, ะฒะฒะตะดะตะฝะฝะพะต ั ะบะปะฐะฒะธะฐั‚ัƒั€ั‹; // โ€ข ะตัะปะธ ั‚ะฐะบะธั… ั€ะฐะฑะพั‚ะฝะธะบะพะฒ ะฝะตั‚, ะฒั‹ะฒะตัั‚ะธ ะฝะฐ ะดะธัะฟะปะตะธฬ† ัะพะพั‚ะฒะตั‚ัั‚ะฒัƒัŽั‰ะตะต ัะพะพะฑั‰ะตะฝะธะต. #include <iostream> #include <cmath> #include <cstring> using namespace std; int main() { struct worker { char name[21]; char pos[21]; int year; int k; }; int n; char name[100]; char pos[100]; int k; int j; do{ fflush(stdin); cin.clear(); cout << "Enter amount of workers: "; cin >> n; if ((!(cin))) { k = 1; cout << "Invalid input, try again" << endl; } else k = 0; }while(k == 1); worker z[n]; for(int i = 0;i != n;i++) { if (i == 0) cout << "\nFirst worker \n"; else cout << "\nNext worker \n"; fflush(stdin); cin.clear(); cout << "\nEnter name: "; cin.getline(name,100); j = 0; for (int m = 0; name[m] != '\0'; m++) { if ((name[m] == ' ') && (name[m+1] != ' ')) { z[i].name[j] = name[m]; j++; } else if ((name[m] != ' ') && (name[m] != '0') && (name[m] != '1') && (name[m] != '2') && (name[m] != '3') && (name[m] != '4') && (name[m] != '5') && (name[m] != '6') && (name[m] != '7') && (name[m] != '8') && (name[m] != '9')) { z[i].name[j] = name[m]; j++; } } z[i].name[j]='\0'; fflush(stdin); cin.clear(); cout << "\nEnter Posititon: "; cin.getline(pos,100); j = 0; for (int m = 0; pos[m] != '\0'; m++) { if (pos[m] != ' ') { z[i].pos[j] = pos[m]; j++; } } z[i].pos[j]='\0'; do{ fflush(stdin); cin.clear(); cout << "\nEnter year of employment: "; cin >> z[i].year; if ((z[i].year > 2020) || (z[i].year < 0) || (!(cin))) { k = 1; cout << "Invalid input, try again" << endl; } else k = 0; }while(k == 1); } worker buf; char alp[27] = "abcdefghijklmnopqrstuvwxyz"; for (int i = 0;i != n;i++) { int j = 0; do { if(z[i].name[0] == alp[j]) { z[i].k = j+1; // cout << z[i].k << endl; j = 27; } j++; } while (j != 28); } for(int i = 0; i != n - 1;i++) { for (int j = n - 1; j != i; j--) { if(z[j].k < z[j-1].k) { strcpy(buf.name,z[j-1].name); strcpy(buf.pos , z[j-1].pos); buf.year = z[j-1].year; buf.k = z[j-1].k; strcpy(z[j-1].name , z[j].name); strcpy(z[j-1].pos , z[j].pos); z[j-1].year = z[j].year; z[j-1].k = z[j].k; strcpy(z[j].name , buf.name); strcpy(z[j].pos , buf.pos); z[j].year = buf.year; z[j].k = buf.k; } } } cout << endl; for(int i = 0;i != n;i++ ) { cout << z[i].name << " "; cout << z[i].pos << " "; cout << z[i].year << " "; // cout << z[i].k << endl; cout << endl; } int st; cout << "\nEnter with what experience show workers " << endl; cin >> st; int m = 0; for(int i = 0;i != n; i++) { if((2020 - z[i].year) > st ) { cout << z[i].name << endl;; m = 1; } } if (m == 0) cout << "There are no workers with such work experience" <<endl; system("pause"); }
0eede0f27282d11a4a6db8121dac0851637e6411
88949f2ef38ed853a1749d6394a92eb3e97bf8fd
/1_year/1_term/2/2-1/main.cpp
8901cafa4e146c7cad8450641e4fcaa83dd6bf7a
[]
no_license
TanVD/SpbSU-Homeworks
c64f6d3a812492daff1df058d178f34fab292613
18ec404eee91df47a264942a08637113e06abefa
refs/heads/master
2021-01-21T04:36:49.194487
2016-05-20T14:25:49
2016-05-20T14:25:49
30,809,072
0
1
null
2016-05-20T14:25:49
2015-02-14T21:17:11
C++
UTF-8
C++
false
false
743
cpp
#include <stdio.h> int recursiveFibbonachi(int number) { if (number < 1) return 0; if (number == 1) return 1; return recursiveFibbonachi(number - 1) + recursiveFibbonachi(number - 2); } int iterativeFibbonachi(int number) { int num1Fib = 1; int num2Fib = 0; int result = 0; for (int i = 1; i < number + 1; i++) { result = num2Fib + num1Fib; num1Fib = num2Fib; num2Fib = result; } return num2Fib; } int main() { printf("Print the last number of sequence: "); int number = 0; scanf("%d", &number); printf("Iterative algorithm give %d\n", iterativeFibbonachi(number)); printf("Recursive algorithm give %d", recursiveFibbonachi(number)); return 0; }
ff7a7024a441b556c0b11769e58eebc137a9361f
6bfa09408bfdf63b3469fdd83470c3e78b65950f
/agregarcorreos.h
72f6b422403e6fe7f0427edd475a774d2424b219
[]
no_license
miguelhasbun/Proyecto-Colas-20
1f54a94207593191327ea97a1ee90d82e43a7d47
4cb00b6aede0f9e89eb0de9be87135051395ec1e
refs/heads/master
2021-01-22T11:28:50.112956
2017-05-29T02:53:59
2017-05-29T02:53:59
92,701,772
0
0
null
null
null
null
UTF-8
C++
false
false
412
h
#ifndef AGREGARCORREOS_H #define AGREGARCORREOS_H #include <QMainWindow> namespace Ui { class agregarcorreos; } class agregarcorreos : public QMainWindow { Q_OBJECT public: explicit agregarcorreos(QWidget *parent = 0); ~agregarcorreos(); private slots: void on_radioButton_clicked(); void on_radioButton_2_clicked(); private: Ui::agregarcorreos *ui; }; #endif // AGREGARCORREOS_H
fc885ecb75885b2d8a24b626ab044b699206af71
ed80b494a6dfadc4631f4a7df2b77f78aa658d9a
/src/oknoz32druzynami.cpp
a8464fc65ecfaa162eb64099c997d6c54dc20ae6
[]
no_license
poliness/football-championship-simulator
8a7380c9a521406120355458bd139d4a8491a7eb
48751cf6243ffe6512fe19aaac8623d2089272ee
refs/heads/master
2020-04-17T15:40:48.838752
2019-01-20T20:53:15
2019-01-20T20:53:15
null
0
0
null
null
null
null
UTF-8
C++
false
false
4,001
cpp
#include "oknoz32druzynami.h" #include "biblioteki.h" #include "druzyna.h" #include "metody.h" #include <qtablewidget.h> void OknoZ32Druzynami::closeEvent(QCloseEvent *bar) { foreach(QWidget *widget, qApp->topLevelWidgets()) { if (widget->windowTitle() == "Spis druzyn" || widget->windowTitle() == "Rozklad druzyn" || widget->windowTitle() == "Podsumowanie Fazy Grupowej" || widget->windowTitle() == "Mecze Fazy Grupowej" || widget->windowTitle() == "Faza grupowa" || widget->windowTitle() == "Faza Pucharowa" || widget->windowTitle() == "Zakonczenie Mistrzostw") widget->close(); if (widget->inherits("QMainWindow")) (widget)->setEnabled(true); } } OknoZ32Druzynami::OknoZ32Druzynami(QWidget *parent) : QWidget(parent) { window = 0; ui.setupUi(this); this->setWindowTitle("Spis druzyn"); setWindowFlags(Qt::CustomizeWindowHint | Qt::WindowTitleHint); setAttribute(Qt::WA_DeleteOnClose); connect(ui.dalejButton, SIGNAL(released()), this, SLOT(odpalOknoMeczowGrupowych())); this->setMaximumHeight(550); this->setMaximumWidth(350); int COL = 3, ROW = 33; // literki do grup // dwie osobne czcionki QFont fontNaglowka("Helvetica", 10, QFont::Bold); QFont fontNazw("Helvetica", 8, QFont::Bold); QColor kolorki[8]; kolorki[0] = Qt::red; kolorki[1] = Qt::darkCyan; kolorki[2] = Qt::darkMagenta; kolorki[3] = Qt::green; kolorki[4] = Qt::cyan; kolorki[5] = Qt::darkRed; kolorki[6] = Qt::darkGreen; kolorki[7] = Qt::gray; table = new QTableWidget(); table->verticalHeader()->setVisible(false); table->horizontalHeader()->setVisible(false); table->setRowCount(ROW); table->setColumnCount(COL); // i kazdej kolumnie i wierszowi odpowiednie 'domyslne' szerokosci. table->horizontalHeader()->setDefaultSectionSize(65); table->verticalHeader()->setDefaultSectionSize(22); table->verticalHeader()->setResizeContentsPrecision(QHeaderView::Fixed); table->horizontalHeader()->setResizeContentsPrecision(QHeaderView::Fixed); table->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); table->setColumnWidth(1, 123); table->setColumnWidth(2, 123); table->setEditTriggers(QAbstractItemView::NoEditTriggers); QTableWidgetItem* numer = new QTableWidgetItem("Nr."); QTableWidgetItem* nazwa = new QTableWidgetItem("Nazwa"); QTableWidgetItem* kontynent = new QTableWidgetItem("Kontynent"); table->setItem(0, 0, numer); table->setItem(0, 1, nazwa); table->setItem(0, 2, kontynent); for (int i = 0; i < 3; i++){ table->item(0, i)->setTextAlignment(Qt::AlignCenter); table->item(0, i)->setFont(fontNaglowka); table->item(0, i)->setBackground(kolorki[0]); } ui.kolumnaDruzynLayout->addWidget(table); table->setContentsMargins(0, 0, 0, 0); } void OknoZ32Druzynami::odpalOknoMeczowGrupowych(){ if (window == 0){ window = new rankingwindow(); window->show(); window->rozpiszMiejscaWRankingu(druzyny); window->setAttribute(Qt::WA_DeleteOnClose); } else window->raise(); } OknoZ32Druzynami::~OknoZ32Druzynami() { delete table; } void OknoZ32Druzynami::rozpisz32Druzyny(list<Druzyna> lista){ this->druzyny.clear(); this->druzyny = lista; vector<Druzyna> temp; for (auto it : lista) temp.push_back(it); for (int i = 0; i < 32; i++){ table->setItem(i+1, 0, new QTableWidgetItem(QString(QString::number(i + 1)))); table->setItem(i + 1, 1, new QTableWidgetItem(QString::fromStdString(temp[i].nazwa))); string kontynent; switch (temp[i].kontynent) { case 1: kontynent = "Azja"; break; case 6: kontynent = "Europa"; break; case 2: kontynent = "Afryka"; break; case 3: kontynent = "Ameryka Pln."; break; case 4: kontynent = "Ameryka Pld."; break; case 5: kontynent = "Australia i Oc."; break; } table->setItem(i+1, 2, new QTableWidgetItem(QString::fromStdString(kontynent))); } for (int k = 0; k < 33; k++) for (int j = 0; j < 3; j++) table->item(k, j)->setTextAlignment(Qt::AlignCenter); }
8dc4ff29b8f243a20305349e13a84cfe0528e057
eea015b7443918606679e0cb17a50444c493aa3c
/ql_Manager.h
386f04b13fa404daf0af97f057ccb8054eb9e105
[ "MIT" ]
permissive
donglinz/database
96be10d0b13e1db01ef97d52f23b15b3914e7745
2fd6cc7f4f225eadaa7fbb430e42d543473edfa3
refs/heads/master
2022-03-11T14:23:09.849471
2019-11-19T16:34:27
2019-11-19T16:34:27
76,961,180
40
5
null
null
null
null
WINDOWS-1252
C++
false
false
373
h
#pragma once #include <exception> #include "ql_select.h" #include "ql_create.h" #include "ql_insert.h" #include "ql_update.h" #include "ql_delete.h" class ql_Manager { public: ql_Manager(); void run(string q_line); void getStanderString(string & q_line); ~ql_Manager(); private: const std::exception ex_sql_empty = std::exception("[ERROR] sqlร“รฏยพรครŽยชยฟร•!"); };
[ "zhuang donglin@DESKTOP-SDK2INM" ]
zhuang donglin@DESKTOP-SDK2INM
2b6c1449ec0df73ae75f943daffe813a31e0db9c
473fc28d466ddbe9758ca49c7d4fb42e7d82586e
/app/src/main/java/com/syd/source/aosp/external/mesa3d/src/gallium/state_trackers/clover/llvm/compat.hpp
81592ce7021762892ac1f9e1c134e8785d324970
[]
no_license
lz-purple/Source
a7788070623f2965a8caa3264778f48d17372bab
e2745b756317aac3c7a27a4c10bdfe0921a82a1c
refs/heads/master
2020-12-23T17:03:12.412572
2020-01-31T01:54:37
2020-01-31T01:54:37
237,205,127
4
2
null
null
null
null
UTF-8
C++
false
false
5,974
hpp
// // Copyright 2016 Francisco Jerez // // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without limitation // the rights to use, copy, modify, merge, publish, distribute, sublicense, // and/or sell copies of the Software, and to permit persons to whom the // Software is furnished to do so, subject to the following conditions: // // The above copyright notice and this permission notice shall be included in // all copies or substantial portions of the Software. // // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL // THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR // OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, // ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR // OTHER DEALINGS IN THE SOFTWARE. // /// /// \file /// Some thin wrappers around the Clang/LLVM API used to preserve /// compatibility with older API versions while keeping the ifdef clutter low /// in the rest of the clover::llvm subtree. In case of an API break please /// consider whether it's possible to preserve backwards compatibility by /// introducing a new one-liner inline function or typedef here under the /// compat namespace in order to keep the running code free from preprocessor /// conditionals. /// #ifndef CLOVER_LLVM_COMPAT_HPP #define CLOVER_LLVM_COMPAT_HPP #include "util/algorithm.hpp" #include <llvm/Linker/Linker.h> #include <llvm/Transforms/IPO.h> #include <llvm/Target/TargetMachine.h> #if HAVE_LLVM >= 0x0400 #include <llvm/Support/Error.h> #else #include <llvm/Support/ErrorOr.h> #endif #if HAVE_LLVM >= 0x0307 #include <llvm/IR/LegacyPassManager.h> #include <llvm/Analysis/TargetLibraryInfo.h> #else #include <llvm/PassManager.h> #include <llvm/Target/TargetLibraryInfo.h> #include <llvm/Target/TargetSubtargetInfo.h> #include <llvm/Support/FormattedStream.h> #endif #include <clang/Frontend/CodeGenOptions.h> #include <clang/Frontend/CompilerInstance.h> namespace clover { namespace llvm { namespace compat { #if HAVE_LLVM >= 0x0307 typedef ::llvm::TargetLibraryInfoImpl target_library_info; #else typedef ::llvm::TargetLibraryInfo target_library_info; #endif inline void set_lang_defaults(clang::CompilerInvocation &inv, clang::LangOptions &lopts, clang::InputKind ik, const ::llvm::Triple &t, clang::PreprocessorOptions &ppopts, clang::LangStandard::Kind std) { #if HAVE_LLVM >= 0x0309 inv.setLangDefaults(lopts, ik, t, ppopts, std); #else inv.setLangDefaults(lopts, ik, std); #endif } inline void add_link_bitcode_file(clang::CodeGenOptions &opts, const std::string &path) { #if HAVE_LLVM >= 0x0308 opts.LinkBitcodeFiles.emplace_back(::llvm::Linker::Flags::None, path); #else opts.LinkBitcodeFile = path; #endif } #if HAVE_LLVM >= 0x0307 typedef ::llvm::legacy::PassManager pass_manager; #else typedef ::llvm::PassManager pass_manager; #endif inline void add_data_layout_pass(pass_manager &pm) { #if HAVE_LLVM < 0x0307 pm.add(new ::llvm::DataLayoutPass()); #endif } inline void add_internalize_pass(pass_manager &pm, const std::vector<std::string> &names) { #if HAVE_LLVM >= 0x0309 pm.add(::llvm::createInternalizePass( [=](const ::llvm::GlobalValue &gv) { return std::find(names.begin(), names.end(), gv.getName()) != names.end(); })); #else pm.add(::llvm::createInternalizePass(std::vector<const char *>( map(std::mem_fn(&std::string::data), names)))); #endif } inline std::unique_ptr<::llvm::Linker> create_linker(::llvm::Module &mod) { #if HAVE_LLVM >= 0x0308 return std::unique_ptr<::llvm::Linker>(new ::llvm::Linker(mod)); #else return std::unique_ptr<::llvm::Linker>(new ::llvm::Linker(&mod)); #endif } inline bool link_in_module(::llvm::Linker &linker, std::unique_ptr<::llvm::Module> mod) { #if HAVE_LLVM >= 0x0308 return linker.linkInModule(std::move(mod)); #else return linker.linkInModule(mod.get()); #endif } #if HAVE_LLVM >= 0x0307 typedef ::llvm::raw_svector_ostream &raw_ostream_to_emit_file; #else typedef ::llvm::formatted_raw_ostream raw_ostream_to_emit_file; #endif #if HAVE_LLVM >= 0x0307 typedef ::llvm::DataLayout data_layout; #else typedef const ::llvm::DataLayout *data_layout; #endif inline data_layout get_data_layout(::llvm::TargetMachine &tm) { #if HAVE_LLVM >= 0x0307 return tm.createDataLayout(); #else return tm.getSubtargetImpl()->getDataLayout(); #endif } #if HAVE_LLVM >= 0x0309 const auto default_reloc_model = ::llvm::None; #else const auto default_reloc_model = ::llvm::Reloc::Default; #endif template<typename M, typename F> void handle_module_error(M &mod, const F &f) { #if HAVE_LLVM >= 0x0400 if (::llvm::Error err = mod.takeError()) ::llvm::handleAllErrors(std::move(err), [&](::llvm::ErrorInfoBase &eib) { f(eib.message()); }); #else if (!mod) f(mod.getError().message()); #endif } } } } #endif
30f47c46e8952baccb40d0237472fb4b88110b4d
7fb0900c3baa1c5e134ee2c47c5159f4401a3a52
/include/AsteroidCollisionComponent.hpp
3ed3b3d56204227c13d4028c43043abc0d67db26
[]
no_license
mnassabain/Asteroids
df966273ef6efbf4b15e55dade5b663db6493aaf
693626cb2e70119cbdde6909883057dc37eb84a1
refs/heads/master
2023-04-23T07:41:50.823768
2021-05-06T21:29:02
2021-05-06T21:29:02
254,962,300
0
0
null
null
null
null
UTF-8
C++
false
false
348
hpp
#ifndef ASTEROIDCOLLISIONCOMPONENT_HPP #define ASTEROIDCOLLISIONCOMPONENT_HPP #include <CollisionComponent.hpp> class AsteroidCollisionComponent : public CollisionComponent { public: AsteroidCollisionComponent(); AsteroidCollisionComponent(Rect&); void update(Object*); }; #endif /* ASTEROIDCOLLISIONCOMPONENT_HPP */
b77452984b39e66500ebb24d6c203181446a422c
94f3e71f819c692f873225ac5c315e4b91b0f1ee
/Logic/DynamicActor.h
3bee6bc8624cbb19a1ff22796a49e10cab5a2df0
[]
no_license
weichao-kooboo/NeverSalvation
b3be63aa354329312dfac8772314e1c1acdc42d2
c74e536bc7aa5494823609b3a31c0ab0c711b843
refs/heads/master
2020-04-04T13:45:54.075510
2019-12-26T02:59:52
2019-12-26T02:59:52
155,938,203
0
0
null
null
null
null
UTF-8
C++
false
false
409
h
#pragma once #ifndef NS_DYNAMICACTOR #define NS_DYNAMICACTOR #include "Actor.h" class LOGIC_API DynamicActor :public Actor { public: DynamicActor() { #ifdef NS_DEBUG cout << "DynamicActor\r\n" << endl; #endif // NS_DEBUG Attack = 0; }; unsigned short Attack; virtual ~DynamicActor() { #ifdef NS_DEBUG cout << "DynamicActor delete\r\n" << endl; #endif // NS_DEBUG }; }; #endif // !NS_DYNAMICACTOR
b85da600695cb164accbc1236a949ba7b9bcac5c
62fc36f21a0a0a9ca6f66cf27dcc53c2301b9a2c
/Assignments/CSC-7 Homework/Vo, Kevin - Lab 1 Luhn Algorithm - 42833/main.cpp
fdf0c8cc03a45ecb2069b504a90f7bb47f21395d
[]
no_license
KTVo/RCC
6edd9e45c652b794b829bafe4aabf52d789297c0
36d81e6bc7ef5fe0b2edc25894fc5ad1a71a2e1e
refs/heads/master
2022-11-27T05:21:32.470894
2020-07-22T23:49:45
2020-07-22T23:49:45
272,364,581
0
0
null
null
null
null
UTF-8
C++
false
false
2,216
cpp
/* * File: main.cpp * Name: Kevin Vo * Instructor: Dr. Lehr * Course: CSC-7 (42833) * Date: 3/24/2016 * Assignment: Lab 1 - Luhn Algorithm (FIXED) */ #include <iostream> #include <cstdlib> #include <ctime> using namespace std; //Global Constants //Function Prototypes char rndDgit(); void prpLuhn(char[],int); void Luhn(char[],int); int main() { //Set the random number seed srand(static_cast<unsigned int>(time(0))); const int SIZE=12; char crdCard[SIZE]; //Prepare for Luhn encoding cout<<"A random number created in Prep for Luhn Digit"<<endl; prpLuhn(crdCard,SIZE-2); //Output the preLuhn credit card cout<<crdCard<<endl; //Now create a function that fills the last digit //using the Luhn Algorithm cout<<"The random number with Luhn Encoding, Output Here!"<<endl; //Calculates Luhn's alg. and displays results w/ last digit Luhn(crdCard, SIZE-2); //Exit Stage Right return 0; } void Luhn(char cc[],int nSIZE){ int even = 0, totEven = 0, odd = 0, totOdd = 0, total = 0; //Slips up every odd and even elements // 2 * every even elements //if cc["EVEN ELEMENT"] > 9 then -9 from it //Odd elements, leave it alone //Sum all up for(int elem = 9; elem >= 0; elem--){ if(elem%2!=0){ even = (cc[elem]-48)* 2; if(even > 9) even -= 9; totEven += even; } else{ odd = (cc[elem]-48); totOdd += odd; } } //Calculates and displays Sum of Digits, Check Digit, in/valid total = totOdd + totEven; cout<<"\n---Results---\n"; cout<<"Sum of Digits: "<<total<<endl; total *= 9; total %= 10; cout<<"Check Digit = "<<total<<endl; cout<<"Credit Card is "; if(total != cc[9])cout<<"INVALID."<<endl; else cout<<"VALID."<<endl; } void prpLuhn(char cc[],int n){ //Create a random cc in prep for Luhn checksum for(int i=0;i<n;i++){ cc[i]=rndDgit(); } //Put null terminator at the end for(int i=n;i<=n+1;i++){ cc[i]='\0'; } } char rndDgit(){ return rand()%10+48; }
1b5cfb0e04a7df59a32ef89b636fa591fde42893
90c95fd7a5687b1095bf499892b8c9ba40f59533
/sprout/predef/library.hpp
0e6a12fe6cf2d4fe684d69230d2d7792d68470d8
[ "BSL-1.0" ]
permissive
CreativeLabs0X3CF/Sprout
af60a938fd12e8439a831d4d538c4c48011ca54f
f08464943fbe2ac2030060e6ff20e4bb9782cd8e
refs/heads/master
2021-01-20T17:03:24.630813
2016-08-15T04:44:46
2016-08-15T04:44:46
null
0
0
null
null
null
null
UTF-8
C++
false
false
637
hpp
/*============================================================================= Copyright (c) 2011-2016 Bolero MURAKAMI https://github.com/bolero-MURAKAMI/Sprout Distributed under the sprout Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.sprout.org/LICENSE_1_0.txt) =============================================================================*/ #ifndef SPROUT_PREDEF_LIBRARY_HPP #define SPROUT_PREDEF_LIBRARY_HPP #include <sprout/config.hpp> #include <sprout/predef/library/c.hpp> #include <sprout/predef/library/std.hpp> #endif //#ifndef SPROUT_PREDEF_LIBRARY_HPP
1fca3e1600d2a6efc4ee0a6c0e415a0c4f21db33
0dba4a3016f3ad5aa22b194137a72efbc92ab19e
/albion2/server/snet.h
6f8a171a287363914adc28c4548bbe4457c215f2
[]
no_license
BackupTheBerlios/albion2
11e89586c3a2d93821b6a0d3332c1a7ef1af6abf
bc3d9ba9cf7b8f7579a58bc190a4abb32b30c716
refs/heads/master
2020-12-30T10:23:18.448750
2007-01-26T23:58:42
2007-01-26T23:58:42
39,515,887
0
0
null
null
null
null
UTF-8
C++
false
false
2,540
h
/* * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #ifndef __SNET_H__ #define __SNET_H__ #ifdef WIN32 #include <windows.h> #endif #include <iostream> #include <string> #include <sstream> #include <SDL/SDL.h> #include <SDL/SDL_image.h> #include <engine.h> #include <msg.h> #include <core.h> #include <gfx.h> #include <event.h> #include <camera.h> #include <a2emodel.h> #include <scene.h> #include <ode.h> #include <ode_object.h> #include <light.h> #include <shader.h> #include <a2emap.h> #include <net.h> #include "userman.h" #include "web.h" #include "map.h" using namespace std; class snet { public: snet(engine* e, net* n, userman* um, web* w, smap* sm); ~snet(); enum PACKET_TYPE { PT_TEST, PT_NEW_CLIENT, PT_QUIT_CLIENT, PT_CHAT_MSG, PT_FLAG, PT_VU_LIST, PT_VO_LIST }; enum CHAT_TYPE { CT_WORLD, CT_REGION, CT_PARTY }; enum FLAGS { F_SUCCESS_LOGIN, F_WRONG_UNAME, F_WRONG_PW, F_GET_MAP, F_GET_POS, F_GET_ROT, F_POST_MAP, F_POST_POS, F_POST_ROT, F_MOVE_FORWARD, F_MOVE_BACK }; int process_packet(unsigned int cnum, char* pdata, unsigned int max_len); void send_packet(unsigned int cnum, unsigned int inum, PACKET_TYPE type); void handle_client(unsigned int cnum); void manage_clients(); int process_http_packet(unsigned int cnum, char* pdata, unsigned int max_len); void write_http_header(stringstream* stream, const char* status); void run(); // used for setting packet data from other classes stringstream* get_data(); protected: engine* e; msg* m; core* c; net* n; userman* um; web* w; smap* sm; unsigned int max_packet_size; string tmp; stringstream* buffer; stringstream* data; char* packet_data; char* line; float piover180; }; #endif
00c36e4c2635f8e518928567b8fef010f9d94ec8
8284ae77781d12b3e7a8295111c61e57af843ff0
/huawei_zhishu.cpp
e1600b368e2d420443576e6b540d09f18604d488
[]
no_license
kevinchow1993/vs_cplus
cc8b453a4cc6404f3963859d9f71138c85a4304e
fafa1522870a106fea66154c51edcb30277481c7
refs/heads/master
2020-03-25T10:25:43.883650
2018-08-22T08:07:20
2018-08-22T08:07:20
143,692,902
0
0
null
2018-08-06T12:41:44
2018-08-06T07:36:21
C++
UTF-8
C++
false
false
406
cpp
#include<iostream> #include<cmath> using namespace std; int main(int argc, char const *argv[]) { int num; cin>>num; while(num%2==0){ cout<<2<<" "; num/=2; } for(int i=3;i<sqrt(num);i+=2){ while(num%i==0){ cout<<i<<" "; num/=i; } } if(num>2){ cout<<num<<" "; } cin.get(); cin.get(); return 0; }
fa142d7cced389cc15b55ae74f014ee490f07bc7
ea1328695989667c9ab168facfa1095ffe55639c
/libs/harfbuzz-ng/src/hb-ot-shape-complex-arabic-table.hh
17100497ecb844c0910a18df74ccb8352e19c5e7
[ "LicenseRef-scancode-other-permissive", "MIT-Modern-Variant", "LicenseRef-scancode-unknown-license-reference", "Apache-2.0" ]
permissive
amarullz/libaroma
c075058d9e434bdd2faf6ed1d3e3e008666f3146
cdbe5847d967ae85c442eaf2db7beb08a8cf6713
refs/heads/master
2022-12-22T16:09:39.500801
2022-12-15T02:37:18
2022-12-15T02:37:18
29,760,977
51
33
Apache-2.0
2022-07-11T02:47:17
2015-01-24T01:17:06
C
UTF-8
C++
false
false
17,401
hh
/* == Start of generated table == */ /* * The following table is generated by running: * * ./gen-arabic-table.py ArabicShaping.txt UnicodeData.txt Blocks.txt * * on files with these headers: * * # ArabicShaping-7.0.0.txt * # Date: 2014-02-14, 21:00:00 GMT [RP, KW, LI] * # Blocks-7.0.0.txt * # Date: 2014-04-03, 23:23:00 GMT [RP, KW] * UnicodeData.txt does not have a header. */ #ifndef HB_OT_SHAPE_COMPLEX_ARABIC_TABLE_HH #define HB_OT_SHAPE_COMPLEX_ARABIC_TABLE_HH #define X JOINING_TYPE_X #define R JOINING_TYPE_R #define U JOINING_TYPE_U #define A JOINING_GROUP_ALAPH #define DR JOINING_GROUP_DALATH_RISH #define L JOINING_TYPE_L #define C JOINING_TYPE_C #define D JOINING_TYPE_D static const uint8_t joining_table[] = { #define joining_offset_0x0600u 0 /* Arabic */ /* 0600 */ U,U,U,U,U,U,X,X,U,X,X,U,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* 0620 */ D,U,R,R,R,R,D,R,D,R,D,D,D,D,D,R,R,R,R,D,D,D,D,D,D,D,D,D,D,D,D,D, /* 0640 */ C,D,D,D,D,D,D,D,R,D,D,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* 0660 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,D,D,X,R,R,R,U,R,R,R,D,D,D,D,D,D,D,D, /* 0680 */ D,D,D,D,D,D,D,D,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,D,D,D,D,D,D, /* 06A0 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D, /* 06C0 */ R,D,D,R,R,R,R,R,R,R,R,R,D,R,D,R,D,D,R,R,X,R,X,X,X,X,X,X,X,U,X,X, /* 06E0 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,R,R,X,X,X,X,X,X,X,X,X,X,D,D,D,X,X,D, /* Syriac */ /* 0700 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,A,X,D,D,D,DR,DR,R,R,R,D,D,D,D,R,D, /* 0720 */ D,D,D,D,D,D,D,D,R,D,DR,D,R,D,D,DR,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* 0740 */ X,X,X,X,X,X,X,X,X,X,X,X,X,R,D,D, /* Arabic Supplement */ /* 0740 */ D,D,D,D,D,D,D,D,D,R,R,R,D,D,D,D, /* 0760 */ D,D,D,D,D,D,D,D,D,D,D,R,R,D,D,D,D,R,D,R,R,D,D,D,R,R,D,D,D,D,D,D, /* FILLER */ /* 0780 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* 07A0 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* NKo */ /* 07C0 */ X,X,X,X,X,X,X,X,X,X,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D, /* 07E0 */ D,D,D,D,D,D,D,D,D,D,D,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,C,X,X,X,X,X, /* FILLER */ /* 0800 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* 0820 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* Mandaic */ /* 0840 */ R,D,D,D,D,D,R,R,D,R,D,D,D,D,D,D,D,D,D,D,R,D,U,U,U,X,X,X,X,X,X,X, /* 0860 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* 0880 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* Arabic Extended-A */ /* 08A0 */ D,D,D,D,D,D,D,D,D,D,R,R,R,U,R,D,D,R,R, #define joining_offset_0x1806u 691 /* Mongolian */ /* 1800 */ U,D,X,X,C,X,X,X,U,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* 1820 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D, /* 1840 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D, /* 1860 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,X,X,X,X,X,X,X,X, /* 1880 */ U,U,U,U,U,U,U,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D, /* 18A0 */ D,D,D,D,D,D,D,D,D,X,D, #define joining_offset_0x200cu 856 /* General Punctuation */ /* 2000 */ U,C, #define joining_offset_0x2066u 858 /* General Punctuation */ /* 2060 */ U,U,U,U, #define joining_offset_0xa840u 862 /* Phags-pa */ /* A840 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D, /* A860 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,L,U, #define joining_offset_0x10ac0u 914 /* Manichaean */ /* 10AC0 */ D,D,D,D,D,R,U,R,U,R,R,U,U,L,R,R,R,R,R,D,D,D,D,L,D,D,D,D,D,R,D,D, /* 10AE0 */ D,R,U,U,R,X,X,X,X,X,X,D,D,D,D,R, #define joining_offset_0x10b80u 962 /* Psalter Pahlavi */ /* 10B80 */ D,R,D,R,R,R,D,D,D,R,D,D,R,D,R,R,D,R,X,X,X,X,X,X,X,X,X,X,X,X,X,X, /* 10BA0 */ X,X,X,X,X,X,X,X,X,R,R,R,R,D,D,U, }; /* Table items: 1010; occupancy: 57% */ static unsigned int joining_type (hb_codepoint_t u) { switch (u >> 12) { case 0x0u: if (hb_in_range (u, 0x0600u, 0x08B2u)) return joining_table[u - 0x0600u + joining_offset_0x0600u]; break; case 0x1u: if (hb_in_range (u, 0x1806u, 0x18AAu)) return joining_table[u - 0x1806u + joining_offset_0x1806u]; break; case 0x2u: if (hb_in_range (u, 0x200Cu, 0x200Du)) return joining_table[u - 0x200Cu + joining_offset_0x200cu]; if (hb_in_range (u, 0x2066u, 0x2069u)) return joining_table[u - 0x2066u + joining_offset_0x2066u]; break; case 0xAu: if (hb_in_range (u, 0xA840u, 0xA873u)) return joining_table[u - 0xA840u + joining_offset_0xa840u]; break; case 0x10u: if (hb_in_range (u, 0x10AC0u, 0x10AEFu)) return joining_table[u - 0x10AC0u + joining_offset_0x10ac0u]; if (hb_in_range (u, 0x10B80u, 0x10BAFu)) return joining_table[u - 0x10B80u + joining_offset_0x10b80u]; break; default: break; } return X; } #undef X #undef R #undef U #undef A #undef DR #undef L #undef C #undef D static const uint16_t shaping_table[][4] = { {0x0000u, 0x0000u, 0x0000u, 0xFE80u}, /* U+0621 ARABIC LETTER HAMZA ISOLATED FORM */ {0x0000u, 0x0000u, 0xFE82u, 0xFE81u}, /* U+0622 ARABIC LETTER ALEF WITH MADDA ABOVE */ {0x0000u, 0x0000u, 0xFE84u, 0xFE83u}, /* U+0623 ARABIC LETTER ALEF WITH HAMZA ABOVE */ {0x0000u, 0x0000u, 0xFE86u, 0xFE85u}, /* U+0624 ARABIC LETTER WAW WITH HAMZA ABOVE */ {0x0000u, 0x0000u, 0xFE88u, 0xFE87u}, /* U+0625 ARABIC LETTER ALEF WITH HAMZA BELOW */ {0xFE8Bu, 0xFE8Cu, 0xFE8Au, 0xFE89u}, /* U+0626 ARABIC LETTER YEH WITH HAMZA ABOVE */ {0x0000u, 0x0000u, 0xFE8Eu, 0xFE8Du}, /* U+0627 ARABIC LETTER ALEF */ {0xFE91u, 0xFE92u, 0xFE90u, 0xFE8Fu}, /* U+0628 ARABIC LETTER BEH */ {0x0000u, 0x0000u, 0xFE94u, 0xFE93u}, /* U+0629 ARABIC LETTER TEH MARBUTA */ {0xFE97u, 0xFE98u, 0xFE96u, 0xFE95u}, /* U+062A ARABIC LETTER TEH */ {0xFE9Bu, 0xFE9Cu, 0xFE9Au, 0xFE99u}, /* U+062B ARABIC LETTER THEH */ {0xFE9Fu, 0xFEA0u, 0xFE9Eu, 0xFE9Du}, /* U+062C ARABIC LETTER JEEM */ {0xFEA3u, 0xFEA4u, 0xFEA2u, 0xFEA1u}, /* U+062D ARABIC LETTER HAH */ {0xFEA7u, 0xFEA8u, 0xFEA6u, 0xFEA5u}, /* U+062E ARABIC LETTER KHAH */ {0x0000u, 0x0000u, 0xFEAAu, 0xFEA9u}, /* U+062F ARABIC LETTER DAL */ {0x0000u, 0x0000u, 0xFEACu, 0xFEABu}, /* U+0630 ARABIC LETTER THAL */ {0x0000u, 0x0000u, 0xFEAEu, 0xFEADu}, /* U+0631 ARABIC LETTER REH */ {0x0000u, 0x0000u, 0xFEB0u, 0xFEAFu}, /* U+0632 ARABIC LETTER ZAIN */ {0xFEB3u, 0xFEB4u, 0xFEB2u, 0xFEB1u}, /* U+0633 ARABIC LETTER SEEN */ {0xFEB7u, 0xFEB8u, 0xFEB6u, 0xFEB5u}, /* U+0634 ARABIC LETTER SHEEN */ {0xFEBBu, 0xFEBCu, 0xFEBAu, 0xFEB9u}, /* U+0635 ARABIC LETTER SAD */ {0xFEBFu, 0xFEC0u, 0xFEBEu, 0xFEBDu}, /* U+0636 ARABIC LETTER DAD */ {0xFEC3u, 0xFEC4u, 0xFEC2u, 0xFEC1u}, /* U+0637 ARABIC LETTER TAH */ {0xFEC7u, 0xFEC8u, 0xFEC6u, 0xFEC5u}, /* U+0638 ARABIC LETTER ZAH */ {0xFECBu, 0xFECCu, 0xFECAu, 0xFEC9u}, /* U+0639 ARABIC LETTER AIN */ {0xFECFu, 0xFED0u, 0xFECEu, 0xFECDu}, /* U+063A ARABIC LETTER GHAIN */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+063B */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+063C */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+063D */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+063E */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+063F */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0640 */ {0xFED3u, 0xFED4u, 0xFED2u, 0xFED1u}, /* U+0641 ARABIC LETTER FEH */ {0xFED7u, 0xFED8u, 0xFED6u, 0xFED5u}, /* U+0642 ARABIC LETTER QAF */ {0xFEDBu, 0xFEDCu, 0xFEDAu, 0xFED9u}, /* U+0643 ARABIC LETTER KAF */ {0xFEDFu, 0xFEE0u, 0xFEDEu, 0xFEDDu}, /* U+0644 ARABIC LETTER LAM */ {0xFEE3u, 0xFEE4u, 0xFEE2u, 0xFEE1u}, /* U+0645 ARABIC LETTER MEEM */ {0xFEE7u, 0xFEE8u, 0xFEE6u, 0xFEE5u}, /* U+0646 ARABIC LETTER NOON */ {0xFEEBu, 0xFEECu, 0xFEEAu, 0xFEE9u}, /* U+0647 ARABIC LETTER HEH */ {0x0000u, 0x0000u, 0xFEEEu, 0xFEEDu}, /* U+0648 ARABIC LETTER WAW */ {0xFBE8u, 0xFBE9u, 0xFEF0u, 0xFEEFu}, /* U+0649 ARABIC LETTER */ {0xFEF3u, 0xFEF4u, 0xFEF2u, 0xFEF1u}, /* U+064A ARABIC LETTER YEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+064B */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+064C */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+064D */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+064E */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+064F */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0650 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0651 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0652 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0653 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0654 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0655 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0656 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0657 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0658 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0659 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+065A */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+065B */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+065C */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+065D */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+065E */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+065F */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0660 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0661 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0662 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0663 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0664 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0665 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0666 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0667 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0668 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0669 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+066A */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+066B */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+066C */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+066D */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+066E */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+066F */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0670 */ {0x0000u, 0x0000u, 0xFB51u, 0xFB50u}, /* U+0671 ARABIC LETTER ALEF WASLA */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0672 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0673 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0674 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0675 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0676 */ {0x0000u, 0x0000u, 0x0000u, 0xFBDDu}, /* U+0677 ARABIC LETTER U WITH HAMZA ABOVE ISOLATED FORM */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0678 */ {0xFB68u, 0xFB69u, 0xFB67u, 0xFB66u}, /* U+0679 ARABIC LETTER TTEH */ {0xFB60u, 0xFB61u, 0xFB5Fu, 0xFB5Eu}, /* U+067A ARABIC LETTER TTEHEH */ {0xFB54u, 0xFB55u, 0xFB53u, 0xFB52u}, /* U+067B ARABIC LETTER BEEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+067C */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+067D */ {0xFB58u, 0xFB59u, 0xFB57u, 0xFB56u}, /* U+067E ARABIC LETTER PEH */ {0xFB64u, 0xFB65u, 0xFB63u, 0xFB62u}, /* U+067F ARABIC LETTER TEHEH */ {0xFB5Cu, 0xFB5Du, 0xFB5Bu, 0xFB5Au}, /* U+0680 ARABIC LETTER BEHEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0681 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0682 */ {0xFB78u, 0xFB79u, 0xFB77u, 0xFB76u}, /* U+0683 ARABIC LETTER NYEH */ {0xFB74u, 0xFB75u, 0xFB73u, 0xFB72u}, /* U+0684 ARABIC LETTER DYEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0685 */ {0xFB7Cu, 0xFB7Du, 0xFB7Bu, 0xFB7Au}, /* U+0686 ARABIC LETTER TCHEH */ {0xFB80u, 0xFB81u, 0xFB7Fu, 0xFB7Eu}, /* U+0687 ARABIC LETTER TCHEHEH */ {0x0000u, 0x0000u, 0xFB89u, 0xFB88u}, /* U+0688 ARABIC LETTER DDAL */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0689 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+068A */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+068B */ {0x0000u, 0x0000u, 0xFB85u, 0xFB84u}, /* U+068C ARABIC LETTER DAHAL */ {0x0000u, 0x0000u, 0xFB83u, 0xFB82u}, /* U+068D ARABIC LETTER DDAHAL */ {0x0000u, 0x0000u, 0xFB87u, 0xFB86u}, /* U+068E ARABIC LETTER DUL */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+068F */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0690 */ {0x0000u, 0x0000u, 0xFB8Du, 0xFB8Cu}, /* U+0691 ARABIC LETTER RREH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0692 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0693 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0694 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0695 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0696 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0697 */ {0x0000u, 0x0000u, 0xFB8Bu, 0xFB8Au}, /* U+0698 ARABIC LETTER JEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+0699 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+069A */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+069B */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+069C */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+069D */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+069E */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+069F */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06A0 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06A1 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06A2 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06A3 */ {0xFB6Cu, 0xFB6Du, 0xFB6Bu, 0xFB6Au}, /* U+06A4 ARABIC LETTER VEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06A5 */ {0xFB70u, 0xFB71u, 0xFB6Fu, 0xFB6Eu}, /* U+06A6 ARABIC LETTER PEHEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06A7 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06A8 */ {0xFB90u, 0xFB91u, 0xFB8Fu, 0xFB8Eu}, /* U+06A9 ARABIC LETTER KEHEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06AA */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06AB */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06AC */ {0xFBD5u, 0xFBD6u, 0xFBD4u, 0xFBD3u}, /* U+06AD ARABIC LETTER NG */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06AE */ {0xFB94u, 0xFB95u, 0xFB93u, 0xFB92u}, /* U+06AF ARABIC LETTER GAF */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06B0 */ {0xFB9Cu, 0xFB9Du, 0xFB9Bu, 0xFB9Au}, /* U+06B1 ARABIC LETTER NGOEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06B2 */ {0xFB98u, 0xFB99u, 0xFB97u, 0xFB96u}, /* U+06B3 ARABIC LETTER GUEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06B4 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06B5 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06B6 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06B7 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06B8 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06B9 */ {0x0000u, 0x0000u, 0xFB9Fu, 0xFB9Eu}, /* U+06BA ARABIC LETTER NOON GHUNNA */ {0xFBA2u, 0xFBA3u, 0xFBA1u, 0xFBA0u}, /* U+06BB ARABIC LETTER RNOON */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06BC */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06BD */ {0xFBACu, 0xFBADu, 0xFBABu, 0xFBAAu}, /* U+06BE ARABIC LETTER HEH DOACHASHMEE */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06BF */ {0x0000u, 0x0000u, 0xFBA5u, 0xFBA4u}, /* U+06C0 ARABIC LETTER HEH WITH YEH ABOVE */ {0xFBA8u, 0xFBA9u, 0xFBA7u, 0xFBA6u}, /* U+06C1 ARABIC LETTER HEH GOAL */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06C2 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06C3 */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06C4 */ {0x0000u, 0x0000u, 0xFBE1u, 0xFBE0u}, /* U+06C5 ARABIC LETTER KIRGHIZ OE */ {0x0000u, 0x0000u, 0xFBDAu, 0xFBD9u}, /* U+06C6 ARABIC LETTER OE */ {0x0000u, 0x0000u, 0xFBD8u, 0xFBD7u}, /* U+06C7 ARABIC LETTER U */ {0x0000u, 0x0000u, 0xFBDCu, 0xFBDBu}, /* U+06C8 ARABIC LETTER YU */ {0x0000u, 0x0000u, 0xFBE3u, 0xFBE2u}, /* U+06C9 ARABIC LETTER KIRGHIZ YU */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06CA */ {0x0000u, 0x0000u, 0xFBDFu, 0xFBDEu}, /* U+06CB ARABIC LETTER VE */ {0xFBFEu, 0xFBFFu, 0xFBFDu, 0xFBFCu}, /* U+06CC ARABIC LETTER FARSI YEH */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06CD */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06CE */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06CF */ {0xFBE6u, 0xFBE7u, 0xFBE5u, 0xFBE4u}, /* U+06D0 ARABIC LETTER E */ {0x0000u, 0x0000u, 0x0000u, 0x0000u}, /* U+06D1 */ {0x0000u, 0x0000u, 0xFBAFu, 0xFBAEu}, /* U+06D2 ARABIC LETTER YEH BARREE */ {0x0000u, 0x0000u, 0xFBB1u, 0xFBB0u}, /* U+06D3 ARABIC LETTER YEH BARREE WITH HAMZA ABOVE */ }; #define SHAPING_TABLE_FIRST 0x0621u #define SHAPING_TABLE_LAST 0x06D3u static const struct ligature_set_t { uint16_t first; struct ligature_pairs_t { uint16_t second; uint16_t ligature; } ligatures[4]; } ligature_table[] = { { 0xFEDFu, { { 0xFE88u, 0xFEF9u }, /* ARABIC LIGATURE LAM WITH ALEF WITH HAMZA BELOW ISOLATED FORM */ { 0xFE82u, 0xFEF5u }, /* ARABIC LIGATURE LAM WITH ALEF WITH MADDA ABOVE ISOLATED FORM */ { 0xFE8Eu, 0xFEFBu }, /* ARABIC LIGATURE LAM WITH ALEF ISOLATED FORM */ { 0xFE84u, 0xFEF7u }, /* ARABIC LIGATURE LAM WITH ALEF WITH HAMZA ABOVE ISOLATED FORM */ }}, { 0xFEE0u, { { 0xFE88u, 0xFEFAu }, /* ARABIC LIGATURE LAM WITH ALEF WITH HAMZA BELOW FINAL FORM */ { 0xFE82u, 0xFEF6u }, /* ARABIC LIGATURE LAM WITH ALEF WITH MADDA ABOVE FINAL FORM */ { 0xFE8Eu, 0xFEFCu }, /* ARABIC LIGATURE LAM WITH ALEF FINAL FORM */ { 0xFE84u, 0xFEF8u }, /* ARABIC LIGATURE LAM WITH ALEF WITH HAMZA ABOVE FINAL FORM */ }}, }; #endif /* HB_OT_SHAPE_COMPLEX_ARABIC_TABLE_HH */ /* == End of generated table == */
271d12d825917bc780c260023f94408707c3867d
e3a7163072b8c323c1ee553421798e77f5099aa6
/src/ArduinoOcpp/Core/OcppServer.h
9d0269bb3ee1d1cafb1271bf3d0cc820e03ad6c3
[ "MIT" ]
permissive
rayleigh-jin/ArduinoOcpp
08d23f4e3ef76db62f966aee6cd680a123abad48
be15473ef90fb94ea1c3a6ef9c886946ceba8a5f
refs/heads/master
2023-04-20T02:55:13.792666
2021-05-03T13:41:36
2021-05-03T13:41:36
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,021
h
// matth-x/ESP8266-OCPP // Copyright Matthias Akstaller 2019 - 2021 // MIT License #ifndef OCPPSERVER_H #define OCPPSERVER_H #include <vector> #include <WebSocketsServer.h> namespace ArduinoOcpp { typedef uint8_t WsClient; typedef std::function<bool(const char*, size_t)> ReceiveTXTcallback; namespace EspWiFi { struct ReceiveTXTroute { IPAddress ip_addr; WsClient num; ReceiveTXTcallback processTXT; }; class OcppServer { private: std::vector<ReceiveTXTroute> receiveTXTrouting; WebSocketsServer wsockServer = WebSocketsServer(80); OcppServer(); static OcppServer *instance; public: static OcppServer *getInstance(); void loop(); void wsockEvent(WsClient num, WStype_t type, uint8_t * payload, size_t length); void setReceiveTXTcallback(IPAddress &ip_addr, ReceiveTXTcallback &callback); void removeReceiveTXTcallback(IPAddress &ip_addr); bool sendTXT(IPAddress &ip_addr, String &out); }; } //end namespace EspWiFi } //end namespace ArduinoOcpp #endif
2e3dbcd5e65c0a5f27b958b18f447fea94b0760b
2f10f807d3307b83293a521da600c02623cdda82
/deps/boost/win/debug/include/boost/icl/impl_config.hpp
54793c54ac61dfe55fe5ebb1994f9670cd3a7e7b
[]
no_license
xpierrohk/dpt-rp1-cpp
2ca4e377628363c3e9d41f88c8cbccc0fc2f1a1e
643d053983fce3e6b099e2d3c9ab8387d0ea5a75
refs/heads/master
2021-05-23T08:19:48.823198
2019-07-26T17:35:28
2019-07-26T17:35:28
null
0
0
null
null
null
null
UTF-8
C++
false
false
129
hpp
version https://git-lfs.github.com/spec/v1 oid sha256:a0dd8eeb3b53a657983879552a31d4be90c013b06882bf5080ded8f12c4f9446 size 3119
657e66544a99540ad9d445002bfcabc81e73c6ce
0be93390219e06314ba284100dcfd8ca5966bee5
/FF12Random/StartGambitData.h
e84fc5c29b4d20f21ee98e14a99a7b5124143c40
[]
no_license
Bartz24/FF12Randomizer
199ad3ae3001f6e738d0e10e931077ac9580ce09
fd365119847f6fd3d96f67c9eb0cd84e61177156
refs/heads/master
2020-04-03T08:38:13.508811
2019-08-18T17:23:58
2019-08-18T17:23:58
155,139,560
3
2
null
null
null
null
UTF-8
C++
false
false
244
h
#pragma once #include "Helpers.h" class StartGambitData { public: unsigned char unknown[64]; unsigned short gambits[12]; //0-17 unsigned short actions[12]; //20-37 StartGambitData(); StartGambitData(char data[64]); ~StartGambitData(); };
03050ace5be9c92816abcfbb2fbed3c2102d4241
451b1797b0dff9dc7ac3b5baba907f932823217a
/practice/hackerrank/heap_sort/heap_sort.h
3c53acdd9df373b7525e71d35f2feeae3acedc3d
[]
no_license
bochf/testing
85ba5e38882da0d5774bd1712a53df83ce21d7e8
78e69b05b20acf19b9a6691e66933a196712ca46
refs/heads/master
2020-04-11T00:25:59.989984
2017-06-09T01:32:28
2017-06-09T01:32:28
41,835,579
0
0
null
2015-12-26T04:30:50
2015-09-03T01:01:07
Groff
UTF-8
C++
false
false
1,110
h
#ifndef __HEAP_SORT_H_ #define __HEAP_SORT_H_ #include <vector> #include <cstdlib> class HeapSort { public: /** * @brief sort an array */ static void sort(std::vector<int>& v); /** * @brief build max heap * repeatly call maxHeapify from bottom to top to move the greater number up */ static void build(std::vector<int>& v); /** * @brief heapify * for any given node, check the sub tree satisfy the max heap rule, e.g. * parent node always greater than child nodes * * if the current node has child(ren), compare the value of current node and its * child(ren), if current node > children, stop heapify. * Otherwise, swap the value of current node and the greater child, make sure * max is always on top, then continue heapify the sub tree on the greater child * to make sure the sub tree satisfes the rule as well. */ static void maxHeapify(std::vector<int>& v, const size_t start, const size_t end); /** * @brief verify parent is always greater than children */ static bool verify(const std::vector<int>& v, const size_t node); private: }; #endif
7be2d05f88fb321f280074952ec988bdfe52e5a5
832c45ae5979dbcf4e07bc3b096e076d4d2d83e7
/20130607/landscape.cxx
c1072a120cdc98c5da1a6877d1b597046f9a8ca4
[]
no_license
personaluser01/Algorithm-problems
9e62da04724a6f4a71c10d0d3f0459bc926da594
9e2ad4571660711cdbed0402969d0cb74d6e4792
refs/heads/master
2021-01-03T12:08:55.749408
2018-10-13T10:59:02
2018-10-13T10:59:02
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,591
cxx
#include <cstdio> #include <iostream> #include <cmath> #include <cstring> #include <vector> #include <string> #include <queue> #include <list> #include <stack> #include <cstdlib> #include <ctime> #include <climits> #include <algorithm> #include <map> #include <utility> #include <complex> #include <set> #include <deque> #define elif else if using namespace std; int n,n1,n2; int w[1002][1002]; bool vs[1002][1002]; int xi[]={-1,1,0,0,1,-1,1,-1}; int yi[]={0,0,-1,1,1,-1,-1,1}; bool dfs1(int x,int y){ vs[x][y]=true; bool check=true; for(int i=0;i<8;i++){ if(x+xi[i]<1) continue; if(y+yi[i]<1) continue; if(x+xi[i]>n) continue; if(y+yi[i]>n) continue; if(w[x+xi[i]][y+yi[i]]==w[x][y]) { if(!vs[x+xi[i]][y+yi[i]]) check=check&dfs1(x+xi[i],y+yi[i]); } else if(w[x+xi[i]][y+yi[i]]<w[x][y]) check=false; } return check; } bool dfs2(int x,int y){ vs[x][y]=false; bool check=true; for(int i=0;i<8;i++){ if(x+xi[i]<1) continue; if(y+yi[i]<1) continue; if(x+xi[i]>n) continue; if(y+yi[i]>n) continue; if(w[x+xi[i]][y+yi[i]]==w[x][y]) { if(vs[x+xi[i]][y+yi[i]]) check=check&dfs2(x+xi[i],y+yi[i]); } else if(w[x+xi[i]][y+yi[i]]>w[x][y]) check=false; } return check; } main(){ freopen("landscape.inp","r",stdin); freopen("landscape.out","w",stdout); scanf("%d",&n); for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) scanf("%d",&w[i][j]); for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) if(!vs[i][j]) if(dfs1(i,j)) n1++; for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) if(vs[i][j]) if(dfs2(i,j)) n2++; swap(n1,n2); cout<<n1<<" "<<n2; }
dbb28af42ae785b3a76f40983e78ee00e09cd31e
1bf6613e21a5695582a8e6d9aaa643af4a1a5fa8
/src/remoting/host/ipc_desktop_environment.h
b4a8818724e3af8fa81bc9d708aa99884375344b
[ "BSD-3-Clause" ]
permissive
pqrkchqps/MusicBrowser
ef5c9603105b4f4508a430d285334667ec3c1445
03216439d1cc3dae160f440417fcb557bb72f8e4
refs/heads/master
2020-05-20T05:12:14.141094
2013-05-31T02:21:07
2013-05-31T02:21:07
10,395,498
1
2
null
null
null
null
UTF-8
C++
false
false
5,280
h
// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef REMOTING_HOST_IPC_DESKTOP_ENVIRONMENT_H_ #define REMOTING_HOST_IPC_DESKTOP_ENVIRONMENT_H_ #include <map> #include <string> #include "base/basictypes.h" #include "base/callback_forward.h" #include "base/memory/ref_counted.h" #include "base/memory/scoped_ptr.h" #include "base/memory/weak_ptr.h" #include "remoting/host/curtain_mode.h" #include "remoting/host/desktop_environment.h" #include "remoting/host/desktop_session_connector.h" namespace base { class SingleThreadTaskRunner; } // base namespace IPC { class Sender; } // namespace IPC namespace remoting { class ClientSessionControl; class DesktopSessionProxy; class ScreenResolution; // A variant of desktop environment integrating with the desktop by means of // a helper process and talking to that process via IPC. class IpcDesktopEnvironment : public DesktopEnvironment { public: // |desktop_session_connector| is used to bind DesktopSessionProxy to // a desktop session, to be notified every time the desktop process is // restarted. IpcDesktopEnvironment( scoped_refptr<base::SingleThreadTaskRunner> audio_task_runner, scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner, scoped_refptr<base::SingleThreadTaskRunner> capture_task_runner, scoped_refptr<base::SingleThreadTaskRunner> io_task_runner, base::WeakPtr<ClientSessionControl> client_session_control, base::WeakPtr<DesktopSessionConnector> desktop_session_connector, bool virtual_terminal); virtual ~IpcDesktopEnvironment(); // DesktopEnvironment implementation. virtual scoped_ptr<AudioCapturer> CreateAudioCapturer() OVERRIDE; virtual scoped_ptr<InputInjector> CreateInputInjector() OVERRIDE; virtual scoped_ptr<ScreenControls> CreateScreenControls() OVERRIDE; virtual scoped_ptr<media::ScreenCapturer> CreateVideoCapturer() OVERRIDE; private: scoped_refptr<DesktopSessionProxy> desktop_session_proxy_; DISALLOW_COPY_AND_ASSIGN(IpcDesktopEnvironment); }; // Used to create IpcDesktopEnvironment objects integrating with the desktop via // a helper process and talking to that process via IPC. class IpcDesktopEnvironmentFactory : public CurtainMode, public DesktopEnvironmentFactory, public DesktopSessionConnector { public: // Passes a reference to the IPC channel connected to the daemon process and // relevant task runners. |daemon_channel| must outlive this object. IpcDesktopEnvironmentFactory( scoped_refptr<base::SingleThreadTaskRunner> audio_task_runner, scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner, scoped_refptr<base::SingleThreadTaskRunner> capture_task_runner, scoped_refptr<base::SingleThreadTaskRunner> io_task_runner, IPC::Sender* daemon_channel); virtual ~IpcDesktopEnvironmentFactory(); // CurtainMode implementation. virtual void SetActivated(bool activated) OVERRIDE; // DesktopEnvironmentFactory implementation. virtual scoped_ptr<DesktopEnvironment> Create( base::WeakPtr<ClientSessionControl> client_session_control) OVERRIDE; virtual bool SupportsAudioCapture() const OVERRIDE; // DesktopSessionConnector implementation. virtual void ConnectTerminal( DesktopSessionProxy* desktop_session_proxy, const ScreenResolution& resolution, bool virtual_terminal) OVERRIDE; virtual void DisconnectTerminal( DesktopSessionProxy* desktop_session_proxy) OVERRIDE; virtual void SetScreenResolution( DesktopSessionProxy* desktop_session_proxy, const ScreenResolution& resolution) OVERRIDE; virtual void OnDesktopSessionAgentAttached( int terminal_id, base::ProcessHandle desktop_process, IPC::PlatformFileForTransit desktop_pipe) OVERRIDE; virtual void OnTerminalDisconnected(int terminal_id) OVERRIDE; private: // Used to run the audio capturer. scoped_refptr<base::SingleThreadTaskRunner> audio_task_runner_; // Task runner on which methods of DesktopEnvironmentFactory interface should // be called. scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner_; // Used to run the video capturer. scoped_refptr<base::SingleThreadTaskRunner> capture_task_runner_; // Task runner used for running background I/O. scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_; // True if curtain mode is activated. bool curtain_activated_; // IPC channel connected to the daemon process. IPC::Sender* daemon_channel_; // List of DesktopEnvironment instances we've told the daemon process about. typedef std::map<int, DesktopSessionProxy*> ActiveConnectionsList; ActiveConnectionsList active_connections_; // Factory for weak pointers to DesktopSessionConnector interface. base::WeakPtrFactory<DesktopSessionConnector> connector_factory_; // Next desktop session ID. IDs are allocated sequentially starting from 0. // This gives us more than 67 years of unique IDs assuming a new ID is // allocated every second. int next_id_; DISALLOW_COPY_AND_ASSIGN(IpcDesktopEnvironmentFactory); }; } // namespace remoting #endif // REMOTING_HOST_IPC_DESKTOP_ENVIRONMENT_H_
a51b45ebb051e84eae665e630344cb713d61e66d
67f988dedfd8ae049d982d1a8213bb83233d90de
/external/chromium/content/renderer/favicon_helper.cc
5553047b7f1cc34cfd606ff0e3f73a3093a6fa7a
[ "BSD-3-Clause" ]
permissive
opensourceyouthprogramming/h5vcc
94a668a9384cc3096a365396b5e4d1d3e02aacc4
d55d074539ba4555e69e9b9a41e5deb9b9d26c5b
refs/heads/master
2020-04-20T04:57:47.419922
2019-02-12T00:56:14
2019-02-12T00:56:14
168,643,719
1
1
null
2019-02-12T00:49:49
2019-02-01T04:47:32
C++
UTF-8
C++
false
false
6,717
cc
// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "content/renderer/favicon_helper.h" #include "base/bind.h" #include "base/command_line.h" #include "base/message_loop.h" #include "content/common/icon_messages.h" #include "content/public/renderer/render_view.h" #include "net/base/data_url.h" #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" #include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h" #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLRequest.h" #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebVector.h" #include "ui/base/ui_base_switches.h" #include "ui/gfx/favicon_size.h" #include "ui/gfx/size.h" #include "ui/gfx/skbitmap_operations.h" #include "webkit/glue/image_decoder.h" #include "webkit/glue/multi_resolution_image_resource_fetcher.h" #include "webkit/glue/webkit_glue.h" using WebKit::WebFrame; using WebKit::WebIconURL; using WebKit::WebVector; using WebKit::WebURL; using WebKit::WebURLRequest; using webkit_glue::MultiResolutionImageResourceFetcher; namespace content { namespace { bool TouchEnabled() { // Based on the definition of chrome::kEnableTouchIcon. #if defined(OS_ANDROID) return true; #else return false; #endif } } // namespace static FaviconURL::IconType ToFaviconType(WebIconURL::Type type) { switch (type) { case WebIconURL::TypeFavicon: return FaviconURL::FAVICON; case WebIconURL::TypeTouch: return FaviconURL::TOUCH_ICON; case WebIconURL::TypeTouchPrecomposed: return FaviconURL::TOUCH_PRECOMPOSED_ICON; case WebIconURL::TypeInvalid: return FaviconURL::INVALID_ICON; } return FaviconURL::INVALID_ICON; } FaviconHelper::FaviconHelper(RenderView* render_view) : RenderViewObserver(render_view) { } void FaviconHelper::DidChangeIcon(WebKit::WebFrame* frame, WebKit::WebIconURL::Type icon_type) { if (frame->parent()) return; if (!TouchEnabled() && icon_type != WebIconURL::TypeFavicon) return; WebVector<WebIconURL> icon_urls = frame->iconURLs(icon_type); std::vector<FaviconURL> urls; for (size_t i = 0; i < icon_urls.size(); i++) { urls.push_back(FaviconURL(icon_urls[i].iconURL(), ToFaviconType(icon_urls[i].iconType()))); } SendUpdateFaviconURL(routing_id(), render_view()->GetPageId(), urls); } FaviconHelper::~FaviconHelper() { } void FaviconHelper::OnDownloadFavicon(int id, const GURL& image_url, int image_size) { std::vector<SkBitmap> result_images; if (image_url.SchemeIs("data")) { SkBitmap data_image = ImageFromDataUrl(image_url); if (!data_image.empty()) result_images.push_back(data_image); } else { if (DownloadFavicon(id, image_url, image_size)) { // Will complete asynchronously via FaviconHelper::DidDownloadFavicon return; } } Send(new IconHostMsg_DidDownloadFavicon(routing_id(), id, image_url, result_images.empty(), image_size, result_images)); } bool FaviconHelper::DownloadFavicon(int id, const GURL& image_url, int image_size) { // Make sure webview was not shut down. if (!render_view()->GetWebView()) return false; // Create an image resource fetcher and assign it with a call back object. image_fetchers_.push_back(new MultiResolutionImageResourceFetcher( image_url, render_view()->GetWebView()->mainFrame(), id, WebURLRequest::TargetIsFavicon, base::Bind(&FaviconHelper::DidDownloadFavicon, base::Unretained(this), image_size))); return true; } void FaviconHelper::DidDownloadFavicon( int requested_size, MultiResolutionImageResourceFetcher* fetcher, const std::vector<SkBitmap>& images) { // Notify requester of image download status. Send(new IconHostMsg_DidDownloadFavicon(routing_id(), fetcher->id(), fetcher->image_url(), images.empty(), requested_size, images)); // Remove the image fetcher from our pending list. We're in the callback from // MultiResolutionImageResourceFetcher, best to delay deletion. ImageResourceFetcherList::iterator iter = std::find(image_fetchers_.begin(), image_fetchers_.end(), fetcher); if (iter != image_fetchers_.end()) { image_fetchers_.weak_erase(iter); MessageLoop::current()->DeleteSoon(FROM_HERE, fetcher); } } SkBitmap FaviconHelper::ImageFromDataUrl(const GURL& url) const { std::string mime_type, char_set, data; if (net::DataURL::Parse(url, &mime_type, &char_set, &data) && !data.empty()) { // Decode the favicon using WebKit's image decoder. webkit_glue::ImageDecoder decoder( gfx::Size(gfx::kFaviconSize, gfx::kFaviconSize)); const unsigned char* src_data = reinterpret_cast<const unsigned char*>(&data[0]); return decoder.Decode(src_data, data.size()); } return SkBitmap(); } void FaviconHelper::SendUpdateFaviconURL(int32 routing_id, int32 page_id, const std::vector<FaviconURL>& urls) { if (!urls.empty()) Send(new IconHostMsg_UpdateFaviconURL(routing_id, page_id, urls)); } bool FaviconHelper::OnMessageReceived(const IPC::Message& message) { bool handled = true; IPC_BEGIN_MESSAGE_MAP(FaviconHelper, message) IPC_MESSAGE_HANDLER(IconMsg_DownloadFavicon, OnDownloadFavicon) IPC_MESSAGE_UNHANDLED(handled = false) IPC_END_MESSAGE_MAP() return handled; } void FaviconHelper::DidStopLoading() { int icon_types = WebIconURL::TypeFavicon; if (TouchEnabled()) icon_types |= WebIconURL::TypeTouchPrecomposed | WebIconURL::TypeTouch; WebVector<WebIconURL> icon_urls = render_view()->GetWebView()->mainFrame()->iconURLs(icon_types); std::vector<FaviconURL> urls; for (size_t i = 0; i < icon_urls.size(); i++) { WebURL url = icon_urls[i].iconURL(); if (!url.isEmpty()) urls.push_back(FaviconURL(url, ToFaviconType(icon_urls[i].iconType()))); } SendUpdateFaviconURL(routing_id(), render_view()->GetPageId(), urls); } } // namespace content
1487a78c5b000958eb211d790c7a0f24771de3f0
3be6d507b0e99e918252d3a45fd60da61cb0e9aa
/piskvork_source/source/pbrain/piskcomp.cpp
19c3d4d629870e3c657cbb904700a5f675007cac
[]
no_license
HoutarouandEru/piskvork
8581267cb590c17cc8e843646adf6b6c5007a9a3
96a263a698ad6828704bd3c3eb54dd52b75ca3d5
refs/heads/master
2021-01-24T12:42:12.870795
2019-01-20T14:05:49
2019-01-20T14:05:49
82,675,428
0
0
null
null
null
null
UTF-8
C++
false
false
18,340
cpp
/* (C) 2000-2005 Petr Lastovicka contents of this file are subject to the Reciprocal Public License ("RPL") */ #include <windows.h> #pragma hdrstop #include <assert.h> #include "board.h" #define EVAL_RAND1 20 //randomness #define EVAL_RAND2 30 //maximal randomness for low evaluation #define AHEAD_DEPTH 4 //depth search to find good total evaluation #define AHEAD_IRRELEVANCE 3 #define NUM_GOOD0 100 #define NUM_GOOD1 30 #define OFFENSIVE 1 #define DEFEND_HIGHEVAL 70 int height2, //height+2 moves, //moves counter depth, //maximal recursion depth (is increased until timeout) diroff[9]; //pointer difference to adjacent squares int winEval[MwinMoves], //evaluation of winMoves1 winMoveDepth[2], //depth of win combination sum[2], //total evaluation for both players dpth=0; //current recursion depth Psquare board=0, //board array boardb, boardk, //pointer to the beginning and end of board loss4, //opponent can win through foursomes resultMove, //the best move highestEval, //square which has the best evaluation lastMove, holdMove; Psquare goodMoves[4][2], //linked lists of highly evaluated squares, for both players winMoves1[MwinMoves],//buffer for win combination *UwinMoves, winMove[2], //the first move of win combination bestMove; bool depthReached, //depth has beeb reached (and can be increased) attackDone,defendDone,defendDone1,testDone, carefulAttack,carefulDefend; const int priority[][3]={{0,1,1},{H10,H11,H12},{H20,H21,H22},{H30,H31,0},{H4,0,0}}; #ifdef DEBUG int mt; //curMoves buffer utilization int resulty; //win/loss/unknown #endif int benchmark;//counter of searched moves //------------------------------------------------------------------- signed char data[]={ 15,1, 4,0,0,0,1,1,2,3,2,2,4,2,5,3,3,4,3,3,5,5,4,3,3,6,4,5,6,5,5,4, 3,1, 11,1, 1,1,0,0,2,2,3,2,3,3,1,3,2,4,1,5,3,3,3,2,5,1, 4,3, 11,1, 1,0,0,0,1,1,3,2,2,2,2,3,3,3,2,4,2,5,1,5,1,4, 0,3, 9,1, 0,0,0,3,0,1,1,2,0,2,2,3,3,3,3,4,2,4, 1,1, 9,1, 1,1,0,0,2,2,3,2,3,3,2,3,1,4,1,3,1,5, 2,4, 9,1, 1,0,0,0,0,1,1,1,2,2,2,1,2,3,1,2,0,3, 1,4, 9,1, 0,0,2,0,1,0,1,1,0,1,2,2,3,2,3,3,2,3, 0,2, 9,1, 1,1,0,0,2,2,0,2,2,1,3,1,1,2,1,3,0,3, 3,0, 9,1, 0,0,2,0,1,1,1,2,2,1,1,4,3,2,4,3,2,3, 0,1, 8,1, 0,2,1,1,1,2,2,0,2,2,3,0,3,1,3,2, 4,0, 8,1, 1,1,3,0,0,2,3,1,1,3,2,2,2,3,1,4, 3,3, 7,1, 0,0,1,1,0,1,2,2,3,2,3,3,2,3, 0,2, 7,1, 3,2,2,1,2,2,1,1,1,0,0,0,0,1, 1,2, 7,1, 0,0,0,1,1,0,0,3,2,1,3,2,1,2, 1,-1, 7,1, 1,0,0,1,0,2,2,2,2,1,3,2,5,2, 3,0, 7,1, 0,0,0,1,2,0,0,3,2,1,1,3,1,2, 2,3, 7,1, 1,0,0,0,0,1,1,1,2,2,1,2,1,3, 2,3, 7,1, 0,1,1,1,2,0,0,2,1,2,3,4,2,3, 2,1, 6,1, 1,0,0,0,0,2,1,1,3,3,2,2, 1,-1, 6,1, 1,0,0,0,1,1,2,1,2,2,1,2, 0,-1, 6,1, 0,0,1,0,2,1,3,1,3,2,2,2, 1,-1, 6,1, 3,0,0,0,1,1,2,1,2,2,1,2, -1,0, 6,1, 0,0,1,1,3,1,2,2,4,3,3,3, 2,4, 6,1, 0,2,0,0,1,1,1,2,2,2,2,1, 3,0, 6,1, 2,1,0,0,2,2,0,1,2,3,1,2, 2,0, 6,1, 2,1,0,0,1,3,0,1,2,3,1,2, 2,0, 5,2, 2,2,0,0,1,0,1,1,0,1, 2,1,1,2, 5,1, 0,0,2,1,0,1,2,3,1,2, 1,3, 5,1, 1,0,0,0,1,1,1,2,2,1, 1,-1, 5,1, 1,1,1,0,0,2,1,3,1,2, 2,2, 5,1, 1,0,0,0,0,1,1,1,2,3, 2,2, 5,2, 0,0,1,1,1,2,0,1,2,1, 2,0,3,0, 5,1, 0,2,1,0,2,0,2,1,1,1, -1,3, 5,1, 1,0,1,1,0,1,2,1,3,2, 2,-1, 5,1, 1,1,0,0,2,1,0,2,3,1, 0,1, 5,2, 1,1,0,0,2,1,1,3,1,2, 0,1,3,1, 5,2, 1,0,0,0,0,1,2,1,1,1, 1,2,-1,2, 5,1, 1,0,1,2,0,1,3,2,2,1, 2,-1, 5,2, 0,1,1,2,2,1,3,0,0,3, 1,1,0,2, 5,1, 2,0,0,2,1,1,1,2,2,2, 0,0, 5,1, 0,0,1,1,1,0,1,2,0,2, 0,1, 4,1, 1,0,0,1,1,3,1,2, -1,0, 4,1, 1,0,0,1,1,1,1,2, -1,0, 4,1, 1,0,1,1,0,2,2,2, 0,0, 4,1, 2,0,0,0,0,2,1,1, 2,2, 4,1, 0,0,1,1,3,1,2,2, 3,3, 4,2, 2,0,0,0,2,2,1,1, 0,-1,1,-1, 4,1, 2,0,0,0,2,1,1,1, 2,2, 4,1, 1,0,0,1,2,0,1,2, -1,0, 4,1, 1,0,0,0,0,2,1,1, -1,-1, 4,1, 1,0,0,1,2,2,1,2, -1,0, 4,1, 0,0,1,1,2,1,2,2, 3,3, 3,1, 0,1,0,0,1,0, 1,1, 3,1, 0,0,2,0,1,1, 2,2, 3,4, 1,0,0,1,1,2, 0,2,0,0,2,0,2,2, 3,1, 1,2,0,0,1,1, 1,3, 3,1, 1,0,0,0,1,1, 1,2, 3,1, 0,0,0,2,0,1, 0,-1, 3,1, 0,0,2,1,1,1, 2,2, 3,1, 0,0,0,1,1,2, 1,1, 3,2, 0,0,2,2,1,1, 2,1,1,2, 3,1, 0,1,3,0,2,0, 1,1, 3,1, 0,0,2,1,2,2, 1,1, 3,4, 0,0,1,1,2,2, 1,-1,-1,1,3,1,1,3, 3,1, 0,0,0,2,1,2, 1,0, 3,2, 1,0,0,3,1,2, 2,3,1,1, 3,2, 0,0,0,3,0,2, 1,3,-1,3, 3,1, 0,0,0,3,1,2, 1,1, 3,1, 1,0,0,2,1,2, 1,1, 3,1, 0,0,2,1,1,2, 0,2, 3,1, 0,0,2,2,1,2, 0,1, 3,1, 0,0,3,3,2,2, 1,1, 3,1, 0,0,3,2,2,2, 1,1, 3,1, 0,0,3,1,2,2, 3,3, 3,6, 0,0,1,0,2,0, 1,1,1,-1,0,2,0,-2,2,2,2,-2, 3,3, 0,0,3,2,2,1, 1,0,1,1,0,1, 2,3, 0,0,1,1, 0,2,2,0,1,2, 2,8, 0,0,1,0, -1,-1,0,-1,1,-1,2,-1,-1,1,0,1,1,1,2,1, 2,2, 0,0,2,2, 1,3,3,1, 1,8, 0,0, -1,0,1,0,0,1,0,-1, 1,1,-1,1,1,-1,-1,-1, 0,0 }; //------------------------------------------------------------------- Psquare Square(int x, int y) //indexed from zero { return boardb + x*height2+(y+1); } //------------------------------------------------------------------- struct PR2 { short h[2]; }; PR2 K[262144]; //evaluation for all combinations of 9 squares static int comb[10]; //current combination static PR2 *ind; //write position in array K static int n[4]; //number of empty fields, stones and borders //------------------------------------------------------------------- void gen2(int *pos) { int *pb,*pe; int n[4],a1,a2; int s; bool six[2]; if(pos==comb+9){ a1=a2=0; if(comb[4]==0){ //the middle square must be empty n[1]=::n[1]; n[2]=::n[2]; n[3]=::n[3]; six[0]=six[1]=false; pb=comb; pe=pb+4; while(pe!=comb+9){ if(!n[3]){ //must not be outside the board if(!n[2]){ //my chances s=0; if(!*pb && pe[1]<2 && pb!=comb+4){ s++; if(!*pe && pe!=comb+4) s++; } if(info_exact5==1 && n[1]==4 && (pe<comb+8 && pe[1]==1 || pb>comb && pb[-1]==1)){ six[0]=true; } amin(a1, priority[n[1]][s]); } if(!n[1]){ //opponent's chances s=0; if(!*pb && !(pe[1]&1) && pb!=comb+4){ s++; if(!*pe && pe!=comb+4) s++; } if(info_exact5==1 && n[2]==4 && (pe<comb+8 && pe[1]==2 || pb>comb && pb[-1]==2)){ six[1]=true; } amin(a2, priority[n[2]][s]); } } n[*++pe]++; n[*pb++]--; } } //store computed evaluation to the array ind->h[0]= short(six[0] ? 0 : a1); ind->h[1]= short(six[1] ? 0 : a2); ind++; }else{ //generate last five squares of combination for(int z=0; z<4; z++){ *pos=z; gen2(pos+1); } } } //generate first four squares of combination void gen1(int *pos) { if(pos==comb+5){ gen2(pos); }else{ for(int z=0; z<4; z++){ *pos=z; n[z]++; gen1(pos+1); n[z]--; } } } void gen() { ind=K; gen1(comb); } //------------------------------------------------------------------- void init() { int x,y,k; Psquare p; Tprior *pr; memset(goodMoves,0,sizeof(goodMoves)); memset(winMove,0,sizeof(winMove)); sum[0]= sum[1]= 0; //alocate the board delete[] board; height2=height+2; board= new Tsquare[(width+10)*(height2)]; boardb= board + 5*height2; boardk= boardb+ width*height2; // 5 4 3 // 6 8 2 // 7 0 1 diroff[0]=sizeof(Tsquare); diroff[4]=-diroff[0]; diroff[1]=sizeof(Tsquare)*(1+height2); diroff[5]=-diroff[1]; diroff[2]=sizeof(Tsquare)* height2; diroff[6]=-diroff[2]; diroff[3]=sizeof(Tsquare)*(-1+height2); diroff[7]=-diroff[3]; diroff[8]=0; //initialize the board p=board; for(x=-5; x<=width+4; x++){ for(y=-1; y<=height; y++){ p->z= (x<0 || y<0 || x>=width || y>=height) ? 3:0; p->x= (short)x; p->y= (short)y; for(k=0;k<2;k++){ pr=&p->h[k]; pr->i=0; pr->pv=4; pr->ps[0]=pr->ps[1]=pr->ps[2]=pr->ps[3]=1; } p++; } } moves=0; } //------------------------------------------------------------------- //evaluate squares around p0 to distance 4 void evaluate(Psquare p0) { int i,k,m,s,h; Tprior *pr; Psquare p,q,qk,*up,pe,pk1; int *u; int ind; unsigned pattern; static int last_exact5=-1; if(info_exact5!=last_exact5){ last_exact5=info_exact5; gen(); } //remove not empty square from list and set its evaluation to zero if(p0->z){ for(k=0; k<2; k++){ pr=&p0->h[k]; if(pr->pv){ if(pr->i){ if((*pr->pre= pr->nxt)!=0) pr->nxt->h[k].pre= pr->pre; pr->i=0; } sum[k]-= pr->pv; pr->pv= pr->ps[0]= pr->ps[1]= pr->ps[2]= pr->ps[3]= 0; } } } //cycle all directions for(i=0; i<4; i++){ s=diroff[i]; pk1=p0; nxtP(pk1,5); pe=p0; p=p0; for(m=4; m>0; m--){ prvP(p,1); if(p->z==3){ nxtP(pe,m); nxtP(p,1); break; } } pattern=0; qk=pe; prvP(qk,9); for(q=pe; q!=qk; prvP(q,1)){ pattern*=4; pattern+=q->z; } while(p->z!=3){ if(!p->z){ for(k=0; k<2; k++){ //both players pr= &p->h[k]; //change evaluation in one direction u= &pr->ps[i]; h= K[pattern].h[k]; if(info_exact5 && h>=H4){ if(prvQ(p,5)->z==k+1 && nxtQ(p,1)->z==0 || nxtQ(p,5)->z==k+1 && prvQ(p,1)->z==0){ h=0; } } m=h-*u; if(m){ *u=h; sum[k]+=m; pr->pv+=m; //choose linked list ind=0; if(pr->pv >= H21){ ind++; if(pr->pv >= 2*H21){ ind++; if(pr->pv >= H4) ind++; } } //put square to another linked list if(ind!=pr->i){ //remove if(pr->i){ if((*pr->pre= pr->nxt)!=0) pr->nxt->h[k].pre= pr->pre; } //append if((pr->i=ind)!=0){ up= &goodMoves[ind][k]; pr->nxt= *up; if(*up) (*up)->h[k].pre= &pr->nxt; pr->pre= up; *up= p; } } } } } nxtP(p,1); if(p==pk1) break; nxtP(pe,1); pattern>>=2; pattern+= pe->z << 16; } } } //------------------------------------------------------------------- int getEval(int player1, Psquare p0) { int i,s,y,c,c1,c2,n,d1,d2; Psquare p; y=0; //count symbols on 8 squares around p0 c1=c2=0; for(i=0; i<8; i++){ s=diroff[i]; p=p0; nxtP(p,1); if(p->z==player1+1) c1++; if(p->z==2-player1) c2++; } c=c1+c2; if(c==0) y-=20; //too empty if(c>4) y-=4*(c-3); //too many //blocked directions d1=d2=0; for(i=0; i<4; i++){ if(p0->h[player1].ps[i]<=1) d1++; if(p0->h[1-player1].ps[i]<=1) d2++; } //detect if there is only one player here if(c2==0 && c1>0 && p0->h[player1].pv>=H12){ y+= (c1+1)*5; } if(d2==4){ n=0; for(i=0; i<4; i++){ if(p0->h[player1].ps[i]>=H12) n++; } y+=15; if(n>1) y+=n*64; } return y + p0->h[player1].pv; } int getEval(Psquare p) { int a,b; a=getEval(0,p); b=getEval(1,p); return a>b ? a+b/2 : a/2+b; } //evaluate all squares in array winMoves void evalWinMoves() { int Nwins; int *e; Psquare *t,p; carefulAttack=true; //add high priority squares for(p=goodMoves[2][1]; p; p=p->h[1].nxt){ addWinMove(p); } //evaluate Nwins= UwinMoves-winMoves1; assert(Nwins<=MwinMoves); for(t=UwinMoves-1,e=winEval+Nwins-1; t!=winMoves1-1; t--,e--){ *e= getEval(1,*t); if(*t==highestEval) *e+=DEFEND_HIGHEVAL; } //add my chances to make four for(p=goodMoves[1][0]; p; p=p->h[0].nxt){ if(p->h[0].pv<H30) continue; addWinMove(p); if(p->inWinMoves==UwinMoves-1){ winEval[Nwins++]= p->h[0].pv>>3; } } } //------------------------------------------------------------------- //find square which has greatest evaluation //return 0 if evaluation is too low Psquare findMax() { Psquare p,t; int m,r; int i,k; m=-1; t=0; for(i=2; i>0 && !t; i--){ for(k=0; k<2; k++){ for(p=goodMoves[i][k]; p; p=p->h[k].nxt){ r= getEval(p); if(r>m){ m=r; t=p; } } } } return t; } //find out what total evaluation will be after AHEAD_DEPTH moves int lookAhead(int player1) { Psquare p; int y,i; if(goodMoves[3][player1]) return 700; int player2=1-player1; p=goodMoves[3][player2]; if(!p && dpth<AHEAD_DEPTH) p=findMax(); if(!p){ y= sum[0]-sum[1]; for(i=2; i>0; i--){ for(p=goodMoves[i][0]; p; p=p->h[0].nxt) y+=NUM_GOOD0; for(p=goodMoves[i][1]; p; p=p->h[1].nxt) y-=NUM_GOOD1; } if(player1) y=-y; return int(y/AHEAD_IRRELEVANCE); } dpth++; p->z=player1+1; evaluate(p); y= -lookAhead(player2); p->z=0; evaluate(p); dpth--; return y; } //------------------------------------------------------------------- DWORD seed= GetTickCount(); unsigned rnd(unsigned n) { seed=seed*367413989+174680251; return (unsigned)(UInt32x32To64(n,seed)>>32); } void databaseMove() { signed char *s,*sn; Psquare p,k; int i,x,y,x1,y1,flip,len1,len2,left,top,right,bottom; //board rectangle for(p=boardb; p->z!=1 && p->z!=2; p++) ; left=p->x; for(k=boardk; k->z!=1 && k->z!=2; k--) ; right=k->x; top=bottom=k->y; for(; p<k; p++){ if(p->z==1 || p->z==2){ amax(top,p->y); amin(bottom,p->y); } } //find current board in the database for(s=data; ; s=sn){ len1=*s++; len2=*s++; sn= s + 2*(len1+len2); if(len1!=moves){ if(len1<moves) return; continue; } //try all symmetries for(flip=0; flip<8; flip++){ for(i=0; ;i++){ x1=s[2*i]; y1=s[2*i+1]; if(i==len1){ s += 2*(len1+rnd(len2)); x1=*s++; y1=*s; } switch(flip){ case 0: x=left+x1; y=top+y1; break; case 1: x=right-x1; y=top+y1; break; case 2: x=left+x1; y=bottom-y1; break; case 3: x=right-x1; y=bottom-y1; break; case 4: x=left+y1; y=top+x1; break; case 5: x=right-y1; y=top+x1; break; case 6: x=left+y1; y=bottom-x1; break; default: x=right-y1; y=bottom-x1; break; } p=Square(x,y); if(i==len1){ doMove(p); return; } if(p->z != 2-(i&1)) break; } } } } void firstMove() { //the first move is in the middle of the board if(moves==0){ doMove(Square(width/2+rnd(5)-2,height/2+rnd(5)-2)); return; } if(moves==2){ Psquare p; for(p=boardb; p->z!=1; p++) ; doMove(nxtS(p,rnd(8))); } databaseMove(); //already four in a line -> don't think if(goodMoves[3][0] && (!info_continuous || !goodMoves[3][0]->h[0].nxt || !goodMoves[3][1])){ if(doMove(goodMoves[3][0])) return; //I win } doMove(goodMoves[3][1]); //I have to defend } //find square which has very good evaluation void getBestEval() { int i,r,m,d,a,b; Psquare p,bestMove; int Nresults=0; bestMove=0; if(moves>9){ m=-0x7ffffffe; for(p=boardb; p<boardk; p++){ if(!p->z && (p->h[0].pv>10 || p->h[1].pv>10)){ a=getEval(0,p); b=getEval(1,p); r= (a>b) ? int((a + b/2)*OFFENSIVE) : (a/2 + b); p->z=1; evaluate(p); r-= lookAhead(1); p->z=0; evaluate(p); if(r>m){ m=r; bestMove=p; Nresults=1; }else if(r>m-EVAL_RAND1){ Nresults++; if(!rnd(Nresults)) bestMove=p; } } } } if(!bestMove){ m=-0x7fffff; for(p=boardb; p<boardk; p++){ if(!p->z){ r=getEval(p); if(r>m) m=r; } } d= abs(m/12); amax(d,EVAL_RAND2); Nresults=0; for(p=boardb; p<boardk; p++){ if(!p->z){ if(getEval(p) >= m-d){ Nresults++; if(!rnd(Nresults)) bestMove=p; } } } } doMove(bestMove); highestEval=bestMove; if(lastMove){ p=lastMove; for(i=0; ; i++){ if(i==8){ //opponent made an isolated move -> defend it doMove(nxtS(p,rnd(8))); break; } if(nxtS(p,i)->h[1].ps[i&3]!=H12) break; } } } //------------------------------------------------------------------- void computer1() { int y=0; const int player1=0, player2=1; if(loss4){ winMove[player2]=loss4; winMoveDepth[player2]=10; y=-1; } bestMove=0; //attack if(!attackDone && (!loss4 || winMove[player1])){ #ifdef DEBUG print(carefulAttack ? "attack2":"attack"); #endif depthReached=false; //I have already found win if(winMove[player1]){ y= alfabeta(carefulAttack,1,player1,0,winMove[player1]); if(y<=0){ if(winMoveDepth[player1]<=depth) winMove[player1]= 0; } } if(!bestMove){ y= alfabeta(carefulAttack,1,player1,0); } if(y>0 && bestMove){ doMove(bestMove); winMove[player1]=bestMove; winMoveDepth[player1]=depth; #ifdef DEBUG if(!terminate) resulty=y; #endif if(!carefulAttack){ carefulAttack=true; }else{ terminate=3; //win } return; } if(!depthReached) attackDone=true; } //find out if opponent can win if(UwinMoves==winMoves1 && !testDone){ #ifdef DEBUG print("thinking"); #endif depthReached=false; y=0; if(winMove[player2]){ y= alfabeta(0,1,player2,1,winMove[player2]); if(y<=0){ if(winMoveDepth[player2]<=depth) winMove[player2]=0; UwinMoves=winMoves1; } } if(y<=0){ y= alfabeta(0,1,player2,1); if(y>0){ winMove[player2]=bestMove; winMoveDepth[player2]=depth; }else{ UwinMoves=winMoves1; } } if(y>0) evalWinMoves(); if(!depthReached) testDone=true; } //defend if(UwinMoves>winMoves1 && !defendDone && (!defendDone1 || carefulDefend)){ #ifdef DEBUG print(carefulDefend ? "defend2":"defend"); #endif depthReached=false; bestMove=0; y=defend(); if(!bestMove){ y=alfabeta(1,0,player1,0); } #ifdef DEBUG if(y<=0 && !terminate) resulty=y; #endif if(!depthReached){ if(!carefulDefend) defendDone1=true; else defendDone=true; } if(y<0) carefulDefend=true; doMove(bestMove); } assert(dpth==0); }
[ "root" ]
root
90cdfe9affffa73af96612ec748991e39572c23b
ce2077a9eb8573c0860f1e253b269ff76d715838
/contrib/qtbase/qbasicatomic.h
bf5bce86ea6a7d522594e8526e6c30674ade1b5c
[]
no_license
bsdoliv/libd
32074d846ac73c0f4f89b65c24f8fb409b2fb347
5b6b881856300807b352da28884b4b15b2ff7fa6
refs/heads/master
2020-09-21T02:27:54.756612
2016-12-13T15:37:13
2019-11-28T14:44:25
224,654,140
0
0
null
null
null
null
UTF-8
C++
false
false
11,598
h
/**************************************************************************** ** ** Copyright (C) 2011 Thiago Macieira <[email protected]> ** Contact: http://www.qt-project.org/legal ** ** This file is part of the QtCore module of the Qt Toolkit. ** ** $QT_BEGIN_LICENSE:LGPL$ ** Commercial License Usage ** Licensees holding valid commercial Qt licenses may use this file in ** accordance with the commercial license agreement provided with the ** Software or, alternatively, in accordance with the terms contained in ** a written agreement between you and Digia. For licensing terms and ** conditions see http://qt.digia.com/licensing. For further information ** use the contact form at http://qt.digia.com/contact-us. ** ** GNU Lesser General Public License Usage ** Alternatively, this file may be used under the terms of the GNU Lesser ** General Public License version 2.1 as published by the Free Software ** Foundation and appearing in the file LICENSE.LGPL included in the ** packaging of this file. Please review the following information to ** ensure the GNU Lesser General Public License version 2.1 requirements ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. ** ** In addition, as a special exception, Digia gives you certain additional ** rights. These rights are described in the Digia Qt LGPL Exception ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. ** ** GNU General Public License Usage ** Alternatively, this file may be used under the terms of the GNU ** General Public License version 3.0 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. Please review the following information to ** ensure the GNU General Public License version 3.0 requirements will be ** met: http://www.gnu.org/copyleft/gpl.html. ** ** ** $QT_END_LICENSE$ ** ****************************************************************************/ #include <qatomic.h> #ifndef QBASICATOMIC_H #define QBASICATOMIC_H #if defined(QT_BOOTSTRAPPED) #include <qatomic_bootstrap.h> // Compiler dependent implementation #elif defined(Q_CC_MSVC) #include <qatomic_msvc.h> // Operating system dependent implementation #elif defined(Q_OS_INTEGRITY) # include "QtCore/qatomic_integrity.h" #elif defined(Q_OS_VXWORKS) # include "QtCore/qatomic_vxworks.h" // Processor dependent implementation #elif defined(Q_PROCESSOR_ALPHA) # include "QtCore/qatomic_alpha.h" #elif defined(Q_PROCESSOR_ARM_V7) # include "QtCore/qatomic_armv7.h" #elif defined(Q_PROCESSOR_ARM_V6) # include "QtCore/qatomic_armv6.h" #elif defined(Q_PROCESSOR_ARM_V5) # include "QtCore/qatomic_armv5.h" #elif defined(Q_PROCESSOR_BFIN) # include "QtCore/qatomic_bfin.h" #elif defined(Q_PROCESSOR_IA64) # include "QtCore/qatomic_ia64.h" #elif defined(Q_PROCESSOR_MIPS) # include "QtCore/qatomic_mips.h" #elif defined(Q_PROCESSOR_POWER) # include "QtCore/qatomic_power.h" #elif defined(Q_PROCESSOR_S390) # include "QtCore/qatomic_s390.h" #elif defined(Q_PROCESSOR_SH4A) # include "QtCore/qatomic_sh4a.h" #elif defined(Q_PROCESSOR_SPARC) # include "QtCore/qatomic_sparc.h" #elif defined(Q_PROCESSOR_X86) #include <qatomic_x86.h> // Fallback compiler dependent implementation #elif defined(Q_COMPILER_ATOMICS) && defined(Q_COMPILER_CONSTEXPR) #include <qatomic_cxx11.h> #elif defined(Q_CC_GNU) #include <qatomic_gcc.h> // Fallback operating system dependent implementation #elif defined(Q_OS_UNIX) #include <qatomic_unix.h> // No fallback #else # error "Qt has not been ported to this platform" #endif // Only include if the implementation has been ported to QAtomicOps #ifndef QOLDBASICATOMIC_H QT_BEGIN_NAMESPACE #if 0 // silence syncqt warnings QT_END_NAMESPACE #pragma qt_no_master_include #pragma qt_sync_stop_processing #endif // New atomics #if defined(Q_COMPILER_CONSTEXPR) && defined(Q_COMPILER_DEFAULT_MEMBERS) && defined(Q_COMPILER_DELETE_MEMBERS) # if defined(Q_CC_CLANG) && ((((__clang_major__ * 100) + __clang_minor__) < 303) \ || defined(__apple_build_version__) \ ) /* Do not define QT_BASIC_ATOMIC_HAS_CONSTRUCTORS for "stock" clang before version 3.3. Apple's version has different (higher!) version numbers, so disable it for all of them for now. (The only way to distinguish between them seems to be a check for __apple_build_version__ .) For details about the bug: see http://llvm.org/bugs/show_bug.cgi?id=12670 */ # else # define QT_BASIC_ATOMIC_HAS_CONSTRUCTORS # endif #endif template <typename T> class QBasicAtomicInteger { public: typedef QAtomicOps<T> Ops; // static check that this is a valid integer typedef char PermittedIntegerType[QAtomicIntegerTraits<T>::IsInteger ? 1 : -1]; typename Ops::Type _q_value; // Non-atomic API T load() const Q_DECL_NOTHROW { return Ops::load(_q_value); } void store(T newValue) Q_DECL_NOTHROW { Ops::store(_q_value, newValue); } // Atomic API, implemented in qatomic_XXX.h T loadAcquire() const Q_DECL_NOTHROW { return Ops::loadAcquire(_q_value); } void storeRelease(T newValue) Q_DECL_NOTHROW { Ops::storeRelease(_q_value, newValue); } static Q_DECL_CONSTEXPR bool isReferenceCountingNative() Q_DECL_NOTHROW { return Ops::isReferenceCountingNative(); } static Q_DECL_CONSTEXPR bool isReferenceCountingWaitFree() Q_DECL_NOTHROW { return Ops::isReferenceCountingWaitFree(); } bool ref() Q_DECL_NOTHROW { return Ops::ref(_q_value); } bool deref() Q_DECL_NOTHROW { return Ops::deref(_q_value); } static Q_DECL_CONSTEXPR bool isTestAndSetNative() Q_DECL_NOTHROW { return Ops::isTestAndSetNative(); } static Q_DECL_CONSTEXPR bool isTestAndSetWaitFree() Q_DECL_NOTHROW { return Ops::isTestAndSetWaitFree(); } bool testAndSetRelaxed(T expectedValue, T newValue) Q_DECL_NOTHROW { return Ops::testAndSetRelaxed(_q_value, expectedValue, newValue); } bool testAndSetAcquire(T expectedValue, T newValue) Q_DECL_NOTHROW { return Ops::testAndSetAcquire(_q_value, expectedValue, newValue); } bool testAndSetRelease(T expectedValue, T newValue) Q_DECL_NOTHROW { return Ops::testAndSetRelease(_q_value, expectedValue, newValue); } bool testAndSetOrdered(T expectedValue, T newValue) Q_DECL_NOTHROW { return Ops::testAndSetOrdered(_q_value, expectedValue, newValue); } static Q_DECL_CONSTEXPR bool isFetchAndStoreNative() Q_DECL_NOTHROW { return Ops::isFetchAndStoreNative(); } static Q_DECL_CONSTEXPR bool isFetchAndStoreWaitFree() Q_DECL_NOTHROW { return Ops::isFetchAndStoreWaitFree(); } T fetchAndStoreRelaxed(T newValue) Q_DECL_NOTHROW { return Ops::fetchAndStoreRelaxed(_q_value, newValue); } T fetchAndStoreAcquire(T newValue) Q_DECL_NOTHROW { return Ops::fetchAndStoreAcquire(_q_value, newValue); } T fetchAndStoreRelease(T newValue) Q_DECL_NOTHROW { return Ops::fetchAndStoreRelease(_q_value, newValue); } T fetchAndStoreOrdered(T newValue) Q_DECL_NOTHROW { return Ops::fetchAndStoreOrdered(_q_value, newValue); } static Q_DECL_CONSTEXPR bool isFetchAndAddNative() Q_DECL_NOTHROW { return Ops::isFetchAndAddNative(); } static Q_DECL_CONSTEXPR bool isFetchAndAddWaitFree() Q_DECL_NOTHROW { return Ops::isFetchAndAddWaitFree(); } T fetchAndAddRelaxed(T valueToAdd) Q_DECL_NOTHROW { return Ops::fetchAndAddRelaxed(_q_value, valueToAdd); } T fetchAndAddAcquire(T valueToAdd) Q_DECL_NOTHROW { return Ops::fetchAndAddAcquire(_q_value, valueToAdd); } T fetchAndAddRelease(T valueToAdd) Q_DECL_NOTHROW { return Ops::fetchAndAddRelease(_q_value, valueToAdd); } T fetchAndAddOrdered(T valueToAdd) Q_DECL_NOTHROW { return Ops::fetchAndAddOrdered(_q_value, valueToAdd); } #ifdef QT_BASIC_ATOMIC_HAS_CONSTRUCTORS QBasicAtomicInteger() = default; constexpr QBasicAtomicInteger(T value) Q_DECL_NOTHROW : _q_value(value) {} QBasicAtomicInteger(const QBasicAtomicInteger &) = delete; QBasicAtomicInteger &operator=(const QBasicAtomicInteger &) = delete; QBasicAtomicInteger &operator=(const QBasicAtomicInteger &) volatile = delete; #endif }; typedef QBasicAtomicInteger<int> QBasicAtomicInt; template <typename X> class QBasicAtomicPointer { public: typedef X *Type; typedef QAtomicOps<Type> Ops; typedef typename Ops::Type AtomicType; AtomicType _q_value; // Non-atomic API Type load() const Q_DECL_NOTHROW { return _q_value; } void store(Type newValue) Q_DECL_NOTHROW { _q_value = newValue; } // Atomic API, implemented in qatomic_XXX.h Type loadAcquire() const Q_DECL_NOTHROW { return Ops::loadAcquire(_q_value); } void storeRelease(Type newValue) Q_DECL_NOTHROW { Ops::storeRelease(_q_value, newValue); } static Q_DECL_CONSTEXPR bool isTestAndSetNative() Q_DECL_NOTHROW { return Ops::isTestAndSetNative(); } static Q_DECL_CONSTEXPR bool isTestAndSetWaitFree() Q_DECL_NOTHROW { return Ops::isTestAndSetWaitFree(); } bool testAndSetRelaxed(Type expectedValue, Type newValue) Q_DECL_NOTHROW { return Ops::testAndSetRelaxed(_q_value, expectedValue, newValue); } bool testAndSetAcquire(Type expectedValue, Type newValue) Q_DECL_NOTHROW { return Ops::testAndSetAcquire(_q_value, expectedValue, newValue); } bool testAndSetRelease(Type expectedValue, Type newValue) Q_DECL_NOTHROW { return Ops::testAndSetRelease(_q_value, expectedValue, newValue); } bool testAndSetOrdered(Type expectedValue, Type newValue) Q_DECL_NOTHROW { return Ops::testAndSetOrdered(_q_value, expectedValue, newValue); } static Q_DECL_CONSTEXPR bool isFetchAndStoreNative() Q_DECL_NOTHROW { return Ops::isFetchAndStoreNative(); } static Q_DECL_CONSTEXPR bool isFetchAndStoreWaitFree() Q_DECL_NOTHROW { return Ops::isFetchAndStoreWaitFree(); } Type fetchAndStoreRelaxed(Type newValue) Q_DECL_NOTHROW { return Ops::fetchAndStoreRelaxed(_q_value, newValue); } Type fetchAndStoreAcquire(Type newValue) Q_DECL_NOTHROW { return Ops::fetchAndStoreAcquire(_q_value, newValue); } Type fetchAndStoreRelease(Type newValue) Q_DECL_NOTHROW { return Ops::fetchAndStoreRelease(_q_value, newValue); } Type fetchAndStoreOrdered(Type newValue) Q_DECL_NOTHROW { return Ops::fetchAndStoreOrdered(_q_value, newValue); } static Q_DECL_CONSTEXPR bool isFetchAndAddNative() Q_DECL_NOTHROW { return Ops::isFetchAndAddNative(); } static Q_DECL_CONSTEXPR bool isFetchAndAddWaitFree() Q_DECL_NOTHROW { return Ops::isFetchAndAddWaitFree(); } Type fetchAndAddRelaxed(qptrdiff valueToAdd) Q_DECL_NOTHROW { return Ops::fetchAndAddRelaxed(_q_value, valueToAdd); } Type fetchAndAddAcquire(qptrdiff valueToAdd) Q_DECL_NOTHROW { return Ops::fetchAndAddAcquire(_q_value, valueToAdd); } Type fetchAndAddRelease(qptrdiff valueToAdd) Q_DECL_NOTHROW { return Ops::fetchAndAddRelease(_q_value, valueToAdd); } Type fetchAndAddOrdered(qptrdiff valueToAdd) Q_DECL_NOTHROW { return Ops::fetchAndAddOrdered(_q_value, valueToAdd); } #ifdef QT_BASIC_ATOMIC_HAS_CONSTRUCTORS QBasicAtomicPointer() = default; constexpr QBasicAtomicPointer(Type value) Q_DECL_NOTHROW : _q_value(value) {} QBasicAtomicPointer(const QBasicAtomicPointer &) = delete; QBasicAtomicPointer &operator=(const QBasicAtomicPointer &) = delete; QBasicAtomicPointer &operator=(const QBasicAtomicPointer &) volatile = delete; #endif }; #ifndef Q_BASIC_ATOMIC_INITIALIZER # define Q_BASIC_ATOMIC_INITIALIZER(a) { (a) } #endif QT_END_NAMESPACE #endif // QOLDBASICATOMIC_H #endif // QBASICATOMIC_H
284eba9939df68f3c80fd298f07e1d9e1168b38c
6fd3d7340eaaab551a22f5918d3c5fd3d27040c0
/SERVERS/NetLib/HttpDownloader.h
4a86c49f256d121a42b822d293217012af4a0d46
[]
no_license
Aden2018/WinServer
beda5bb9058a08d1961f2852b48ca5217ca80e86
f3c068cd8afed691e32fc6516060187014ba3a71
refs/heads/master
2023-03-18T20:10:55.698791
2018-03-02T03:50:21
2018-03-02T03:50:21
null
0
0
null
null
null
null
UTF-8
C++
false
false
2,367
h
#ifndef __HTTP_DOWNLAODER__ #define __HTTP_DOWNLAODER__ #ifndef interface #define interface struct #endif #include <WinSock2.h> #include <msxml.h> #include <windows.h> #include <atlcomcli.h> #include <string> #include <stdio.h> namespace CHttpDownloaderHelper { struct Helper { Helper(); virtual ~Helper(); }; } typedef bool (*HttpDownloaderCallback)( IStream* pStream, void* userItem ); class CHttpDownloader { public: CHttpDownloader(); virtual ~CHttpDownloader(); public: HANDLE startDownload( std::string url, std::string fileName ); void startReceive( std::string &url, std::string method,HANDLE completedEvent ); HANDLE startReceive( std::string url ); std::string getFileName(); bool isFinished(); private: class XMLHttpEventSink : public IDispatch { public: XMLHttpEventSink(IXMLHttpRequest* request, HANDLE completedEvent, HttpDownloaderCallback httpCallback, void* userItem ) : _refCount(1), _request(request), _completedEvent(completedEvent), mHttpCallback(httpCallback), mUserItem( userItem ) { // Don't increase the reference count to the request object; doing so would create a circular reference // and thus a memory leak. } virtual ~XMLHttpEventSink() { } // IUnknown STDMETHODIMP QueryInterface(REFIID riid, void **ppvObject); STDMETHODIMP_(ULONG) AddRef(); STDMETHODIMP_(ULONG) Release(); // IDispatch STDMETHODIMP GetTypeInfoCount(UINT *pctinfo); STDMETHODIMP GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo); STDMETHODIMP GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId); STDMETHODIMP Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr); private: LONG _refCount; IXMLHttpRequest* _request; HANDLE _completedEvent; HttpDownloaderCallback mHttpCallback; void* mUserItem; }; private: enum { StateNone, StateGetHeader, StateGetData, }; private: CComPtr<IXMLHttpRequest> mXmlHttpRequest; int mState; FILE* mFile; std::string mFileName; int mTotalReceiveSize; int mFileSize; std::string mUrl; HANDLE mCompletHandle; static const int MAX_BUFFSER_SIZE = 1024 * 1024; static CHttpDownloaderHelper::Helper _httpDownloaderHelper; static bool ProcessReceive( IStream* pStream, void* userItem ); } ; #endif
eb36a2043f8bc56035d39e70480fb8d9dcc4360b
76ddfd4a89be8d5dacad976ffe6d19ef8304c8d7
/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp
cae3e943842fc4b5350e89074e6c6e73f08859b8
[ "MIT" ]
permissive
aismann/cocos2d-x
a76f8c2557a257cf9af528efc48f1bad9a3ea3a6
48cb13de46a92e8435b5aceb16acaa8e2cf71bb6
refs/heads/master
2023-07-01T16:59:39.115716
2021-08-04T22:41:56
2021-08-04T22:41:56
null
0
0
null
null
null
null
UTF-8
C++
false
false
3,027,748
cpp
#include "scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp" #include "cocos2d.h" #include "2d/CCProtectedNode.h" #include "base/CCAsyncTaskPool.h" #include "scripting/lua-bindings/manual/CCComponentLua.h" #include "scripting/lua-bindings/manual/tolua_fix.h" #include "scripting/lua-bindings/manual/LuaBasicConversions.h" #if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID || \ CC_TARGET_PLATFORM == CC_PLATFORM_IOS || \ CC_TARGET_PLATFORM == CC_PLATFORM_WINRT || \ CC_TARGET_PLATFORM == CC_PLATFORM_MAC) #include "base/CCEventListenerController.h" #include "base/CCEventController.h" #include "base/CCController.h" #endif int lua_cocos2dx_Ref_release(lua_State* tolua_S) { int argc = 0; cocos2d::Ref* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ref",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ref*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ref_release'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ref_release'", nullptr); return 0; } cobj->release(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ref:release",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ref_release'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ref_retain(lua_State* tolua_S) { int argc = 0; cocos2d::Ref* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ref",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ref*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ref_retain'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ref_retain'", nullptr); return 0; } cobj->retain(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ref:retain",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ref_retain'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ref_getReferenceCount(lua_State* tolua_S) { int argc = 0; cocos2d::Ref* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ref",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ref*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ref_getReferenceCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ref_getReferenceCount'", nullptr); return 0; } unsigned int ret = cobj->getReferenceCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ref:getReferenceCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ref_getReferenceCount'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Ref_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Ref)"); return 0; } int lua_register_cocos2dx_Ref(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Ref"); tolua_cclass(tolua_S,"Ref","cc.Ref","",nullptr); tolua_beginmodule(tolua_S,"Ref"); tolua_function(tolua_S,"release",lua_cocos2dx_Ref_release); tolua_function(tolua_S,"retain",lua_cocos2dx_Ref_retain); tolua_function(tolua_S,"getReferenceCount",lua_cocos2dx_Ref_getReferenceCount); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Ref).name(); g_luaType[typeName] = "cc.Ref"; g_typeCast["Ref"] = "cc.Ref"; return 1; } int lua_cocos2dx_Console_addSubCommand(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_addSubCommand'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Console::Command arg0; #pragma warning NO CONVERSION TO NATIVE FOR Command ok = false; if (!ok) { break; } cocos2d::Console::Command arg1; #pragma warning NO CONVERSION TO NATIVE FOR Command ok = false; if (!ok) { break; } cobj->addSubCommand(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Console:addSubCommand"); if (!ok) { break; } cocos2d::Console::Command arg1; #pragma warning NO CONVERSION TO NATIVE FOR Command ok = false; if (!ok) { break; } cobj->addSubCommand(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:addSubCommand",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_addSubCommand'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_listenOnTCP(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_listenOnTCP'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Console:listenOnTCP"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Console_listenOnTCP'", nullptr); return 0; } bool ret = cobj->listenOnTCP(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:listenOnTCP",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_listenOnTCP'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_log(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_log'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Console:log"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Console_log'", nullptr); return 0; } cobj->log(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:log",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_log'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_getSubCommand(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_getSubCommand'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Console::Command arg0; #pragma warning NO CONVERSION TO NATIVE FOR Command ok = false; if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Console:getSubCommand"); if (!ok) { break; } const cocos2d::Console::Command* ret = cobj->getSubCommand(arg0, arg1); #pragma warning NO CONVERSION FROM NATIVE FOR Command*; return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Console:getSubCommand"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Console:getSubCommand"); if (!ok) { break; } const cocos2d::Console::Command* ret = cobj->getSubCommand(arg0, arg1); #pragma warning NO CONVERSION FROM NATIVE FOR Command*; return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:getSubCommand",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_getSubCommand'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_delCommand(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_delCommand'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Console:delCommand"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Console_delCommand'", nullptr); return 0; } cobj->delCommand(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:delCommand",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_delCommand'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_stop(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_stop'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Console_stop'", nullptr); return 0; } cobj->stop(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:stop",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_stop'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_getCommand(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_getCommand'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Console:getCommand"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Console_getCommand'", nullptr); return 0; } const cocos2d::Console::Command* ret = cobj->getCommand(arg0); #pragma warning NO CONVERSION FROM NATIVE FOR Command*; return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:getCommand",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_getCommand'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_listenOnFileDescriptor(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_listenOnFileDescriptor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Console:listenOnFileDescriptor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Console_listenOnFileDescriptor'", nullptr); return 0; } bool ret = cobj->listenOnFileDescriptor(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:listenOnFileDescriptor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_listenOnFileDescriptor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_setBindAddress(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_setBindAddress'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Console:setBindAddress"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Console_setBindAddress'", nullptr); return 0; } cobj->setBindAddress(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:setBindAddress",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_setBindAddress'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_delSubCommand(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_delSubCommand'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Console::Command arg0; #pragma warning NO CONVERSION TO NATIVE FOR Command ok = false; if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Console:delSubCommand"); if (!ok) { break; } cobj->delSubCommand(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Console:delSubCommand"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Console:delSubCommand"); if (!ok) { break; } cobj->delSubCommand(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:delSubCommand",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_delSubCommand'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Console_isIpv6Server(lua_State* tolua_S) { int argc = 0; cocos2d::Console* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Console",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Console*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Console_isIpv6Server'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Console_isIpv6Server'", nullptr); return 0; } bool ret = cobj->isIpv6Server(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Console:isIpv6Server",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Console_isIpv6Server'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Console_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Console)"); return 0; } int lua_register_cocos2dx_Console(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Console"); tolua_cclass(tolua_S,"Console","cc.Console","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Console"); tolua_function(tolua_S,"addSubCommand",lua_cocos2dx_Console_addSubCommand); tolua_function(tolua_S,"listenOnTCP",lua_cocos2dx_Console_listenOnTCP); tolua_function(tolua_S,"log",lua_cocos2dx_Console_log); tolua_function(tolua_S,"getSubCommand",lua_cocos2dx_Console_getSubCommand); tolua_function(tolua_S,"delCommand",lua_cocos2dx_Console_delCommand); tolua_function(tolua_S,"stop",lua_cocos2dx_Console_stop); tolua_function(tolua_S,"getCommand",lua_cocos2dx_Console_getCommand); tolua_function(tolua_S,"listenOnFileDescriptor",lua_cocos2dx_Console_listenOnFileDescriptor); tolua_function(tolua_S,"setBindAddress",lua_cocos2dx_Console_setBindAddress); tolua_function(tolua_S,"delSubCommand",lua_cocos2dx_Console_delSubCommand); tolua_function(tolua_S,"isIpv6Server",lua_cocos2dx_Console_isIpv6Server); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Console).name(); g_luaType[typeName] = "cc.Console"; g_typeCast["Console"] = "cc.Console"; return 1; } int lua_cocos2dx_Texture2D_getMaxT(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getMaxT'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getMaxT'", nullptr); return 0; } double ret = cobj->getMaxT(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getMaxT",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getMaxT'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_setAlphaTexture(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_setAlphaTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Texture2D:setAlphaTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_setAlphaTexture'", nullptr); return 0; } cobj->setAlphaTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:setAlphaTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_setAlphaTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getStringForFormat(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getStringForFormat'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getStringForFormat'", nullptr); return 0; } const char* ret = cobj->getStringForFormat(); tolua_pushstring(tolua_S,(const char*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getStringForFormat",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getStringForFormat'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_initWithImage(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_initWithImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Image* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Image>(tolua_S, 2, "cc.Image",&arg0, "cc.Texture2D:initWithImage"); if (!ok) { break; } cocos2d::Texture2D::PixelFormat arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Texture2D:initWithImage"); if (!ok) { break; } bool ret = cobj->initWithImage(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Image* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Image>(tolua_S, 2, "cc.Image",&arg0, "cc.Texture2D:initWithImage"); if (!ok) { break; } bool ret = cobj->initWithImage(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:initWithImage",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_initWithImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getMaxS(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getMaxS'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getMaxS'", nullptr); return 0; } double ret = cobj->getMaxS(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getMaxS",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getMaxS'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_releaseGLTexture(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_releaseGLTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_releaseGLTexture'", nullptr); return 0; } cobj->releaseGLTexture(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:releaseGLTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_releaseGLTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_hasPremultipliedAlpha(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_hasPremultipliedAlpha'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_hasPremultipliedAlpha'", nullptr); return 0; } bool ret = cobj->hasPremultipliedAlpha(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:hasPremultipliedAlpha",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_hasPremultipliedAlpha'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getPixelsHigh(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getPixelsHigh'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getPixelsHigh'", nullptr); return 0; } int ret = cobj->getPixelsHigh(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getPixelsHigh",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getPixelsHigh'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getAlphaTextureName(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getAlphaTextureName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getAlphaTextureName'", nullptr); return 0; } unsigned int ret = cobj->getAlphaTextureName(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getAlphaTextureName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getAlphaTextureName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getBitsPerPixelForFormat(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getBitsPerPixelForFormat'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { cocos2d::Texture2D::PixelFormat arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Texture2D:getBitsPerPixelForFormat"); if (!ok) { break; } unsigned int ret = cobj->getBitsPerPixelForFormat(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { unsigned int ret = cobj->getBitsPerPixelForFormat(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getBitsPerPixelForFormat",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getBitsPerPixelForFormat'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getName(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getName'", nullptr); return 0; } unsigned int ret = cobj->getName(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_initWithString(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_initWithString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Texture2D:initWithString"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } cocos2d::FontDefinition arg1; ok &= luaval_to_fontdefinition(tolua_S, 3, &arg1, "cc.Texture2D:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Texture2D:initWithString"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Texture2D:initWithString"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Texture2D:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Texture2D:initWithString"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Texture2D:initWithString"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::Size arg3; ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Texture2D:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 5) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Texture2D:initWithString"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Texture2D:initWithString"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::Size arg3; ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::TextHAlignment arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.Texture2D:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 6) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Texture2D:initWithString"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Texture2D:initWithString"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::Size arg3; ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::TextHAlignment arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::TextVAlignment arg5; ok &= luaval_to_int32(tolua_S, 7,(int *)&arg5, "cc.Texture2D:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1, arg2, arg3, arg4, arg5); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 7) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Texture2D:initWithString"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Texture2D:initWithString"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::Size arg3; ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::TextHAlignment arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::TextVAlignment arg5; ok &= luaval_to_int32(tolua_S, 7,(int *)&arg5, "cc.Texture2D:initWithString"); if (!ok) { break; } bool arg6; ok &= luaval_to_boolean(tolua_S, 8,&arg6, "cc.Texture2D:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1, arg2, arg3, arg4, arg5, arg6); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 8) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Texture2D:initWithString"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Texture2D:initWithString"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::Size arg3; ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::TextHAlignment arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.Texture2D:initWithString"); if (!ok) { break; } cocos2d::TextVAlignment arg5; ok &= luaval_to_int32(tolua_S, 7,(int *)&arg5, "cc.Texture2D:initWithString"); if (!ok) { break; } bool arg6; ok &= luaval_to_boolean(tolua_S, 8,&arg6, "cc.Texture2D:initWithString"); if (!ok) { break; } int arg7; ok &= luaval_to_int32(tolua_S, 9,(int *)&arg7, "cc.Texture2D:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:initWithString",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_initWithString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_setMaxT(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_setMaxT'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Texture2D:setMaxT"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_setMaxT'", nullptr); return 0; } cobj->setMaxT(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:setMaxT",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_setMaxT'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getPath(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getPath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getPath'", nullptr); return 0; } std::string ret = cobj->getPath(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getPath",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getPath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_drawInRect(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_drawInRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Texture2D:drawInRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_drawInRect'", nullptr); return 0; } cobj->drawInRect(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:drawInRect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_drawInRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getContentSize(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getContentSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getContentSize'", nullptr); return 0; } cocos2d::Size ret = cobj->getContentSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getContentSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getContentSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_setAliasTexParameters(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_setAliasTexParameters'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_setAliasTexParameters'", nullptr); return 0; } cobj->setAliasTexParameters(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:setAliasTexParameters",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_setAliasTexParameters'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_setAntiAliasTexParameters(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_setAntiAliasTexParameters'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_setAntiAliasTexParameters'", nullptr); return 0; } cobj->setAntiAliasTexParameters(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:setAntiAliasTexParameters",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_setAntiAliasTexParameters'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_generateMipmap(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_generateMipmap'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_generateMipmap'", nullptr); return 0; } cobj->generateMipmap(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:generateMipmap",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_generateMipmap'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getAlphaTexture(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getAlphaTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getAlphaTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getAlphaTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getAlphaTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getAlphaTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getDescription(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getDescription'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getDescription'", nullptr); return 0; } std::string ret = cobj->getDescription(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getDescription",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getDescription'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getPixelFormat(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getPixelFormat'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getPixelFormat'", nullptr); return 0; } int ret = (int)cobj->getPixelFormat(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getPixelFormat",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getPixelFormat'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_setGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_setGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::GLProgram* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GLProgram>(tolua_S, 2, "cc.GLProgram",&arg0, "cc.Texture2D:setGLProgram"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_setGLProgram'", nullptr); return 0; } cobj->setGLProgram(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:setGLProgram",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_setGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getContentSizeInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getContentSizeInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getContentSizeInPixels'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getContentSizeInPixels(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getContentSizeInPixels",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getContentSizeInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getPixelsWide(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getPixelsWide'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getPixelsWide'", nullptr); return 0; } int ret = cobj->getPixelsWide(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getPixelsWide",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getPixelsWide'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_drawAtPoint(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_drawAtPoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Texture2D:drawAtPoint"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_drawAtPoint'", nullptr); return 0; } cobj->drawAtPoint(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:drawAtPoint",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_drawAtPoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_getGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getGLProgram'", nullptr); return 0; } cocos2d::GLProgram* ret = cobj->getGLProgram(); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:getGLProgram",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_hasMipmaps(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_hasMipmaps'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_hasMipmaps'", nullptr); return 0; } bool ret = cobj->hasMipmaps(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:hasMipmaps",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_hasMipmaps'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_setMaxS(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Texture2D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Texture2D_setMaxS'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Texture2D:setMaxS"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_setMaxS'", nullptr); return 0; } cobj->setMaxS(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:setMaxS",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_setMaxS'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_setDefaultAlphaPixelFormat(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Texture2D::PixelFormat arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Texture2D:setDefaultAlphaPixelFormat"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_setDefaultAlphaPixelFormat'", nullptr); return 0; } cocos2d::Texture2D::setDefaultAlphaPixelFormat(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Texture2D:setDefaultAlphaPixelFormat",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_setDefaultAlphaPixelFormat'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_getDefaultAlphaPixelFormat(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Texture2D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_getDefaultAlphaPixelFormat'", nullptr); return 0; } int ret = (int)cocos2d::Texture2D::getDefaultAlphaPixelFormat(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Texture2D:getDefaultAlphaPixelFormat",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_getDefaultAlphaPixelFormat'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Texture2D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Texture2D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Texture2D_constructor'", nullptr); return 0; } cobj = new cocos2d::Texture2D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Texture2D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Texture2D:Texture2D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Texture2D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Texture2D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Texture2D)"); return 0; } int lua_register_cocos2dx_Texture2D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Texture2D"); tolua_cclass(tolua_S,"Texture2D","cc.Texture2D","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Texture2D"); tolua_function(tolua_S,"new",lua_cocos2dx_Texture2D_constructor); tolua_function(tolua_S,"getMaxT",lua_cocos2dx_Texture2D_getMaxT); tolua_function(tolua_S,"setAlphaTexture",lua_cocos2dx_Texture2D_setAlphaTexture); tolua_function(tolua_S,"getStringForFormat",lua_cocos2dx_Texture2D_getStringForFormat); tolua_function(tolua_S,"initWithImage",lua_cocos2dx_Texture2D_initWithImage); tolua_function(tolua_S,"getMaxS",lua_cocos2dx_Texture2D_getMaxS); tolua_function(tolua_S,"releaseGLTexture",lua_cocos2dx_Texture2D_releaseGLTexture); tolua_function(tolua_S,"hasPremultipliedAlpha",lua_cocos2dx_Texture2D_hasPremultipliedAlpha); tolua_function(tolua_S,"getPixelsHigh",lua_cocos2dx_Texture2D_getPixelsHigh); tolua_function(tolua_S,"getAlphaTextureName",lua_cocos2dx_Texture2D_getAlphaTextureName); tolua_function(tolua_S,"getBitsPerPixelForFormat",lua_cocos2dx_Texture2D_getBitsPerPixelForFormat); tolua_function(tolua_S,"getName",lua_cocos2dx_Texture2D_getName); tolua_function(tolua_S,"initWithString",lua_cocos2dx_Texture2D_initWithString); tolua_function(tolua_S,"setMaxT",lua_cocos2dx_Texture2D_setMaxT); tolua_function(tolua_S,"getPath",lua_cocos2dx_Texture2D_getPath); tolua_function(tolua_S,"drawInRect",lua_cocos2dx_Texture2D_drawInRect); tolua_function(tolua_S,"getContentSize",lua_cocos2dx_Texture2D_getContentSize); tolua_function(tolua_S,"setAliasTexParameters",lua_cocos2dx_Texture2D_setAliasTexParameters); tolua_function(tolua_S,"setAntiAliasTexParameters",lua_cocos2dx_Texture2D_setAntiAliasTexParameters); tolua_function(tolua_S,"generateMipmap",lua_cocos2dx_Texture2D_generateMipmap); tolua_function(tolua_S,"getAlphaTexture",lua_cocos2dx_Texture2D_getAlphaTexture); tolua_function(tolua_S,"getDescription",lua_cocos2dx_Texture2D_getDescription); tolua_function(tolua_S,"getPixelFormat",lua_cocos2dx_Texture2D_getPixelFormat); tolua_function(tolua_S,"setGLProgram",lua_cocos2dx_Texture2D_setGLProgram); tolua_function(tolua_S,"getContentSizeInPixels",lua_cocos2dx_Texture2D_getContentSizeInPixels); tolua_function(tolua_S,"getPixelsWide",lua_cocos2dx_Texture2D_getPixelsWide); tolua_function(tolua_S,"drawAtPoint",lua_cocos2dx_Texture2D_drawAtPoint); tolua_function(tolua_S,"getGLProgram",lua_cocos2dx_Texture2D_getGLProgram); tolua_function(tolua_S,"hasMipmaps",lua_cocos2dx_Texture2D_hasMipmaps); tolua_function(tolua_S,"setMaxS",lua_cocos2dx_Texture2D_setMaxS); tolua_function(tolua_S,"setDefaultAlphaPixelFormat", lua_cocos2dx_Texture2D_setDefaultAlphaPixelFormat); tolua_function(tolua_S,"getDefaultAlphaPixelFormat", lua_cocos2dx_Texture2D_getDefaultAlphaPixelFormat); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Texture2D).name(); g_luaType[typeName] = "cc.Texture2D"; g_typeCast["Texture2D"] = "cc.Texture2D"; return 1; } int lua_cocos2dx_Touch_getPreviousLocationInView(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getPreviousLocationInView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getPreviousLocationInView'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getPreviousLocationInView(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getPreviousLocationInView",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getPreviousLocationInView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getLocation(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getLocation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getLocation'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getLocation(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getLocation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getLocation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getDelta(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getDelta'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getDelta'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getDelta(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getDelta",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getDelta'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getStartLocationInView(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getStartLocationInView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getStartLocationInView'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getStartLocationInView(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getStartLocationInView",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getStartLocationInView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getCurrentForce(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getCurrentForce'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getCurrentForce'", nullptr); return 0; } double ret = cobj->getCurrentForce(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getCurrentForce",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getCurrentForce'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getStartLocation(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getStartLocation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getStartLocation'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getStartLocation(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getStartLocation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getStartLocation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getID(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getID'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getID'", nullptr); return 0; } int ret = cobj->getID(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getID",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getID'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_setTouchInfo(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_setTouchInfo'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 5) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Touch:setTouchInfo"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Touch:setTouchInfo"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Touch:setTouchInfo"); if (!ok) { break; } double arg3; ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Touch:setTouchInfo"); if (!ok) { break; } double arg4; ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.Touch:setTouchInfo"); if (!ok) { break; } cobj->setTouchInfo(arg0, arg1, arg2, arg3, arg4); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Touch:setTouchInfo"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Touch:setTouchInfo"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Touch:setTouchInfo"); if (!ok) { break; } cobj->setTouchInfo(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:setTouchInfo",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_setTouchInfo'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getMaxForce(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getMaxForce'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getMaxForce'", nullptr); return 0; } double ret = cobj->getMaxForce(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getMaxForce",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getMaxForce'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getLocationInView(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getLocationInView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getLocationInView'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getLocationInView(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getLocationInView",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getLocationInView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_getPreviousLocation(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Touch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Touch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Touch_getPreviousLocation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_getPreviousLocation'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getPreviousLocation(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:getPreviousLocation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_getPreviousLocation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Touch_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Touch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Touch_constructor'", nullptr); return 0; } cobj = new cocos2d::Touch(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Touch"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Touch:Touch",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Touch_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Touch_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Touch)"); return 0; } int lua_register_cocos2dx_Touch(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Touch"); tolua_cclass(tolua_S,"Touch","cc.Touch","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Touch"); tolua_function(tolua_S,"new",lua_cocos2dx_Touch_constructor); tolua_function(tolua_S,"getPreviousLocationInView",lua_cocos2dx_Touch_getPreviousLocationInView); tolua_function(tolua_S,"getLocation",lua_cocos2dx_Touch_getLocation); tolua_function(tolua_S,"getDelta",lua_cocos2dx_Touch_getDelta); tolua_function(tolua_S,"getStartLocationInView",lua_cocos2dx_Touch_getStartLocationInView); tolua_function(tolua_S,"getCurrentForce",lua_cocos2dx_Touch_getCurrentForce); tolua_function(tolua_S,"getStartLocation",lua_cocos2dx_Touch_getStartLocation); tolua_function(tolua_S,"getId",lua_cocos2dx_Touch_getID); tolua_function(tolua_S,"setTouchInfo",lua_cocos2dx_Touch_setTouchInfo); tolua_function(tolua_S,"getMaxForce",lua_cocos2dx_Touch_getMaxForce); tolua_function(tolua_S,"getLocationInView",lua_cocos2dx_Touch_getLocationInView); tolua_function(tolua_S,"getPreviousLocation",lua_cocos2dx_Touch_getPreviousLocation); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Touch).name(); g_luaType[typeName] = "cc.Touch"; g_typeCast["Touch"] = "cc.Touch"; return 1; } int lua_cocos2dx_Event_isStopped(lua_State* tolua_S) { int argc = 0; cocos2d::Event* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Event",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Event*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Event_isStopped'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Event_isStopped'", nullptr); return 0; } bool ret = cobj->isStopped(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Event:isStopped",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Event_isStopped'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Event_getType(lua_State* tolua_S) { int argc = 0; cocos2d::Event* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Event",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Event*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Event_getType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Event_getType'", nullptr); return 0; } int ret = (int)cobj->getType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Event:getType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Event_getType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Event_getCurrentTarget(lua_State* tolua_S) { int argc = 0; cocos2d::Event* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Event",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Event*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Event_getCurrentTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Event_getCurrentTarget'", nullptr); return 0; } cocos2d::Node* ret = cobj->getCurrentTarget(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Event:getCurrentTarget",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Event_getCurrentTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Event_stopPropagation(lua_State* tolua_S) { int argc = 0; cocos2d::Event* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Event",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Event*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Event_stopPropagation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Event_stopPropagation'", nullptr); return 0; } cobj->stopPropagation(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Event:stopPropagation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Event_stopPropagation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Event_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Event* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Event::Type arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Event:Event"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Event_constructor'", nullptr); return 0; } cobj = new cocos2d::Event(arg0); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Event"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Event:Event",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Event_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Event_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Event)"); return 0; } int lua_register_cocos2dx_Event(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Event"); tolua_cclass(tolua_S,"Event","cc.Event","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Event"); tolua_function(tolua_S,"new",lua_cocos2dx_Event_constructor); tolua_function(tolua_S,"isStopped",lua_cocos2dx_Event_isStopped); tolua_function(tolua_S,"getType",lua_cocos2dx_Event_getType); tolua_function(tolua_S,"getCurrentTarget",lua_cocos2dx_Event_getCurrentTarget); tolua_function(tolua_S,"stopPropagation",lua_cocos2dx_Event_stopPropagation); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Event).name(); g_luaType[typeName] = "cc.Event"; g_typeCast["Event"] = "cc.Event"; return 1; } int lua_cocos2dx_EventTouch_getEventCode(lua_State* tolua_S) { int argc = 0; cocos2d::EventTouch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventTouch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventTouch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventTouch_getEventCode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventTouch_getEventCode'", nullptr); return 0; } int ret = (int)cobj->getEventCode(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventTouch:getEventCode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventTouch_getEventCode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventTouch_setEventCode(lua_State* tolua_S) { int argc = 0; cocos2d::EventTouch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventTouch",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventTouch*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventTouch_setEventCode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventTouch::EventCode arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EventTouch:setEventCode"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventTouch_setEventCode'", nullptr); return 0; } cobj->setEventCode(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventTouch:setEventCode",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventTouch_setEventCode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventTouch_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventTouch* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventTouch_constructor'", nullptr); return 0; } cobj = new cocos2d::EventTouch(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventTouch"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventTouch:EventTouch",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventTouch_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventTouch_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventTouch)"); return 0; } int lua_register_cocos2dx_EventTouch(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventTouch"); tolua_cclass(tolua_S,"EventTouch","cc.EventTouch","cc.Event",nullptr); tolua_beginmodule(tolua_S,"EventTouch"); tolua_function(tolua_S,"new",lua_cocos2dx_EventTouch_constructor); tolua_function(tolua_S,"getEventCode",lua_cocos2dx_EventTouch_getEventCode); tolua_function(tolua_S,"setEventCode",lua_cocos2dx_EventTouch_setEventCode); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventTouch).name(); g_luaType[typeName] = "cc.EventTouch"; g_typeCast["EventTouch"] = "cc.EventTouch"; return 1; } int lua_cocos2dx_EventKeyboard_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventKeyboard* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::EventKeyboard::KeyCode arg0; bool arg1; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EventKeyboard:EventKeyboard"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.EventKeyboard:EventKeyboard"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventKeyboard_constructor'", nullptr); return 0; } cobj = new cocos2d::EventKeyboard(arg0, arg1); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventKeyboard"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventKeyboard:EventKeyboard",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventKeyboard_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventKeyboard_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventKeyboard)"); return 0; } int lua_register_cocos2dx_EventKeyboard(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventKeyboard"); tolua_cclass(tolua_S,"EventKeyboard","cc.EventKeyboard","cc.Event",nullptr); tolua_beginmodule(tolua_S,"EventKeyboard"); tolua_function(tolua_S,"new",lua_cocos2dx_EventKeyboard_constructor); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventKeyboard).name(); g_luaType[typeName] = "cc.EventKeyboard"; g_typeCast["EventKeyboard"] = "cc.EventKeyboard"; return 1; } int lua_cocos2dx_Component_setEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_setEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Component:setEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_setEnabled'", nullptr); return 0; } cobj->setEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:setEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_setEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_onRemove(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_onRemove'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_onRemove'", nullptr); return 0; } cobj->onRemove(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:onRemove",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_onRemove'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_setName(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_setName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Component:setName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_setName'", nullptr); return 0; } cobj->setName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:setName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_setName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_isEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_isEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_isEnabled'", nullptr); return 0; } bool ret = cobj->isEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:isEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_isEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_update(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_update'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Component:update"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_update'", nullptr); return 0; } cobj->update(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:update",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_update'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_getOwner(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_getOwner'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_getOwner'", nullptr); return 0; } cocos2d::Node* ret = cobj->getOwner(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:getOwner",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_getOwner'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_init(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_setOwner(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_setOwner'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Component:setOwner"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_setOwner'", nullptr); return 0; } cobj->setOwner(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:setOwner",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_setOwner'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_getName(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_getName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_getName'", nullptr); return 0; } const std::string& ret = cobj->getName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:getName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_getName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_onAdd(lua_State* tolua_S) { int argc = 0; cocos2d::Component* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Component*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Component_onAdd'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_onAdd'", nullptr); return 0; } cobj->onAdd(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Component:onAdd",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_onAdd'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Component_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Component",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Component_create'", nullptr); return 0; } cocos2d::Component* ret = cocos2d::Component::create(); object_to_luaval<cocos2d::Component>(tolua_S, "cc.Component",(cocos2d::Component*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Component:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Component_create'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Component_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Component)"); return 0; } int lua_register_cocos2dx_Component(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Component"); tolua_cclass(tolua_S,"Component","cc.Component","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Component"); tolua_function(tolua_S,"setEnabled",lua_cocos2dx_Component_setEnabled); tolua_function(tolua_S,"onRemove",lua_cocos2dx_Component_onRemove); tolua_function(tolua_S,"setName",lua_cocos2dx_Component_setName); tolua_function(tolua_S,"isEnabled",lua_cocos2dx_Component_isEnabled); tolua_function(tolua_S,"update",lua_cocos2dx_Component_update); tolua_function(tolua_S,"getOwner",lua_cocos2dx_Component_getOwner); tolua_function(tolua_S,"init",lua_cocos2dx_Component_init); tolua_function(tolua_S,"setOwner",lua_cocos2dx_Component_setOwner); tolua_function(tolua_S,"getName",lua_cocos2dx_Component_getName); tolua_function(tolua_S,"onAdd",lua_cocos2dx_Component_onAdd); tolua_function(tolua_S,"create", lua_cocos2dx_Component_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Component).name(); g_luaType[typeName] = "cc.Component"; g_typeCast["Component"] = "cc.Component"; return 1; } int lua_cocos2dx_Node_addChild(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_addChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:addChild"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Node:addChild"); if (!ok) { break; } cobj->addChild(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:addChild"); if (!ok) { break; } cobj->addChild(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:addChild"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Node:addChild"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Node:addChild"); if (!ok) { break; } cobj->addChild(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:addChild"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Node:addChild"); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.Node:addChild"); if (!ok) { break; } cobj->addChild(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:addChild",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_addChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_removeComponent(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_removeComponent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { cocos2d::Component* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Component>(tolua_S, 2, "cc.Component",&arg0, "cc.Node:removeComponent"); if (!ok) { break; } bool ret = cobj->removeComponent(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Node:removeComponent"); if (!ok) { break; } bool ret = cobj->removeComponent(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:removeComponent",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_removeComponent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setPhysicsBody(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setPhysicsBody'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::PhysicsBody* arg0 = nullptr; ok &= luaval_to_object<cocos2d::PhysicsBody>(tolua_S, 2, "cc.PhysicsBody",&arg0, "cc.Node:setPhysicsBody"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setPhysicsBody'", nullptr); return 0; } cobj->setPhysicsBody(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setPhysicsBody",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setPhysicsBody'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getDescription(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getDescription'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getDescription'", nullptr); return 0; } std::string ret = cobj->getDescription(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getDescription",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getDescription'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setRotationSkewY(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setRotationSkewY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setRotationSkewY"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setRotationSkewY'", nullptr); return 0; } cobj->setRotationSkewY(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setRotationSkewY",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setRotationSkewY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setOpacityModifyRGB(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setOpacityModifyRGB'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Node:setOpacityModifyRGB"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setOpacityModifyRGB'", nullptr); return 0; } cobj->setOpacityModifyRGB(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setOpacityModifyRGB",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setOpacityModifyRGB'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setCascadeOpacityEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setCascadeOpacityEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Node:setCascadeOpacityEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setCascadeOpacityEnabled'", nullptr); return 0; } cobj->setCascadeOpacityEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setCascadeOpacityEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setCascadeOpacityEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getChildren(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getChildren'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { const cocos2d::Vector<cocos2d::Node *>& ret = cobj->getChildren(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { cocos2d::Vector<cocos2d::Node *>& ret = cobj->getChildren(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getChildren",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getChildren'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setOnExitCallback(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setOnExitCallback'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::function<void ()> arg0; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setOnExitCallback'", nullptr); return 0; } cobj->setOnExitCallback(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setOnExitCallback",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setOnExitCallback'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setActionManager(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setActionManager'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionManager* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionManager>(tolua_S, 2, "cc.ActionManager",&arg0, "cc.Node:setActionManager"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setActionManager'", nullptr); return 0; } cobj->setActionManager(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setActionManager",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setActionManager'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_convertToWorldSpaceAR(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_convertToWorldSpaceAR'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Node:convertToWorldSpaceAR"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_convertToWorldSpaceAR'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->convertToWorldSpaceAR(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:convertToWorldSpaceAR",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_convertToWorldSpaceAR'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_isIgnoreAnchorPointForPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_isIgnoreAnchorPointForPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_isIgnoreAnchorPointForPosition'", nullptr); return 0; } bool ret = cobj->isIgnoreAnchorPointForPosition(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:isIgnoreAnchorPointForPosition",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_isIgnoreAnchorPointForPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getChildByName(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getChildByName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Node:getChildByName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getChildByName'", nullptr); return 0; } cocos2d::Node* ret = cobj->getChildByName(arg0); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getChildByName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getChildByName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_updateDisplayedOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_updateDisplayedOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { uint16_t arg0; ok &= luaval_to_uint16(tolua_S, 2,&arg0, "cc.Node:updateDisplayedOpacity"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_updateDisplayedOpacity'", nullptr); return 0; } cobj->updateDisplayedOpacity(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:updateDisplayedOpacity",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_updateDisplayedOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_init(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getCameraMask(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getCameraMask'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getCameraMask'", nullptr); return 0; } unsigned short ret = cobj->getCameraMask(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getCameraMask",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getCameraMask'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setRotation(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setRotation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setRotation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setRotation'", nullptr); return 0; } cobj->setRotation(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setRotation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setRotation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setScaleZ(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setScaleZ'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setScaleZ"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setScaleZ'", nullptr); return 0; } cobj->setScaleZ(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setScaleZ",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setScaleZ'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setScaleY(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setScaleY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setScaleY"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setScaleY'", nullptr); return 0; } cobj->setScaleY(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setScaleY",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setScaleY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setScaleX(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setScaleX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setScaleX"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setScaleX'", nullptr); return 0; } cobj->setScaleX(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setScaleX",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setScaleX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setRotationSkewX(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setRotationSkewX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setRotationSkewX"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setRotationSkewX'", nullptr); return 0; } cobj->setRotationSkewX(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setRotationSkewX",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setRotationSkewX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setonEnterTransitionDidFinishCallback(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setonEnterTransitionDidFinishCallback'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::function<void ()> arg0; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setonEnterTransitionDidFinishCallback'", nullptr); return 0; } cobj->setonEnterTransitionDidFinishCallback(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setonEnterTransitionDidFinishCallback",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setonEnterTransitionDidFinishCallback'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_removeAllComponents(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_removeAllComponents'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_removeAllComponents'", nullptr); return 0; } cobj->removeAllComponents(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:removeAllComponents",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_removeAllComponents'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node__setLocalZOrder(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node__setLocalZOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:_setLocalZOrder"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node__setLocalZOrder'", nullptr); return 0; } cobj->_setLocalZOrder(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:_setLocalZOrder",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node__setLocalZOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setCameraMask(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setCameraMask'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned short arg0; ok &= luaval_to_ushort(tolua_S, 2, &arg0, "cc.Node:setCameraMask"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setCameraMask'", nullptr); return 0; } cobj->setCameraMask(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { unsigned short arg0; bool arg1; ok &= luaval_to_ushort(tolua_S, 2, &arg0, "cc.Node:setCameraMask"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Node:setCameraMask"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setCameraMask'", nullptr); return 0; } cobj->setCameraMask(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setCameraMask",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setCameraMask'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getTag(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getTag'", nullptr); return 0; } int ret = cobj->getTag(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getTag",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getGLProgram'", nullptr); return 0; } cocos2d::GLProgram* ret = cobj->getGLProgram(); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getGLProgram",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getNodeToWorldTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getNodeToWorldTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getNodeToWorldTransform'", nullptr); return 0; } cocos2d::Mat4 ret = cobj->getNodeToWorldTransform(); mat4_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getNodeToWorldTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getNodeToWorldTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getPosition3D(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getPosition3D'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getPosition3D'", nullptr); return 0; } cocos2d::Vec3 ret = cobj->getPosition3D(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getPosition3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getPosition3D'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_removeChild(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_removeChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:removeChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_removeChild'", nullptr); return 0; } cobj->removeChild(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { cocos2d::Node* arg0 = nullptr; bool arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:removeChild"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Node:removeChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_removeChild'", nullptr); return 0; } cobj->removeChild(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:removeChild",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_removeChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_convertToWorldSpace(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_convertToWorldSpace'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Node:convertToWorldSpace"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_convertToWorldSpace'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->convertToWorldSpace(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:convertToWorldSpace",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_convertToWorldSpace'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getScene(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getScene'", nullptr); return 0; } cocos2d::Scene* ret = cobj->getScene(); object_to_luaval<cocos2d::Scene>(tolua_S, "cc.Scene",(cocos2d::Scene*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getScene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getEventDispatcher(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getEventDispatcher'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getEventDispatcher'", nullptr); return 0; } cocos2d::EventDispatcher* ret = cobj->getEventDispatcher(); object_to_luaval<cocos2d::EventDispatcher>(tolua_S, "cc.EventDispatcher",(cocos2d::EventDispatcher*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getEventDispatcher",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getEventDispatcher'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setSkewX(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setSkewX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setSkewX"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setSkewX'", nullptr); return 0; } cobj->setSkewX(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setSkewX",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setSkewX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setGLProgramState(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setGLProgramState'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::GLProgramState* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GLProgramState>(tolua_S, 2, "cc.GLProgramState",&arg0, "cc.Node:setGLProgramState"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setGLProgramState'", nullptr); return 0; } cobj->setGLProgramState(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setGLProgramState",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setGLProgramState'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setOnEnterCallback(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setOnEnterCallback'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::function<void ()> arg0; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setOnEnterCallback'", nullptr); return 0; } cobj->setOnEnterCallback(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setOnEnterCallback",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setOnEnterCallback'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_stopActionsByFlags(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_stopActionsByFlags'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned int arg0; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.Node:stopActionsByFlags"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_stopActionsByFlags'", nullptr); return 0; } cobj->stopActionsByFlags(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:stopActionsByFlags",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_stopActionsByFlags'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setNormalizedPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setNormalizedPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Node:setNormalizedPosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setNormalizedPosition'", nullptr); return 0; } cobj->setNormalizedPosition(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setNormalizedPosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setNormalizedPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setonExitTransitionDidStartCallback(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setonExitTransitionDidStartCallback'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::function<void ()> arg0; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setonExitTransitionDidStartCallback'", nullptr); return 0; } cobj->setonExitTransitionDidStartCallback(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setonExitTransitionDidStartCallback",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setonExitTransitionDidStartCallback'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_convertTouchToNodeSpace(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_convertTouchToNodeSpace'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Touch* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Touch>(tolua_S, 2, "cc.Touch",&arg0, "cc.Node:convertTouchToNodeSpace"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_convertTouchToNodeSpace'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->convertTouchToNodeSpace(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:convertTouchToNodeSpace",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_convertTouchToNodeSpace'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_removeAllChildrenWithCleanup(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_removeAllChildrenWithCleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Node:removeAllChildrenWithCleanup"); if (!ok) { break; } cobj->removeAllChildrenWithCleanup(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 0) { cobj->removeAllChildren(); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:removeAllChildren",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_removeAllChildrenWithCleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getNodeToParentAffineTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getNodeToParentAffineTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:getNodeToParentAffineTransform"); if (!ok) { break; } cocos2d::AffineTransform ret = cobj->getNodeToParentAffineTransform(arg0); affinetransform_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { cocos2d::AffineTransform ret = cobj->getNodeToParentAffineTransform(); affinetransform_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getNodeToParentAffineTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getNodeToParentAffineTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_isCascadeOpacityEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_isCascadeOpacityEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_isCascadeOpacityEnabled'", nullptr); return 0; } bool ret = cobj->isCascadeOpacityEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:isCascadeOpacityEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_isCascadeOpacityEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setParent(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setParent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:setParent"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setParent'", nullptr); return 0; } cobj->setParent(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setParent",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setParent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getName(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getName'", nullptr); return 0; } const std::string& ret = cobj->getName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_resume(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_resume'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_resume'", nullptr); return 0; } cobj->resume(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:resume",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_resume'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getRotation3D(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getRotation3D'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getRotation3D'", nullptr); return 0; } cocos2d::Vec3 ret = cobj->getRotation3D(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getRotation3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getRotation3D'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getNodeToParentTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getNodeToParentTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:getNodeToParentTransform"); if (!ok) { break; } cocos2d::Mat4 ret = cobj->getNodeToParentTransform(arg0); mat4_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::Mat4& ret = cobj->getNodeToParentTransform(); mat4_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getNodeToParentTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getNodeToParentTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_convertTouchToNodeSpaceAR(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_convertTouchToNodeSpaceAR'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Touch* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Touch>(tolua_S, 2, "cc.Touch",&arg0, "cc.Node:convertTouchToNodeSpaceAR"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_convertTouchToNodeSpaceAR'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->convertTouchToNodeSpaceAR(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:convertTouchToNodeSpaceAR",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_convertTouchToNodeSpaceAR'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_convertToNodeSpace(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_convertToNodeSpace'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Node:convertToNodeSpace"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_convertToNodeSpace'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->convertToNodeSpace(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:convertToNodeSpace",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_convertToNodeSpace'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setPositionNormalized(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setPositionNormalized'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Node:setPositionNormalized"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setPositionNormalized'", nullptr); return 0; } cobj->setPositionNormalized(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setPositionNormalized",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setPositionNormalized'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_pause(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_pause'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_pause'", nullptr); return 0; } cobj->pause(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:pause",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_pause'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_isOpacityModifyRGB(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_isOpacityModifyRGB'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_isOpacityModifyRGB'", nullptr); return 0; } bool ret = cobj->isOpacityModifyRGB(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:isOpacityModifyRGB",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_isOpacityModifyRGB'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setPosition"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Node:setPosition"); if (!ok) { break; } cobj->setPosition(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Node:setPosition"); if (!ok) { break; } cobj->setPosition(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setPosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_stopActionByTag(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_stopActionByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:stopActionByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_stopActionByTag'", nullptr); return 0; } cobj->stopActionByTag(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:stopActionByTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_stopActionByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_reorderChild(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_reorderChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Node* arg0 = nullptr; int arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Node:reorderChild"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Node:reorderChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_reorderChild'", nullptr); return 0; } cobj->reorderChild(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:reorderChild",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_reorderChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setSkewY(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setSkewY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setSkewY"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setSkewY'", nullptr); return 0; } cobj->setSkewY(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setSkewY",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setSkewY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setPositionZ(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setPositionZ'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setPositionZ"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setPositionZ'", nullptr); return 0; } cobj->setPositionZ(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setPositionZ",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setPositionZ'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setRotation3D(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setRotation3D'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.Node:setRotation3D"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setRotation3D'", nullptr); return 0; } cobj->setRotation3D(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setRotation3D",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setRotation3D'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setPositionX(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setPositionX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setPositionX"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setPositionX'", nullptr); return 0; } cobj->setPositionX(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setPositionX",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setPositionX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setNodeToParentTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setNodeToParentTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Mat4 arg0; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.Node:setNodeToParentTransform"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setNodeToParentTransform'", nullptr); return 0; } cobj->setNodeToParentTransform(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setNodeToParentTransform",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setNodeToParentTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getAnchorPoint(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getAnchorPoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getAnchorPoint'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getAnchorPoint(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getAnchorPoint",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getAnchorPoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getNumberOfRunningActions(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getNumberOfRunningActions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getNumberOfRunningActions'", nullptr); return 0; } ssize_t ret = cobj->getNumberOfRunningActions(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getNumberOfRunningActions",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getNumberOfRunningActions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_updateTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_updateTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_updateTransform'", nullptr); return 0; } cobj->updateTransform(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:updateTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_updateTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::GLProgram* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GLProgram>(tolua_S, 2, "cc.GLProgram",&arg0, "cc.Node:setGLProgram"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setGLProgram'", nullptr); return 0; } cobj->setGLProgram(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setGLProgram",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_isVisible(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_isVisible'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_isVisible'", nullptr); return 0; } bool ret = cobj->isVisible(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:isVisible",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_isVisible'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getChildrenCount(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getChildrenCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getChildrenCount'", nullptr); return 0; } ssize_t ret = cobj->getChildrenCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getChildrenCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getChildrenCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_convertToNodeSpaceAR(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_convertToNodeSpaceAR'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Node:convertToNodeSpaceAR"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_convertToNodeSpaceAR'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->convertToNodeSpaceAR(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:convertToNodeSpaceAR",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_convertToNodeSpaceAR'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_addComponent(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_addComponent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Component* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Component>(tolua_S, 2, "cc.Component",&arg0, "cc.Node:addComponent"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_addComponent'", nullptr); return 0; } bool ret = cobj->addComponent(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:addComponent",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_addComponent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_runAction(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_runAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Action* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Action>(tolua_S, 2, "cc.Action",&arg0, "cc.Node:runAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_runAction'", nullptr); return 0; } cocos2d::Action* ret = cobj->runAction(arg0); object_to_luaval<cocos2d::Action>(tolua_S, "cc.Action",(cocos2d::Action*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:runAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_runAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_visit(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_visit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cobj->visit(); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Renderer* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Renderer>(tolua_S, 2, "cc.Renderer",&arg0, "cc.Node:visit"); if (!ok) { break; } cocos2d::Mat4 arg1; ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.Node:visit"); if (!ok) { break; } unsigned int arg2; ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Node:visit"); if (!ok) { break; } cobj->visit(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:visit",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_visit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getRotation(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getRotation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getRotation'", nullptr); return 0; } double ret = cobj->getRotation(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getRotation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getRotation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getPhysicsBody(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getPhysicsBody'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getPhysicsBody'", nullptr); return 0; } cocos2d::PhysicsBody* ret = cobj->getPhysicsBody(); object_to_luaval<cocos2d::PhysicsBody>(tolua_S, "cc.PhysicsBody",(cocos2d::PhysicsBody*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getPhysicsBody",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getPhysicsBody'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getAnchorPointInPoints(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getAnchorPointInPoints'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getAnchorPointInPoints'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getAnchorPointInPoints(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getAnchorPointInPoints",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getAnchorPointInPoints'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_removeChildByName(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_removeChildByName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Node:removeChildByName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_removeChildByName'", nullptr); return 0; } cobj->removeChildByName(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { std::string arg0; bool arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Node:removeChildByName"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Node:removeChildByName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_removeChildByName'", nullptr); return 0; } cobj->removeChildByName(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:removeChildByName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_removeChildByName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getGLProgramState(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getGLProgramState'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getGLProgramState'", nullptr); return 0; } cocos2d::GLProgramState* ret = cobj->getGLProgramState(); object_to_luaval<cocos2d::GLProgramState>(tolua_S, "cc.GLProgramState",(cocos2d::GLProgramState*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getGLProgramState",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getGLProgramState'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setScheduler(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setScheduler'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Scheduler* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Scheduler>(tolua_S, 2, "cc.Scheduler",&arg0, "cc.Node:setScheduler"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setScheduler'", nullptr); return 0; } cobj->setScheduler(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setScheduler",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setScheduler'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_stopAllActions(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_stopAllActions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_stopAllActions'", nullptr); return 0; } cobj->stopAllActions(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:stopAllActions",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_stopAllActions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getSkewX(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getSkewX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getSkewX'", nullptr); return 0; } double ret = cobj->getSkewX(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getSkewX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getSkewX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getSkewY(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getSkewY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getSkewY'", nullptr); return 0; } double ret = cobj->getSkewY(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getSkewY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getSkewY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getDisplayedColor(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getDisplayedColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getDisplayedColor'", nullptr); return 0; } const cocos2d::Color3B& ret = cobj->getDisplayedColor(); color3b_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getDisplayedColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getDisplayedColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getActionByTag(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getActionByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:getActionByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getActionByTag'", nullptr); return 0; } cocos2d::Action* ret = cobj->getActionByTag(arg0); object_to_luaval<cocos2d::Action>(tolua_S, "cc.Action",(cocos2d::Action*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getActionByTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getActionByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setName(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Node:setName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setName'", nullptr); return 0; } cobj->setName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_update(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_update'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:update"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_update'", nullptr); return 0; } cobj->update(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:update",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_update'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getDisplayedOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getDisplayedOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getDisplayedOpacity'", nullptr); return 0; } uint16_t ret = cobj->getDisplayedOpacity(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getDisplayedOpacity",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getDisplayedOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getLocalZOrder(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getLocalZOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getLocalZOrder'", nullptr); return 0; } int ret = cobj->getLocalZOrder(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getLocalZOrder",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getLocalZOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getScheduler(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getScheduler'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { const cocos2d::Scheduler* ret = cobj->getScheduler(); object_to_luaval<cocos2d::Scheduler>(tolua_S, "cc.Scheduler",(cocos2d::Scheduler*)ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { cocos2d::Scheduler* ret = cobj->getScheduler(); object_to_luaval<cocos2d::Scheduler>(tolua_S, "cc.Scheduler",(cocos2d::Scheduler*)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getScheduler",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getScheduler'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getParentToNodeAffineTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getParentToNodeAffineTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getParentToNodeAffineTransform'", nullptr); return 0; } cocos2d::AffineTransform ret = cobj->getParentToNodeAffineTransform(); affinetransform_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getParentToNodeAffineTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getParentToNodeAffineTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getPositionNormalized(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getPositionNormalized'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getPositionNormalized'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getPositionNormalized(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getPositionNormalized",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getPositionNormalized'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setColor(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color3B arg0; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.Node:setColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setColor'", nullptr); return 0; } cobj->setColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_isRunning(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_isRunning'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_isRunning'", nullptr); return 0; } bool ret = cobj->isRunning(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:isRunning",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_isRunning'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getParent(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getParent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { const cocos2d::Node* ret = cobj->getParent(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { cocos2d::Node* ret = cobj->getParent(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getParent",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getParent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getPositionZ(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getPositionZ'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getPositionZ'", nullptr); return 0; } double ret = cobj->getPositionZ(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getPositionZ",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getPositionZ'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getPositionY(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getPositionY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getPositionY'", nullptr); return 0; } double ret = cobj->getPositionY(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getPositionY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getPositionY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getPositionX(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getPositionX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getPositionX'", nullptr); return 0; } double ret = cobj->getPositionX(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getPositionX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getPositionX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_removeChildByTag(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_removeChildByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:removeChildByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_removeChildByTag'", nullptr); return 0; } cobj->removeChildByTag(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { int arg0; bool arg1; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:removeChildByTag"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Node:removeChildByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_removeChildByTag'", nullptr); return 0; } cobj->removeChildByTag(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:removeChildByTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_removeChildByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setPositionY(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setPositionY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setPositionY"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setPositionY'", nullptr); return 0; } cobj->setPositionY(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setPositionY",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setPositionY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getNodeToWorldAffineTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getNodeToWorldAffineTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getNodeToWorldAffineTransform'", nullptr); return 0; } cocos2d::AffineTransform ret = cobj->getNodeToWorldAffineTransform(); affinetransform_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getNodeToWorldAffineTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getNodeToWorldAffineTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_updateDisplayedColor(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_updateDisplayedColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color3B arg0; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.Node:updateDisplayedColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_updateDisplayedColor'", nullptr); return 0; } cobj->updateDisplayedColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:updateDisplayedColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_updateDisplayedColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setVisible(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setVisible'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Node:setVisible"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setVisible'", nullptr); return 0; } cobj->setVisible(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setVisible",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setVisible'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getParentToNodeTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getParentToNodeTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getParentToNodeTransform'", nullptr); return 0; } const cocos2d::Mat4& ret = cobj->getParentToNodeTransform(); mat4_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getParentToNodeTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getParentToNodeTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_isScheduled(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_isScheduled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Node:isScheduled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_isScheduled'", nullptr); return 0; } bool ret = cobj->isScheduled(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:isScheduled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_isScheduled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setGlobalZOrder(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setGlobalZOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setGlobalZOrder"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setGlobalZOrder'", nullptr); return 0; } cobj->setGlobalZOrder(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setGlobalZOrder",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setGlobalZOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setScale(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setScale'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setScale"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Node:setScale"); if (!ok) { break; } cobj->setScale(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Node:setScale"); if (!ok) { break; } cobj->setScale(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setScale",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setScale'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getChildByTag(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getChildByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:getChildByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getChildByTag'", nullptr); return 0; } cocos2d::Node* ret = cobj->getChildByTag(arg0); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getChildByTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getChildByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getScaleZ(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getScaleZ'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getScaleZ'", nullptr); return 0; } double ret = cobj->getScaleZ(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getScaleZ",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getScaleZ'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getScaleY(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getScaleY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getScaleY'", nullptr); return 0; } double ret = cobj->getScaleY(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getScaleY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getScaleY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getScaleX(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getScaleX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getScaleX'", nullptr); return 0; } double ret = cobj->getScaleX(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getScaleX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getScaleX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setLocalZOrder(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setLocalZOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:setLocalZOrder"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setLocalZOrder'", nullptr); return 0; } cobj->setLocalZOrder(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setLocalZOrder",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setLocalZOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getWorldToNodeAffineTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getWorldToNodeAffineTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getWorldToNodeAffineTransform'", nullptr); return 0; } cocos2d::AffineTransform ret = cobj->getWorldToNodeAffineTransform(); affinetransform_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getWorldToNodeAffineTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getWorldToNodeAffineTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setCascadeColorEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setCascadeColorEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Node:setCascadeColorEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setCascadeColorEnabled'", nullptr); return 0; } cobj->setCascadeColorEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setCascadeColorEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setCascadeColorEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { uint16_t arg0; ok &= luaval_to_uint16(tolua_S, 2,&arg0, "cc.Node:setOpacity"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setOpacity'", nullptr); return 0; } cobj->setOpacity(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setOpacity",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_cleanup(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_cleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_cleanup'", nullptr); return 0; } cobj->cleanup(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:cleanup",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_cleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getComponent(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getComponent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Node:getComponent"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getComponent'", nullptr); return 0; } cocos2d::Component* ret = cobj->getComponent(arg0); object_to_luaval<cocos2d::Component>(tolua_S, "cc.Component",(cocos2d::Component*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getComponent",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getComponent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getContentSize(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getContentSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getContentSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getContentSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getContentSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getContentSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_stopAllActionsByTag(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_stopAllActionsByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:stopAllActionsByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_stopAllActionsByTag'", nullptr); return 0; } cobj->stopAllActionsByTag(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:stopAllActionsByTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_stopAllActionsByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getColor(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getColor'", nullptr); return 0; } const cocos2d::Color3B& ret = cobj->getColor(); color3b_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getBoundingBox(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getBoundingBox'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getBoundingBox'", nullptr); return 0; } cocos2d::Rect ret = cobj->getBoundingBox(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getBoundingBox",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getBoundingBox'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setIgnoreAnchorPointForPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setIgnoreAnchorPointForPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Node:setIgnoreAnchorPointForPosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setIgnoreAnchorPointForPosition'", nullptr); return 0; } cobj->setIgnoreAnchorPointForPosition(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setIgnoreAnchorPointForPosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setIgnoreAnchorPointForPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setEventDispatcher(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setEventDispatcher'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventDispatcher* arg0 = nullptr; ok &= luaval_to_object<cocos2d::EventDispatcher>(tolua_S, 2, "cc.EventDispatcher",&arg0, "cc.Node:setEventDispatcher"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setEventDispatcher'", nullptr); return 0; } cobj->setEventDispatcher(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setEventDispatcher",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setEventDispatcher'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getGlobalZOrder(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getGlobalZOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getGlobalZOrder'", nullptr); return 0; } double ret = cobj->getGlobalZOrder(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getGlobalZOrder",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getGlobalZOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_draw(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_draw'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cobj->draw(); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Renderer* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Renderer>(tolua_S, 2, "cc.Renderer",&arg0, "cc.Node:draw"); if (!ok) { break; } cocos2d::Mat4 arg1; ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.Node:draw"); if (!ok) { break; } unsigned int arg2; ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Node:draw"); if (!ok) { break; } cobj->draw(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:draw",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_draw'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setUserObject(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setUserObject'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Ref* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Ref>(tolua_S, 2, "cc.Ref",&arg0, "cc.Node:setUserObject"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setUserObject'", nullptr); return 0; } cobj->setUserObject(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setUserObject",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setUserObject'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_removeFromParentAndCleanup(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_removeFromParentAndCleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Node:removeFromParentAndCleanup"); if (!ok) { break; } cobj->removeFromParentAndCleanup(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 0) { cobj->removeFromParent(); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:removeFromParent",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_removeFromParentAndCleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setPosition3D(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setPosition3D'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.Node:setPosition3D"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setPosition3D'", nullptr); return 0; } cobj->setPosition3D(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setPosition3D",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setPosition3D'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getNumberOfRunningActionsByTag(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getNumberOfRunningActionsByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:getNumberOfRunningActionsByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getNumberOfRunningActionsByTag'", nullptr); return 0; } ssize_t ret = cobj->getNumberOfRunningActionsByTag(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getNumberOfRunningActionsByTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getNumberOfRunningActionsByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_sortAllChildren(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_sortAllChildren'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_sortAllChildren'", nullptr); return 0; } cobj->sortAllChildren(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:sortAllChildren",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_sortAllChildren'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getWorldToNodeTransform(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getWorldToNodeTransform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getWorldToNodeTransform'", nullptr); return 0; } cocos2d::Mat4 ret = cobj->getWorldToNodeTransform(); mat4_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getWorldToNodeTransform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getWorldToNodeTransform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getScale(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getScale'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getScale'", nullptr); return 0; } double ret = cobj->getScale(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getScale",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getScale'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getOpacity'", nullptr); return 0; } uint16_t ret = cobj->getOpacity(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getOpacity",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_updateOrderOfArrival(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_updateOrderOfArrival'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_updateOrderOfArrival'", nullptr); return 0; } cobj->updateOrderOfArrival(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:updateOrderOfArrival",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_updateOrderOfArrival'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getNormalizedPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getNormalizedPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getNormalizedPosition'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getNormalizedPosition(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getNormalizedPosition",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getNormalizedPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getRotationSkewX(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getRotationSkewX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getRotationSkewX'", nullptr); return 0; } double ret = cobj->getRotationSkewX(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getRotationSkewX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getRotationSkewX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getRotationSkewY(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getRotationSkewY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_getRotationSkewY'", nullptr); return 0; } double ret = cobj->getRotationSkewY(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getRotationSkewY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getRotationSkewY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_setTag(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_setTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Node:setTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_setTag'", nullptr); return 0; } cobj->setTag(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:setTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_setTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_isCascadeColorEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_isCascadeColorEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_isCascadeColorEnabled'", nullptr); return 0; } bool ret = cobj->isCascadeColorEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:isCascadeColorEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_isCascadeColorEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_stopAction(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_stopAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Action* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Action>(tolua_S, 2, "cc.Action",&arg0, "cc.Node:stopAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_stopAction'", nullptr); return 0; } cobj->stopAction(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:stopAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_stopAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_getActionManager(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getActionManager'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { const cocos2d::ActionManager* ret = cobj->getActionManager(); object_to_luaval<cocos2d::ActionManager>(tolua_S, "cc.ActionManager",(cocos2d::ActionManager*)ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { cocos2d::ActionManager* ret = cobj->getActionManager(); object_to_luaval<cocos2d::ActionManager>(tolua_S, "cc.ActionManager",(cocos2d::ActionManager*)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:getActionManager",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getActionManager'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_create'", nullptr); return 0; } cocos2d::Node* ret = cocos2d::Node::create(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Node:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Node_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Node* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Node_constructor'", nullptr); return 0; } cobj = new cocos2d::Node(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Node"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Node:Node",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Node_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Node)"); return 0; } int lua_register_cocos2dx_Node(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Node"); tolua_cclass(tolua_S,"Node","cc.Node","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Node"); tolua_function(tolua_S,"new",lua_cocos2dx_Node_constructor); tolua_function(tolua_S,"addChild",lua_cocos2dx_Node_addChild); tolua_function(tolua_S,"removeComponent",lua_cocos2dx_Node_removeComponent); tolua_function(tolua_S,"setPhysicsBody",lua_cocos2dx_Node_setPhysicsBody); tolua_function(tolua_S,"getDescription",lua_cocos2dx_Node_getDescription); tolua_function(tolua_S,"setRotationSkewY",lua_cocos2dx_Node_setRotationSkewY); tolua_function(tolua_S,"setOpacityModifyRGB",lua_cocos2dx_Node_setOpacityModifyRGB); tolua_function(tolua_S,"setCascadeOpacityEnabled",lua_cocos2dx_Node_setCascadeOpacityEnabled); tolua_function(tolua_S,"getChildren",lua_cocos2dx_Node_getChildren); tolua_function(tolua_S,"setOnExitCallback",lua_cocos2dx_Node_setOnExitCallback); tolua_function(tolua_S,"setActionManager",lua_cocos2dx_Node_setActionManager); tolua_function(tolua_S,"convertToWorldSpaceAR",lua_cocos2dx_Node_convertToWorldSpaceAR); tolua_function(tolua_S,"isIgnoreAnchorPointForPosition",lua_cocos2dx_Node_isIgnoreAnchorPointForPosition); tolua_function(tolua_S,"getChildByName",lua_cocos2dx_Node_getChildByName); tolua_function(tolua_S,"updateDisplayedOpacity",lua_cocos2dx_Node_updateDisplayedOpacity); tolua_function(tolua_S,"init",lua_cocos2dx_Node_init); tolua_function(tolua_S,"getCameraMask",lua_cocos2dx_Node_getCameraMask); tolua_function(tolua_S,"setRotation",lua_cocos2dx_Node_setRotation); tolua_function(tolua_S,"setScaleZ",lua_cocos2dx_Node_setScaleZ); tolua_function(tolua_S,"setScaleY",lua_cocos2dx_Node_setScaleY); tolua_function(tolua_S,"setScaleX",lua_cocos2dx_Node_setScaleX); tolua_function(tolua_S,"setRotationSkewX",lua_cocos2dx_Node_setRotationSkewX); tolua_function(tolua_S,"setonEnterTransitionDidFinishCallback",lua_cocos2dx_Node_setonEnterTransitionDidFinishCallback); tolua_function(tolua_S,"removeAllComponents",lua_cocos2dx_Node_removeAllComponents); tolua_function(tolua_S,"_setLocalZOrder",lua_cocos2dx_Node__setLocalZOrder); tolua_function(tolua_S,"setCameraMask",lua_cocos2dx_Node_setCameraMask); tolua_function(tolua_S,"getTag",lua_cocos2dx_Node_getTag); tolua_function(tolua_S,"getGLProgram",lua_cocos2dx_Node_getGLProgram); tolua_function(tolua_S,"getNodeToWorldTransform",lua_cocos2dx_Node_getNodeToWorldTransform); tolua_function(tolua_S,"getPosition3D",lua_cocos2dx_Node_getPosition3D); tolua_function(tolua_S,"removeChild",lua_cocos2dx_Node_removeChild); tolua_function(tolua_S,"convertToWorldSpace",lua_cocos2dx_Node_convertToWorldSpace); tolua_function(tolua_S,"getScene",lua_cocos2dx_Node_getScene); tolua_function(tolua_S,"getEventDispatcher",lua_cocos2dx_Node_getEventDispatcher); tolua_function(tolua_S,"setSkewX",lua_cocos2dx_Node_setSkewX); tolua_function(tolua_S,"setGLProgramState",lua_cocos2dx_Node_setGLProgramState); tolua_function(tolua_S,"setOnEnterCallback",lua_cocos2dx_Node_setOnEnterCallback); tolua_function(tolua_S,"stopActionsByFlags",lua_cocos2dx_Node_stopActionsByFlags); tolua_function(tolua_S,"setNormalizedPosition",lua_cocos2dx_Node_setNormalizedPosition); tolua_function(tolua_S,"setonExitTransitionDidStartCallback",lua_cocos2dx_Node_setonExitTransitionDidStartCallback); tolua_function(tolua_S,"convertTouchToNodeSpace",lua_cocos2dx_Node_convertTouchToNodeSpace); tolua_function(tolua_S,"removeAllChildren",lua_cocos2dx_Node_removeAllChildrenWithCleanup); tolua_function(tolua_S,"getNodeToParentAffineTransform",lua_cocos2dx_Node_getNodeToParentAffineTransform); tolua_function(tolua_S,"isCascadeOpacityEnabled",lua_cocos2dx_Node_isCascadeOpacityEnabled); tolua_function(tolua_S,"setParent",lua_cocos2dx_Node_setParent); tolua_function(tolua_S,"getName",lua_cocos2dx_Node_getName); tolua_function(tolua_S,"resume",lua_cocos2dx_Node_resume); tolua_function(tolua_S,"getRotation3D",lua_cocos2dx_Node_getRotation3D); tolua_function(tolua_S,"getNodeToParentTransform",lua_cocos2dx_Node_getNodeToParentTransform); tolua_function(tolua_S,"convertTouchToNodeSpaceAR",lua_cocos2dx_Node_convertTouchToNodeSpaceAR); tolua_function(tolua_S,"convertToNodeSpace",lua_cocos2dx_Node_convertToNodeSpace); tolua_function(tolua_S,"setPositionNormalized",lua_cocos2dx_Node_setPositionNormalized); tolua_function(tolua_S,"pause",lua_cocos2dx_Node_pause); tolua_function(tolua_S,"isOpacityModifyRGB",lua_cocos2dx_Node_isOpacityModifyRGB); tolua_function(tolua_S,"setPosition",lua_cocos2dx_Node_setPosition); tolua_function(tolua_S,"stopActionByTag",lua_cocos2dx_Node_stopActionByTag); tolua_function(tolua_S,"reorderChild",lua_cocos2dx_Node_reorderChild); tolua_function(tolua_S,"setSkewY",lua_cocos2dx_Node_setSkewY); tolua_function(tolua_S,"setPositionZ",lua_cocos2dx_Node_setPositionZ); tolua_function(tolua_S,"setRotation3D",lua_cocos2dx_Node_setRotation3D); tolua_function(tolua_S,"setPositionX",lua_cocos2dx_Node_setPositionX); tolua_function(tolua_S,"setNodeToParentTransform",lua_cocos2dx_Node_setNodeToParentTransform); tolua_function(tolua_S,"getAnchorPoint",lua_cocos2dx_Node_getAnchorPoint); tolua_function(tolua_S,"getNumberOfRunningActions",lua_cocos2dx_Node_getNumberOfRunningActions); tolua_function(tolua_S,"updateTransform",lua_cocos2dx_Node_updateTransform); tolua_function(tolua_S,"setGLProgram",lua_cocos2dx_Node_setGLProgram); tolua_function(tolua_S,"isVisible",lua_cocos2dx_Node_isVisible); tolua_function(tolua_S,"getChildrenCount",lua_cocos2dx_Node_getChildrenCount); tolua_function(tolua_S,"convertToNodeSpaceAR",lua_cocos2dx_Node_convertToNodeSpaceAR); tolua_function(tolua_S,"addComponent",lua_cocos2dx_Node_addComponent); tolua_function(tolua_S,"runAction",lua_cocos2dx_Node_runAction); tolua_function(tolua_S,"visit",lua_cocos2dx_Node_visit); tolua_function(tolua_S,"getRotation",lua_cocos2dx_Node_getRotation); tolua_function(tolua_S,"getPhysicsBody",lua_cocos2dx_Node_getPhysicsBody); tolua_function(tolua_S,"getAnchorPointInPoints",lua_cocos2dx_Node_getAnchorPointInPoints); tolua_function(tolua_S,"removeChildByName",lua_cocos2dx_Node_removeChildByName); tolua_function(tolua_S,"getGLProgramState",lua_cocos2dx_Node_getGLProgramState); tolua_function(tolua_S,"setScheduler",lua_cocos2dx_Node_setScheduler); tolua_function(tolua_S,"stopAllActions",lua_cocos2dx_Node_stopAllActions); tolua_function(tolua_S,"getSkewX",lua_cocos2dx_Node_getSkewX); tolua_function(tolua_S,"getSkewY",lua_cocos2dx_Node_getSkewY); tolua_function(tolua_S,"getDisplayedColor",lua_cocos2dx_Node_getDisplayedColor); tolua_function(tolua_S,"getActionByTag",lua_cocos2dx_Node_getActionByTag); tolua_function(tolua_S,"setName",lua_cocos2dx_Node_setName); tolua_function(tolua_S,"update",lua_cocos2dx_Node_update); tolua_function(tolua_S,"getDisplayedOpacity",lua_cocos2dx_Node_getDisplayedOpacity); tolua_function(tolua_S,"getLocalZOrder",lua_cocos2dx_Node_getLocalZOrder); tolua_function(tolua_S,"getScheduler",lua_cocos2dx_Node_getScheduler); tolua_function(tolua_S,"getParentToNodeAffineTransform",lua_cocos2dx_Node_getParentToNodeAffineTransform); tolua_function(tolua_S,"getPositionNormalized",lua_cocos2dx_Node_getPositionNormalized); tolua_function(tolua_S,"setColor",lua_cocos2dx_Node_setColor); tolua_function(tolua_S,"isRunning",lua_cocos2dx_Node_isRunning); tolua_function(tolua_S,"getParent",lua_cocos2dx_Node_getParent); tolua_function(tolua_S,"getPositionZ",lua_cocos2dx_Node_getPositionZ); tolua_function(tolua_S,"getPositionY",lua_cocos2dx_Node_getPositionY); tolua_function(tolua_S,"getPositionX",lua_cocos2dx_Node_getPositionX); tolua_function(tolua_S,"removeChildByTag",lua_cocos2dx_Node_removeChildByTag); tolua_function(tolua_S,"setPositionY",lua_cocos2dx_Node_setPositionY); tolua_function(tolua_S,"getNodeToWorldAffineTransform",lua_cocos2dx_Node_getNodeToWorldAffineTransform); tolua_function(tolua_S,"updateDisplayedColor",lua_cocos2dx_Node_updateDisplayedColor); tolua_function(tolua_S,"setVisible",lua_cocos2dx_Node_setVisible); tolua_function(tolua_S,"getParentToNodeTransform",lua_cocos2dx_Node_getParentToNodeTransform); tolua_function(tolua_S,"isScheduled",lua_cocos2dx_Node_isScheduled); tolua_function(tolua_S,"setGlobalZOrder",lua_cocos2dx_Node_setGlobalZOrder); tolua_function(tolua_S,"setScale",lua_cocos2dx_Node_setScale); tolua_function(tolua_S,"getChildByTag",lua_cocos2dx_Node_getChildByTag); tolua_function(tolua_S,"getScaleZ",lua_cocos2dx_Node_getScaleZ); tolua_function(tolua_S,"getScaleY",lua_cocos2dx_Node_getScaleY); tolua_function(tolua_S,"getScaleX",lua_cocos2dx_Node_getScaleX); tolua_function(tolua_S,"setLocalZOrder",lua_cocos2dx_Node_setLocalZOrder); tolua_function(tolua_S,"getWorldToNodeAffineTransform",lua_cocos2dx_Node_getWorldToNodeAffineTransform); tolua_function(tolua_S,"setCascadeColorEnabled",lua_cocos2dx_Node_setCascadeColorEnabled); tolua_function(tolua_S,"setOpacity",lua_cocos2dx_Node_setOpacity); tolua_function(tolua_S,"cleanup",lua_cocos2dx_Node_cleanup); tolua_function(tolua_S,"getComponent",lua_cocos2dx_Node_getComponent); tolua_function(tolua_S,"getContentSize",lua_cocos2dx_Node_getContentSize); tolua_function(tolua_S,"stopAllActionsByTag",lua_cocos2dx_Node_stopAllActionsByTag); tolua_function(tolua_S,"getColor",lua_cocos2dx_Node_getColor); tolua_function(tolua_S,"getBoundingBox",lua_cocos2dx_Node_getBoundingBox); tolua_function(tolua_S,"setIgnoreAnchorPointForPosition",lua_cocos2dx_Node_setIgnoreAnchorPointForPosition); tolua_function(tolua_S,"setEventDispatcher",lua_cocos2dx_Node_setEventDispatcher); tolua_function(tolua_S,"getGlobalZOrder",lua_cocos2dx_Node_getGlobalZOrder); tolua_function(tolua_S,"draw",lua_cocos2dx_Node_draw); tolua_function(tolua_S,"setUserObject",lua_cocos2dx_Node_setUserObject); tolua_function(tolua_S,"removeFromParent",lua_cocos2dx_Node_removeFromParentAndCleanup); tolua_function(tolua_S,"setPosition3D",lua_cocos2dx_Node_setPosition3D); tolua_function(tolua_S,"getNumberOfRunningActionsByTag",lua_cocos2dx_Node_getNumberOfRunningActionsByTag); tolua_function(tolua_S,"sortAllChildren",lua_cocos2dx_Node_sortAllChildren); tolua_function(tolua_S,"getWorldToNodeTransform",lua_cocos2dx_Node_getWorldToNodeTransform); tolua_function(tolua_S,"getScale",lua_cocos2dx_Node_getScale); tolua_function(tolua_S,"getOpacity",lua_cocos2dx_Node_getOpacity); tolua_function(tolua_S,"updateOrderOfArrival",lua_cocos2dx_Node_updateOrderOfArrival); tolua_function(tolua_S,"getNormalizedPosition",lua_cocos2dx_Node_getNormalizedPosition); tolua_function(tolua_S,"getRotationSkewX",lua_cocos2dx_Node_getRotationSkewX); tolua_function(tolua_S,"getRotationSkewY",lua_cocos2dx_Node_getRotationSkewY); tolua_function(tolua_S,"setTag",lua_cocos2dx_Node_setTag); tolua_function(tolua_S,"isCascadeColorEnabled",lua_cocos2dx_Node_isCascadeColorEnabled); tolua_function(tolua_S,"stopAction",lua_cocos2dx_Node_stopAction); tolua_function(tolua_S,"getActionManager",lua_cocos2dx_Node_getActionManager); tolua_function(tolua_S,"create", lua_cocos2dx_Node_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Node).name(); g_luaType[typeName] = "cc.Node"; g_typeCast["Node"] = "cc.Node"; return 1; } int lua_cocos2dx_Scene_initWithPhysics(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scene_initWithPhysics'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_initWithPhysics'", nullptr); return 0; } bool ret = cobj->initWithPhysics(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:initWithPhysics",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_initWithPhysics'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_setCameraOrderDirty(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scene_setCameraOrderDirty'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_setCameraOrderDirty'", nullptr); return 0; } cobj->setCameraOrderDirty(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:setCameraOrderDirty",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_setCameraOrderDirty'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_render(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scene_render'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 4) { cocos2d::Renderer* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Renderer>(tolua_S, 2, "cc.Renderer",&arg0, "cc.Scene:render"); if (!ok) { break; } const cocos2d::Mat4* arg1 = nullptr; ok &= luaval_to_object<const cocos2d::Mat4>(tolua_S, 3, "cc.Mat4",&arg1, "cc.Scene:render"); if (!ok) { break; } const cocos2d::Mat4* arg2 = nullptr; ok &= luaval_to_object<const cocos2d::Mat4>(tolua_S, 4, "cc.Mat4",&arg2, "cc.Scene:render"); if (!ok) { break; } unsigned int arg3; ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.Scene:render"); if (!ok) { break; } cobj->render(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { cocos2d::Renderer* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Renderer>(tolua_S, 2, "cc.Renderer",&arg0, "cc.Scene:render"); if (!ok) { break; } cocos2d::Mat4 arg1; ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.Scene:render"); if (!ok) { break; } cobj->render(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Renderer* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Renderer>(tolua_S, 2, "cc.Renderer",&arg0, "cc.Scene:render"); if (!ok) { break; } cocos2d::Mat4 arg1; ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.Scene:render"); if (!ok) { break; } const cocos2d::Mat4* arg2 = nullptr; ok &= luaval_to_object<const cocos2d::Mat4>(tolua_S, 4, "cc.Mat4",&arg2, "cc.Scene:render"); if (!ok) { break; } cobj->render(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:render",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_render'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_stepPhysicsAndNavigation(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scene_stepPhysicsAndNavigation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Scene:stepPhysicsAndNavigation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_stepPhysicsAndNavigation'", nullptr); return 0; } cobj->stepPhysicsAndNavigation(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:stepPhysicsAndNavigation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_stepPhysicsAndNavigation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_onProjectionChanged(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scene_onProjectionChanged'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventCustom* arg0 = nullptr; ok &= luaval_to_object<cocos2d::EventCustom>(tolua_S, 2, "cc.EventCustom",&arg0, "cc.Scene:onProjectionChanged"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_onProjectionChanged'", nullptr); return 0; } cobj->onProjectionChanged(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:onProjectionChanged",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_onProjectionChanged'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_getPhysicsWorld(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scene_getPhysicsWorld'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_getPhysicsWorld'", nullptr); return 0; } cocos2d::PhysicsWorld* ret = cobj->getPhysicsWorld(); object_to_luaval<cocos2d::PhysicsWorld>(tolua_S, "cc.PhysicsWorld",(cocos2d::PhysicsWorld*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:getPhysicsWorld",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_getPhysicsWorld'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_initWithSize(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scene_initWithSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.Scene:initWithSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_initWithSize'", nullptr); return 0; } bool ret = cobj->initWithSize(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:initWithSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_initWithSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_getDefaultCamera(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scene_getDefaultCamera'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_getDefaultCamera'", nullptr); return 0; } cocos2d::Camera* ret = cobj->getDefaultCamera(); object_to_luaval<cocos2d::Camera>(tolua_S, "cc.Camera",(cocos2d::Camera*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:getDefaultCamera",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_getDefaultCamera'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_createWithSize(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.Scene:createWithSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_createWithSize'", nullptr); return 0; } cocos2d::Scene* ret = cocos2d::Scene::createWithSize(arg0); object_to_luaval<cocos2d::Scene>(tolua_S, "cc.Scene",(cocos2d::Scene*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Scene:createWithSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_createWithSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_create'", nullptr); return 0; } cocos2d::Scene* ret = cocos2d::Scene::create(); object_to_luaval<cocos2d::Scene>(tolua_S, "cc.Scene",(cocos2d::Scene*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Scene:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_createWithPhysics(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Scene",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_createWithPhysics'", nullptr); return 0; } cocos2d::Scene* ret = cocos2d::Scene::createWithPhysics(); object_to_luaval<cocos2d::Scene>(tolua_S, "cc.Scene",(cocos2d::Scene*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Scene:createWithPhysics",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_createWithPhysics'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scene_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Scene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scene_constructor'", nullptr); return 0; } cobj = new cocos2d::Scene(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Scene"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scene:Scene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scene_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Scene_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Scene)"); return 0; } int lua_register_cocos2dx_Scene(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Scene"); tolua_cclass(tolua_S,"Scene","cc.Scene","cc.Node",nullptr); tolua_beginmodule(tolua_S,"Scene"); tolua_function(tolua_S,"new",lua_cocos2dx_Scene_constructor); tolua_function(tolua_S,"initWithPhysics",lua_cocos2dx_Scene_initWithPhysics); tolua_function(tolua_S,"setCameraOrderDirty",lua_cocos2dx_Scene_setCameraOrderDirty); tolua_function(tolua_S,"render",lua_cocos2dx_Scene_render); tolua_function(tolua_S,"stepPhysicsAndNavigation",lua_cocos2dx_Scene_stepPhysicsAndNavigation); tolua_function(tolua_S,"onProjectionChanged",lua_cocos2dx_Scene_onProjectionChanged); tolua_function(tolua_S,"getPhysicsWorld",lua_cocos2dx_Scene_getPhysicsWorld); tolua_function(tolua_S,"initWithSize",lua_cocos2dx_Scene_initWithSize); tolua_function(tolua_S,"getDefaultCamera",lua_cocos2dx_Scene_getDefaultCamera); tolua_function(tolua_S,"createWithSize", lua_cocos2dx_Scene_createWithSize); tolua_function(tolua_S,"create", lua_cocos2dx_Scene_create); tolua_function(tolua_S,"createWithPhysics", lua_cocos2dx_Scene_createWithPhysics); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Scene).name(); g_luaType[typeName] = "cc.Scene"; g_typeCast["Scene"] = "cc.Scene"; return 1; } int lua_cocos2dx_GLView_setFrameSize(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setFrameSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; double arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.GLView:setFrameSize"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.GLView:setFrameSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setFrameSize'", nullptr); return 0; } cobj->setFrameSize(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setFrameSize",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setFrameSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getViewPortRect(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getViewPortRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getViewPortRect'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getViewPortRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getViewPortRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getViewPortRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setContentScaleFactor(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setContentScaleFactor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.GLView:setContentScaleFactor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setContentScaleFactor'", nullptr); return 0; } bool ret = cobj->setContentScaleFactor(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setContentScaleFactor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setContentScaleFactor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getContentScaleFactor(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getContentScaleFactor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getContentScaleFactor'", nullptr); return 0; } double ret = cobj->getContentScaleFactor(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getContentScaleFactor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getContentScaleFactor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setIMEKeyboardState(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setIMEKeyboardState'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.GLView:setIMEKeyboardState"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setIMEKeyboardState'", nullptr); return 0; } cobj->setIMEKeyboardState(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setIMEKeyboardState",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setIMEKeyboardState'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getVR(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getVR'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getVR'", nullptr); return 0; } cocos2d::VRIRenderer* ret = cobj->getVR(); object_to_luaval<cocos2d::VRIRenderer>(tolua_S, "cc.VRIRenderer",(cocos2d::VRIRenderer*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getVR",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getVR'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setScissorInPoints(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setScissorInPoints'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; double arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.GLView:setScissorInPoints"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.GLView:setScissorInPoints"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.GLView:setScissorInPoints"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.GLView:setScissorInPoints"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setScissorInPoints'", nullptr); return 0; } cobj->setScissorInPoints(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setScissorInPoints",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setScissorInPoints'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getViewName(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getViewName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getViewName'", nullptr); return 0; } const std::string& ret = cobj->getViewName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getViewName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getViewName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_isOpenGLReady(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_isOpenGLReady'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_isOpenGLReady'", nullptr); return 0; } bool ret = cobj->isOpenGLReady(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:isOpenGLReady",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_isOpenGLReady'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setCursorVisible(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setCursorVisible'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.GLView:setCursorVisible"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setCursorVisible'", nullptr); return 0; } cobj->setCursorVisible(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setCursorVisible",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setCursorVisible'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getFrameSize(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getFrameSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getFrameSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getFrameSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getFrameSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getFrameSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getScaleY(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getScaleY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getScaleY'", nullptr); return 0; } double ret = cobj->getScaleY(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getScaleY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getScaleY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getScaleX(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getScaleX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getScaleX'", nullptr); return 0; } double ret = cobj->getScaleX(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getScaleX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getScaleX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getVisibleOrigin(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getVisibleOrigin'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getVisibleOrigin'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getVisibleOrigin(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getVisibleOrigin",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getVisibleOrigin'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setFrameZoomFactor(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setFrameZoomFactor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.GLView:setFrameZoomFactor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setFrameZoomFactor'", nullptr); return 0; } cobj->setFrameZoomFactor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setFrameZoomFactor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setFrameZoomFactor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getFrameZoomFactor(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getFrameZoomFactor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getFrameZoomFactor'", nullptr); return 0; } double ret = cobj->getFrameZoomFactor(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getFrameZoomFactor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getFrameZoomFactor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getDesignResolutionSize(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getDesignResolutionSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getDesignResolutionSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getDesignResolutionSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getDesignResolutionSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getDesignResolutionSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_windowShouldClose(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_windowShouldClose'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_windowShouldClose'", nullptr); return 0; } bool ret = cobj->windowShouldClose(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:windowShouldClose",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_windowShouldClose'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_swapBuffers(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_swapBuffers'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_swapBuffers'", nullptr); return 0; } cobj->swapBuffers(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:swapBuffers",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_swapBuffers'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setDesignResolutionSize(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setDesignResolutionSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; double arg1; ResolutionPolicy arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.GLView:setDesignResolutionSize"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.GLView:setDesignResolutionSize"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.GLView:setDesignResolutionSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setDesignResolutionSize'", nullptr); return 0; } cobj->setDesignResolutionSize(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setDesignResolutionSize",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setDesignResolutionSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getResolutionPolicy(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getResolutionPolicy'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getResolutionPolicy'", nullptr); return 0; } int ret = (int)cobj->getResolutionPolicy(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getResolutionPolicy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getResolutionPolicy'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_end(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_end'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_end'", nullptr); return 0; } cobj->end(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:end",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_end'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_isRetinaDisplay(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_isRetinaDisplay'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_isRetinaDisplay'", nullptr); return 0; } bool ret = cobj->isRetinaDisplay(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:isRetinaDisplay",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_isRetinaDisplay'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_renderScene(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_renderScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Scene* arg0 = nullptr; cocos2d::Renderer* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 2, "cc.Scene",&arg0, "cc.GLView:renderScene"); ok &= luaval_to_object<cocos2d::Renderer>(tolua_S, 3, "cc.Renderer",&arg1, "cc.GLView:renderScene"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_renderScene'", nullptr); return 0; } cobj->renderScene(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:renderScene",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_renderScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setVR(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setVR'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::VRIRenderer* arg0 = nullptr; ok &= luaval_to_object<cocos2d::VRIRenderer>(tolua_S, 2, "cc.VRIRenderer",&arg0, "cc.GLView:setVR"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setVR'", nullptr); return 0; } cobj->setVR(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setVR",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setVR'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setViewPortInPoints(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setViewPortInPoints'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; double arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.GLView:setViewPortInPoints"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.GLView:setViewPortInPoints"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.GLView:setViewPortInPoints"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.GLView:setViewPortInPoints"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setViewPortInPoints'", nullptr); return 0; } cobj->setViewPortInPoints(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setViewPortInPoints",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setViewPortInPoints'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getScissorRect(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getScissorRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getScissorRect'", nullptr); return 0; } cocos2d::Rect ret = cobj->getScissorRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getScissorRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getScissorRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getRetinaFactor(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getRetinaFactor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getRetinaFactor'", nullptr); return 0; } int ret = cobj->getRetinaFactor(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getRetinaFactor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getRetinaFactor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setViewName(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_setViewName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLView:setViewName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setViewName'", nullptr); return 0; } cobj->setViewName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:setViewName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setViewName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getVisibleRect(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getVisibleRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getVisibleRect'", nullptr); return 0; } cocos2d::Rect ret = cobj->getVisibleRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getVisibleRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getVisibleRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getVisibleSize(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_getVisibleSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getVisibleSize'", nullptr); return 0; } cocos2d::Size ret = cobj->getVisibleSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:getVisibleSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getVisibleSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_isScissorEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_isScissorEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_isScissorEnabled'", nullptr); return 0; } bool ret = cobj->isScissorEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:isScissorEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_isScissorEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_pollEvents(lua_State* tolua_S) { int argc = 0; cocos2d::GLView* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLView*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLView_pollEvents'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_pollEvents'", nullptr); return 0; } cobj->pollEvents(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLView:pollEvents",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_pollEvents'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_setGLContextAttrs(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { GLContextAttrs arg0; #pragma warning NO CONVERSION TO NATIVE FOR GLContextAttrs ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_setGLContextAttrs'", nullptr); return 0; } cocos2d::GLView::setGLContextAttrs(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLView:setGLContextAttrs",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_setGLContextAttrs'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLView_getGLContextAttrs(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLView",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLView_getGLContextAttrs'", nullptr); return 0; } GLContextAttrs ret = cocos2d::GLView::getGLContextAttrs(); #pragma warning NO CONVERSION FROM NATIVE FOR GLContextAttrs; return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLView:getGLContextAttrs",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLView_getGLContextAttrs'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_GLView_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (GLView)"); return 0; } int lua_register_cocos2dx_GLView(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.GLView"); tolua_cclass(tolua_S,"GLView","cc.GLView","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"GLView"); tolua_function(tolua_S,"setFrameSize",lua_cocos2dx_GLView_setFrameSize); tolua_function(tolua_S,"getViewPortRect",lua_cocos2dx_GLView_getViewPortRect); tolua_function(tolua_S,"setContentScaleFactor",lua_cocos2dx_GLView_setContentScaleFactor); tolua_function(tolua_S,"getContentScaleFactor",lua_cocos2dx_GLView_getContentScaleFactor); tolua_function(tolua_S,"setIMEKeyboardState",lua_cocos2dx_GLView_setIMEKeyboardState); tolua_function(tolua_S,"getVR",lua_cocos2dx_GLView_getVR); tolua_function(tolua_S,"setScissorInPoints",lua_cocos2dx_GLView_setScissorInPoints); tolua_function(tolua_S,"getViewName",lua_cocos2dx_GLView_getViewName); tolua_function(tolua_S,"isOpenGLReady",lua_cocos2dx_GLView_isOpenGLReady); tolua_function(tolua_S,"setCursorVisible",lua_cocos2dx_GLView_setCursorVisible); tolua_function(tolua_S,"getFrameSize",lua_cocos2dx_GLView_getFrameSize); tolua_function(tolua_S,"getScaleY",lua_cocos2dx_GLView_getScaleY); tolua_function(tolua_S,"getScaleX",lua_cocos2dx_GLView_getScaleX); tolua_function(tolua_S,"getVisibleOrigin",lua_cocos2dx_GLView_getVisibleOrigin); tolua_function(tolua_S,"setFrameZoomFactor",lua_cocos2dx_GLView_setFrameZoomFactor); tolua_function(tolua_S,"getFrameZoomFactor",lua_cocos2dx_GLView_getFrameZoomFactor); tolua_function(tolua_S,"getDesignResolutionSize",lua_cocos2dx_GLView_getDesignResolutionSize); tolua_function(tolua_S,"windowShouldClose",lua_cocos2dx_GLView_windowShouldClose); tolua_function(tolua_S,"swapBuffers",lua_cocos2dx_GLView_swapBuffers); tolua_function(tolua_S,"setDesignResolutionSize",lua_cocos2dx_GLView_setDesignResolutionSize); tolua_function(tolua_S,"getResolutionPolicy",lua_cocos2dx_GLView_getResolutionPolicy); tolua_function(tolua_S,"endToLua",lua_cocos2dx_GLView_end); tolua_function(tolua_S,"isRetinaDisplay",lua_cocos2dx_GLView_isRetinaDisplay); tolua_function(tolua_S,"renderScene",lua_cocos2dx_GLView_renderScene); tolua_function(tolua_S,"setVR",lua_cocos2dx_GLView_setVR); tolua_function(tolua_S,"setViewPortInPoints",lua_cocos2dx_GLView_setViewPortInPoints); tolua_function(tolua_S,"getScissorRect",lua_cocos2dx_GLView_getScissorRect); tolua_function(tolua_S,"getRetinaFactor",lua_cocos2dx_GLView_getRetinaFactor); tolua_function(tolua_S,"setViewName",lua_cocos2dx_GLView_setViewName); tolua_function(tolua_S,"getVisibleRect",lua_cocos2dx_GLView_getVisibleRect); tolua_function(tolua_S,"getVisibleSize",lua_cocos2dx_GLView_getVisibleSize); tolua_function(tolua_S,"isScissorEnabled",lua_cocos2dx_GLView_isScissorEnabled); tolua_function(tolua_S,"pollEvents",lua_cocos2dx_GLView_pollEvents); tolua_function(tolua_S,"setGLContextAttrs", lua_cocos2dx_GLView_setGLContextAttrs); tolua_function(tolua_S,"getGLContextAttrs", lua_cocos2dx_GLView_getGLContextAttrs); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::GLView).name(); g_luaType[typeName] = "cc.GLView"; g_typeCast["GLView"] = "cc.GLView"; return 1; } int lua_cocos2dx_Director_pause(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_pause'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_pause'", nullptr); return 0; } cobj->pause(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:pause",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_pause'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_pushProjectionMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_pushProjectionMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned long arg0; ok &= luaval_to_ulong(tolua_S, 2, &arg0, "cc.Director:pushProjectionMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_pushProjectionMatrix'", nullptr); return 0; } cobj->pushProjectionMatrix(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:pushProjectionMatrix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_pushProjectionMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_popProjectionMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_popProjectionMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned long arg0; ok &= luaval_to_ulong(tolua_S, 2, &arg0, "cc.Director:popProjectionMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_popProjectionMatrix'", nullptr); return 0; } cobj->popProjectionMatrix(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:popProjectionMatrix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_popProjectionMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setEventDispatcher(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setEventDispatcher'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventDispatcher* arg0 = nullptr; ok &= luaval_to_object<cocos2d::EventDispatcher>(tolua_S, 2, "cc.EventDispatcher",&arg0, "cc.Director:setEventDispatcher"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setEventDispatcher'", nullptr); return 0; } cobj->setEventDispatcher(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setEventDispatcher",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setEventDispatcher'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_loadProjectionIdentityMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_loadProjectionIdentityMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned long arg0; ok &= luaval_to_ulong(tolua_S, 2, &arg0, "cc.Director:loadProjectionIdentityMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_loadProjectionIdentityMatrix'", nullptr); return 0; } cobj->loadProjectionIdentityMatrix(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:loadProjectionIdentityMatrix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_loadProjectionIdentityMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setContentScaleFactor(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setContentScaleFactor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Director:setContentScaleFactor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setContentScaleFactor'", nullptr); return 0; } cobj->setContentScaleFactor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setContentScaleFactor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setContentScaleFactor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getContentScaleFactor(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getContentScaleFactor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getContentScaleFactor'", nullptr); return 0; } double ret = cobj->getContentScaleFactor(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getContentScaleFactor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getContentScaleFactor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getWinSizeInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getWinSizeInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getWinSizeInPixels'", nullptr); return 0; } cocos2d::Size ret = cobj->getWinSizeInPixels(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getWinSizeInPixels",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getWinSizeInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getDeltaTime(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getDeltaTime'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getDeltaTime'", nullptr); return 0; } double ret = cobj->getDeltaTime(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getDeltaTime",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getDeltaTime'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setGLDefaultValues(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setGLDefaultValues'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setGLDefaultValues'", nullptr); return 0; } cobj->setGLDefaultValues(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setGLDefaultValues",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setGLDefaultValues'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setActionManager(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setActionManager'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionManager* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionManager>(tolua_S, 2, "cc.ActionManager",&arg0, "cc.Director:setActionManager"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setActionManager'", nullptr); return 0; } cobj->setActionManager(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setActionManager",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setActionManager'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setAlphaBlending(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setAlphaBlending'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Director:setAlphaBlending"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setAlphaBlending'", nullptr); return 0; } cobj->setAlphaBlending(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setAlphaBlending",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setAlphaBlending'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_popToRootScene(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_popToRootScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_popToRootScene'", nullptr); return 0; } cobj->popToRootScene(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:popToRootScene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_popToRootScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_loadMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_loadMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::MATRIX_STACK_TYPE arg0; cocos2d::Mat4 arg1; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Director:loadMatrix"); ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.Director:loadMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_loadMatrix'", nullptr); return 0; } cobj->loadMatrix(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:loadMatrix",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_loadMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getNotificationNode(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getNotificationNode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getNotificationNode'", nullptr); return 0; } cocos2d::Node* ret = cobj->getNotificationNode(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getNotificationNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getNotificationNode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getWinSize(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getWinSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getWinSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getWinSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getWinSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getWinSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getTextureCache(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getTextureCache'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getTextureCache'", nullptr); return 0; } cocos2d::TextureCache* ret = cobj->getTextureCache(); object_to_luaval<cocos2d::TextureCache>(tolua_S, "cc.TextureCache",(cocos2d::TextureCache*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getTextureCache",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getTextureCache'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_isSendCleanupToScene(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_isSendCleanupToScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_isSendCleanupToScene'", nullptr); return 0; } bool ret = cobj->isSendCleanupToScene(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:isSendCleanupToScene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_isSendCleanupToScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getVisibleOrigin(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getVisibleOrigin'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getVisibleOrigin'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getVisibleOrigin(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getVisibleOrigin",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getVisibleOrigin'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_mainLoop(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_mainLoop'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_mainLoop'", nullptr); return 0; } cobj->mainLoop(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:mainLoop",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_mainLoop'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setDepthTest(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setDepthTest'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Director:setDepthTest"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setDepthTest'", nullptr); return 0; } cobj->setDepthTest(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setDepthTest",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setDepthTest'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getFrameRate(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getFrameRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getFrameRate'", nullptr); return 0; } double ret = cobj->getFrameRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getFrameRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getFrameRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getSecondsPerFrame(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getSecondsPerFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getSecondsPerFrame'", nullptr); return 0; } double ret = cobj->getSecondsPerFrame(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getSecondsPerFrame",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getSecondsPerFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_resetMatrixStack(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_resetMatrixStack'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_resetMatrixStack'", nullptr); return 0; } cobj->resetMatrixStack(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:resetMatrixStack",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_resetMatrixStack'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_convertToUI(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_convertToUI'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Director:convertToUI"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_convertToUI'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->convertToUI(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:convertToUI",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_convertToUI'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_pushMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_pushMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::MATRIX_STACK_TYPE arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Director:pushMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_pushMatrix'", nullptr); return 0; } cobj->pushMatrix(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:pushMatrix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_pushMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setDefaultValues(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setDefaultValues'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setDefaultValues'", nullptr); return 0; } cobj->setDefaultValues(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setDefaultValues",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setDefaultValues'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_init(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setScheduler(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setScheduler'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Scheduler* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Scheduler>(tolua_S, 2, "cc.Scheduler",&arg0, "cc.Director:setScheduler"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setScheduler'", nullptr); return 0; } cobj->setScheduler(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setScheduler",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setScheduler'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_multiplyProjectionMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_multiplyProjectionMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Mat4 arg0; unsigned long arg1; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.Director:multiplyProjectionMatrix"); ok &= luaval_to_ulong(tolua_S, 3, &arg1, "cc.Director:multiplyProjectionMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_multiplyProjectionMatrix'", nullptr); return 0; } cobj->multiplyProjectionMatrix(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:multiplyProjectionMatrix",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_multiplyProjectionMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::MATRIX_STACK_TYPE arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Director:getMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getMatrix'", nullptr); return 0; } const cocos2d::Mat4& ret = cobj->getMatrix(arg0); mat4_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getMatrix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_isValid(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_isValid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_isValid'", nullptr); return 0; } bool ret = cobj->isValid(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:isValid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_isValid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_startAnimation(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_startAnimation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_startAnimation'", nullptr); return 0; } cobj->startAnimation(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:startAnimation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_startAnimation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getOpenGLView(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getOpenGLView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getOpenGLView'", nullptr); return 0; } cocos2d::GLView* ret = cobj->getOpenGLView(); object_to_luaval<cocos2d::GLView>(tolua_S, "cc.GLView",(cocos2d::GLView*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getOpenGLView",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getOpenGLView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getRunningScene(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getRunningScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getRunningScene'", nullptr); return 0; } cocos2d::Scene* ret = cobj->getRunningScene(); object_to_luaval<cocos2d::Scene>(tolua_S, "cc.Scene",(cocos2d::Scene*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getRunningScene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getRunningScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setViewport(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setViewport'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setViewport'", nullptr); return 0; } cobj->setViewport(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setViewport",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setViewport'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_stopAnimation(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_stopAnimation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_stopAnimation'", nullptr); return 0; } cobj->stopAnimation(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:stopAnimation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_stopAnimation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_popToSceneStackLevel(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_popToSceneStackLevel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Director:popToSceneStackLevel"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_popToSceneStackLevel'", nullptr); return 0; } cobj->popToSceneStackLevel(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:popToSceneStackLevel",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_popToSceneStackLevel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_resume(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_resume'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_resume'", nullptr); return 0; } cobj->resume(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:resume",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_resume'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_isNextDeltaTimeZero(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_isNextDeltaTimeZero'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_isNextDeltaTimeZero'", nullptr); return 0; } bool ret = cobj->isNextDeltaTimeZero(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:isNextDeltaTimeZero",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_isNextDeltaTimeZero'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setClearColor(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setClearColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4F arg0; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.Director:setClearColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setClearColor'", nullptr); return 0; } cobj->setClearColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setClearColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setClearColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_end(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_end'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_end'", nullptr); return 0; } cobj->end(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:end",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_end'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setOpenGLView(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setOpenGLView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::GLView* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GLView>(tolua_S, 2, "cc.GLView",&arg0, "cc.Director:setOpenGLView"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setOpenGLView'", nullptr); return 0; } cobj->setOpenGLView(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setOpenGLView",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setOpenGLView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_convertToGL(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_convertToGL'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Director:convertToGL"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_convertToGL'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->convertToGL(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:convertToGL",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_convertToGL'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_purgeCachedData(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_purgeCachedData'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_purgeCachedData'", nullptr); return 0; } cobj->purgeCachedData(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:purgeCachedData",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_purgeCachedData'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getTotalFrames(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getTotalFrames'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getTotalFrames'", nullptr); return 0; } unsigned int ret = cobj->getTotalFrames(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getTotalFrames",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getTotalFrames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_runWithScene(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_runWithScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Scene* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 2, "cc.Scene",&arg0, "cc.Director:runWithScene"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_runWithScene'", nullptr); return 0; } cobj->runWithScene(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:runWithScene",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_runWithScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setNotificationNode(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setNotificationNode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Director:setNotificationNode"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setNotificationNode'", nullptr); return 0; } cobj->setNotificationNode(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setNotificationNode",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setNotificationNode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_drawScene(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_drawScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_drawScene'", nullptr); return 0; } cobj->drawScene(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:drawScene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_drawScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_restart(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_restart'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_restart'", nullptr); return 0; } cobj->restart(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:restart",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_restart'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_popScene(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_popScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_popScene'", nullptr); return 0; } cobj->popScene(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:popScene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_popScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_loadIdentityMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_loadIdentityMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::MATRIX_STACK_TYPE arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Director:loadIdentityMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_loadIdentityMatrix'", nullptr); return 0; } cobj->loadIdentityMatrix(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:loadIdentityMatrix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_loadIdentityMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_isDisplayStats(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_isDisplayStats'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_isDisplayStats'", nullptr); return 0; } bool ret = cobj->isDisplayStats(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:isDisplayStats",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_isDisplayStats'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setProjection(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setProjection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Director::Projection arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Director:setProjection"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setProjection'", nullptr); return 0; } cobj->setProjection(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setProjection",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setProjection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getConsole(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getConsole'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getConsole'", nullptr); return 0; } cocos2d::Console* ret = cobj->getConsole(); object_to_luaval<cocos2d::Console>(tolua_S, "cc.Console",(cocos2d::Console*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getConsole",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getConsole'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_multiplyMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_multiplyMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::MATRIX_STACK_TYPE arg0; cocos2d::Mat4 arg1; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Director:multiplyMatrix"); ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.Director:multiplyMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_multiplyMatrix'", nullptr); return 0; } cobj->multiplyMatrix(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:multiplyMatrix",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_multiplyMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getZEye(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getZEye'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getZEye'", nullptr); return 0; } double ret = cobj->getZEye(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getZEye",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getZEye'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setNextDeltaTimeZero(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setNextDeltaTimeZero'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Director:setNextDeltaTimeZero"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setNextDeltaTimeZero'", nullptr); return 0; } cobj->setNextDeltaTimeZero(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setNextDeltaTimeZero",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setNextDeltaTimeZero'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_popMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_popMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::MATRIX_STACK_TYPE arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Director:popMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_popMatrix'", nullptr); return 0; } cobj->popMatrix(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:popMatrix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_popMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getVisibleSize(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getVisibleSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getVisibleSize'", nullptr); return 0; } cocos2d::Size ret = cobj->getVisibleSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getVisibleSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getVisibleSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_loadProjectionMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_loadProjectionMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Mat4 arg0; unsigned long arg1; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.Director:loadProjectionMatrix"); ok &= luaval_to_ulong(tolua_S, 3, &arg1, "cc.Director:loadProjectionMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_loadProjectionMatrix'", nullptr); return 0; } cobj->loadProjectionMatrix(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:loadProjectionMatrix",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_loadProjectionMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_initProjectionMatrixStack(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_initProjectionMatrixStack'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned long arg0; ok &= luaval_to_ulong(tolua_S, 2, &arg0, "cc.Director:initProjectionMatrixStack"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_initProjectionMatrixStack'", nullptr); return 0; } cobj->initProjectionMatrixStack(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:initProjectionMatrixStack",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_initProjectionMatrixStack'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getScheduler(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getScheduler'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getScheduler'", nullptr); return 0; } cocos2d::Scheduler* ret = cobj->getScheduler(); object_to_luaval<cocos2d::Scheduler>(tolua_S, "cc.Scheduler",(cocos2d::Scheduler*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getScheduler",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getScheduler'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_pushScene(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_pushScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Scene* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 2, "cc.Scene",&arg0, "cc.Director:pushScene"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_pushScene'", nullptr); return 0; } cobj->pushScene(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:pushScene",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_pushScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getAnimationInterval(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getAnimationInterval'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getAnimationInterval'", nullptr); return 0; } double ret = cobj->getAnimationInterval(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getAnimationInterval",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getAnimationInterval'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_isPaused(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_isPaused'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_isPaused'", nullptr); return 0; } bool ret = cobj->isPaused(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:isPaused",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_isPaused'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setDisplayStats(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setDisplayStats'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Director:setDisplayStats"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setDisplayStats'", nullptr); return 0; } cobj->setDisplayStats(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setDisplayStats",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setDisplayStats'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getEventDispatcher(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getEventDispatcher'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getEventDispatcher'", nullptr); return 0; } cocos2d::EventDispatcher* ret = cobj->getEventDispatcher(); object_to_luaval<cocos2d::EventDispatcher>(tolua_S, "cc.EventDispatcher",(cocos2d::EventDispatcher*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getEventDispatcher",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getEventDispatcher'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_replaceScene(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_replaceScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Scene* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 2, "cc.Scene",&arg0, "cc.Director:replaceScene"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_replaceScene'", nullptr); return 0; } cobj->replaceScene(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:replaceScene",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_replaceScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_setAnimationInterval(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_setAnimationInterval'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Director:setAnimationInterval"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_setAnimationInterval'", nullptr); return 0; } cobj->setAnimationInterval(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:setAnimationInterval",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_setAnimationInterval'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getActionManager(lua_State* tolua_S) { int argc = 0; cocos2d::Director* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Director*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Director_getActionManager'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getActionManager'", nullptr); return 0; } cocos2d::ActionManager* ret = cobj->getActionManager(); object_to_luaval<cocos2d::ActionManager>(tolua_S, "cc.ActionManager",(cocos2d::ActionManager*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Director:getActionManager",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getActionManager'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Director_getInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Director",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Director_getInstance'", nullptr); return 0; } cocos2d::Director* ret = cocos2d::Director::getInstance(); object_to_luaval<cocos2d::Director>(tolua_S, "cc.Director",(cocos2d::Director*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Director:getInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Director_getInstance'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Director_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Director)"); return 0; } int lua_register_cocos2dx_Director(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Director"); tolua_cclass(tolua_S,"Director","cc.Director","",nullptr); tolua_beginmodule(tolua_S,"Director"); tolua_function(tolua_S,"pause",lua_cocos2dx_Director_pause); tolua_function(tolua_S,"pushProjectionMatrix",lua_cocos2dx_Director_pushProjectionMatrix); tolua_function(tolua_S,"popProjectionMatrix",lua_cocos2dx_Director_popProjectionMatrix); tolua_function(tolua_S,"setEventDispatcher",lua_cocos2dx_Director_setEventDispatcher); tolua_function(tolua_S,"loadProjectionIdentityMatrix",lua_cocos2dx_Director_loadProjectionIdentityMatrix); tolua_function(tolua_S,"setContentScaleFactor",lua_cocos2dx_Director_setContentScaleFactor); tolua_function(tolua_S,"getContentScaleFactor",lua_cocos2dx_Director_getContentScaleFactor); tolua_function(tolua_S,"getWinSizeInPixels",lua_cocos2dx_Director_getWinSizeInPixels); tolua_function(tolua_S,"getDeltaTime",lua_cocos2dx_Director_getDeltaTime); tolua_function(tolua_S,"setGLDefaultValues",lua_cocos2dx_Director_setGLDefaultValues); tolua_function(tolua_S,"setActionManager",lua_cocos2dx_Director_setActionManager); tolua_function(tolua_S,"setAlphaBlending",lua_cocos2dx_Director_setAlphaBlending); tolua_function(tolua_S,"popToRootScene",lua_cocos2dx_Director_popToRootScene); tolua_function(tolua_S,"loadMatrix",lua_cocos2dx_Director_loadMatrix); tolua_function(tolua_S,"getNotificationNode",lua_cocos2dx_Director_getNotificationNode); tolua_function(tolua_S,"getWinSize",lua_cocos2dx_Director_getWinSize); tolua_function(tolua_S,"getTextureCache",lua_cocos2dx_Director_getTextureCache); tolua_function(tolua_S,"isSendCleanupToScene",lua_cocos2dx_Director_isSendCleanupToScene); tolua_function(tolua_S,"getVisibleOrigin",lua_cocos2dx_Director_getVisibleOrigin); tolua_function(tolua_S,"mainLoop",lua_cocos2dx_Director_mainLoop); tolua_function(tolua_S,"setDepthTest",lua_cocos2dx_Director_setDepthTest); tolua_function(tolua_S,"getFrameRate",lua_cocos2dx_Director_getFrameRate); tolua_function(tolua_S,"getSecondsPerFrame",lua_cocos2dx_Director_getSecondsPerFrame); tolua_function(tolua_S,"resetMatrixStack",lua_cocos2dx_Director_resetMatrixStack); tolua_function(tolua_S,"convertToUI",lua_cocos2dx_Director_convertToUI); tolua_function(tolua_S,"pushMatrix",lua_cocos2dx_Director_pushMatrix); tolua_function(tolua_S,"setDefaultValues",lua_cocos2dx_Director_setDefaultValues); tolua_function(tolua_S,"init",lua_cocos2dx_Director_init); tolua_function(tolua_S,"setScheduler",lua_cocos2dx_Director_setScheduler); tolua_function(tolua_S,"multiplyProjectionMatrix",lua_cocos2dx_Director_multiplyProjectionMatrix); tolua_function(tolua_S,"getMatrix",lua_cocos2dx_Director_getMatrix); tolua_function(tolua_S,"isValid",lua_cocos2dx_Director_isValid); tolua_function(tolua_S,"startAnimation",lua_cocos2dx_Director_startAnimation); tolua_function(tolua_S,"getOpenGLView",lua_cocos2dx_Director_getOpenGLView); tolua_function(tolua_S,"getRunningScene",lua_cocos2dx_Director_getRunningScene); tolua_function(tolua_S,"setViewport",lua_cocos2dx_Director_setViewport); tolua_function(tolua_S,"stopAnimation",lua_cocos2dx_Director_stopAnimation); tolua_function(tolua_S,"popToSceneStackLevel",lua_cocos2dx_Director_popToSceneStackLevel); tolua_function(tolua_S,"resume",lua_cocos2dx_Director_resume); tolua_function(tolua_S,"isNextDeltaTimeZero",lua_cocos2dx_Director_isNextDeltaTimeZero); tolua_function(tolua_S,"setClearColor",lua_cocos2dx_Director_setClearColor); tolua_function(tolua_S,"endToLua",lua_cocos2dx_Director_end); tolua_function(tolua_S,"setOpenGLView",lua_cocos2dx_Director_setOpenGLView); tolua_function(tolua_S,"convertToGL",lua_cocos2dx_Director_convertToGL); tolua_function(tolua_S,"purgeCachedData",lua_cocos2dx_Director_purgeCachedData); tolua_function(tolua_S,"getTotalFrames",lua_cocos2dx_Director_getTotalFrames); tolua_function(tolua_S,"runWithScene",lua_cocos2dx_Director_runWithScene); tolua_function(tolua_S,"setNotificationNode",lua_cocos2dx_Director_setNotificationNode); tolua_function(tolua_S,"drawScene",lua_cocos2dx_Director_drawScene); tolua_function(tolua_S,"restart",lua_cocos2dx_Director_restart); tolua_function(tolua_S,"popScene",lua_cocos2dx_Director_popScene); tolua_function(tolua_S,"loadIdentityMatrix",lua_cocos2dx_Director_loadIdentityMatrix); tolua_function(tolua_S,"isDisplayStats",lua_cocos2dx_Director_isDisplayStats); tolua_function(tolua_S,"setProjection",lua_cocos2dx_Director_setProjection); tolua_function(tolua_S,"getConsole",lua_cocos2dx_Director_getConsole); tolua_function(tolua_S,"multiplyMatrix",lua_cocos2dx_Director_multiplyMatrix); tolua_function(tolua_S,"getZEye",lua_cocos2dx_Director_getZEye); tolua_function(tolua_S,"setNextDeltaTimeZero",lua_cocos2dx_Director_setNextDeltaTimeZero); tolua_function(tolua_S,"popMatrix",lua_cocos2dx_Director_popMatrix); tolua_function(tolua_S,"getVisibleSize",lua_cocos2dx_Director_getVisibleSize); tolua_function(tolua_S,"loadProjectionMatrix",lua_cocos2dx_Director_loadProjectionMatrix); tolua_function(tolua_S,"initProjectionMatrixStack",lua_cocos2dx_Director_initProjectionMatrixStack); tolua_function(tolua_S,"getScheduler",lua_cocos2dx_Director_getScheduler); tolua_function(tolua_S,"pushScene",lua_cocos2dx_Director_pushScene); tolua_function(tolua_S,"getAnimationInterval",lua_cocos2dx_Director_getAnimationInterval); tolua_function(tolua_S,"isPaused",lua_cocos2dx_Director_isPaused); tolua_function(tolua_S,"setDisplayStats",lua_cocos2dx_Director_setDisplayStats); tolua_function(tolua_S,"getEventDispatcher",lua_cocos2dx_Director_getEventDispatcher); tolua_function(tolua_S,"replaceScene",lua_cocos2dx_Director_replaceScene); tolua_function(tolua_S,"setAnimationInterval",lua_cocos2dx_Director_setAnimationInterval); tolua_function(tolua_S,"getActionManager",lua_cocos2dx_Director_getActionManager); tolua_function(tolua_S,"getInstance", lua_cocos2dx_Director_getInstance); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Director).name(); g_luaType[typeName] = "cc.Director"; g_typeCast["Director"] = "cc.Director"; return 1; } int lua_cocos2dx_Timer_getInterval(lua_State* tolua_S) { int argc = 0; cocos2d::Timer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Timer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Timer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Timer_getInterval'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Timer_getInterval'", nullptr); return 0; } double ret = cobj->getInterval(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Timer:getInterval",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Timer_getInterval'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Timer_setupTimerWithInterval(lua_State* tolua_S) { int argc = 0; cocos2d::Timer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Timer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Timer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Timer_setupTimerWithInterval'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; unsigned int arg1; double arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Timer:setupTimerWithInterval"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.Timer:setupTimerWithInterval"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Timer:setupTimerWithInterval"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Timer_setupTimerWithInterval'", nullptr); return 0; } cobj->setupTimerWithInterval(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Timer:setupTimerWithInterval",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Timer_setupTimerWithInterval'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Timer_setInterval(lua_State* tolua_S) { int argc = 0; cocos2d::Timer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Timer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Timer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Timer_setInterval'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Timer:setInterval"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Timer_setInterval'", nullptr); return 0; } cobj->setInterval(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Timer:setInterval",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Timer_setInterval'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Timer_update(lua_State* tolua_S) { int argc = 0; cocos2d::Timer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Timer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Timer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Timer_update'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Timer:update"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Timer_update'", nullptr); return 0; } cobj->update(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Timer:update",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Timer_update'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Timer_isAborted(lua_State* tolua_S) { int argc = 0; cocos2d::Timer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Timer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Timer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Timer_isAborted'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Timer_isAborted'", nullptr); return 0; } bool ret = cobj->isAborted(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Timer:isAborted",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Timer_isAborted'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Timer_trigger(lua_State* tolua_S) { int argc = 0; cocos2d::Timer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Timer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Timer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Timer_trigger'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Timer:trigger"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Timer_trigger'", nullptr); return 0; } cobj->trigger(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Timer:trigger",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Timer_trigger'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Timer_cancel(lua_State* tolua_S) { int argc = 0; cocos2d::Timer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Timer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Timer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Timer_cancel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Timer_cancel'", nullptr); return 0; } cobj->cancel(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Timer:cancel",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Timer_cancel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Timer_setAborted(lua_State* tolua_S) { int argc = 0; cocos2d::Timer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Timer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Timer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Timer_setAborted'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Timer_setAborted'", nullptr); return 0; } cobj->setAborted(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Timer:setAborted",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Timer_setAborted'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Timer_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Timer)"); return 0; } int lua_register_cocos2dx_Timer(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Timer"); tolua_cclass(tolua_S,"Timer","cc.Timer","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Timer"); tolua_function(tolua_S,"getInterval",lua_cocos2dx_Timer_getInterval); tolua_function(tolua_S,"setupTimerWithInterval",lua_cocos2dx_Timer_setupTimerWithInterval); tolua_function(tolua_S,"setInterval",lua_cocos2dx_Timer_setInterval); tolua_function(tolua_S,"update",lua_cocos2dx_Timer_update); tolua_function(tolua_S,"isAborted",lua_cocos2dx_Timer_isAborted); tolua_function(tolua_S,"trigger",lua_cocos2dx_Timer_trigger); tolua_function(tolua_S,"cancel",lua_cocos2dx_Timer_cancel); tolua_function(tolua_S,"setAborted",lua_cocos2dx_Timer_setAborted); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Timer).name(); g_luaType[typeName] = "cc.Timer"; g_typeCast["Timer"] = "cc.Timer"; return 1; } int lua_cocos2dx_Scheduler_setTimeScale(lua_State* tolua_S) { int argc = 0; cocos2d::Scheduler* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scheduler",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scheduler*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scheduler_setTimeScale'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Scheduler:setTimeScale"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scheduler_setTimeScale'", nullptr); return 0; } cobj->setTimeScale(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scheduler:setTimeScale",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scheduler_setTimeScale'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scheduler_removeAllFunctionsToBePerformedInCocosThread(lua_State* tolua_S) { int argc = 0; cocos2d::Scheduler* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scheduler",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scheduler*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scheduler_removeAllFunctionsToBePerformedInCocosThread'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scheduler_removeAllFunctionsToBePerformedInCocosThread'", nullptr); return 0; } cobj->removeAllFunctionsToBePerformedInCocosThread(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scheduler:removeAllFunctionsToBePerformedInCocosThread",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scheduler_removeAllFunctionsToBePerformedInCocosThread'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scheduler_getTimeScale(lua_State* tolua_S) { int argc = 0; cocos2d::Scheduler* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Scheduler",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Scheduler*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Scheduler_getTimeScale'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scheduler_getTimeScale'", nullptr); return 0; } double ret = cobj->getTimeScale(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scheduler:getTimeScale",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scheduler_getTimeScale'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Scheduler_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Scheduler* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Scheduler_constructor'", nullptr); return 0; } cobj = new cocos2d::Scheduler(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Scheduler"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scheduler:Scheduler",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Scheduler_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Scheduler_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Scheduler)"); return 0; } int lua_register_cocos2dx_Scheduler(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Scheduler"); tolua_cclass(tolua_S,"Scheduler","cc.Scheduler","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Scheduler"); tolua_function(tolua_S,"new",lua_cocos2dx_Scheduler_constructor); tolua_function(tolua_S,"setTimeScale",lua_cocos2dx_Scheduler_setTimeScale); tolua_function(tolua_S,"removeAllFunctionsToBePerformedInCocosThread",lua_cocos2dx_Scheduler_removeAllFunctionsToBePerformedInCocosThread); tolua_function(tolua_S,"getTimeScale",lua_cocos2dx_Scheduler_getTimeScale); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Scheduler).name(); g_luaType[typeName] = "cc.Scheduler"; g_typeCast["Scheduler"] = "cc.Scheduler"; return 1; } int lua_cocos2dx_AsyncTaskPool_stopTasks(lua_State* tolua_S) { int argc = 0; cocos2d::AsyncTaskPool* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AsyncTaskPool",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AsyncTaskPool*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AsyncTaskPool_stopTasks'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::AsyncTaskPool::TaskType arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.AsyncTaskPool:stopTasks"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AsyncTaskPool_stopTasks'", nullptr); return 0; } cobj->stopTasks(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AsyncTaskPool:stopTasks",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AsyncTaskPool_stopTasks'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AsyncTaskPool_destroyInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.AsyncTaskPool",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AsyncTaskPool_destroyInstance'", nullptr); return 0; } cocos2d::AsyncTaskPool::destroyInstance(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.AsyncTaskPool:destroyInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AsyncTaskPool_destroyInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AsyncTaskPool_getInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.AsyncTaskPool",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AsyncTaskPool_getInstance'", nullptr); return 0; } cocos2d::AsyncTaskPool* ret = cocos2d::AsyncTaskPool::getInstance(); object_to_luaval<cocos2d::AsyncTaskPool>(tolua_S, "cc.AsyncTaskPool",(cocos2d::AsyncTaskPool*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.AsyncTaskPool:getInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AsyncTaskPool_getInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AsyncTaskPool_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::AsyncTaskPool* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AsyncTaskPool_constructor'", nullptr); return 0; } cobj = new cocos2d::AsyncTaskPool(); tolua_pushusertype(tolua_S,(void*)cobj,"cc.AsyncTaskPool"); tolua_register_gc(tolua_S,lua_gettop(tolua_S)); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AsyncTaskPool:AsyncTaskPool",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AsyncTaskPool_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_AsyncTaskPool_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (AsyncTaskPool)"); return 0; } int lua_register_cocos2dx_AsyncTaskPool(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.AsyncTaskPool"); tolua_cclass(tolua_S,"AsyncTaskPool","cc.AsyncTaskPool","",nullptr); tolua_beginmodule(tolua_S,"AsyncTaskPool"); tolua_function(tolua_S,"new",lua_cocos2dx_AsyncTaskPool_constructor); tolua_function(tolua_S,"stopTasks",lua_cocos2dx_AsyncTaskPool_stopTasks); tolua_function(tolua_S,"destroyInstance", lua_cocos2dx_AsyncTaskPool_destroyInstance); tolua_function(tolua_S,"getInstance", lua_cocos2dx_AsyncTaskPool_getInstance); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::AsyncTaskPool).name(); g_luaType[typeName] = "cc.AsyncTaskPool"; g_typeCast["AsyncTaskPool"] = "cc.AsyncTaskPool"; return 1; } int lua_cocos2dx_Action_startWithTarget(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_startWithTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Action:startWithTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_startWithTarget'", nullptr); return 0; } cobj->startWithTarget(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:startWithTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_startWithTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_setOriginalTarget(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_setOriginalTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Action:setOriginalTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_setOriginalTarget'", nullptr); return 0; } cobj->setOriginalTarget(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:setOriginalTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_setOriginalTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_clone(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_clone'", nullptr); return 0; } cocos2d::Action* ret = cobj->clone(); object_to_luaval<cocos2d::Action>(tolua_S, "cc.Action",(cocos2d::Action*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_getOriginalTarget(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_getOriginalTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_getOriginalTarget'", nullptr); return 0; } cocos2d::Node* ret = cobj->getOriginalTarget(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:getOriginalTarget",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_getOriginalTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_stop(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_stop'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_stop'", nullptr); return 0; } cobj->stop(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:stop",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_stop'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_update(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_update'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Action:update"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_update'", nullptr); return 0; } cobj->update(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:update",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_update'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_getTarget(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_getTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_getTarget'", nullptr); return 0; } cocos2d::Node* ret = cobj->getTarget(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:getTarget",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_getTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_getFlags(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_getFlags'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_getFlags'", nullptr); return 0; } unsigned int ret = cobj->getFlags(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:getFlags",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_getFlags'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_step(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_step'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Action:step"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_step'", nullptr); return 0; } cobj->step(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:step",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_step'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_setTag(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_setTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Action:setTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_setTag'", nullptr); return 0; } cobj->setTag(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:setTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_setTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_setFlags(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_setFlags'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned int arg0; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.Action:setFlags"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_setFlags'", nullptr); return 0; } cobj->setFlags(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:setFlags",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_setFlags'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_getTag(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_getTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_getTag'", nullptr); return 0; } int ret = cobj->getTag(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:getTag",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_getTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_setTarget(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_setTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Action:setTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_setTarget'", nullptr); return 0; } cobj->setTarget(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:setTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_setTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_isDone(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_isDone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_isDone'", nullptr); return 0; } bool ret = cobj->isDone(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:isDone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_isDone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Action_reverse(lua_State* tolua_S) { int argc = 0; cocos2d::Action* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Action",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Action*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Action_reverse'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Action_reverse'", nullptr); return 0; } cocos2d::Action* ret = cobj->reverse(); object_to_luaval<cocos2d::Action>(tolua_S, "cc.Action",(cocos2d::Action*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Action:reverse",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Action_reverse'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Action_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Action)"); return 0; } int lua_register_cocos2dx_Action(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Action"); tolua_cclass(tolua_S,"Action","cc.Action","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Action"); tolua_function(tolua_S,"startWithTarget",lua_cocos2dx_Action_startWithTarget); tolua_function(tolua_S,"setOriginalTarget",lua_cocos2dx_Action_setOriginalTarget); tolua_function(tolua_S,"clone",lua_cocos2dx_Action_clone); tolua_function(tolua_S,"getOriginalTarget",lua_cocos2dx_Action_getOriginalTarget); tolua_function(tolua_S,"stop",lua_cocos2dx_Action_stop); tolua_function(tolua_S,"update",lua_cocos2dx_Action_update); tolua_function(tolua_S,"getTarget",lua_cocos2dx_Action_getTarget); tolua_function(tolua_S,"getFlags",lua_cocos2dx_Action_getFlags); tolua_function(tolua_S,"step",lua_cocos2dx_Action_step); tolua_function(tolua_S,"setTag",lua_cocos2dx_Action_setTag); tolua_function(tolua_S,"setFlags",lua_cocos2dx_Action_setFlags); tolua_function(tolua_S,"getTag",lua_cocos2dx_Action_getTag); tolua_function(tolua_S,"setTarget",lua_cocos2dx_Action_setTarget); tolua_function(tolua_S,"isDone",lua_cocos2dx_Action_isDone); tolua_function(tolua_S,"reverse",lua_cocos2dx_Action_reverse); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Action).name(); g_luaType[typeName] = "cc.Action"; g_typeCast["Action"] = "cc.Action"; return 1; } int lua_cocos2dx_FiniteTimeAction_setDuration(lua_State* tolua_S) { int argc = 0; cocos2d::FiniteTimeAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FiniteTimeAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FiniteTimeAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FiniteTimeAction_setDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FiniteTimeAction:setDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FiniteTimeAction_setDuration'", nullptr); return 0; } cobj->setDuration(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FiniteTimeAction:setDuration",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FiniteTimeAction_setDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FiniteTimeAction_getDuration(lua_State* tolua_S) { int argc = 0; cocos2d::FiniteTimeAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FiniteTimeAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FiniteTimeAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FiniteTimeAction_getDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FiniteTimeAction_getDuration'", nullptr); return 0; } double ret = cobj->getDuration(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FiniteTimeAction:getDuration",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FiniteTimeAction_getDuration'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FiniteTimeAction_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FiniteTimeAction)"); return 0; } int lua_register_cocos2dx_FiniteTimeAction(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FiniteTimeAction"); tolua_cclass(tolua_S,"FiniteTimeAction","cc.FiniteTimeAction","cc.Action",nullptr); tolua_beginmodule(tolua_S,"FiniteTimeAction"); tolua_function(tolua_S,"setDuration",lua_cocos2dx_FiniteTimeAction_setDuration); tolua_function(tolua_S,"getDuration",lua_cocos2dx_FiniteTimeAction_getDuration); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FiniteTimeAction).name(); g_luaType[typeName] = "cc.FiniteTimeAction"; g_typeCast["FiniteTimeAction"] = "cc.FiniteTimeAction"; return 1; } int lua_cocos2dx_Speed_setInnerAction(lua_State* tolua_S) { int argc = 0; cocos2d::Speed* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Speed",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Speed*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Speed_setInnerAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.Speed:setInnerAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Speed_setInnerAction'", nullptr); return 0; } cobj->setInnerAction(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Speed:setInnerAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Speed_setInnerAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Speed_getSpeed(lua_State* tolua_S) { int argc = 0; cocos2d::Speed* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Speed",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Speed*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Speed_getSpeed'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Speed_getSpeed'", nullptr); return 0; } double ret = cobj->getSpeed(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Speed:getSpeed",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Speed_getSpeed'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Speed_setSpeed(lua_State* tolua_S) { int argc = 0; cocos2d::Speed* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Speed",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Speed*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Speed_setSpeed'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Speed:setSpeed"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Speed_setSpeed'", nullptr); return 0; } cobj->setSpeed(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Speed:setSpeed",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Speed_setSpeed'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Speed_initWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::Speed* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Speed",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Speed*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Speed_initWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.Speed:initWithAction"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Speed:initWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Speed_initWithAction'", nullptr); return 0; } bool ret = cobj->initWithAction(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Speed:initWithAction",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Speed_initWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Speed_getInnerAction(lua_State* tolua_S) { int argc = 0; cocos2d::Speed* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Speed",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Speed*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Speed_getInnerAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Speed_getInnerAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->getInnerAction(); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Speed:getInnerAction",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Speed_getInnerAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Speed_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Speed",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.Speed:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Speed:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Speed_create'", nullptr); return 0; } cocos2d::Speed* ret = cocos2d::Speed::create(arg0, arg1); object_to_luaval<cocos2d::Speed>(tolua_S, "cc.Speed",(cocos2d::Speed*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Speed:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Speed_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Speed_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Speed* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Speed_constructor'", nullptr); return 0; } cobj = new cocos2d::Speed(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Speed"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Speed:Speed",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Speed_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Speed_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Speed)"); return 0; } int lua_register_cocos2dx_Speed(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Speed"); tolua_cclass(tolua_S,"Speed","cc.Speed","cc.Action",nullptr); tolua_beginmodule(tolua_S,"Speed"); tolua_function(tolua_S,"new",lua_cocos2dx_Speed_constructor); tolua_function(tolua_S,"setInnerAction",lua_cocos2dx_Speed_setInnerAction); tolua_function(tolua_S,"getSpeed",lua_cocos2dx_Speed_getSpeed); tolua_function(tolua_S,"setSpeed",lua_cocos2dx_Speed_setSpeed); tolua_function(tolua_S,"initWithAction",lua_cocos2dx_Speed_initWithAction); tolua_function(tolua_S,"getInnerAction",lua_cocos2dx_Speed_getInnerAction); tolua_function(tolua_S,"create", lua_cocos2dx_Speed_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Speed).name(); g_luaType[typeName] = "cc.Speed"; g_typeCast["Speed"] = "cc.Speed"; return 1; } int lua_cocos2dx_Follow_setBoundarySet(lua_State* tolua_S) { int argc = 0; cocos2d::Follow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Follow",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Follow*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Follow_setBoundarySet'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Follow:setBoundarySet"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_setBoundarySet'", nullptr); return 0; } cobj->setBoundarySet(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Follow:setBoundarySet",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Follow_setBoundarySet'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Follow_initWithTarget(lua_State* tolua_S) { int argc = 0; cocos2d::Follow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Follow",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Follow*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Follow_initWithTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Follow:initWithTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_initWithTarget'", nullptr); return 0; } bool ret = cobj->initWithTarget(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 2) { cocos2d::Node* arg0 = nullptr; cocos2d::Rect arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Follow:initWithTarget"); ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Follow:initWithTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_initWithTarget'", nullptr); return 0; } bool ret = cobj->initWithTarget(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Follow:initWithTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Follow_initWithTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Follow_initWithTargetAndOffset(lua_State* tolua_S) { int argc = 0; cocos2d::Follow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Follow",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Follow*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Follow_initWithTargetAndOffset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Node* arg0 = nullptr; double arg1; double arg2; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Follow:initWithTargetAndOffset"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Follow:initWithTargetAndOffset"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Follow:initWithTargetAndOffset"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_initWithTargetAndOffset'", nullptr); return 0; } bool ret = cobj->initWithTargetAndOffset(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 4) { cocos2d::Node* arg0 = nullptr; double arg1; double arg2; cocos2d::Rect arg3; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Follow:initWithTargetAndOffset"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Follow:initWithTargetAndOffset"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Follow:initWithTargetAndOffset"); ok &= luaval_to_rect(tolua_S, 5, &arg3, "cc.Follow:initWithTargetAndOffset"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_initWithTargetAndOffset'", nullptr); return 0; } bool ret = cobj->initWithTargetAndOffset(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Follow:initWithTargetAndOffset",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Follow_initWithTargetAndOffset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Follow_isBoundarySet(lua_State* tolua_S) { int argc = 0; cocos2d::Follow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Follow",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Follow*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Follow_isBoundarySet'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_isBoundarySet'", nullptr); return 0; } bool ret = cobj->isBoundarySet(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Follow:isBoundarySet",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Follow_isBoundarySet'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Follow_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Follow",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Follow:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_create'", nullptr); return 0; } cocos2d::Follow* ret = cocos2d::Follow::create(arg0); object_to_luaval<cocos2d::Follow>(tolua_S, "cc.Follow",(cocos2d::Follow*)ret); return 1; } if (argc == 2) { cocos2d::Node* arg0 = nullptr; cocos2d::Rect arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Follow:create"); ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Follow:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_create'", nullptr); return 0; } cocos2d::Follow* ret = cocos2d::Follow::create(arg0, arg1); object_to_luaval<cocos2d::Follow>(tolua_S, "cc.Follow",(cocos2d::Follow*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Follow:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Follow_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Follow_createWithOffset(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Follow",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { cocos2d::Node* arg0 = nullptr; double arg1; double arg2; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Follow:createWithOffset"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Follow:createWithOffset"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Follow:createWithOffset"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_createWithOffset'", nullptr); return 0; } cocos2d::Follow* ret = cocos2d::Follow::createWithOffset(arg0, arg1, arg2); object_to_luaval<cocos2d::Follow>(tolua_S, "cc.Follow",(cocos2d::Follow*)ret); return 1; } if (argc == 4) { cocos2d::Node* arg0 = nullptr; double arg1; double arg2; cocos2d::Rect arg3; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.Follow:createWithOffset"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Follow:createWithOffset"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Follow:createWithOffset"); ok &= luaval_to_rect(tolua_S, 5, &arg3, "cc.Follow:createWithOffset"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_createWithOffset'", nullptr); return 0; } cocos2d::Follow* ret = cocos2d::Follow::createWithOffset(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Follow>(tolua_S, "cc.Follow",(cocos2d::Follow*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Follow:createWithOffset",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Follow_createWithOffset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Follow_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Follow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Follow_constructor'", nullptr); return 0; } cobj = new cocos2d::Follow(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Follow"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Follow:Follow",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Follow_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Follow_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Follow)"); return 0; } int lua_register_cocos2dx_Follow(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Follow"); tolua_cclass(tolua_S,"Follow","cc.Follow","cc.Action",nullptr); tolua_beginmodule(tolua_S,"Follow"); tolua_function(tolua_S,"new",lua_cocos2dx_Follow_constructor); tolua_function(tolua_S,"setBoundarySet",lua_cocos2dx_Follow_setBoundarySet); tolua_function(tolua_S,"initWithTarget",lua_cocos2dx_Follow_initWithTarget); tolua_function(tolua_S,"initWithTargetAndOffset",lua_cocos2dx_Follow_initWithTargetAndOffset); tolua_function(tolua_S,"isBoundarySet",lua_cocos2dx_Follow_isBoundarySet); tolua_function(tolua_S,"create", lua_cocos2dx_Follow_create); tolua_function(tolua_S,"createWithOffset", lua_cocos2dx_Follow_createWithOffset); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Follow).name(); g_luaType[typeName] = "cc.Follow"; g_typeCast["Follow"] = "cc.Follow"; return 1; } int lua_cocos2dx_Image_hasPremultipliedAlpha(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_hasPremultipliedAlpha'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_hasPremultipliedAlpha'", nullptr); return 0; } bool ret = cobj->hasPremultipliedAlpha(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:hasPremultipliedAlpha",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_hasPremultipliedAlpha'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_saveToFile(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_saveToFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Image:saveToFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_saveToFile'", nullptr); return 0; } bool ret = cobj->saveToFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 2) { std::string arg0; bool arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Image:saveToFile"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Image:saveToFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_saveToFile'", nullptr); return 0; } bool ret = cobj->saveToFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:saveToFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_saveToFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_hasAlpha(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_hasAlpha'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_hasAlpha'", nullptr); return 0; } bool ret = cobj->hasAlpha(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:hasAlpha",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_hasAlpha'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_isCompressed(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_isCompressed'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_isCompressed'", nullptr); return 0; } bool ret = cobj->isCompressed(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:isCompressed",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_isCompressed'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_getHeight(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_getHeight'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_getHeight'", nullptr); return 0; } int ret = cobj->getHeight(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:getHeight",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_getHeight'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_initWithImageFile(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_initWithImageFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Image:initWithImageFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_initWithImageFile'", nullptr); return 0; } bool ret = cobj->initWithImageFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:initWithImageFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_initWithImageFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_getWidth(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_getWidth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_getWidth'", nullptr); return 0; } int ret = cobj->getWidth(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:getWidth",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_getWidth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_getBitPerPixel(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_getBitPerPixel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_getBitPerPixel'", nullptr); return 0; } int ret = cobj->getBitPerPixel(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:getBitPerPixel",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_getBitPerPixel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_getFileType(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_getFileType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_getFileType'", nullptr); return 0; } int ret = (int)cobj->getFileType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:getFileType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_getFileType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_getFilePath(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_getFilePath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_getFilePath'", nullptr); return 0; } std::string ret = cobj->getFilePath(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:getFilePath",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_getFilePath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_getNumberOfMipmaps(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_getNumberOfMipmaps'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_getNumberOfMipmaps'", nullptr); return 0; } int ret = cobj->getNumberOfMipmaps(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:getNumberOfMipmaps",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_getNumberOfMipmaps'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_getRenderFormat(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Image*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Image_getRenderFormat'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_getRenderFormat'", nullptr); return 0; } int ret = (int)cobj->getRenderFormat(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:getRenderFormat",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_getRenderFormat'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_setPVRImagesHavePremultipliedAlpha(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Image:setPVRImagesHavePremultipliedAlpha"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_setPVRImagesHavePremultipliedAlpha'", nullptr); return 0; } cocos2d::Image::setPVRImagesHavePremultipliedAlpha(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Image:setPVRImagesHavePremultipliedAlpha",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_setPVRImagesHavePremultipliedAlpha'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_setPNGPremultipliedAlphaEnabled(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Image",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Image:setPNGPremultipliedAlphaEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_setPNGPremultipliedAlphaEnabled'", nullptr); return 0; } cocos2d::Image::setPNGPremultipliedAlphaEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Image:setPNGPremultipliedAlphaEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_setPNGPremultipliedAlphaEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Image_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Image* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Image_constructor'", nullptr); return 0; } cobj = new cocos2d::Image(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Image"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Image:Image",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Image_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Image_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Image)"); return 0; } int lua_register_cocos2dx_Image(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Image"); tolua_cclass(tolua_S,"Image","cc.Image","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Image"); tolua_function(tolua_S,"new",lua_cocos2dx_Image_constructor); tolua_function(tolua_S,"hasPremultipliedAlpha",lua_cocos2dx_Image_hasPremultipliedAlpha); tolua_function(tolua_S,"saveToFile",lua_cocos2dx_Image_saveToFile); tolua_function(tolua_S,"hasAlpha",lua_cocos2dx_Image_hasAlpha); tolua_function(tolua_S,"isCompressed",lua_cocos2dx_Image_isCompressed); tolua_function(tolua_S,"getHeight",lua_cocos2dx_Image_getHeight); tolua_function(tolua_S,"initWithImageFile",lua_cocos2dx_Image_initWithImageFile); tolua_function(tolua_S,"getWidth",lua_cocos2dx_Image_getWidth); tolua_function(tolua_S,"getBitPerPixel",lua_cocos2dx_Image_getBitPerPixel); tolua_function(tolua_S,"getFileType",lua_cocos2dx_Image_getFileType); tolua_function(tolua_S,"getFilePath",lua_cocos2dx_Image_getFilePath); tolua_function(tolua_S,"getNumberOfMipmaps",lua_cocos2dx_Image_getNumberOfMipmaps); tolua_function(tolua_S,"getRenderFormat",lua_cocos2dx_Image_getRenderFormat); tolua_function(tolua_S,"setPVRImagesHavePremultipliedAlpha", lua_cocos2dx_Image_setPVRImagesHavePremultipliedAlpha); tolua_function(tolua_S,"setPNGPremultipliedAlphaEnabled", lua_cocos2dx_Image_setPNGPremultipliedAlphaEnabled); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Image).name(); g_luaType[typeName] = "cc.Image"; g_typeCast["Image"] = "cc.Image"; return 1; } int lua_cocos2dx_GLProgramState_getVertexAttribsFlags(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_getVertexAttribsFlags'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_getVertexAttribsFlags'", nullptr); return 0; } unsigned int ret = cobj->getVertexAttribsFlags(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:getVertexAttribsFlags",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_getVertexAttribsFlags'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformVec4(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformVec4'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformVec4"); if (!ok) { break; } cocos2d::Vec4 arg1; ok &= luaval_to_vec4(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec4"); if (!ok) { break; } cobj->setUniformVec4(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformVec4"); if (!ok) { break; } cocos2d::Vec4 arg1; ok &= luaval_to_vec4(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec4"); if (!ok) { break; } cobj->setUniformVec4(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformVec4",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformVec4'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_applyAutoBinding(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_applyAutoBinding'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:applyAutoBinding"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgramState:applyAutoBinding"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_applyAutoBinding'", nullptr); return 0; } cobj->applyAutoBinding(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:applyAutoBinding",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_applyAutoBinding'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformVec2(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformVec2'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformVec2"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec2"); if (!ok) { break; } cobj->setUniformVec2(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformVec2"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec2"); if (!ok) { break; } cobj->setUniformVec2(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformVec2",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformVec2'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformVec3(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformVec3'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformVec3"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec3"); if (!ok) { break; } cobj->setUniformVec3(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformVec3"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec3"); if (!ok) { break; } cobj->setUniformVec3(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformVec3",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformVec3'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_apply(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_apply'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Mat4 arg0; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.GLProgramState:apply"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_apply'", nullptr); return 0; } cobj->apply(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:apply",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_apply'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_getNodeBinding(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_getNodeBinding'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_getNodeBinding'", nullptr); return 0; } cocos2d::Node* ret = cobj->getNodeBinding(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:getNodeBinding",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_getNodeBinding'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformVec4v(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformVec4v'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformVec4v"); if (!ok) { break; } ssize_t arg1; ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec4v"); if (!ok) { break; } const cocos2d::Vec4* arg2 = nullptr; ok &= luaval_to_object<const cocos2d::Vec4>(tolua_S, 4, "cc.Vec4",&arg2, "cc.GLProgramState:setUniformVec4v"); if (!ok) { break; } cobj->setUniformVec4v(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformVec4v"); if (!ok) { break; } ssize_t arg1; ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec4v"); if (!ok) { break; } const cocos2d::Vec4* arg2 = nullptr; ok &= luaval_to_object<const cocos2d::Vec4>(tolua_S, 4, "cc.Vec4",&arg2, "cc.GLProgramState:setUniformVec4v"); if (!ok) { break; } cobj->setUniformVec4v(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformVec4v",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformVec4v'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_applyGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_applyGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Mat4 arg0; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.GLProgramState:applyGLProgram"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_applyGLProgram'", nullptr); return 0; } cobj->applyGLProgram(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:applyGLProgram",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_applyGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setNodeBinding(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setNodeBinding'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.GLProgramState:setNodeBinding"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_setNodeBinding'", nullptr); return 0; } cobj->setNodeBinding(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setNodeBinding",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setNodeBinding'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformInt(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformInt'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformInt"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.GLProgramState:setUniformInt"); if (!ok) { break; } cobj->setUniformInt(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformInt"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.GLProgramState:setUniformInt"); if (!ok) { break; } cobj->setUniformInt(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformInt",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformInt'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setParameterAutoBinding(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setParameterAutoBinding'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setParameterAutoBinding"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgramState:setParameterAutoBinding"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_setParameterAutoBinding'", nullptr); return 0; } cobj->setParameterAutoBinding(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setParameterAutoBinding",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setParameterAutoBinding'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformVec2v(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformVec2v'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformVec2v"); if (!ok) { break; } ssize_t arg1; ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec2v"); if (!ok) { break; } const cocos2d::Vec2* arg2 = nullptr; ok &= luaval_to_object<const cocos2d::Vec2>(tolua_S, 4, "cc.Vec2",&arg2, "cc.GLProgramState:setUniformVec2v"); if (!ok) { break; } cobj->setUniformVec2v(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformVec2v"); if (!ok) { break; } ssize_t arg1; ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec2v"); if (!ok) { break; } const cocos2d::Vec2* arg2 = nullptr; ok &= luaval_to_object<const cocos2d::Vec2>(tolua_S, 4, "cc.Vec2",&arg2, "cc.GLProgramState:setUniformVec2v"); if (!ok) { break; } cobj->setUniformVec2v(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformVec2v",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformVec2v'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_getUniformCount(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_getUniformCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_getUniformCount'", nullptr); return 0; } ssize_t ret = cobj->getUniformCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:getUniformCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_getUniformCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_applyAttributes(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_applyAttributes'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_applyAttributes'", nullptr); return 0; } cobj->applyAttributes(); lua_settop(tolua_S, 1); return 1; } if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.GLProgramState:applyAttributes"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_applyAttributes'", nullptr); return 0; } cobj->applyAttributes(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:applyAttributes",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_applyAttributes'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_clone(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_clone'", nullptr); return 0; } cocos2d::GLProgramState* ret = cobj->clone(); object_to_luaval<cocos2d::GLProgramState>(tolua_S, "cc.GLProgramState",(cocos2d::GLProgramState*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::GLProgram* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GLProgram>(tolua_S, 2, "cc.GLProgram",&arg0, "cc.GLProgramState:setGLProgram"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_setGLProgram'", nullptr); return 0; } cobj->setGLProgram(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setGLProgram",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformFloatv(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformFloatv'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformFloatv"); if (!ok) { break; } ssize_t arg1; ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformFloatv"); if (!ok) { break; } const float* arg2 = nullptr; #pragma warning NO CONVERSION TO NATIVE FOR float* ok = false; if (!ok) { break; } cobj->setUniformFloatv(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformFloatv"); if (!ok) { break; } ssize_t arg1; ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformFloatv"); if (!ok) { break; } const float* arg2 = nullptr; #pragma warning NO CONVERSION TO NATIVE FOR float* ok = false; if (!ok) { break; } cobj->setUniformFloatv(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformFloatv",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformFloatv'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_getGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_getGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_getGLProgram'", nullptr); return 0; } cocos2d::GLProgram* ret = cobj->getGLProgram(); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:getGLProgram",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_getGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformTexture(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformTexture"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.GLProgramState:setUniformTexture"); if (!ok) { break; } cobj->setUniformTexture(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformTexture"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.GLProgramState:setUniformTexture"); if (!ok) { break; } cobj->setUniformTexture(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformTexture",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_applyUniforms(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_applyUniforms'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_applyUniforms'", nullptr); return 0; } cobj->applyUniforms(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:applyUniforms",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_applyUniforms'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformFloat(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformFloat'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformFloat"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.GLProgramState:setUniformFloat"); if (!ok) { break; } cobj->setUniformFloat(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformFloat"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.GLProgramState:setUniformFloat"); if (!ok) { break; } cobj->setUniformFloat(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformFloat",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformFloat'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformMat4(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformMat4'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformMat4"); if (!ok) { break; } cocos2d::Mat4 arg1; ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformMat4"); if (!ok) { break; } cobj->setUniformMat4(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformMat4"); if (!ok) { break; } cocos2d::Mat4 arg1; ok &= luaval_to_mat4(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformMat4"); if (!ok) { break; } cobj->setUniformMat4(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformMat4",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformMat4'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_setUniformVec3v(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_setUniformVec3v'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgramState:setUniformVec3v"); if (!ok) { break; } ssize_t arg1; ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec3v"); if (!ok) { break; } const cocos2d::Vec3* arg2 = nullptr; ok &= luaval_to_object<const cocos2d::Vec3>(tolua_S, 4, "cc.Vec3",&arg2, "cc.GLProgramState:setUniformVec3v"); if (!ok) { break; } cobj->setUniformVec3v(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:setUniformVec3v"); if (!ok) { break; } ssize_t arg1; ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.GLProgramState:setUniformVec3v"); if (!ok) { break; } const cocos2d::Vec3* arg2 = nullptr; ok &= luaval_to_object<const cocos2d::Vec3>(tolua_S, 4, "cc.Vec3",&arg2, "cc.GLProgramState:setUniformVec3v"); if (!ok) { break; } cobj->setUniformVec3v(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:setUniformVec3v",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_setUniformVec3v'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_getVertexAttribCount(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramState_getVertexAttribCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_getVertexAttribCount'", nullptr); return 0; } ssize_t ret = cobj->getVertexAttribCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramState:getVertexAttribCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_getVertexAttribCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::GLProgram* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GLProgram>(tolua_S, 2, "cc.GLProgram",&arg0, "cc.GLProgramState:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_create'", nullptr); return 0; } cocos2d::GLProgramState* ret = cocos2d::GLProgramState::create(arg0); object_to_luaval<cocos2d::GLProgramState>(tolua_S, "cc.GLProgramState",(cocos2d::GLProgramState*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLProgramState:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_getOrCreateWithGLProgramName(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:getOrCreateWithGLProgramName"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.GLProgramState:getOrCreateWithGLProgramName"); if (!ok) { break; } cocos2d::GLProgramState* ret = cocos2d::GLProgramState::getOrCreateWithGLProgramName(arg0, arg1); object_to_luaval<cocos2d::GLProgramState>(tolua_S, "cc.GLProgramState",(cocos2d::GLProgramState*)ret); return 1; } } while (0); ok = true; do { if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:getOrCreateWithGLProgramName"); if (!ok) { break; } cocos2d::GLProgramState* ret = cocos2d::GLProgramState::getOrCreateWithGLProgramName(arg0); object_to_luaval<cocos2d::GLProgramState>(tolua_S, "cc.GLProgramState",(cocos2d::GLProgramState*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.GLProgramState:getOrCreateWithGLProgramName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_getOrCreateWithGLProgramName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_getOrCreateWithGLProgram(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::GLProgram* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GLProgram>(tolua_S, 2, "cc.GLProgram",&arg0, "cc.GLProgramState:getOrCreateWithGLProgram"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_getOrCreateWithGLProgram'", nullptr); return 0; } cocos2d::GLProgramState* ret = cocos2d::GLProgramState::getOrCreateWithGLProgram(arg0); object_to_luaval<cocos2d::GLProgramState>(tolua_S, "cc.GLProgramState",(cocos2d::GLProgramState*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLProgramState:getOrCreateWithGLProgram",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_getOrCreateWithGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramState_getOrCreateWithShaders(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLProgramState",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { std::string arg0; std::string arg1; std::string arg2; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramState:getOrCreateWithShaders"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgramState:getOrCreateWithShaders"); ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgramState:getOrCreateWithShaders"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramState_getOrCreateWithShaders'", nullptr); return 0; } cocos2d::GLProgramState* ret = cocos2d::GLProgramState::getOrCreateWithShaders(arg0, arg1, arg2); object_to_luaval<cocos2d::GLProgramState>(tolua_S, "cc.GLProgramState",(cocos2d::GLProgramState*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLProgramState:getOrCreateWithShaders",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramState_getOrCreateWithShaders'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_GLProgramState_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (GLProgramState)"); return 0; } int lua_register_cocos2dx_GLProgramState(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.GLProgramState"); tolua_cclass(tolua_S,"GLProgramState","cc.GLProgramState","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"GLProgramState"); tolua_function(tolua_S,"getVertexAttribsFlags",lua_cocos2dx_GLProgramState_getVertexAttribsFlags); tolua_function(tolua_S,"setUniformVec4",lua_cocos2dx_GLProgramState_setUniformVec4); tolua_function(tolua_S,"applyAutoBinding",lua_cocos2dx_GLProgramState_applyAutoBinding); tolua_function(tolua_S,"setUniformVec2",lua_cocos2dx_GLProgramState_setUniformVec2); tolua_function(tolua_S,"setUniformVec3",lua_cocos2dx_GLProgramState_setUniformVec3); tolua_function(tolua_S,"apply",lua_cocos2dx_GLProgramState_apply); tolua_function(tolua_S,"getNodeBinding",lua_cocos2dx_GLProgramState_getNodeBinding); tolua_function(tolua_S,"setUniformVec4v",lua_cocos2dx_GLProgramState_setUniformVec4v); tolua_function(tolua_S,"applyGLProgram",lua_cocos2dx_GLProgramState_applyGLProgram); tolua_function(tolua_S,"setNodeBinding",lua_cocos2dx_GLProgramState_setNodeBinding); tolua_function(tolua_S,"setUniformInt",lua_cocos2dx_GLProgramState_setUniformInt); tolua_function(tolua_S,"setParameterAutoBinding",lua_cocos2dx_GLProgramState_setParameterAutoBinding); tolua_function(tolua_S,"setUniformVec2v",lua_cocos2dx_GLProgramState_setUniformVec2v); tolua_function(tolua_S,"getUniformCount",lua_cocos2dx_GLProgramState_getUniformCount); tolua_function(tolua_S,"applyAttributes",lua_cocos2dx_GLProgramState_applyAttributes); tolua_function(tolua_S,"clone",lua_cocos2dx_GLProgramState_clone); tolua_function(tolua_S,"setGLProgram",lua_cocos2dx_GLProgramState_setGLProgram); tolua_function(tolua_S,"setUniformFloatv",lua_cocos2dx_GLProgramState_setUniformFloatv); tolua_function(tolua_S,"getGLProgram",lua_cocos2dx_GLProgramState_getGLProgram); tolua_function(tolua_S,"setUniformTexture",lua_cocos2dx_GLProgramState_setUniformTexture); tolua_function(tolua_S,"applyUniforms",lua_cocos2dx_GLProgramState_applyUniforms); tolua_function(tolua_S,"setUniformFloat",lua_cocos2dx_GLProgramState_setUniformFloat); tolua_function(tolua_S,"setUniformMat4",lua_cocos2dx_GLProgramState_setUniformMat4); tolua_function(tolua_S,"setUniformVec3v",lua_cocos2dx_GLProgramState_setUniformVec3v); tolua_function(tolua_S,"getVertexAttribCount",lua_cocos2dx_GLProgramState_getVertexAttribCount); tolua_function(tolua_S,"create", lua_cocos2dx_GLProgramState_create); tolua_function(tolua_S,"getOrCreateWithGLProgramName", lua_cocos2dx_GLProgramState_getOrCreateWithGLProgramName); tolua_function(tolua_S,"getOrCreateWithGLProgram", lua_cocos2dx_GLProgramState_getOrCreateWithGLProgram); tolua_function(tolua_S,"getOrCreateWithShaders", lua_cocos2dx_GLProgramState_getOrCreateWithShaders); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::GLProgramState).name(); g_luaType[typeName] = "cc.GLProgramState"; g_typeCast["GLProgramState"] = "cc.GLProgramState"; return 1; } int lua_cocos2dx_PolygonInfo_getFilename(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_getFilename'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_getFilename'", nullptr); return 0; } const std::string& ret = cobj->getFilename(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:getFilename",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_getFilename'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_getArea(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_getArea'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_getArea'", nullptr); return 0; } double ret = cobj->getArea(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:getArea",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_getArea'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_getRect(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_getRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_getRect'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:getRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_getRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_setFilename(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_setFilename'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.PolygonInfo:setFilename"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_setFilename'", nullptr); return 0; } cobj->setFilename(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:setFilename",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_setFilename'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_setQuads(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_setQuads'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::V3F_C4B_T2F_Quad* arg0 = nullptr; int arg1; #pragma warning NO CONVERSION TO NATIVE FOR V3F_C4B_T2F_Quad* ok = false; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.PolygonInfo:setQuads"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_setQuads'", nullptr); return 0; } cobj->setQuads(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:setQuads",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_setQuads'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_getVertCount(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_getVertCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_getVertCount'", nullptr); return 0; } unsigned int ret = cobj->getVertCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:getVertCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_getVertCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_getTrianglesCount(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_getTrianglesCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_getTrianglesCount'", nullptr); return 0; } unsigned int ret = cobj->getTrianglesCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:getTrianglesCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_getTrianglesCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_setQuad(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_setQuad'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::V3F_C4B_T2F_Quad* arg0 = nullptr; #pragma warning NO CONVERSION TO NATIVE FOR V3F_C4B_T2F_Quad* ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_setQuad'", nullptr); return 0; } cobj->setQuad(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:setQuad",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_setQuad'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_setTriangles(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_setTriangles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TrianglesCommand::Triangles arg0; #pragma warning NO CONVERSION TO NATIVE FOR Triangles ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_setTriangles'", nullptr); return 0; } cobj->setTriangles(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:setTriangles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_setTriangles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_setRect(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PolygonInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PolygonInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PolygonInfo_setRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.PolygonInfo:setRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_setRect'", nullptr); return 0; } cobj->setRect(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:setRect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_setRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PolygonInfo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::PolygonInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PolygonInfo_constructor'", nullptr); return 0; } cobj = new cocos2d::PolygonInfo(); tolua_pushusertype(tolua_S,(void*)cobj,"cc.PolygonInfo"); tolua_register_gc(tolua_S,lua_gettop(tolua_S)); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PolygonInfo:PolygonInfo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PolygonInfo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_PolygonInfo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (PolygonInfo)"); return 0; } int lua_register_cocos2dx_PolygonInfo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.PolygonInfo"); tolua_cclass(tolua_S,"PolygonInfo","cc.PolygonInfo","",nullptr); tolua_beginmodule(tolua_S,"PolygonInfo"); tolua_function(tolua_S,"new",lua_cocos2dx_PolygonInfo_constructor); tolua_function(tolua_S,"getFilename",lua_cocos2dx_PolygonInfo_getFilename); tolua_function(tolua_S,"getArea",lua_cocos2dx_PolygonInfo_getArea); tolua_function(tolua_S,"getRect",lua_cocos2dx_PolygonInfo_getRect); tolua_function(tolua_S,"setFilename",lua_cocos2dx_PolygonInfo_setFilename); tolua_function(tolua_S,"setQuads",lua_cocos2dx_PolygonInfo_setQuads); tolua_function(tolua_S,"getVertCount",lua_cocos2dx_PolygonInfo_getVertCount); tolua_function(tolua_S,"getTrianglesCount",lua_cocos2dx_PolygonInfo_getTrianglesCount); tolua_function(tolua_S,"setQuad",lua_cocos2dx_PolygonInfo_setQuad); tolua_function(tolua_S,"setTriangles",lua_cocos2dx_PolygonInfo_setTriangles); tolua_function(tolua_S,"setRect",lua_cocos2dx_PolygonInfo_setRect); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::PolygonInfo).name(); g_luaType[typeName] = "cc.PolygonInfo"; g_typeCast["PolygonInfo"] = "cc.PolygonInfo"; return 1; } int lua_cocos2dx_AutoPolygon_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::AutoPolygon* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.AutoPolygon:AutoPolygon"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AutoPolygon_constructor'", nullptr); return 0; } cobj = new cocos2d::AutoPolygon(arg0); tolua_pushusertype(tolua_S,(void*)cobj,"cc.AutoPolygon"); tolua_register_gc(tolua_S,lua_gettop(tolua_S)); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AutoPolygon:AutoPolygon",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AutoPolygon_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_AutoPolygon_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (AutoPolygon)"); return 0; } int lua_register_cocos2dx_AutoPolygon(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.AutoPolygon"); tolua_cclass(tolua_S,"AutoPolygon","cc.AutoPolygon","",nullptr); tolua_beginmodule(tolua_S,"AutoPolygon"); tolua_function(tolua_S,"new",lua_cocos2dx_AutoPolygon_constructor); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::AutoPolygon).name(); g_luaType[typeName] = "cc.AutoPolygon"; g_typeCast["AutoPolygon"] = "cc.AutoPolygon"; return 1; } int lua_cocos2dx_SpriteFrame_setAnchorPoint(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setAnchorPoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.SpriteFrame:setAnchorPoint"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setAnchorPoint'", nullptr); return 0; } cobj->setAnchorPoint(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setAnchorPoint",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setAnchorPoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteFrame:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setOffsetInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setOffsetInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.SpriteFrame:setOffsetInPixels"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setOffsetInPixels'", nullptr); return 0; } cobj->setOffsetInPixels(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setOffsetInPixels",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setOffsetInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getOriginalSizeInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getOriginalSizeInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getOriginalSizeInPixels'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getOriginalSizeInPixels(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getOriginalSizeInPixels",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getOriginalSizeInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setOriginalSize(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setOriginalSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.SpriteFrame:setOriginalSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setOriginalSize'", nullptr); return 0; } cobj->setOriginalSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setOriginalSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setOriginalSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getCenterRect(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getCenterRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getCenterRect'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getCenterRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getCenterRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getCenterRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setRectInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setRectInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.SpriteFrame:setRectInPixels"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setRectInPixels'", nullptr); return 0; } cobj->setRectInPixels(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setRectInPixels",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setRectInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getRect(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getRect'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setCenterRectInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setCenterRectInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.SpriteFrame:setCenterRectInPixels"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setCenterRectInPixels'", nullptr); return 0; } cobj->setCenterRectInPixels(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setCenterRectInPixels",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setCenterRectInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setOffset(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setOffset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.SpriteFrame:setOffset"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setOffset'", nullptr); return 0; } cobj->setOffset(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setOffset",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setOffset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_initWithTextureFilename(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_initWithTextureFilename'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 5) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrame:initWithTextureFilename"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.SpriteFrame:initWithTextureFilename"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.SpriteFrame:initWithTextureFilename"); if (!ok) { break; } cocos2d::Vec2 arg3; ok &= luaval_to_vec2(tolua_S, 5, &arg3, "cc.SpriteFrame:initWithTextureFilename"); if (!ok) { break; } cocos2d::Size arg4; ok &= luaval_to_size(tolua_S, 6, &arg4, "cc.SpriteFrame:initWithTextureFilename"); if (!ok) { break; } bool ret = cobj->initWithTextureFilename(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrame:initWithTextureFilename"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.SpriteFrame:initWithTextureFilename"); if (!ok) { break; } bool ret = cobj->initWithTextureFilename(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:initWithTextureFilename",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_initWithTextureFilename'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setRect(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.SpriteFrame:setRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setRect'", nullptr); return 0; } cobj->setRect(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setRect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_initWithTexture(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_initWithTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 5) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteFrame:initWithTexture"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.SpriteFrame:initWithTexture"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.SpriteFrame:initWithTexture"); if (!ok) { break; } cocos2d::Vec2 arg3; ok &= luaval_to_vec2(tolua_S, 5, &arg3, "cc.SpriteFrame:initWithTexture"); if (!ok) { break; } cocos2d::Size arg4; ok &= luaval_to_size(tolua_S, 6, &arg4, "cc.SpriteFrame:initWithTexture"); if (!ok) { break; } bool ret = cobj->initWithTexture(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteFrame:initWithTexture"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.SpriteFrame:initWithTexture"); if (!ok) { break; } bool ret = cobj->initWithTexture(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:initWithTexture",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_initWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getOriginalSize(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getOriginalSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getOriginalSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getOriginalSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getOriginalSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getOriginalSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_clone(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_clone'", nullptr); return 0; } cocos2d::SpriteFrame* ret = cobj->clone(); object_to_luaval<cocos2d::SpriteFrame>(tolua_S, "cc.SpriteFrame",(cocos2d::SpriteFrame*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getRectInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getRectInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getRectInPixels'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getRectInPixels(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getRectInPixels",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getRectInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_isRotated(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_isRotated'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_isRotated'", nullptr); return 0; } bool ret = cobj->isRotated(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:isRotated",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_isRotated'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_hasCenterRect(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_hasCenterRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_hasCenterRect'", nullptr); return 0; } bool ret = cobj->hasCenterRect(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:hasCenterRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_hasCenterRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setRotated(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setRotated'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.SpriteFrame:setRotated"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setRotated'", nullptr); return 0; } cobj->setRotated(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setRotated",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setRotated'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getOffset(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getOffset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getOffset'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getOffset(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getOffset",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getOffset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_setOriginalSizeInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_setOriginalSizeInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.SpriteFrame:setOriginalSizeInPixels"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_setOriginalSizeInPixels'", nullptr); return 0; } cobj->setOriginalSizeInPixels(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:setOriginalSizeInPixels",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_setOriginalSizeInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getAnchorPoint(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getAnchorPoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getAnchorPoint'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getAnchorPoint(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getAnchorPoint",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getAnchorPoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_hasAnchorPoint(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_hasAnchorPoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_hasAnchorPoint'", nullptr); return 0; } bool ret = cobj->hasAnchorPoint(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:hasAnchorPoint",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_hasAnchorPoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_getOffsetInPixels(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrame_getOffsetInPixels'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_getOffsetInPixels'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getOffsetInPixels(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:getOffsetInPixels",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_getOffsetInPixels'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 5) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrame:create"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.SpriteFrame:create"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.SpriteFrame:create"); if (!ok) { break; } cocos2d::Vec2 arg3; ok &= luaval_to_vec2(tolua_S, 5, &arg3, "cc.SpriteFrame:create"); if (!ok) { break; } cocos2d::Size arg4; ok &= luaval_to_size(tolua_S, 6, &arg4, "cc.SpriteFrame:create"); if (!ok) { break; } cocos2d::SpriteFrame* ret = cocos2d::SpriteFrame::create(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::SpriteFrame>(tolua_S, "cc.SpriteFrame",(cocos2d::SpriteFrame*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrame:create"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.SpriteFrame:create"); if (!ok) { break; } cocos2d::SpriteFrame* ret = cocos2d::SpriteFrame::create(arg0, arg1); object_to_luaval<cocos2d::SpriteFrame>(tolua_S, "cc.SpriteFrame",(cocos2d::SpriteFrame*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.SpriteFrame:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_createWithTexture(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SpriteFrame",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 5) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteFrame:createWithTexture"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.SpriteFrame:createWithTexture"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.SpriteFrame:createWithTexture"); if (!ok) { break; } cocos2d::Vec2 arg3; ok &= luaval_to_vec2(tolua_S, 5, &arg3, "cc.SpriteFrame:createWithTexture"); if (!ok) { break; } cocos2d::Size arg4; ok &= luaval_to_size(tolua_S, 6, &arg4, "cc.SpriteFrame:createWithTexture"); if (!ok) { break; } cocos2d::SpriteFrame* ret = cocos2d::SpriteFrame::createWithTexture(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::SpriteFrame>(tolua_S, "cc.SpriteFrame",(cocos2d::SpriteFrame*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteFrame:createWithTexture"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.SpriteFrame:createWithTexture"); if (!ok) { break; } cocos2d::SpriteFrame* ret = cocos2d::SpriteFrame::createWithTexture(arg0, arg1); object_to_luaval<cocos2d::SpriteFrame>(tolua_S, "cc.SpriteFrame",(cocos2d::SpriteFrame*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.SpriteFrame:createWithTexture",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_createWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrame_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrame_constructor'", nullptr); return 0; } cobj = new cocos2d::SpriteFrame(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.SpriteFrame"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrame:SpriteFrame",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrame_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_SpriteFrame_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SpriteFrame)"); return 0; } int lua_register_cocos2dx_SpriteFrame(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.SpriteFrame"); tolua_cclass(tolua_S,"SpriteFrame","cc.SpriteFrame","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"SpriteFrame"); tolua_function(tolua_S,"new",lua_cocos2dx_SpriteFrame_constructor); tolua_function(tolua_S,"setAnchorPoint",lua_cocos2dx_SpriteFrame_setAnchorPoint); tolua_function(tolua_S,"setTexture",lua_cocos2dx_SpriteFrame_setTexture); tolua_function(tolua_S,"getTexture",lua_cocos2dx_SpriteFrame_getTexture); tolua_function(tolua_S,"setOffsetInPixels",lua_cocos2dx_SpriteFrame_setOffsetInPixels); tolua_function(tolua_S,"getOriginalSizeInPixels",lua_cocos2dx_SpriteFrame_getOriginalSizeInPixels); tolua_function(tolua_S,"setOriginalSize",lua_cocos2dx_SpriteFrame_setOriginalSize); tolua_function(tolua_S,"getCenterRect",lua_cocos2dx_SpriteFrame_getCenterRect); tolua_function(tolua_S,"setRectInPixels",lua_cocos2dx_SpriteFrame_setRectInPixels); tolua_function(tolua_S,"getRect",lua_cocos2dx_SpriteFrame_getRect); tolua_function(tolua_S,"setCenterRectInPixels",lua_cocos2dx_SpriteFrame_setCenterRectInPixels); tolua_function(tolua_S,"setOffset",lua_cocos2dx_SpriteFrame_setOffset); tolua_function(tolua_S,"initWithTextureFilename",lua_cocos2dx_SpriteFrame_initWithTextureFilename); tolua_function(tolua_S,"setRect",lua_cocos2dx_SpriteFrame_setRect); tolua_function(tolua_S,"initWithTexture",lua_cocos2dx_SpriteFrame_initWithTexture); tolua_function(tolua_S,"getOriginalSize",lua_cocos2dx_SpriteFrame_getOriginalSize); tolua_function(tolua_S,"clone",lua_cocos2dx_SpriteFrame_clone); tolua_function(tolua_S,"getRectInPixels",lua_cocos2dx_SpriteFrame_getRectInPixels); tolua_function(tolua_S,"isRotated",lua_cocos2dx_SpriteFrame_isRotated); tolua_function(tolua_S,"hasCenterRect",lua_cocos2dx_SpriteFrame_hasCenterRect); tolua_function(tolua_S,"setRotated",lua_cocos2dx_SpriteFrame_setRotated); tolua_function(tolua_S,"getOffset",lua_cocos2dx_SpriteFrame_getOffset); tolua_function(tolua_S,"setOriginalSizeInPixels",lua_cocos2dx_SpriteFrame_setOriginalSizeInPixels); tolua_function(tolua_S,"getAnchorPoint",lua_cocos2dx_SpriteFrame_getAnchorPoint); tolua_function(tolua_S,"hasAnchorPoint",lua_cocos2dx_SpriteFrame_hasAnchorPoint); tolua_function(tolua_S,"getOffsetInPixels",lua_cocos2dx_SpriteFrame_getOffsetInPixels); tolua_function(tolua_S,"create", lua_cocos2dx_SpriteFrame_create); tolua_function(tolua_S,"createWithTexture", lua_cocos2dx_SpriteFrame_createWithTexture); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::SpriteFrame).name(); g_luaType[typeName] = "cc.SpriteFrame"; g_typeCast["SpriteFrame"] = "cc.SpriteFrame"; return 1; } int lua_cocos2dx_AnimationFrame_setSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationFrame_setSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.AnimationFrame:setSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_setSpriteFrame'", nullptr); return 0; } cobj->setSpriteFrame(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:setSpriteFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_setSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_getUserInfo(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationFrame_getUserInfo'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::ValueMap& ret = cobj->getUserInfo(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::ValueMap& ret = cobj->getUserInfo(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:getUserInfo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_getUserInfo'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_setDelayUnits(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationFrame_setDelayUnits'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.AnimationFrame:setDelayUnits"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_setDelayUnits'", nullptr); return 0; } cobj->setDelayUnits(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:setDelayUnits",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_setDelayUnits'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_clone(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationFrame_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_clone'", nullptr); return 0; } cocos2d::AnimationFrame* ret = cobj->clone(); object_to_luaval<cocos2d::AnimationFrame>(tolua_S, "cc.AnimationFrame",(cocos2d::AnimationFrame*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_getSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationFrame_getSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_getSpriteFrame'", nullptr); return 0; } cocos2d::SpriteFrame* ret = cobj->getSpriteFrame(); object_to_luaval<cocos2d::SpriteFrame>(tolua_S, "cc.SpriteFrame",(cocos2d::SpriteFrame*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:getSpriteFrame",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_getSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_getDelayUnits(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationFrame_getDelayUnits'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_getDelayUnits'", nullptr); return 0; } double ret = cobj->getDelayUnits(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:getDelayUnits",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_getDelayUnits'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_setUserInfo(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationFrame_setUserInfo'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.AnimationFrame:setUserInfo"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_setUserInfo'", nullptr); return 0; } cobj->setUserInfo(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:setUserInfo",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_setUserInfo'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_initWithSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationFrame*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationFrame_initWithSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::SpriteFrame* arg0 = nullptr; double arg1; cocos2d::ValueMap arg2; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.AnimationFrame:initWithSpriteFrame"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.AnimationFrame:initWithSpriteFrame"); ok &= luaval_to_ccvaluemap(tolua_S, 4, &arg2, "cc.AnimationFrame:initWithSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_initWithSpriteFrame'", nullptr); return 0; } bool ret = cobj->initWithSpriteFrame(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:initWithSpriteFrame",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_initWithSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.AnimationFrame",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { cocos2d::SpriteFrame* arg0 = nullptr; double arg1; cocos2d::ValueMap arg2; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.AnimationFrame:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.AnimationFrame:create"); ok &= luaval_to_ccvaluemap(tolua_S, 4, &arg2, "cc.AnimationFrame:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_create'", nullptr); return 0; } cocos2d::AnimationFrame* ret = cocos2d::AnimationFrame::create(arg0, arg1, arg2); object_to_luaval<cocos2d::AnimationFrame>(tolua_S, "cc.AnimationFrame",(cocos2d::AnimationFrame*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.AnimationFrame:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationFrame_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationFrame* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationFrame_constructor'", nullptr); return 0; } cobj = new cocos2d::AnimationFrame(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.AnimationFrame"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationFrame:AnimationFrame",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationFrame_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_AnimationFrame_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (AnimationFrame)"); return 0; } int lua_register_cocos2dx_AnimationFrame(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.AnimationFrame"); tolua_cclass(tolua_S,"AnimationFrame","cc.AnimationFrame","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"AnimationFrame"); tolua_function(tolua_S,"new",lua_cocos2dx_AnimationFrame_constructor); tolua_function(tolua_S,"setSpriteFrame",lua_cocos2dx_AnimationFrame_setSpriteFrame); tolua_function(tolua_S,"getUserInfo",lua_cocos2dx_AnimationFrame_getUserInfo); tolua_function(tolua_S,"setDelayUnits",lua_cocos2dx_AnimationFrame_setDelayUnits); tolua_function(tolua_S,"clone",lua_cocos2dx_AnimationFrame_clone); tolua_function(tolua_S,"getSpriteFrame",lua_cocos2dx_AnimationFrame_getSpriteFrame); tolua_function(tolua_S,"getDelayUnits",lua_cocos2dx_AnimationFrame_getDelayUnits); tolua_function(tolua_S,"setUserInfo",lua_cocos2dx_AnimationFrame_setUserInfo); tolua_function(tolua_S,"initWithSpriteFrame",lua_cocos2dx_AnimationFrame_initWithSpriteFrame); tolua_function(tolua_S,"create", lua_cocos2dx_AnimationFrame_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::AnimationFrame).name(); g_luaType[typeName] = "cc.AnimationFrame"; g_typeCast["AnimationFrame"] = "cc.AnimationFrame"; return 1; } int lua_cocos2dx_Animation_getLoops(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_getLoops'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_getLoops'", nullptr); return 0; } unsigned int ret = cobj->getLoops(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:getLoops",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_getLoops'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_addSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_addSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.Animation:addSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_addSpriteFrame'", nullptr); return 0; } cobj->addSpriteFrame(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:addSpriteFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_addSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_setRestoreOriginalFrame(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_setRestoreOriginalFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Animation:setRestoreOriginalFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_setRestoreOriginalFrame'", nullptr); return 0; } cobj->setRestoreOriginalFrame(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:setRestoreOriginalFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_setRestoreOriginalFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_clone(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_clone'", nullptr); return 0; } cocos2d::Animation* ret = cobj->clone(); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_getDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_getDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_getDuration'", nullptr); return 0; } double ret = cobj->getDuration(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:getDuration",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_getDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_initWithAnimationFrames(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_initWithAnimationFrames'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Vector<cocos2d::AnimationFrame *> arg0; double arg1; unsigned int arg2; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:initWithAnimationFrames"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Animation:initWithAnimationFrames"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Animation:initWithAnimationFrames"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_initWithAnimationFrames'", nullptr); return 0; } bool ret = cobj->initWithAnimationFrames(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:initWithAnimationFrames",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_initWithAnimationFrames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_init(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_setFrames(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_setFrames'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::AnimationFrame *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:setFrames"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_setFrames'", nullptr); return 0; } cobj->setFrames(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:setFrames",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_setFrames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_getFrames(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_getFrames'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_getFrames'", nullptr); return 0; } const cocos2d::Vector<cocos2d::AnimationFrame *>& ret = cobj->getFrames(); ccvector_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:getFrames",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_getFrames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_setLoops(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_setLoops'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned int arg0; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.Animation:setLoops"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_setLoops'", nullptr); return 0; } cobj->setLoops(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:setLoops",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_setLoops'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_setDelayPerUnit(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_setDelayPerUnit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Animation:setDelayPerUnit"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_setDelayPerUnit'", nullptr); return 0; } cobj->setDelayPerUnit(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:setDelayPerUnit",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_setDelayPerUnit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_addSpriteFrameWithFile(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_addSpriteFrameWithFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Animation:addSpriteFrameWithFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_addSpriteFrameWithFile'", nullptr); return 0; } cobj->addSpriteFrameWithFile(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:addSpriteFrameWithFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_addSpriteFrameWithFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_getTotalDelayUnits(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_getTotalDelayUnits'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_getTotalDelayUnits'", nullptr); return 0; } double ret = cobj->getTotalDelayUnits(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:getTotalDelayUnits",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_getTotalDelayUnits'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_getDelayPerUnit(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_getDelayPerUnit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_getDelayPerUnit'", nullptr); return 0; } double ret = cobj->getDelayPerUnit(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:getDelayPerUnit",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_getDelayPerUnit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_initWithSpriteFrames(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_initWithSpriteFrames'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::SpriteFrame *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:initWithSpriteFrames"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_initWithSpriteFrames'", nullptr); return 0; } bool ret = cobj->initWithSpriteFrames(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 2) { cocos2d::Vector<cocos2d::SpriteFrame *> arg0; double arg1; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:initWithSpriteFrames"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Animation:initWithSpriteFrames"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_initWithSpriteFrames'", nullptr); return 0; } bool ret = cobj->initWithSpriteFrames(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 3) { cocos2d::Vector<cocos2d::SpriteFrame *> arg0; double arg1; unsigned int arg2; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:initWithSpriteFrames"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Animation:initWithSpriteFrames"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Animation:initWithSpriteFrames"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_initWithSpriteFrames'", nullptr); return 0; } bool ret = cobj->initWithSpriteFrames(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:initWithSpriteFrames",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_initWithSpriteFrames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_getRestoreOriginalFrame(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_getRestoreOriginalFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_getRestoreOriginalFrame'", nullptr); return 0; } bool ret = cobj->getRestoreOriginalFrame(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:getRestoreOriginalFrame",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_getRestoreOriginalFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_addSpriteFrameWithTexture(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animation*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animation_addSpriteFrameWithTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; cocos2d::Rect arg1; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Animation:addSpriteFrameWithTexture"); ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Animation:addSpriteFrameWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_addSpriteFrameWithTexture'", nullptr); return 0; } cobj->addSpriteFrameWithTexture(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:addSpriteFrameWithTexture",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_addSpriteFrameWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { cocos2d::Vector<cocos2d::AnimationFrame *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Animation:create"); if (!ok) { break; } cocos2d::Animation* ret = cocos2d::Animation::create(arg0, arg1); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { cocos2d::Vector<cocos2d::AnimationFrame *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Animation:create"); if (!ok) { break; } unsigned int arg2; ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Animation:create"); if (!ok) { break; } cocos2d::Animation* ret = cocos2d::Animation::create(arg0, arg1, arg2); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } } while (0); ok = true; do { if (argc == 0) { cocos2d::Animation* ret = cocos2d::Animation::create(); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.Animation:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_createWithSpriteFrames(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Animation",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Vector<cocos2d::SpriteFrame *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:createWithSpriteFrames"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_createWithSpriteFrames'", nullptr); return 0; } cocos2d::Animation* ret = cocos2d::Animation::createWithSpriteFrames(arg0); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } if (argc == 2) { cocos2d::Vector<cocos2d::SpriteFrame *> arg0; double arg1; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:createWithSpriteFrames"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Animation:createWithSpriteFrames"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_createWithSpriteFrames'", nullptr); return 0; } cocos2d::Animation* ret = cocos2d::Animation::createWithSpriteFrames(arg0, arg1); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } if (argc == 3) { cocos2d::Vector<cocos2d::SpriteFrame *> arg0; double arg1; unsigned int arg2; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Animation:createWithSpriteFrames"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Animation:createWithSpriteFrames"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Animation:createWithSpriteFrames"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_createWithSpriteFrames'", nullptr); return 0; } cocos2d::Animation* ret = cocos2d::Animation::createWithSpriteFrames(arg0, arg1, arg2); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Animation:createWithSpriteFrames",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_createWithSpriteFrames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animation_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Animation* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animation_constructor'", nullptr); return 0; } cobj = new cocos2d::Animation(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Animation"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animation:Animation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animation_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Animation_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Animation)"); return 0; } int lua_register_cocos2dx_Animation(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Animation"); tolua_cclass(tolua_S,"Animation","cc.Animation","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"Animation"); tolua_function(tolua_S,"new",lua_cocos2dx_Animation_constructor); tolua_function(tolua_S,"getLoops",lua_cocos2dx_Animation_getLoops); tolua_function(tolua_S,"addSpriteFrame",lua_cocos2dx_Animation_addSpriteFrame); tolua_function(tolua_S,"setRestoreOriginalFrame",lua_cocos2dx_Animation_setRestoreOriginalFrame); tolua_function(tolua_S,"clone",lua_cocos2dx_Animation_clone); tolua_function(tolua_S,"getDuration",lua_cocos2dx_Animation_getDuration); tolua_function(tolua_S,"initWithAnimationFrames",lua_cocos2dx_Animation_initWithAnimationFrames); tolua_function(tolua_S,"init",lua_cocos2dx_Animation_init); tolua_function(tolua_S,"setFrames",lua_cocos2dx_Animation_setFrames); tolua_function(tolua_S,"getFrames",lua_cocos2dx_Animation_getFrames); tolua_function(tolua_S,"setLoops",lua_cocos2dx_Animation_setLoops); tolua_function(tolua_S,"setDelayPerUnit",lua_cocos2dx_Animation_setDelayPerUnit); tolua_function(tolua_S,"addSpriteFrameWithFile",lua_cocos2dx_Animation_addSpriteFrameWithFile); tolua_function(tolua_S,"getTotalDelayUnits",lua_cocos2dx_Animation_getTotalDelayUnits); tolua_function(tolua_S,"getDelayPerUnit",lua_cocos2dx_Animation_getDelayPerUnit); tolua_function(tolua_S,"initWithSpriteFrames",lua_cocos2dx_Animation_initWithSpriteFrames); tolua_function(tolua_S,"getRestoreOriginalFrame",lua_cocos2dx_Animation_getRestoreOriginalFrame); tolua_function(tolua_S,"addSpriteFrameWithTexture",lua_cocos2dx_Animation_addSpriteFrameWithTexture); tolua_function(tolua_S,"create", lua_cocos2dx_Animation_create); tolua_function(tolua_S,"createWithSpriteFrames", lua_cocos2dx_Animation_createWithSpriteFrames); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Animation).name(); g_luaType[typeName] = "cc.Animation"; g_typeCast["Animation"] = "cc.Animation"; return 1; } int lua_cocos2dx_ActionInterval_getAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::ActionInterval* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionInterval",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionInterval*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionInterval_getAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionInterval_getAmplitudeRate'", nullptr); return 0; } double ret = cobj->getAmplitudeRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionInterval:getAmplitudeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionInterval_getAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionInterval_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ActionInterval* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionInterval",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionInterval*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionInterval_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ActionInterval:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionInterval_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionInterval:initWithDuration",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionInterval_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionInterval_setAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::ActionInterval* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionInterval",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionInterval*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionInterval_setAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ActionInterval:setAmplitudeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionInterval_setAmplitudeRate'", nullptr); return 0; } cobj->setAmplitudeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionInterval:setAmplitudeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionInterval_setAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionInterval_getElapsed(lua_State* tolua_S) { int argc = 0; cocos2d::ActionInterval* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionInterval",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionInterval*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionInterval_getElapsed'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionInterval_getElapsed'", nullptr); return 0; } double ret = cobj->getElapsed(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionInterval:getElapsed",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionInterval_getElapsed'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ActionInterval_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ActionInterval)"); return 0; } int lua_register_cocos2dx_ActionInterval(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ActionInterval"); tolua_cclass(tolua_S,"ActionInterval","cc.ActionInterval","cc.FiniteTimeAction",nullptr); tolua_beginmodule(tolua_S,"ActionInterval"); tolua_function(tolua_S,"getAmplitudeRate",lua_cocos2dx_ActionInterval_getAmplitudeRate); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ActionInterval_initWithDuration); tolua_function(tolua_S,"setAmplitudeRate",lua_cocos2dx_ActionInterval_setAmplitudeRate); tolua_function(tolua_S,"getElapsed",lua_cocos2dx_ActionInterval_getElapsed); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ActionInterval).name(); g_luaType[typeName] = "cc.ActionInterval"; g_typeCast["ActionInterval"] = "cc.ActionInterval"; return 1; } int lua_cocos2dx_Sequence_init(lua_State* tolua_S) { int argc = 0; cocos2d::Sequence* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sequence",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sequence*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sequence_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::FiniteTimeAction *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Sequence:init"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sequence_init'", nullptr); return 0; } bool ret = cobj->init(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sequence:init",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sequence_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sequence_initWithTwoActions(lua_State* tolua_S) { int argc = 0; cocos2d::Sequence* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sequence",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sequence*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sequence_initWithTwoActions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::FiniteTimeAction* arg0 = nullptr; cocos2d::FiniteTimeAction* arg1 = nullptr; ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 2, "cc.FiniteTimeAction",&arg0, "cc.Sequence:initWithTwoActions"); ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 3, "cc.FiniteTimeAction",&arg1, "cc.Sequence:initWithTwoActions"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sequence_initWithTwoActions'", nullptr); return 0; } bool ret = cobj->initWithTwoActions(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sequence:initWithTwoActions",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sequence_initWithTwoActions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sequence_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Sequence* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sequence_constructor'", nullptr); return 0; } cobj = new cocos2d::Sequence(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Sequence"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sequence:Sequence",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sequence_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Sequence_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Sequence)"); return 0; } int lua_register_cocos2dx_Sequence(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Sequence"); tolua_cclass(tolua_S,"Sequence","cc.Sequence","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"Sequence"); tolua_function(tolua_S,"new",lua_cocos2dx_Sequence_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_Sequence_init); tolua_function(tolua_S,"initWithTwoActions",lua_cocos2dx_Sequence_initWithTwoActions); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Sequence).name(); g_luaType[typeName] = "cc.Sequence"; g_typeCast["Sequence"] = "cc.Sequence"; return 1; } int lua_cocos2dx_Repeat_setInnerAction(lua_State* tolua_S) { int argc = 0; cocos2d::Repeat* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Repeat",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Repeat*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Repeat_setInnerAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::FiniteTimeAction* arg0 = nullptr; ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 2, "cc.FiniteTimeAction",&arg0, "cc.Repeat:setInnerAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Repeat_setInnerAction'", nullptr); return 0; } cobj->setInnerAction(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Repeat:setInnerAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Repeat_setInnerAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Repeat_initWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::Repeat* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Repeat",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Repeat*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Repeat_initWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::FiniteTimeAction* arg0 = nullptr; unsigned int arg1; ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 2, "cc.FiniteTimeAction",&arg0, "cc.Repeat:initWithAction"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.Repeat:initWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Repeat_initWithAction'", nullptr); return 0; } bool ret = cobj->initWithAction(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Repeat:initWithAction",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Repeat_initWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Repeat_getInnerAction(lua_State* tolua_S) { int argc = 0; cocos2d::Repeat* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Repeat",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Repeat*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Repeat_getInnerAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Repeat_getInnerAction'", nullptr); return 0; } cocos2d::FiniteTimeAction* ret = cobj->getInnerAction(); object_to_luaval<cocos2d::FiniteTimeAction>(tolua_S, "cc.FiniteTimeAction",(cocos2d::FiniteTimeAction*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Repeat:getInnerAction",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Repeat_getInnerAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Repeat_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Repeat",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::FiniteTimeAction* arg0 = nullptr; unsigned int arg1; ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 2, "cc.FiniteTimeAction",&arg0, "cc.Repeat:create"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.Repeat:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Repeat_create'", nullptr); return 0; } cocos2d::Repeat* ret = cocos2d::Repeat::create(arg0, arg1); object_to_luaval<cocos2d::Repeat>(tolua_S, "cc.Repeat",(cocos2d::Repeat*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Repeat:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Repeat_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Repeat_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Repeat* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Repeat_constructor'", nullptr); return 0; } cobj = new cocos2d::Repeat(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Repeat"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Repeat:Repeat",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Repeat_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Repeat_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Repeat)"); return 0; } int lua_register_cocos2dx_Repeat(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Repeat"); tolua_cclass(tolua_S,"Repeat","cc.Repeat","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"Repeat"); tolua_function(tolua_S,"new",lua_cocos2dx_Repeat_constructor); tolua_function(tolua_S,"setInnerAction",lua_cocos2dx_Repeat_setInnerAction); tolua_function(tolua_S,"initWithAction",lua_cocos2dx_Repeat_initWithAction); tolua_function(tolua_S,"getInnerAction",lua_cocos2dx_Repeat_getInnerAction); tolua_function(tolua_S,"create", lua_cocos2dx_Repeat_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Repeat).name(); g_luaType[typeName] = "cc.Repeat"; g_typeCast["Repeat"] = "cc.Repeat"; return 1; } int lua_cocos2dx_RepeatForever_setInnerAction(lua_State* tolua_S) { int argc = 0; cocos2d::RepeatForever* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RepeatForever",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RepeatForever*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RepeatForever_setInnerAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.RepeatForever:setInnerAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RepeatForever_setInnerAction'", nullptr); return 0; } cobj->setInnerAction(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RepeatForever:setInnerAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RepeatForever_setInnerAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RepeatForever_initWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::RepeatForever* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RepeatForever",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RepeatForever*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RepeatForever_initWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.RepeatForever:initWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RepeatForever_initWithAction'", nullptr); return 0; } bool ret = cobj->initWithAction(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RepeatForever:initWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RepeatForever_initWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RepeatForever_getInnerAction(lua_State* tolua_S) { int argc = 0; cocos2d::RepeatForever* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RepeatForever",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RepeatForever*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RepeatForever_getInnerAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RepeatForever_getInnerAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->getInnerAction(); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RepeatForever:getInnerAction",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RepeatForever_getInnerAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RepeatForever_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.RepeatForever",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.RepeatForever:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RepeatForever_create'", nullptr); return 0; } cocos2d::RepeatForever* ret = cocos2d::RepeatForever::create(arg0); object_to_luaval<cocos2d::RepeatForever>(tolua_S, "cc.RepeatForever",(cocos2d::RepeatForever*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.RepeatForever:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RepeatForever_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RepeatForever_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::RepeatForever* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RepeatForever_constructor'", nullptr); return 0; } cobj = new cocos2d::RepeatForever(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.RepeatForever"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RepeatForever:RepeatForever",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RepeatForever_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_RepeatForever_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (RepeatForever)"); return 0; } int lua_register_cocos2dx_RepeatForever(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.RepeatForever"); tolua_cclass(tolua_S,"RepeatForever","cc.RepeatForever","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"RepeatForever"); tolua_function(tolua_S,"new",lua_cocos2dx_RepeatForever_constructor); tolua_function(tolua_S,"setInnerAction",lua_cocos2dx_RepeatForever_setInnerAction); tolua_function(tolua_S,"initWithAction",lua_cocos2dx_RepeatForever_initWithAction); tolua_function(tolua_S,"getInnerAction",lua_cocos2dx_RepeatForever_getInnerAction); tolua_function(tolua_S,"create", lua_cocos2dx_RepeatForever_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::RepeatForever).name(); g_luaType[typeName] = "cc.RepeatForever"; g_typeCast["RepeatForever"] = "cc.RepeatForever"; return 1; } int lua_cocos2dx_Spawn_init(lua_State* tolua_S) { int argc = 0; cocos2d::Spawn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Spawn",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Spawn*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Spawn_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::FiniteTimeAction *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Spawn:init"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Spawn_init'", nullptr); return 0; } bool ret = cobj->init(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Spawn:init",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Spawn_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Spawn_initWithTwoActions(lua_State* tolua_S) { int argc = 0; cocos2d::Spawn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Spawn",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Spawn*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Spawn_initWithTwoActions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::FiniteTimeAction* arg0 = nullptr; cocos2d::FiniteTimeAction* arg1 = nullptr; ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 2, "cc.FiniteTimeAction",&arg0, "cc.Spawn:initWithTwoActions"); ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 3, "cc.FiniteTimeAction",&arg1, "cc.Spawn:initWithTwoActions"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Spawn_initWithTwoActions'", nullptr); return 0; } bool ret = cobj->initWithTwoActions(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Spawn:initWithTwoActions",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Spawn_initWithTwoActions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Spawn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Spawn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Spawn_constructor'", nullptr); return 0; } cobj = new cocos2d::Spawn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Spawn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Spawn:Spawn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Spawn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Spawn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Spawn)"); return 0; } int lua_register_cocos2dx_Spawn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Spawn"); tolua_cclass(tolua_S,"Spawn","cc.Spawn","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"Spawn"); tolua_function(tolua_S,"new",lua_cocos2dx_Spawn_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_Spawn_init); tolua_function(tolua_S,"initWithTwoActions",lua_cocos2dx_Spawn_initWithTwoActions); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Spawn).name(); g_luaType[typeName] = "cc.Spawn"; g_typeCast["Spawn"] = "cc.Spawn"; return 1; } int lua_cocos2dx_RotateTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::RotateTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RotateTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RotateTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RotateTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateTo:initWithDuration"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.RotateTo:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateTo:initWithDuration"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RotateTo:initWithDuration"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.RotateTo:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RotateTo:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RotateTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RotateTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.RotateTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateTo:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RotateTo:create"); if (!ok) { break; } cocos2d::RotateTo* ret = cocos2d::RotateTo::create(arg0, arg1); object_to_luaval<cocos2d::RotateTo>(tolua_S, "cc.RotateTo",(cocos2d::RotateTo*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateTo:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RotateTo:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.RotateTo:create"); if (!ok) { break; } cocos2d::RotateTo* ret = cocos2d::RotateTo::create(arg0, arg1, arg2); object_to_luaval<cocos2d::RotateTo>(tolua_S, "cc.RotateTo",(cocos2d::RotateTo*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateTo:create"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.RotateTo:create"); if (!ok) { break; } cocos2d::RotateTo* ret = cocos2d::RotateTo::create(arg0, arg1); object_to_luaval<cocos2d::RotateTo>(tolua_S, "cc.RotateTo",(cocos2d::RotateTo*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.RotateTo:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RotateTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RotateTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::RotateTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RotateTo_constructor'", nullptr); return 0; } cobj = new cocos2d::RotateTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.RotateTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RotateTo:RotateTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RotateTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_RotateTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (RotateTo)"); return 0; } int lua_register_cocos2dx_RotateTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.RotateTo"); tolua_cclass(tolua_S,"RotateTo","cc.RotateTo","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"RotateTo"); tolua_function(tolua_S,"new",lua_cocos2dx_RotateTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_RotateTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_RotateTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::RotateTo).name(); g_luaType[typeName] = "cc.RotateTo"; g_typeCast["RotateTo"] = "cc.RotateTo"; return 1; } int lua_cocos2dx_RotateBy_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::RotateBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RotateBy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RotateBy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RotateBy_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateBy:initWithDuration"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RotateBy:initWithDuration"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.RotateBy:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateBy:initWithDuration"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RotateBy:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateBy:initWithDuration"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.RotateBy:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RotateBy:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RotateBy_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RotateBy_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.RotateBy",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateBy:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RotateBy:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.RotateBy:create"); if (!ok) { break; } cocos2d::RotateBy* ret = cocos2d::RotateBy::create(arg0, arg1, arg2); object_to_luaval<cocos2d::RotateBy>(tolua_S, "cc.RotateBy",(cocos2d::RotateBy*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateBy:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RotateBy:create"); if (!ok) { break; } cocos2d::RotateBy* ret = cocos2d::RotateBy::create(arg0, arg1); object_to_luaval<cocos2d::RotateBy>(tolua_S, "cc.RotateBy",(cocos2d::RotateBy*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RotateBy:create"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.RotateBy:create"); if (!ok) { break; } cocos2d::RotateBy* ret = cocos2d::RotateBy::create(arg0, arg1); object_to_luaval<cocos2d::RotateBy>(tolua_S, "cc.RotateBy",(cocos2d::RotateBy*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.RotateBy:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RotateBy_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RotateBy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::RotateBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RotateBy_constructor'", nullptr); return 0; } cobj = new cocos2d::RotateBy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.RotateBy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RotateBy:RotateBy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RotateBy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_RotateBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (RotateBy)"); return 0; } int lua_register_cocos2dx_RotateBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.RotateBy"); tolua_cclass(tolua_S,"RotateBy","cc.RotateBy","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"RotateBy"); tolua_function(tolua_S,"new",lua_cocos2dx_RotateBy_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_RotateBy_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_RotateBy_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::RotateBy).name(); g_luaType[typeName] = "cc.RotateBy"; g_typeCast["RotateBy"] = "cc.RotateBy"; return 1; } int lua_cocos2dx_MoveBy_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::MoveBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MoveBy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MoveBy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MoveBy_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MoveBy:initWithDuration"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.MoveBy:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MoveBy:initWithDuration"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.MoveBy:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MoveBy:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MoveBy_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MoveBy_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.MoveBy",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MoveBy:create"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.MoveBy:create"); if (!ok) { break; } cocos2d::MoveBy* ret = cocos2d::MoveBy::create(arg0, arg1); object_to_luaval<cocos2d::MoveBy>(tolua_S, "cc.MoveBy",(cocos2d::MoveBy*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MoveBy:create"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.MoveBy:create"); if (!ok) { break; } cocos2d::MoveBy* ret = cocos2d::MoveBy::create(arg0, arg1); object_to_luaval<cocos2d::MoveBy>(tolua_S, "cc.MoveBy",(cocos2d::MoveBy*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.MoveBy:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MoveBy_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MoveBy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MoveBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MoveBy_constructor'", nullptr); return 0; } cobj = new cocos2d::MoveBy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MoveBy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MoveBy:MoveBy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MoveBy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MoveBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MoveBy)"); return 0; } int lua_register_cocos2dx_MoveBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MoveBy"); tolua_cclass(tolua_S,"MoveBy","cc.MoveBy","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"MoveBy"); tolua_function(tolua_S,"new",lua_cocos2dx_MoveBy_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_MoveBy_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_MoveBy_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MoveBy).name(); g_luaType[typeName] = "cc.MoveBy"; g_typeCast["MoveBy"] = "cc.MoveBy"; return 1; } int lua_cocos2dx_MoveTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::MoveTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MoveTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MoveTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MoveTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MoveTo:initWithDuration"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.MoveTo:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MoveTo:initWithDuration"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.MoveTo:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MoveTo:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MoveTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MoveTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.MoveTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MoveTo:create"); if (!ok) { break; } cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.MoveTo:create"); if (!ok) { break; } cocos2d::MoveTo* ret = cocos2d::MoveTo::create(arg0, arg1); object_to_luaval<cocos2d::MoveTo>(tolua_S, "cc.MoveTo",(cocos2d::MoveTo*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MoveTo:create"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.MoveTo:create"); if (!ok) { break; } cocos2d::MoveTo* ret = cocos2d::MoveTo::create(arg0, arg1); object_to_luaval<cocos2d::MoveTo>(tolua_S, "cc.MoveTo",(cocos2d::MoveTo*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.MoveTo:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MoveTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MoveTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MoveTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MoveTo_constructor'", nullptr); return 0; } cobj = new cocos2d::MoveTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MoveTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MoveTo:MoveTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MoveTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MoveTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MoveTo)"); return 0; } int lua_register_cocos2dx_MoveTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MoveTo"); tolua_cclass(tolua_S,"MoveTo","cc.MoveTo","cc.MoveBy",nullptr); tolua_beginmodule(tolua_S,"MoveTo"); tolua_function(tolua_S,"new",lua_cocos2dx_MoveTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_MoveTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_MoveTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MoveTo).name(); g_luaType[typeName] = "cc.MoveTo"; g_typeCast["MoveTo"] = "cc.MoveTo"; return 1; } int lua_cocos2dx_SkewTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::SkewTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SkewTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SkewTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SkewTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; double arg1; double arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SkewTo:initWithDuration"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.SkewTo:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.SkewTo:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SkewTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SkewTo:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SkewTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SkewTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SkewTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { double arg0; double arg1; double arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SkewTo:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.SkewTo:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.SkewTo:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SkewTo_create'", nullptr); return 0; } cocos2d::SkewTo* ret = cocos2d::SkewTo::create(arg0, arg1, arg2); object_to_luaval<cocos2d::SkewTo>(tolua_S, "cc.SkewTo",(cocos2d::SkewTo*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SkewTo:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SkewTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SkewTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::SkewTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SkewTo_constructor'", nullptr); return 0; } cobj = new cocos2d::SkewTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.SkewTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SkewTo:SkewTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SkewTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_SkewTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SkewTo)"); return 0; } int lua_register_cocos2dx_SkewTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.SkewTo"); tolua_cclass(tolua_S,"SkewTo","cc.SkewTo","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"SkewTo"); tolua_function(tolua_S,"new",lua_cocos2dx_SkewTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_SkewTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_SkewTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::SkewTo).name(); g_luaType[typeName] = "cc.SkewTo"; g_typeCast["SkewTo"] = "cc.SkewTo"; return 1; } int lua_cocos2dx_SkewBy_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::SkewBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SkewBy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SkewBy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SkewBy_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; double arg1; double arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SkewBy:initWithDuration"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.SkewBy:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.SkewBy:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SkewBy_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SkewBy:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SkewBy_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SkewBy_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SkewBy",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { double arg0; double arg1; double arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SkewBy:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.SkewBy:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.SkewBy:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SkewBy_create'", nullptr); return 0; } cocos2d::SkewBy* ret = cocos2d::SkewBy::create(arg0, arg1, arg2); object_to_luaval<cocos2d::SkewBy>(tolua_S, "cc.SkewBy",(cocos2d::SkewBy*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SkewBy:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SkewBy_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SkewBy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::SkewBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SkewBy_constructor'", nullptr); return 0; } cobj = new cocos2d::SkewBy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.SkewBy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SkewBy:SkewBy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SkewBy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_SkewBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SkewBy)"); return 0; } int lua_register_cocos2dx_SkewBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.SkewBy"); tolua_cclass(tolua_S,"SkewBy","cc.SkewBy","cc.SkewTo",nullptr); tolua_beginmodule(tolua_S,"SkewBy"); tolua_function(tolua_S,"new",lua_cocos2dx_SkewBy_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_SkewBy_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_SkewBy_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::SkewBy).name(); g_luaType[typeName] = "cc.SkewBy"; g_typeCast["SkewBy"] = "cc.SkewBy"; return 1; } int lua_cocos2dx_JumpBy_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::JumpBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.JumpBy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::JumpBy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_JumpBy_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Vec2 arg1; double arg2; int arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.JumpBy:initWithDuration"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.JumpBy:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.JumpBy:initWithDuration"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.JumpBy:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpBy_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpBy:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpBy_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpBy_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.JumpBy",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Vec2 arg1; double arg2; int arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.JumpBy:create"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.JumpBy:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.JumpBy:create"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.JumpBy:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpBy_create'", nullptr); return 0; } cocos2d::JumpBy* ret = cocos2d::JumpBy::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::JumpBy>(tolua_S, "cc.JumpBy",(cocos2d::JumpBy*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.JumpBy:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpBy_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpBy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::JumpBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpBy_constructor'", nullptr); return 0; } cobj = new cocos2d::JumpBy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.JumpBy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpBy:JumpBy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpBy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_JumpBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (JumpBy)"); return 0; } int lua_register_cocos2dx_JumpBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.JumpBy"); tolua_cclass(tolua_S,"JumpBy","cc.JumpBy","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"JumpBy"); tolua_function(tolua_S,"new",lua_cocos2dx_JumpBy_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_JumpBy_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_JumpBy_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::JumpBy).name(); g_luaType[typeName] = "cc.JumpBy"; g_typeCast["JumpBy"] = "cc.JumpBy"; return 1; } int lua_cocos2dx_JumpTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::JumpTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.JumpTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::JumpTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_JumpTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Vec2 arg1; double arg2; int arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.JumpTo:initWithDuration"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.JumpTo:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.JumpTo:initWithDuration"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.JumpTo:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpTo:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.JumpTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Vec2 arg1; double arg2; int arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.JumpTo:create"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.JumpTo:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.JumpTo:create"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.JumpTo:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTo_create'", nullptr); return 0; } cocos2d::JumpTo* ret = cocos2d::JumpTo::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::JumpTo>(tolua_S, "cc.JumpTo",(cocos2d::JumpTo*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.JumpTo:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::JumpTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTo_constructor'", nullptr); return 0; } cobj = new cocos2d::JumpTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.JumpTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpTo:JumpTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_JumpTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (JumpTo)"); return 0; } int lua_register_cocos2dx_JumpTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.JumpTo"); tolua_cclass(tolua_S,"JumpTo","cc.JumpTo","cc.JumpBy",nullptr); tolua_beginmodule(tolua_S,"JumpTo"); tolua_function(tolua_S,"new",lua_cocos2dx_JumpTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_JumpTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_JumpTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::JumpTo).name(); g_luaType[typeName] = "cc.JumpTo"; g_typeCast["JumpTo"] = "cc.JumpTo"; return 1; } int lua_cocos2dx_BezierBy_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::BezierBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BezierBy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BezierBy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BezierBy_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; cocos2d::_ccBezierConfig arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.BezierBy:initWithDuration"); #pragma warning NO CONVERSION TO NATIVE FOR _ccBezierConfig ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BezierBy_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BezierBy:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BezierBy_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_BezierBy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::BezierBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BezierBy_constructor'", nullptr); return 0; } cobj = new cocos2d::BezierBy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.BezierBy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BezierBy:BezierBy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BezierBy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_BezierBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (BezierBy)"); return 0; } int lua_register_cocos2dx_BezierBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.BezierBy"); tolua_cclass(tolua_S,"BezierBy","cc.BezierBy","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"BezierBy"); tolua_function(tolua_S,"new",lua_cocos2dx_BezierBy_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_BezierBy_initWithDuration); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::BezierBy).name(); g_luaType[typeName] = "cc.BezierBy"; g_typeCast["BezierBy"] = "cc.BezierBy"; return 1; } int lua_cocos2dx_BezierTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::BezierTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BezierTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BezierTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BezierTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; cocos2d::_ccBezierConfig arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.BezierTo:initWithDuration"); #pragma warning NO CONVERSION TO NATIVE FOR _ccBezierConfig ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BezierTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BezierTo:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BezierTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_BezierTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::BezierTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BezierTo_constructor'", nullptr); return 0; } cobj = new cocos2d::BezierTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.BezierTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BezierTo:BezierTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BezierTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_BezierTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (BezierTo)"); return 0; } int lua_register_cocos2dx_BezierTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.BezierTo"); tolua_cclass(tolua_S,"BezierTo","cc.BezierTo","cc.BezierBy",nullptr); tolua_beginmodule(tolua_S,"BezierTo"); tolua_function(tolua_S,"new",lua_cocos2dx_BezierTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_BezierTo_initWithDuration); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::BezierTo).name(); g_luaType[typeName] = "cc.BezierTo"; g_typeCast["BezierTo"] = "cc.BezierTo"; return 1; } int lua_cocos2dx_ScaleTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ScaleTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ScaleTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ScaleTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ScaleTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } double arg3; ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.ScaleTo:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ScaleTo:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ScaleTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ScaleTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ScaleTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleTo:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleTo:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ScaleTo:create"); if (!ok) { break; } cocos2d::ScaleTo* ret = cocos2d::ScaleTo::create(arg0, arg1, arg2); object_to_luaval<cocos2d::ScaleTo>(tolua_S, "cc.ScaleTo",(cocos2d::ScaleTo*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleTo:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleTo:create"); if (!ok) { break; } cocos2d::ScaleTo* ret = cocos2d::ScaleTo::create(arg0, arg1); object_to_luaval<cocos2d::ScaleTo>(tolua_S, "cc.ScaleTo",(cocos2d::ScaleTo*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleTo:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleTo:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ScaleTo:create"); if (!ok) { break; } double arg3; ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.ScaleTo:create"); if (!ok) { break; } cocos2d::ScaleTo* ret = cocos2d::ScaleTo::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::ScaleTo>(tolua_S, "cc.ScaleTo",(cocos2d::ScaleTo*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.ScaleTo:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ScaleTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ScaleTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ScaleTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ScaleTo_constructor'", nullptr); return 0; } cobj = new cocos2d::ScaleTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ScaleTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ScaleTo:ScaleTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ScaleTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ScaleTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ScaleTo)"); return 0; } int lua_register_cocos2dx_ScaleTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ScaleTo"); tolua_cclass(tolua_S,"ScaleTo","cc.ScaleTo","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"ScaleTo"); tolua_function(tolua_S,"new",lua_cocos2dx_ScaleTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ScaleTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_ScaleTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ScaleTo).name(); g_luaType[typeName] = "cc.ScaleTo"; g_typeCast["ScaleTo"] = "cc.ScaleTo"; return 1; } int lua_cocos2dx_ScaleBy_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ScaleBy",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleBy:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleBy:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ScaleBy:create"); if (!ok) { break; } cocos2d::ScaleBy* ret = cocos2d::ScaleBy::create(arg0, arg1, arg2); object_to_luaval<cocos2d::ScaleBy>(tolua_S, "cc.ScaleBy",(cocos2d::ScaleBy*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleBy:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleBy:create"); if (!ok) { break; } cocos2d::ScaleBy* ret = cocos2d::ScaleBy::create(arg0, arg1); object_to_luaval<cocos2d::ScaleBy>(tolua_S, "cc.ScaleBy",(cocos2d::ScaleBy*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ScaleBy:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ScaleBy:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ScaleBy:create"); if (!ok) { break; } double arg3; ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.ScaleBy:create"); if (!ok) { break; } cocos2d::ScaleBy* ret = cocos2d::ScaleBy::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::ScaleBy>(tolua_S, "cc.ScaleBy",(cocos2d::ScaleBy*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.ScaleBy:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ScaleBy_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ScaleBy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ScaleBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ScaleBy_constructor'", nullptr); return 0; } cobj = new cocos2d::ScaleBy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ScaleBy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ScaleBy:ScaleBy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ScaleBy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ScaleBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ScaleBy)"); return 0; } int lua_register_cocos2dx_ScaleBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ScaleBy"); tolua_cclass(tolua_S,"ScaleBy","cc.ScaleBy","cc.ScaleTo",nullptr); tolua_beginmodule(tolua_S,"ScaleBy"); tolua_function(tolua_S,"new",lua_cocos2dx_ScaleBy_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_ScaleBy_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ScaleBy).name(); g_luaType[typeName] = "cc.ScaleBy"; g_typeCast["ScaleBy"] = "cc.ScaleBy"; return 1; } int lua_cocos2dx_Blink_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Blink* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Blink",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Blink*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Blink_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; int arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Blink:initWithDuration"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Blink:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Blink_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Blink:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Blink_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Blink_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Blink",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; int arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Blink:create"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Blink:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Blink_create'", nullptr); return 0; } cocos2d::Blink* ret = cocos2d::Blink::create(arg0, arg1); object_to_luaval<cocos2d::Blink>(tolua_S, "cc.Blink",(cocos2d::Blink*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Blink:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Blink_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Blink_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Blink* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Blink_constructor'", nullptr); return 0; } cobj = new cocos2d::Blink(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Blink"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Blink:Blink",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Blink_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Blink_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Blink)"); return 0; } int lua_register_cocos2dx_Blink(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Blink"); tolua_cclass(tolua_S,"Blink","cc.Blink","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"Blink"); tolua_function(tolua_S,"new",lua_cocos2dx_Blink_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_Blink_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_Blink_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Blink).name(); g_luaType[typeName] = "cc.Blink"; g_typeCast["Blink"] = "cc.Blink"; return 1; } int lua_cocos2dx_FadeTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::FadeTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FadeTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FadeTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FadeTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; uint16_t arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FadeTo:initWithDuration"); ok &= luaval_to_uint16(tolua_S, 3,&arg1, "cc.FadeTo:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeTo:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FadeTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; uint16_t arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FadeTo:create"); ok &= luaval_to_uint16(tolua_S, 3,&arg1, "cc.FadeTo:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeTo_create'", nullptr); return 0; } cocos2d::FadeTo* ret = cocos2d::FadeTo::create(arg0, arg1); object_to_luaval<cocos2d::FadeTo>(tolua_S, "cc.FadeTo",(cocos2d::FadeTo*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FadeTo:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FadeTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeTo_constructor'", nullptr); return 0; } cobj = new cocos2d::FadeTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FadeTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeTo:FadeTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FadeTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FadeTo)"); return 0; } int lua_register_cocos2dx_FadeTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FadeTo"); tolua_cclass(tolua_S,"FadeTo","cc.FadeTo","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"FadeTo"); tolua_function(tolua_S,"new",lua_cocos2dx_FadeTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_FadeTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_FadeTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FadeTo).name(); g_luaType[typeName] = "cc.FadeTo"; g_typeCast["FadeTo"] = "cc.FadeTo"; return 1; } int lua_cocos2dx_FadeIn_setReverseAction(lua_State* tolua_S) { int argc = 0; cocos2d::FadeIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FadeIn",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FadeIn*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FadeIn_setReverseAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::FadeTo* arg0 = nullptr; ok &= luaval_to_object<cocos2d::FadeTo>(tolua_S, 2, "cc.FadeTo",&arg0, "cc.FadeIn:setReverseAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeIn_setReverseAction'", nullptr); return 0; } cobj->setReverseAction(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeIn:setReverseAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeIn_setReverseAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FadeIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FadeIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeIn_create'", nullptr); return 0; } cocos2d::FadeIn* ret = cocos2d::FadeIn::create(arg0); object_to_luaval<cocos2d::FadeIn>(tolua_S, "cc.FadeIn",(cocos2d::FadeIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FadeIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FadeIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeIn_constructor'", nullptr); return 0; } cobj = new cocos2d::FadeIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FadeIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeIn:FadeIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FadeIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FadeIn)"); return 0; } int lua_register_cocos2dx_FadeIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FadeIn"); tolua_cclass(tolua_S,"FadeIn","cc.FadeIn","cc.FadeTo",nullptr); tolua_beginmodule(tolua_S,"FadeIn"); tolua_function(tolua_S,"new",lua_cocos2dx_FadeIn_constructor); tolua_function(tolua_S,"setReverseAction",lua_cocos2dx_FadeIn_setReverseAction); tolua_function(tolua_S,"create", lua_cocos2dx_FadeIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FadeIn).name(); g_luaType[typeName] = "cc.FadeIn"; g_typeCast["FadeIn"] = "cc.FadeIn"; return 1; } int lua_cocos2dx_FadeOut_setReverseAction(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FadeOut",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FadeOut*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FadeOut_setReverseAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::FadeTo* arg0 = nullptr; ok &= luaval_to_object<cocos2d::FadeTo>(tolua_S, 2, "cc.FadeTo",&arg0, "cc.FadeOut:setReverseAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOut_setReverseAction'", nullptr); return 0; } cobj->setReverseAction(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOut:setReverseAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOut_setReverseAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FadeOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FadeOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOut_create'", nullptr); return 0; } cocos2d::FadeOut* ret = cocos2d::FadeOut::create(arg0); object_to_luaval<cocos2d::FadeOut>(tolua_S, "cc.FadeOut",(cocos2d::FadeOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FadeOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOut_constructor'", nullptr); return 0; } cobj = new cocos2d::FadeOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FadeOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOut:FadeOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FadeOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FadeOut)"); return 0; } int lua_register_cocos2dx_FadeOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FadeOut"); tolua_cclass(tolua_S,"FadeOut","cc.FadeOut","cc.FadeTo",nullptr); tolua_beginmodule(tolua_S,"FadeOut"); tolua_function(tolua_S,"new",lua_cocos2dx_FadeOut_constructor); tolua_function(tolua_S,"setReverseAction",lua_cocos2dx_FadeOut_setReverseAction); tolua_function(tolua_S,"create", lua_cocos2dx_FadeOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FadeOut).name(); g_luaType[typeName] = "cc.FadeOut"; g_typeCast["FadeOut"] = "cc.FadeOut"; return 1; } int lua_cocos2dx_TintTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::TintTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TintTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TintTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TintTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; uint16_t arg1; uint16_t arg2; uint16_t arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TintTo:initWithDuration"); ok &= luaval_to_uint16(tolua_S, 3,&arg1, "cc.TintTo:initWithDuration"); ok &= luaval_to_uint16(tolua_S, 4,&arg2, "cc.TintTo:initWithDuration"); ok &= luaval_to_uint16(tolua_S, 5,&arg3, "cc.TintTo:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TintTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TintTo:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TintTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TintTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TintTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TintTo:create"); if (!ok) { break; } cocos2d::Color3B arg1; ok &= luaval_to_color3b(tolua_S, 3, &arg1, "cc.TintTo:create"); if (!ok) { break; } cocos2d::TintTo* ret = cocos2d::TintTo::create(arg0, arg1); object_to_luaval<cocos2d::TintTo>(tolua_S, "cc.TintTo",(cocos2d::TintTo*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TintTo:create"); if (!ok) { break; } uint16_t arg1; ok &= luaval_to_uint16(tolua_S, 3,&arg1, "cc.TintTo:create"); if (!ok) { break; } uint16_t arg2; ok &= luaval_to_uint16(tolua_S, 4,&arg2, "cc.TintTo:create"); if (!ok) { break; } uint16_t arg3; ok &= luaval_to_uint16(tolua_S, 5,&arg3, "cc.TintTo:create"); if (!ok) { break; } cocos2d::TintTo* ret = cocos2d::TintTo::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::TintTo>(tolua_S, "cc.TintTo",(cocos2d::TintTo*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TintTo:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TintTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TintTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TintTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TintTo_constructor'", nullptr); return 0; } cobj = new cocos2d::TintTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TintTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TintTo:TintTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TintTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TintTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TintTo)"); return 0; } int lua_register_cocos2dx_TintTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TintTo"); tolua_cclass(tolua_S,"TintTo","cc.TintTo","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"TintTo"); tolua_function(tolua_S,"new",lua_cocos2dx_TintTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TintTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_TintTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TintTo).name(); g_luaType[typeName] = "cc.TintTo"; g_typeCast["TintTo"] = "cc.TintTo"; return 1; } int lua_cocos2dx_TintBy_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::TintBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TintBy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TintBy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TintBy_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; int32_t arg1; int32_t arg2; int32_t arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TintBy:initWithDuration"); ok &= luaval_to_int32(tolua_S, 3,&arg1, "cc.TintBy:initWithDuration"); ok &= luaval_to_int32(tolua_S, 4,&arg2, "cc.TintBy:initWithDuration"); ok &= luaval_to_int32(tolua_S, 5,&arg3, "cc.TintBy:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TintBy_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TintBy:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TintBy_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TintBy_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TintBy",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; int32_t arg1; int32_t arg2; int32_t arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TintBy:create"); ok &= luaval_to_int32(tolua_S, 3,&arg1, "cc.TintBy:create"); ok &= luaval_to_int32(tolua_S, 4,&arg2, "cc.TintBy:create"); ok &= luaval_to_int32(tolua_S, 5,&arg3, "cc.TintBy:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TintBy_create'", nullptr); return 0; } cocos2d::TintBy* ret = cocos2d::TintBy::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::TintBy>(tolua_S, "cc.TintBy",(cocos2d::TintBy*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TintBy:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TintBy_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TintBy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TintBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TintBy_constructor'", nullptr); return 0; } cobj = new cocos2d::TintBy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TintBy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TintBy:TintBy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TintBy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TintBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TintBy)"); return 0; } int lua_register_cocos2dx_TintBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TintBy"); tolua_cclass(tolua_S,"TintBy","cc.TintBy","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"TintBy"); tolua_function(tolua_S,"new",lua_cocos2dx_TintBy_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TintBy_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_TintBy_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TintBy).name(); g_luaType[typeName] = "cc.TintBy"; g_typeCast["TintBy"] = "cc.TintBy"; return 1; } int lua_cocos2dx_DelayTime_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.DelayTime",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.DelayTime:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DelayTime_create'", nullptr); return 0; } cocos2d::DelayTime* ret = cocos2d::DelayTime::create(arg0); object_to_luaval<cocos2d::DelayTime>(tolua_S, "cc.DelayTime",(cocos2d::DelayTime*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.DelayTime:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DelayTime_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DelayTime_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::DelayTime* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DelayTime_constructor'", nullptr); return 0; } cobj = new cocos2d::DelayTime(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.DelayTime"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DelayTime:DelayTime",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DelayTime_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_DelayTime_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (DelayTime)"); return 0; } int lua_register_cocos2dx_DelayTime(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.DelayTime"); tolua_cclass(tolua_S,"DelayTime","cc.DelayTime","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"DelayTime"); tolua_function(tolua_S,"new",lua_cocos2dx_DelayTime_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_DelayTime_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::DelayTime).name(); g_luaType[typeName] = "cc.DelayTime"; g_typeCast["DelayTime"] = "cc.DelayTime"; return 1; } int lua_cocos2dx_Animate_initWithAnimation(lua_State* tolua_S) { int argc = 0; cocos2d::Animate* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animate",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animate*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animate_initWithAnimation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Animation* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Animation>(tolua_S, 2, "cc.Animation",&arg0, "cc.Animate:initWithAnimation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animate_initWithAnimation'", nullptr); return 0; } bool ret = cobj->initWithAnimation(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animate:initWithAnimation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animate_initWithAnimation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animate_getAnimation(lua_State* tolua_S) { int argc = 0; cocos2d::Animate* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animate",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animate*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animate_getAnimation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { const cocos2d::Animation* ret = cobj->getAnimation(); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { cocos2d::Animation* ret = cobj->getAnimation(); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animate:getAnimation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animate_getAnimation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animate_getCurrentFrameIndex(lua_State* tolua_S) { int argc = 0; cocos2d::Animate* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animate",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animate*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animate_getCurrentFrameIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animate_getCurrentFrameIndex'", nullptr); return 0; } int ret = cobj->getCurrentFrameIndex(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animate:getCurrentFrameIndex",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animate_getCurrentFrameIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animate_setAnimation(lua_State* tolua_S) { int argc = 0; cocos2d::Animate* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Animate",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Animate*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Animate_setAnimation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Animation* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Animation>(tolua_S, 2, "cc.Animation",&arg0, "cc.Animate:setAnimation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animate_setAnimation'", nullptr); return 0; } cobj->setAnimation(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animate:setAnimation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animate_setAnimation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animate_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Animate",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Animation* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Animation>(tolua_S, 2, "cc.Animation",&arg0, "cc.Animate:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animate_create'", nullptr); return 0; } cocos2d::Animate* ret = cocos2d::Animate::create(arg0); object_to_luaval<cocos2d::Animate>(tolua_S, "cc.Animate",(cocos2d::Animate*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Animate:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animate_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Animate_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Animate* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Animate_constructor'", nullptr); return 0; } cobj = new cocos2d::Animate(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Animate"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Animate:Animate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Animate_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Animate_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Animate)"); return 0; } int lua_register_cocos2dx_Animate(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Animate"); tolua_cclass(tolua_S,"Animate","cc.Animate","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"Animate"); tolua_function(tolua_S,"new",lua_cocos2dx_Animate_constructor); tolua_function(tolua_S,"initWithAnimation",lua_cocos2dx_Animate_initWithAnimation); tolua_function(tolua_S,"getAnimation",lua_cocos2dx_Animate_getAnimation); tolua_function(tolua_S,"getCurrentFrameIndex",lua_cocos2dx_Animate_getCurrentFrameIndex); tolua_function(tolua_S,"setAnimation",lua_cocos2dx_Animate_setAnimation); tolua_function(tolua_S,"create", lua_cocos2dx_Animate_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Animate).name(); g_luaType[typeName] = "cc.Animate"; g_typeCast["Animate"] = "cc.Animate"; return 1; } int lua_cocos2dx_TargetedAction_getForcedTarget(lua_State* tolua_S) { int argc = 0; cocos2d::TargetedAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TargetedAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TargetedAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TargetedAction_getForcedTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { const cocos2d::Node* ret = cobj->getForcedTarget(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { cocos2d::Node* ret = cobj->getForcedTarget(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TargetedAction:getForcedTarget",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TargetedAction_getForcedTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TargetedAction_initWithTarget(lua_State* tolua_S) { int argc = 0; cocos2d::TargetedAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TargetedAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TargetedAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TargetedAction_initWithTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Node* arg0 = nullptr; cocos2d::FiniteTimeAction* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.TargetedAction:initWithTarget"); ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 3, "cc.FiniteTimeAction",&arg1, "cc.TargetedAction:initWithTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TargetedAction_initWithTarget'", nullptr); return 0; } bool ret = cobj->initWithTarget(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TargetedAction:initWithTarget",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TargetedAction_initWithTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TargetedAction_setForcedTarget(lua_State* tolua_S) { int argc = 0; cocos2d::TargetedAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TargetedAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TargetedAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TargetedAction_setForcedTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.TargetedAction:setForcedTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TargetedAction_setForcedTarget'", nullptr); return 0; } cobj->setForcedTarget(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TargetedAction:setForcedTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TargetedAction_setForcedTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TargetedAction_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TargetedAction",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::Node* arg0 = nullptr; cocos2d::FiniteTimeAction* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.TargetedAction:create"); ok &= luaval_to_object<cocos2d::FiniteTimeAction>(tolua_S, 3, "cc.FiniteTimeAction",&arg1, "cc.TargetedAction:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TargetedAction_create'", nullptr); return 0; } cocos2d::TargetedAction* ret = cocos2d::TargetedAction::create(arg0, arg1); object_to_luaval<cocos2d::TargetedAction>(tolua_S, "cc.TargetedAction",(cocos2d::TargetedAction*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TargetedAction:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TargetedAction_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TargetedAction_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TargetedAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TargetedAction_constructor'", nullptr); return 0; } cobj = new cocos2d::TargetedAction(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TargetedAction"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TargetedAction:TargetedAction",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TargetedAction_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TargetedAction_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TargetedAction)"); return 0; } int lua_register_cocos2dx_TargetedAction(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TargetedAction"); tolua_cclass(tolua_S,"TargetedAction","cc.TargetedAction","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"TargetedAction"); tolua_function(tolua_S,"new",lua_cocos2dx_TargetedAction_constructor); tolua_function(tolua_S,"getForcedTarget",lua_cocos2dx_TargetedAction_getForcedTarget); tolua_function(tolua_S,"initWithTarget",lua_cocos2dx_TargetedAction_initWithTarget); tolua_function(tolua_S,"setForcedTarget",lua_cocos2dx_TargetedAction_setForcedTarget); tolua_function(tolua_S,"create", lua_cocos2dx_TargetedAction_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TargetedAction).name(); g_luaType[typeName] = "cc.TargetedAction"; g_typeCast["TargetedAction"] = "cc.TargetedAction"; return 1; } int lua_cocos2dx_ActionFloat_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ActionFloat* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionFloat",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionFloat*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionFloat_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; double arg1; double arg2; std::function<void (float)> arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ActionFloat:initWithDuration"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ActionFloat:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ActionFloat:initWithDuration"); do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionFloat_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionFloat:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionFloat_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionFloat_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ActionFloat",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; double arg1; double arg2; std::function<void (float)> arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ActionFloat:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ActionFloat:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ActionFloat:create"); do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionFloat_create'", nullptr); return 0; } cocos2d::ActionFloat* ret = cocos2d::ActionFloat::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::ActionFloat>(tolua_S, "cc.ActionFloat",(cocos2d::ActionFloat*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ActionFloat:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionFloat_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionFloat_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ActionFloat* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionFloat_constructor'", nullptr); return 0; } cobj = new cocos2d::ActionFloat(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ActionFloat"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionFloat:ActionFloat",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionFloat_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ActionFloat_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ActionFloat)"); return 0; } int lua_register_cocos2dx_ActionFloat(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ActionFloat"); tolua_cclass(tolua_S,"ActionFloat","cc.ActionFloat","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"ActionFloat"); tolua_function(tolua_S,"new",lua_cocos2dx_ActionFloat_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ActionFloat_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_ActionFloat_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ActionFloat).name(); g_luaType[typeName] = "cc.ActionFloat"; g_typeCast["ActionFloat"] = "cc.ActionFloat"; return 1; } int lua_cocos2dx_Properties_getVariable(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getVariable'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getVariable"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getVariable'", nullptr); return 0; } const char* ret = cobj->getVariable(arg0); tolua_pushstring(tolua_S,(const char*)ret); return 1; } if (argc == 2) { const char* arg0 = nullptr; const char* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getVariable"); arg0 = arg0_tmp.c_str(); std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.Properties:getVariable"); arg1 = arg1_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getVariable'", nullptr); return 0; } const char* ret = cobj->getVariable(arg0, arg1); tolua_pushstring(tolua_S,(const char*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getVariable",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getVariable'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getString(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getString'", nullptr); return 0; } const char* ret = cobj->getString(); tolua_pushstring(tolua_S,(const char*)ret); return 1; } if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getString"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getString'", nullptr); return 0; } const char* ret = cobj->getString(arg0); tolua_pushstring(tolua_S,(const char*)ret); return 1; } if (argc == 2) { const char* arg0 = nullptr; const char* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getString"); arg0 = arg0_tmp.c_str(); std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.Properties:getString"); arg1 = arg1_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getString'", nullptr); return 0; } const char* ret = cobj->getString(arg0, arg1); tolua_pushstring(tolua_S,(const char*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getString",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getLong(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getLong'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getLong'", nullptr); return 0; } long ret = cobj->getLong(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getLong"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getLong'", nullptr); return 0; } long ret = cobj->getLong(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getLong",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getLong'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getNamespace(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getNamespace'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { const char* ret = cobj->getNamespace(); tolua_pushstring(tolua_S,(const char*)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getNamespace"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } cocos2d::Properties* ret = cobj->getNamespace(arg0); object_to_luaval<cocos2d::Properties>(tolua_S, "cc.Properties",(cocos2d::Properties*)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getNamespace"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } bool arg1; ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Properties:getNamespace"); if (!ok) { break; } cocos2d::Properties* ret = cobj->getNamespace(arg0, arg1); object_to_luaval<cocos2d::Properties>(tolua_S, "cc.Properties",(cocos2d::Properties*)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getNamespace"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } bool arg1; ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Properties:getNamespace"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.Properties:getNamespace"); if (!ok) { break; } cocos2d::Properties* ret = cobj->getNamespace(arg0, arg1, arg2); object_to_luaval<cocos2d::Properties>(tolua_S, "cc.Properties",(cocos2d::Properties*)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getNamespace",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getNamespace'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getPath(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getPath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; std::string* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getPath"); arg0 = arg0_tmp.c_str(); #pragma warning NO CONVERSION TO NATIVE FOR std::string* ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getPath'", nullptr); return 0; } bool ret = cobj->getPath(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getPath",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getPath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getMat4(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getMat4'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Mat4* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getMat4"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Mat4>(tolua_S, 3, "cc.Mat4",&arg1, "cc.Properties:getMat4"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getMat4'", nullptr); return 0; } bool ret = cobj->getMat4(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getMat4",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getMat4'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_exists(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_exists'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:exists"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_exists'", nullptr); return 0; } bool ret = cobj->exists(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:exists",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_exists'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_setString(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_setString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; const char* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:setString"); arg0 = arg0_tmp.c_str(); std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.Properties:setString"); arg1 = arg1_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_setString'", nullptr); return 0; } bool ret = cobj->setString(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:setString",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_setString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getId(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getId'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getId'", nullptr); return 0; } const char* ret = cobj->getId(); tolua_pushstring(tolua_S,(const char*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getId",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getId'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_rewind(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_rewind'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_rewind'", nullptr); return 0; } cobj->rewind(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:rewind",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_rewind'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_setVariable(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_setVariable'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; const char* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:setVariable"); arg0 = arg0_tmp.c_str(); std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.Properties:setVariable"); arg1 = arg1_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_setVariable'", nullptr); return 0; } cobj->setVariable(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:setVariable",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_setVariable'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getBool(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getBool'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getBool'", nullptr); return 0; } bool ret = cobj->getBool(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getBool"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getBool'", nullptr); return 0; } bool ret = cobj->getBool(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 2) { const char* arg0 = nullptr; bool arg1; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getBool"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Properties:getBool"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getBool'", nullptr); return 0; } bool ret = cobj->getBool(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getBool",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getBool'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getColor(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getColor"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } cocos2d::Vec4* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Vec4>(tolua_S, 3, "cc.Vec4",&arg1, "cc.Properties:getColor"); if (!ok) { break; } bool ret = cobj->getColor(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getColor"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } cocos2d::Vec3* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Vec3>(tolua_S, 3, "cc.Vec3",&arg1, "cc.Properties:getColor"); if (!ok) { break; } bool ret = cobj->getColor(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getColor",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getType(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getType'", nullptr); return 0; } int ret = (int)cobj->getType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getType"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getType'", nullptr); return 0; } int ret = (int)cobj->getType(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getNextNamespace(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getNextNamespace'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getNextNamespace'", nullptr); return 0; } cocos2d::Properties* ret = cobj->getNextNamespace(); object_to_luaval<cocos2d::Properties>(tolua_S, "cc.Properties",(cocos2d::Properties*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getNextNamespace",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getNextNamespace'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getInt(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getInt'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getInt'", nullptr); return 0; } int ret = cobj->getInt(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getInt"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getInt'", nullptr); return 0; } int ret = cobj->getInt(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getInt",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getInt'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getVec3(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getVec3'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Vec3* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getVec3"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Vec3>(tolua_S, 3, "cc.Vec3",&arg1, "cc.Properties:getVec3"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getVec3'", nullptr); return 0; } bool ret = cobj->getVec3(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getVec3",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getVec3'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getVec2(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getVec2'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Vec2* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getVec2"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Vec2>(tolua_S, 3, "cc.Vec2",&arg1, "cc.Properties:getVec2"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getVec2'", nullptr); return 0; } bool ret = cobj->getVec2(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getVec2",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getVec2'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getVec4(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getVec4'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Vec4* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getVec4"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Vec4>(tolua_S, 3, "cc.Vec4",&arg1, "cc.Properties:getVec4"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getVec4'", nullptr); return 0; } bool ret = cobj->getVec4(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getVec4",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getVec4'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getNextProperty(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getNextProperty'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getNextProperty'", nullptr); return 0; } const char* ret = cobj->getNextProperty(); tolua_pushstring(tolua_S,(const char*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getNextProperty",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getNextProperty'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getFloat(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getFloat'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getFloat'", nullptr); return 0; } double ret = cobj->getFloat(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getFloat"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getFloat'", nullptr); return 0; } double ret = cobj->getFloat(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getFloat",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getFloat'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_getQuaternionFromAxisAngle(lua_State* tolua_S) { int argc = 0; cocos2d::Properties* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Properties*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Properties_getQuaternionFromAxisAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Quaternion* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:getQuaternionFromAxisAngle"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Quaternion>(tolua_S, 3, "cc.Quaternion",&arg1, "cc.Properties:getQuaternionFromAxisAngle"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_getQuaternionFromAxisAngle'", nullptr); return 0; } bool ret = cobj->getQuaternionFromAxisAngle(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Properties:getQuaternionFromAxisAngle",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_getQuaternionFromAxisAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_parseColor(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:parseColor"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } cocos2d::Vec4* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Vec4>(tolua_S, 3, "cc.Vec4",&arg1, "cc.Properties:parseColor"); if (!ok) { break; } bool ret = cocos2d::Properties::parseColor(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:parseColor"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } cocos2d::Vec3* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Vec3>(tolua_S, 3, "cc.Vec3",&arg1, "cc.Properties:parseColor"); if (!ok) { break; } bool ret = cocos2d::Properties::parseColor(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.Properties:parseColor",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_parseColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_parseVec3(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Vec3* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:parseVec3"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Vec3>(tolua_S, 3, "cc.Vec3",&arg1, "cc.Properties:parseVec3"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_parseVec3'", nullptr); return 0; } bool ret = cocos2d::Properties::parseVec3(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Properties:parseVec3",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_parseVec3'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_parseAxisAngle(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Quaternion* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:parseAxisAngle"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Quaternion>(tolua_S, 3, "cc.Quaternion",&arg1, "cc.Properties:parseAxisAngle"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_parseAxisAngle'", nullptr); return 0; } bool ret = cocos2d::Properties::parseAxisAngle(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Properties:parseAxisAngle",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_parseAxisAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_parseVec2(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Vec2* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:parseVec2"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Vec2>(tolua_S, 3, "cc.Vec2",&arg1, "cc.Properties:parseVec2"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_parseVec2'", nullptr); return 0; } bool ret = cocos2d::Properties::parseVec2(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Properties:parseVec2",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_parseVec2'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Properties_parseVec4(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Properties",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { const char* arg0 = nullptr; cocos2d::Vec4* arg1 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.Properties:parseVec4"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_object<cocos2d::Vec4>(tolua_S, 3, "cc.Vec4",&arg1, "cc.Properties:parseVec4"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Properties_parseVec4'", nullptr); return 0; } bool ret = cocos2d::Properties::parseVec4(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Properties:parseVec4",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Properties_parseVec4'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Properties_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Properties)"); return 0; } int lua_register_cocos2dx_Properties(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Properties"); tolua_cclass(tolua_S,"Properties","cc.Properties","",nullptr); tolua_beginmodule(tolua_S,"Properties"); tolua_function(tolua_S,"getVariable",lua_cocos2dx_Properties_getVariable); tolua_function(tolua_S,"getString",lua_cocos2dx_Properties_getString); tolua_function(tolua_S,"getLong",lua_cocos2dx_Properties_getLong); tolua_function(tolua_S,"getNamespace",lua_cocos2dx_Properties_getNamespace); tolua_function(tolua_S,"getPath",lua_cocos2dx_Properties_getPath); tolua_function(tolua_S,"getMat4",lua_cocos2dx_Properties_getMat4); tolua_function(tolua_S,"exists",lua_cocos2dx_Properties_exists); tolua_function(tolua_S,"setString",lua_cocos2dx_Properties_setString); tolua_function(tolua_S,"getId",lua_cocos2dx_Properties_getId); tolua_function(tolua_S,"rewind",lua_cocos2dx_Properties_rewind); tolua_function(tolua_S,"setVariable",lua_cocos2dx_Properties_setVariable); tolua_function(tolua_S,"getBool",lua_cocos2dx_Properties_getBool); tolua_function(tolua_S,"getColor",lua_cocos2dx_Properties_getColor); tolua_function(tolua_S,"getType",lua_cocos2dx_Properties_getType); tolua_function(tolua_S,"getNextNamespace",lua_cocos2dx_Properties_getNextNamespace); tolua_function(tolua_S,"getInt",lua_cocos2dx_Properties_getInt); tolua_function(tolua_S,"getVec3",lua_cocos2dx_Properties_getVec3); tolua_function(tolua_S,"getVec2",lua_cocos2dx_Properties_getVec2); tolua_function(tolua_S,"getVec4",lua_cocos2dx_Properties_getVec4); tolua_function(tolua_S,"getNextProperty",lua_cocos2dx_Properties_getNextProperty); tolua_function(tolua_S,"getFloat",lua_cocos2dx_Properties_getFloat); tolua_function(tolua_S,"getQuaternionFromAxisAngle",lua_cocos2dx_Properties_getQuaternionFromAxisAngle); tolua_function(tolua_S,"parseColor", lua_cocos2dx_Properties_parseColor); tolua_function(tolua_S,"parseVec3", lua_cocos2dx_Properties_parseVec3); tolua_function(tolua_S,"parseAxisAngle", lua_cocos2dx_Properties_parseAxisAngle); tolua_function(tolua_S,"parseVec2", lua_cocos2dx_Properties_parseVec2); tolua_function(tolua_S,"parseVec4", lua_cocos2dx_Properties_parseVec4); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Properties).name(); g_luaType[typeName] = "cc.Properties"; g_typeCast["Properties"] = "cc.Properties"; return 1; } int lua_cocos2dx_UserDefault_setIntegerForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_setIntegerForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; int arg1; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:setIntegerForKey"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.UserDefault:setIntegerForKey"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_setIntegerForKey'", nullptr); return 0; } cobj->setIntegerForKey(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:setIntegerForKey",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_setIntegerForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_deleteValueForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_deleteValueForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:deleteValueForKey"); arg0 = arg0_tmp.c_str(); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_deleteValueForKey'", nullptr); return 0; } cobj->deleteValueForKey(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:deleteValueForKey",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_deleteValueForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_getFloatForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_getFloatForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getFloatForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.UserDefault:getFloatForKey"); if (!ok) { break; } double ret = cobj->getFloatForKey(arg0, arg1); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getFloatForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } double ret = cobj->getFloatForKey(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:getFloatForKey",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_getFloatForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_getBoolForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_getBoolForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getBoolForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } bool arg1; ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.UserDefault:getBoolForKey"); if (!ok) { break; } bool ret = cobj->getBoolForKey(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getBoolForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } bool ret = cobj->getBoolForKey(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:getBoolForKey",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_getBoolForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_setDoubleForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_setDoubleForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; double arg1; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:setDoubleForKey"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.UserDefault:setDoubleForKey"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_setDoubleForKey'", nullptr); return 0; } cobj->setDoubleForKey(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:setDoubleForKey",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_setDoubleForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_setFloatForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_setFloatForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; double arg1; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:setFloatForKey"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.UserDefault:setFloatForKey"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_setFloatForKey'", nullptr); return 0; } cobj->setFloatForKey(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:setFloatForKey",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_setFloatForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_getStringForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_getStringForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getStringForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.UserDefault:getStringForKey"); if (!ok) { break; } std::string ret = cobj->getStringForKey(arg0, arg1); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } }while(0); ok = true; do{ if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getStringForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } std::string ret = cobj->getStringForKey(arg0); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:getStringForKey",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_getStringForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_setStringForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_setStringForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; std::string arg1; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:setStringForKey"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.UserDefault:setStringForKey"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_setStringForKey'", nullptr); return 0; } cobj->setStringForKey(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:setStringForKey",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_setStringForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_flush(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_flush'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_flush'", nullptr); return 0; } cobj->flush(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:flush",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_flush'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_getIntegerForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_getIntegerForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getIntegerForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.UserDefault:getIntegerForKey"); if (!ok) { break; } int ret = cobj->getIntegerForKey(arg0, arg1); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getIntegerForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } int ret = cobj->getIntegerForKey(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:getIntegerForKey",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_getIntegerForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_getDoubleForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_getDoubleForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getDoubleForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.UserDefault:getDoubleForKey"); if (!ok) { break; } double ret = cobj->getDoubleForKey(arg0, arg1); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:getDoubleForKey"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } double ret = cobj->getDoubleForKey(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:getDoubleForKey",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_getDoubleForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_setBoolForKey(lua_State* tolua_S) { int argc = 0; cocos2d::UserDefault* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::UserDefault*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_UserDefault_setBoolForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; bool arg1; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.UserDefault:setBoolForKey"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.UserDefault:setBoolForKey"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_setBoolForKey'", nullptr); return 0; } cobj->setBoolForKey(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.UserDefault:setBoolForKey",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_setBoolForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_destroyInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_destroyInstance'", nullptr); return 0; } cocos2d::UserDefault::destroyInstance(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.UserDefault:destroyInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_destroyInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_getXMLFilePath(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_getXMLFilePath'", nullptr); return 0; } const std::string& ret = cocos2d::UserDefault::getXMLFilePath(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.UserDefault:getXMLFilePath",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_getXMLFilePath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_UserDefault_isXMLFileExist(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.UserDefault",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_UserDefault_isXMLFileExist'", nullptr); return 0; } bool ret = cocos2d::UserDefault::isXMLFileExist(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.UserDefault:isXMLFileExist",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_UserDefault_isXMLFileExist'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_UserDefault_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (UserDefault)"); return 0; } int lua_register_cocos2dx_UserDefault(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.UserDefault"); tolua_cclass(tolua_S,"UserDefault","cc.UserDefault","",nullptr); tolua_beginmodule(tolua_S,"UserDefault"); tolua_function(tolua_S,"setIntegerForKey",lua_cocos2dx_UserDefault_setIntegerForKey); tolua_function(tolua_S,"deleteValueForKey",lua_cocos2dx_UserDefault_deleteValueForKey); tolua_function(tolua_S,"getFloatForKey",lua_cocos2dx_UserDefault_getFloatForKey); tolua_function(tolua_S,"getBoolForKey",lua_cocos2dx_UserDefault_getBoolForKey); tolua_function(tolua_S,"setDoubleForKey",lua_cocos2dx_UserDefault_setDoubleForKey); tolua_function(tolua_S,"setFloatForKey",lua_cocos2dx_UserDefault_setFloatForKey); tolua_function(tolua_S,"getStringForKey",lua_cocos2dx_UserDefault_getStringForKey); tolua_function(tolua_S,"setStringForKey",lua_cocos2dx_UserDefault_setStringForKey); tolua_function(tolua_S,"flush",lua_cocos2dx_UserDefault_flush); tolua_function(tolua_S,"getIntegerForKey",lua_cocos2dx_UserDefault_getIntegerForKey); tolua_function(tolua_S,"getDoubleForKey",lua_cocos2dx_UserDefault_getDoubleForKey); tolua_function(tolua_S,"setBoolForKey",lua_cocos2dx_UserDefault_setBoolForKey); tolua_function(tolua_S,"destroyInstance", lua_cocos2dx_UserDefault_destroyInstance); tolua_function(tolua_S,"getXMLFilePath", lua_cocos2dx_UserDefault_getXMLFilePath); tolua_function(tolua_S,"isXMLFileExist", lua_cocos2dx_UserDefault_isXMLFileExist); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::UserDefault).name(); g_luaType[typeName] = "cc.UserDefault"; g_typeCast["UserDefault"] = "cc.UserDefault"; return 1; } int lua_cocos2dx_FileUtils_fullPathForFilename(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_fullPathForFilename'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:fullPathForFilename"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_fullPathForFilename'", nullptr); return 0; } std::string ret = cobj->fullPathForFilename(arg0); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:fullPathForFilename",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_fullPathForFilename'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getStringFromFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getStringFromFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getStringFromFile"); if (!ok) { break; } std::function<void (std::basic_string<char>)> arg1; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->getStringFromFile(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getStringFromFile"); if (!ok) { break; } std::string ret = cobj->getStringFromFile(arg0); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getStringFromFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getStringFromFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_setFilenameLookupDictionary(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_setFilenameLookupDictionary'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.FileUtils:setFilenameLookupDictionary"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_setFilenameLookupDictionary'", nullptr); return 0; } cobj->setFilenameLookupDictionary(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:setFilenameLookupDictionary",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_setFilenameLookupDictionary'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_removeFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_removeFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:removeFile"); if (!ok) { break; } std::function<void (bool)> arg1; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->removeFile(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:removeFile"); if (!ok) { break; } bool ret = cobj->removeFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:removeFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_removeFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_isAbsolutePath(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_isAbsolutePath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:isAbsolutePath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_isAbsolutePath'", nullptr); return 0; } bool ret = cobj->isAbsolutePath(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:isAbsolutePath",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_isAbsolutePath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_renameFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_renameFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 4) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:renameFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:renameFile"); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.FileUtils:renameFile"); if (!ok) { break; } std::function<void (bool)> arg3; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->renameFile(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:renameFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:renameFile"); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.FileUtils:renameFile"); if (!ok) { break; } bool ret = cobj->renameFile(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:renameFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:renameFile"); if (!ok) { break; } bool ret = cobj->renameFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:renameFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:renameFile"); if (!ok) { break; } std::function<void (bool)> arg2; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->renameFile(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:renameFile",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_renameFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getDefaultResourceRootPath(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getDefaultResourceRootPath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getDefaultResourceRootPath'", nullptr); return 0; } const std::string& ret = cobj->getDefaultResourceRootPath(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getDefaultResourceRootPath",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getDefaultResourceRootPath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_loadFilenameLookupDictionaryFromFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_loadFilenameLookupDictionaryFromFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:loadFilenameLookupDictionaryFromFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_loadFilenameLookupDictionaryFromFile'", nullptr); return 0; } cobj->loadFilenameLookupDictionaryFromFile(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:loadFilenameLookupDictionaryFromFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_loadFilenameLookupDictionaryFromFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_isPopupNotify(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_isPopupNotify'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_isPopupNotify'", nullptr); return 0; } bool ret = cobj->isPopupNotify(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:isPopupNotify",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_isPopupNotify'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getValueVectorFromFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getValueVectorFromFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getValueVectorFromFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getValueVectorFromFile'", nullptr); return 0; } cocos2d::ValueVector ret = cobj->getValueVectorFromFile(arg0); ccvaluevector_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getValueVectorFromFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getValueVectorFromFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getSearchPaths(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getSearchPaths'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getSearchPaths'", nullptr); return 0; } const std::vector<std::string>& ret = cobj->getSearchPaths(); ccvector_std_string_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getSearchPaths",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getSearchPaths'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_writeToFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_writeToFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::ValueMap arg0; std::string arg1; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.FileUtils:writeToFile"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:writeToFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_writeToFile'", nullptr); return 0; } bool ret = cobj->writeToFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:writeToFile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_writeToFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getOriginalSearchPaths(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getOriginalSearchPaths'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getOriginalSearchPaths'", nullptr); return 0; } const std::vector<std::string>& ret = cobj->getOriginalSearchPaths(); ccvector_std_string_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getOriginalSearchPaths",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getOriginalSearchPaths'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getNewFilename(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getNewFilename'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getNewFilename"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getNewFilename'", nullptr); return 0; } std::string ret = cobj->getNewFilename(arg0); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getNewFilename",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getNewFilename'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_listFiles(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_listFiles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:listFiles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_listFiles'", nullptr); return 0; } std::vector<std::string> ret = cobj->listFiles(arg0); ccvector_std_string_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:listFiles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_listFiles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getValueMapFromFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getValueMapFromFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getValueMapFromFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getValueMapFromFile'", nullptr); return 0; } cocos2d::ValueMap ret = cobj->getValueMapFromFile(arg0); ccvaluemap_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getValueMapFromFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getValueMapFromFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getFileSize(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getFileSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getFileSize"); if (!ok) { break; } std::function<void (long)> arg1; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->getFileSize(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getFileSize"); if (!ok) { break; } long ret = cobj->getFileSize(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getFileSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getFileSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getValueMapFromData(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getValueMapFromData'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const char* arg0 = nullptr; int arg1; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.FileUtils:getValueMapFromData"); arg0 = arg0_tmp.c_str(); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.FileUtils:getValueMapFromData"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getValueMapFromData'", nullptr); return 0; } cocos2d::ValueMap ret = cobj->getValueMapFromData(arg0, arg1); ccvaluemap_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getValueMapFromData",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getValueMapFromData'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_removeDirectory(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_removeDirectory'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:removeDirectory"); if (!ok) { break; } std::function<void (bool)> arg1; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->removeDirectory(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:removeDirectory"); if (!ok) { break; } bool ret = cobj->removeDirectory(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:removeDirectory",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_removeDirectory'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_setSearchPaths(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_setSearchPaths'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::vector<std::string> arg0; ok &= luaval_to_std_vector_string(tolua_S, 2, &arg0, "cc.FileUtils:setSearchPaths"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_setSearchPaths'", nullptr); return 0; } cobj->setSearchPaths(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:setSearchPaths",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_setSearchPaths'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_writeStringToFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_writeStringToFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:writeStringToFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:writeStringToFile"); if (!ok) { break; } std::function<void (bool)> arg2; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->writeStringToFile(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:writeStringToFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:writeStringToFile"); if (!ok) { break; } bool ret = cobj->writeStringToFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:writeStringToFile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_writeStringToFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_setSearchResolutionsOrder(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_setSearchResolutionsOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::vector<std::string> arg0; ok &= luaval_to_std_vector_string(tolua_S, 2, &arg0, "cc.FileUtils:setSearchResolutionsOrder"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_setSearchResolutionsOrder'", nullptr); return 0; } cobj->setSearchResolutionsOrder(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:setSearchResolutionsOrder",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_setSearchResolutionsOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_addSearchResolutionsOrder(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_addSearchResolutionsOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:addSearchResolutionsOrder"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_addSearchResolutionsOrder'", nullptr); return 0; } cobj->addSearchResolutionsOrder(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { std::string arg0; bool arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:addSearchResolutionsOrder"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.FileUtils:addSearchResolutionsOrder"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_addSearchResolutionsOrder'", nullptr); return 0; } cobj->addSearchResolutionsOrder(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:addSearchResolutionsOrder",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_addSearchResolutionsOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_addSearchPath(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_addSearchPath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:addSearchPath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_addSearchPath'", nullptr); return 0; } cobj->addSearchPath(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { std::string arg0; bool arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:addSearchPath"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.FileUtils:addSearchPath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_addSearchPath'", nullptr); return 0; } cobj->addSearchPath(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:addSearchPath",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_addSearchPath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_writeValueVectorToFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_writeValueVectorToFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { cocos2d::ValueVector arg0; ok &= luaval_to_ccvaluevector(tolua_S, 2, &arg0, "cc.FileUtils:writeValueVectorToFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:writeValueVectorToFile"); if (!ok) { break; } std::function<void (bool)> arg2; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->writeValueVectorToFile(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { cocos2d::ValueVector arg0; ok &= luaval_to_ccvaluevector(tolua_S, 2, &arg0, "cc.FileUtils:writeValueVectorToFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:writeValueVectorToFile"); if (!ok) { break; } bool ret = cobj->writeValueVectorToFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:writeValueVectorToFile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_writeValueVectorToFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_isFileExist(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_isFileExist'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:isFileExist"); if (!ok) { break; } std::function<void (bool)> arg1; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->isFileExist(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:isFileExist"); if (!ok) { break; } bool ret = cobj->isFileExist(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:isFileExist",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_isFileExist'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_purgeCachedEntries(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_purgeCachedEntries'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_purgeCachedEntries'", nullptr); return 0; } cobj->purgeCachedEntries(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:purgeCachedEntries",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_purgeCachedEntries'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_fullPathFromRelativeFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_fullPathFromRelativeFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:fullPathFromRelativeFile"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:fullPathFromRelativeFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_fullPathFromRelativeFile'", nullptr); return 0; } std::string ret = cobj->fullPathFromRelativeFile(arg0, arg1); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:fullPathFromRelativeFile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_fullPathFromRelativeFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getSuitableFOpen(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getSuitableFOpen'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getSuitableFOpen"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getSuitableFOpen'", nullptr); return 0; } std::string ret = cobj->getSuitableFOpen(arg0); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getSuitableFOpen",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getSuitableFOpen'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_writeValueMapToFile(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_writeValueMapToFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.FileUtils:writeValueMapToFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:writeValueMapToFile"); if (!ok) { break; } std::function<void (bool)> arg2; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->writeValueMapToFile(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.FileUtils:writeValueMapToFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.FileUtils:writeValueMapToFile"); if (!ok) { break; } bool ret = cobj->writeValueMapToFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:writeValueMapToFile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_writeValueMapToFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getFileExtension(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getFileExtension'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:getFileExtension"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getFileExtension'", nullptr); return 0; } std::string ret = cobj->getFileExtension(arg0); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getFileExtension",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getFileExtension'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_setWritablePath(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_setWritablePath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:setWritablePath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_setWritablePath'", nullptr); return 0; } cobj->setWritablePath(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:setWritablePath",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_setWritablePath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_setPopupNotify(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_setPopupNotify'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.FileUtils:setPopupNotify"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_setPopupNotify'", nullptr); return 0; } cobj->setPopupNotify(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:setPopupNotify",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_setPopupNotify'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_isDirectoryExist(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_isDirectoryExist'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:isDirectoryExist"); if (!ok) { break; } std::function<void (bool)> arg1; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->isDirectoryExist(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:isDirectoryExist"); if (!ok) { break; } bool ret = cobj->isDirectoryExist(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:isDirectoryExist",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_isDirectoryExist'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_setDefaultResourceRootPath(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_setDefaultResourceRootPath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:setDefaultResourceRootPath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_setDefaultResourceRootPath'", nullptr); return 0; } cobj->setDefaultResourceRootPath(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:setDefaultResourceRootPath",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_setDefaultResourceRootPath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getSearchResolutionsOrder(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getSearchResolutionsOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getSearchResolutionsOrder'", nullptr); return 0; } const std::vector<std::string>& ret = cobj->getSearchResolutionsOrder(); ccvector_std_string_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getSearchResolutionsOrder",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getSearchResolutionsOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_createDirectory(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_createDirectory'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:createDirectory"); if (!ok) { break; } std::function<void (bool)> arg1; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } cobj->createDirectory(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:createDirectory"); if (!ok) { break; } bool ret = cobj->createDirectory(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:createDirectory",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_createDirectory'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_listFilesRecursively(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_listFilesRecursively'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::vector<std::basic_string<char>, std::allocator<std::basic_string<char> > >* arg1 = nullptr; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.FileUtils:listFilesRecursively"); ok &= luaval_to_object<std::vector<std::basic_string<char>, std::allocator<std::basic_string<char> > >>(tolua_S, 3, "std::vector<std::basic_string<char>, std::allocator<std::basic_string<char> > >*",&arg1, "cc.FileUtils:listFilesRecursively"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_listFilesRecursively'", nullptr); return 0; } cobj->listFilesRecursively(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:listFilesRecursively",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_listFilesRecursively'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getWritablePath(lua_State* tolua_S) { int argc = 0; cocos2d::FileUtils* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FileUtils*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FileUtils_getWritablePath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getWritablePath'", nullptr); return 0; } std::string ret = cobj->getWritablePath(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FileUtils:getWritablePath",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getWritablePath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_destroyInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_destroyInstance'", nullptr); return 0; } cocos2d::FileUtils::destroyInstance(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FileUtils:destroyInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_destroyInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FileUtils_getInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FileUtils",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FileUtils_getInstance'", nullptr); return 0; } cocos2d::FileUtils* ret = cocos2d::FileUtils::getInstance(); object_to_luaval<cocos2d::FileUtils>(tolua_S, "cc.FileUtils",(cocos2d::FileUtils*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FileUtils:getInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FileUtils_getInstance'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FileUtils_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FileUtils)"); return 0; } int lua_register_cocos2dx_FileUtils(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FileUtils"); tolua_cclass(tolua_S,"FileUtils","cc.FileUtils","",nullptr); tolua_beginmodule(tolua_S,"FileUtils"); tolua_function(tolua_S,"fullPathForFilename",lua_cocos2dx_FileUtils_fullPathForFilename); tolua_function(tolua_S,"getStringFromFile",lua_cocos2dx_FileUtils_getStringFromFile); tolua_function(tolua_S,"setFilenameLookupDictionary",lua_cocos2dx_FileUtils_setFilenameLookupDictionary); tolua_function(tolua_S,"removeFile",lua_cocos2dx_FileUtils_removeFile); tolua_function(tolua_S,"isAbsolutePath",lua_cocos2dx_FileUtils_isAbsolutePath); tolua_function(tolua_S,"renameFile",lua_cocos2dx_FileUtils_renameFile); tolua_function(tolua_S,"getDefaultResourceRootPath",lua_cocos2dx_FileUtils_getDefaultResourceRootPath); tolua_function(tolua_S,"loadFilenameLookup",lua_cocos2dx_FileUtils_loadFilenameLookupDictionaryFromFile); tolua_function(tolua_S,"isPopupNotify",lua_cocos2dx_FileUtils_isPopupNotify); tolua_function(tolua_S,"getValueVectorFromFile",lua_cocos2dx_FileUtils_getValueVectorFromFile); tolua_function(tolua_S,"getSearchPaths",lua_cocos2dx_FileUtils_getSearchPaths); tolua_function(tolua_S,"writeToFile",lua_cocos2dx_FileUtils_writeToFile); tolua_function(tolua_S,"getOriginalSearchPaths",lua_cocos2dx_FileUtils_getOriginalSearchPaths); tolua_function(tolua_S,"getNewFilename",lua_cocos2dx_FileUtils_getNewFilename); tolua_function(tolua_S,"listFiles",lua_cocos2dx_FileUtils_listFiles); tolua_function(tolua_S,"getValueMapFromFile",lua_cocos2dx_FileUtils_getValueMapFromFile); tolua_function(tolua_S,"getFileSize",lua_cocos2dx_FileUtils_getFileSize); tolua_function(tolua_S,"getValueMapFromData",lua_cocos2dx_FileUtils_getValueMapFromData); tolua_function(tolua_S,"removeDirectory",lua_cocos2dx_FileUtils_removeDirectory); tolua_function(tolua_S,"setSearchPaths",lua_cocos2dx_FileUtils_setSearchPaths); tolua_function(tolua_S,"writeStringToFile",lua_cocos2dx_FileUtils_writeStringToFile); tolua_function(tolua_S,"setSearchResolutionsOrder",lua_cocos2dx_FileUtils_setSearchResolutionsOrder); tolua_function(tolua_S,"addSearchResolutionsOrder",lua_cocos2dx_FileUtils_addSearchResolutionsOrder); tolua_function(tolua_S,"addSearchPath",lua_cocos2dx_FileUtils_addSearchPath); tolua_function(tolua_S,"writeValueVectorToFile",lua_cocos2dx_FileUtils_writeValueVectorToFile); tolua_function(tolua_S,"isFileExist",lua_cocos2dx_FileUtils_isFileExist); tolua_function(tolua_S,"purgeCachedEntries",lua_cocos2dx_FileUtils_purgeCachedEntries); tolua_function(tolua_S,"fullPathFromRelativeFile",lua_cocos2dx_FileUtils_fullPathFromRelativeFile); tolua_function(tolua_S,"getSuitableFOpen",lua_cocos2dx_FileUtils_getSuitableFOpen); tolua_function(tolua_S,"writeValueMapToFile",lua_cocos2dx_FileUtils_writeValueMapToFile); tolua_function(tolua_S,"getFileExtension",lua_cocos2dx_FileUtils_getFileExtension); tolua_function(tolua_S,"setWritablePath",lua_cocos2dx_FileUtils_setWritablePath); tolua_function(tolua_S,"setPopupNotify",lua_cocos2dx_FileUtils_setPopupNotify); tolua_function(tolua_S,"isDirectoryExist",lua_cocos2dx_FileUtils_isDirectoryExist); tolua_function(tolua_S,"setDefaultResourceRootPath",lua_cocos2dx_FileUtils_setDefaultResourceRootPath); tolua_function(tolua_S,"getSearchResolutionsOrder",lua_cocos2dx_FileUtils_getSearchResolutionsOrder); tolua_function(tolua_S,"createDirectory",lua_cocos2dx_FileUtils_createDirectory); tolua_function(tolua_S,"listFilesRecursively",lua_cocos2dx_FileUtils_listFilesRecursively); tolua_function(tolua_S,"getWritablePath",lua_cocos2dx_FileUtils_getWritablePath); tolua_function(tolua_S,"destroyInstance", lua_cocos2dx_FileUtils_destroyInstance); tolua_function(tolua_S,"getInstance", lua_cocos2dx_FileUtils_getInstance); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FileUtils).name(); g_luaType[typeName] = "cc.FileUtils"; g_typeCast["FileUtils"] = "cc.FileUtils"; return 1; } static int lua_cocos2dx_EventAcceleration_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventAcceleration)"); return 0; } int lua_register_cocos2dx_EventAcceleration(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventAcceleration"); tolua_cclass(tolua_S,"EventAcceleration","cc.EventAcceleration","cc.Event",nullptr); tolua_beginmodule(tolua_S,"EventAcceleration"); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventAcceleration).name(); g_luaType[typeName] = "cc.EventAcceleration"; g_typeCast["EventAcceleration"] = "cc.EventAcceleration"; return 1; } int lua_cocos2dx_EventCustom_getEventName(lua_State* tolua_S) { int argc = 0; cocos2d::EventCustom* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventCustom",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventCustom*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventCustom_getEventName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventCustom_getEventName'", nullptr); return 0; } const std::string& ret = cobj->getEventName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventCustom:getEventName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventCustom_getEventName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventCustom_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventCustom* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.EventCustom:EventCustom"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventCustom_constructor'", nullptr); return 0; } cobj = new cocos2d::EventCustom(arg0); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventCustom"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventCustom:EventCustom",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventCustom_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventCustom_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventCustom)"); return 0; } int lua_register_cocos2dx_EventCustom(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventCustom"); tolua_cclass(tolua_S,"EventCustom","cc.EventCustom","cc.Event",nullptr); tolua_beginmodule(tolua_S,"EventCustom"); tolua_function(tolua_S,"new",lua_cocos2dx_EventCustom_constructor); tolua_function(tolua_S,"getEventName",lua_cocos2dx_EventCustom_getEventName); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventCustom).name(); g_luaType[typeName] = "cc.EventCustom"; g_typeCast["EventCustom"] = "cc.EventCustom"; return 1; } int lua_cocos2dx_EventListener_setEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::EventListener* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListener",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListener*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListener_setEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.EventListener:setEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListener_setEnabled'", nullptr); return 0; } cobj->setEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListener:setEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListener_setEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListener_isEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::EventListener* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListener",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListener*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListener_isEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListener_isEnabled'", nullptr); return 0; } bool ret = cobj->isEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListener:isEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListener_isEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListener_clone(lua_State* tolua_S) { int argc = 0; cocos2d::EventListener* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListener",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListener*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListener_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListener_clone'", nullptr); return 0; } cocos2d::EventListener* ret = cobj->clone(); object_to_luaval<cocos2d::EventListener>(tolua_S, "cc.EventListener",(cocos2d::EventListener*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListener:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListener_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListener_checkAvailable(lua_State* tolua_S) { int argc = 0; cocos2d::EventListener* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListener",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListener*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListener_checkAvailable'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListener_checkAvailable'", nullptr); return 0; } bool ret = cobj->checkAvailable(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListener:checkAvailable",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListener_checkAvailable'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventListener_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListener)"); return 0; } int lua_register_cocos2dx_EventListener(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventListener"); tolua_cclass(tolua_S,"EventListener","cc.EventListener","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"EventListener"); tolua_function(tolua_S,"setEnabled",lua_cocos2dx_EventListener_setEnabled); tolua_function(tolua_S,"isEnabled",lua_cocos2dx_EventListener_isEnabled); tolua_function(tolua_S,"clone",lua_cocos2dx_EventListener_clone); tolua_function(tolua_S,"checkAvailable",lua_cocos2dx_EventListener_checkAvailable); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListener).name(); g_luaType[typeName] = "cc.EventListener"; g_typeCast["EventListener"] = "cc.EventListener"; return 1; } int lua_cocos2dx_EventDispatcher_pauseEventListenersForTarget(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_pauseEventListenersForTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.EventDispatcher:pauseEventListenersForTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_pauseEventListenersForTarget'", nullptr); return 0; } cobj->pauseEventListenersForTarget(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { cocos2d::Node* arg0 = nullptr; bool arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.EventDispatcher:pauseEventListenersForTarget"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.EventDispatcher:pauseEventListenersForTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_pauseEventListenersForTarget'", nullptr); return 0; } cobj->pauseEventListenersForTarget(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:pauseEventListenersForTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_pauseEventListenersForTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_addEventListenerWithSceneGraphPriority(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_addEventListenerWithSceneGraphPriority'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::EventListener* arg0 = nullptr; cocos2d::Node* arg1 = nullptr; ok &= luaval_to_object<cocos2d::EventListener>(tolua_S, 2, "cc.EventListener",&arg0, "cc.EventDispatcher:addEventListenerWithSceneGraphPriority"); ok &= luaval_to_object<cocos2d::Node>(tolua_S, 3, "cc.Node",&arg1, "cc.EventDispatcher:addEventListenerWithSceneGraphPriority"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_addEventListenerWithSceneGraphPriority'", nullptr); return 0; } cobj->addEventListenerWithSceneGraphPriority(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:addEventListenerWithSceneGraphPriority",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_addEventListenerWithSceneGraphPriority'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_setEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_setEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.EventDispatcher:setEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_setEnabled'", nullptr); return 0; } cobj->setEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:setEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_setEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_addEventListenerWithFixedPriority(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_addEventListenerWithFixedPriority'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::EventListener* arg0 = nullptr; int arg1; ok &= luaval_to_object<cocos2d::EventListener>(tolua_S, 2, "cc.EventListener",&arg0, "cc.EventDispatcher:addEventListenerWithFixedPriority"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.EventDispatcher:addEventListenerWithFixedPriority"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_addEventListenerWithFixedPriority'", nullptr); return 0; } cobj->addEventListenerWithFixedPriority(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:addEventListenerWithFixedPriority",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_addEventListenerWithFixedPriority'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_removeEventListener(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_removeEventListener'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventListener* arg0 = nullptr; ok &= luaval_to_object<cocos2d::EventListener>(tolua_S, 2, "cc.EventListener",&arg0, "cc.EventDispatcher:removeEventListener"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_removeEventListener'", nullptr); return 0; } cobj->removeEventListener(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:removeEventListener",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_removeEventListener'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_dispatchCustomEvent(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_dispatchCustomEvent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.EventDispatcher:dispatchCustomEvent"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_dispatchCustomEvent'", nullptr); return 0; } cobj->dispatchCustomEvent(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { std::string arg0; void* arg1 = nullptr; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.EventDispatcher:dispatchCustomEvent"); #pragma warning NO CONVERSION TO NATIVE FOR void* ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_dispatchCustomEvent'", nullptr); return 0; } cobj->dispatchCustomEvent(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:dispatchCustomEvent",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_dispatchCustomEvent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_resumeEventListenersForTarget(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_resumeEventListenersForTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.EventDispatcher:resumeEventListenersForTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_resumeEventListenersForTarget'", nullptr); return 0; } cobj->resumeEventListenersForTarget(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { cocos2d::Node* arg0 = nullptr; bool arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.EventDispatcher:resumeEventListenersForTarget"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.EventDispatcher:resumeEventListenersForTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_resumeEventListenersForTarget'", nullptr); return 0; } cobj->resumeEventListenersForTarget(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:resumeEventListenersForTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_resumeEventListenersForTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_removeEventListenersForTarget(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_removeEventListenersForTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.EventDispatcher:removeEventListenersForTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_removeEventListenersForTarget'", nullptr); return 0; } cobj->removeEventListenersForTarget(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { cocos2d::Node* arg0 = nullptr; bool arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.EventDispatcher:removeEventListenersForTarget"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.EventDispatcher:removeEventListenersForTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_removeEventListenersForTarget'", nullptr); return 0; } cobj->removeEventListenersForTarget(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:removeEventListenersForTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_removeEventListenersForTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_setPriority(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_setPriority'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::EventListener* arg0 = nullptr; int arg1; ok &= luaval_to_object<cocos2d::EventListener>(tolua_S, 2, "cc.EventListener",&arg0, "cc.EventDispatcher:setPriority"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.EventDispatcher:setPriority"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_setPriority'", nullptr); return 0; } cobj->setPriority(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:setPriority",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_setPriority'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_addCustomEventListener(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_addCustomEventListener'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::function<void (cocos2d::EventCustom *)> arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.EventDispatcher:addCustomEventListener"); do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_addCustomEventListener'", nullptr); return 0; } cocos2d::EventListenerCustom* ret = cobj->addCustomEventListener(arg0, arg1); object_to_luaval<cocos2d::EventListenerCustom>(tolua_S, "cc.EventListenerCustom",(cocos2d::EventListenerCustom*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:addCustomEventListener",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_addCustomEventListener'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_dispatchEvent(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_dispatchEvent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Event* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Event>(tolua_S, 2, "cc.Event",&arg0, "cc.EventDispatcher:dispatchEvent"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_dispatchEvent'", nullptr); return 0; } cobj->dispatchEvent(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:dispatchEvent",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_dispatchEvent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_hasEventListener(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_hasEventListener'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventListener::ListenerID arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.EventDispatcher:hasEventListener"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_hasEventListener'", nullptr); return 0; } bool ret = cobj->hasEventListener(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:hasEventListener",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_hasEventListener'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_removeAllEventListeners(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_removeAllEventListeners'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_removeAllEventListeners'", nullptr); return 0; } cobj->removeAllEventListeners(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:removeAllEventListeners",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_removeAllEventListeners'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_removeCustomEventListeners(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_removeCustomEventListeners'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.EventDispatcher:removeCustomEventListeners"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_removeCustomEventListeners'", nullptr); return 0; } cobj->removeCustomEventListeners(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:removeCustomEventListeners",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_removeCustomEventListeners'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_isEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_isEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_isEnabled'", nullptr); return 0; } bool ret = cobj->isEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:isEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_isEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_removeEventListenersForType(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventDispatcher",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventDispatcher*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventDispatcher_removeEventListenersForType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventListener::Type arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EventDispatcher:removeEventListenersForType"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_removeEventListenersForType'", nullptr); return 0; } cobj->removeEventListenersForType(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:removeEventListenersForType",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_removeEventListenersForType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventDispatcher_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventDispatcher* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventDispatcher_constructor'", nullptr); return 0; } cobj = new cocos2d::EventDispatcher(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventDispatcher"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventDispatcher:EventDispatcher",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventDispatcher_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventDispatcher_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventDispatcher)"); return 0; } int lua_register_cocos2dx_EventDispatcher(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventDispatcher"); tolua_cclass(tolua_S,"EventDispatcher","cc.EventDispatcher","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"EventDispatcher"); tolua_function(tolua_S,"new",lua_cocos2dx_EventDispatcher_constructor); tolua_function(tolua_S,"pauseEventListenersForTarget",lua_cocos2dx_EventDispatcher_pauseEventListenersForTarget); tolua_function(tolua_S,"addEventListenerWithSceneGraphPriority",lua_cocos2dx_EventDispatcher_addEventListenerWithSceneGraphPriority); tolua_function(tolua_S,"setEnabled",lua_cocos2dx_EventDispatcher_setEnabled); tolua_function(tolua_S,"addEventListenerWithFixedPriority",lua_cocos2dx_EventDispatcher_addEventListenerWithFixedPriority); tolua_function(tolua_S,"removeEventListener",lua_cocos2dx_EventDispatcher_removeEventListener); tolua_function(tolua_S,"dispatchCustomEvent",lua_cocos2dx_EventDispatcher_dispatchCustomEvent); tolua_function(tolua_S,"resumeEventListenersForTarget",lua_cocos2dx_EventDispatcher_resumeEventListenersForTarget); tolua_function(tolua_S,"removeEventListenersForTarget",lua_cocos2dx_EventDispatcher_removeEventListenersForTarget); tolua_function(tolua_S,"setPriority",lua_cocos2dx_EventDispatcher_setPriority); tolua_function(tolua_S,"addCustomEventListener",lua_cocos2dx_EventDispatcher_addCustomEventListener); tolua_function(tolua_S,"dispatchEvent",lua_cocos2dx_EventDispatcher_dispatchEvent); tolua_function(tolua_S,"hasEventListener",lua_cocos2dx_EventDispatcher_hasEventListener); tolua_function(tolua_S,"removeAllEventListeners",lua_cocos2dx_EventDispatcher_removeAllEventListeners); tolua_function(tolua_S,"removeCustomEventListeners",lua_cocos2dx_EventDispatcher_removeCustomEventListeners); tolua_function(tolua_S,"isEnabled",lua_cocos2dx_EventDispatcher_isEnabled); tolua_function(tolua_S,"removeEventListenersForType",lua_cocos2dx_EventDispatcher_removeEventListenersForType); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventDispatcher).name(); g_luaType[typeName] = "cc.EventDispatcher"; g_typeCast["EventDispatcher"] = "cc.EventDispatcher"; return 1; } int lua_cocos2dx_EventFocus_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventFocus* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::ui::Widget* arg0 = nullptr; cocos2d::ui::Widget* arg1 = nullptr; ok &= luaval_to_object<cocos2d::ui::Widget>(tolua_S, 2, "ccui.Widget",&arg0, "cc.EventFocus:EventFocus"); ok &= luaval_to_object<cocos2d::ui::Widget>(tolua_S, 3, "ccui.Widget",&arg1, "cc.EventFocus:EventFocus"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventFocus_constructor'", nullptr); return 0; } cobj = new cocos2d::EventFocus(arg0, arg1); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventFocus"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventFocus:EventFocus",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventFocus_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventFocus_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventFocus)"); return 0; } int lua_register_cocos2dx_EventFocus(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventFocus"); tolua_cclass(tolua_S,"EventFocus","cc.EventFocus","cc.Event",nullptr); tolua_beginmodule(tolua_S,"EventFocus"); tolua_function(tolua_S,"new",lua_cocos2dx_EventFocus_constructor); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventFocus).name(); g_luaType[typeName] = "cc.EventFocus"; g_typeCast["EventFocus"] = "cc.EventFocus"; return 1; } int lua_cocos2dx_EventListenerAcceleration_init(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerAcceleration* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListenerAcceleration",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListenerAcceleration*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListenerAcceleration_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::function<void (cocos2d::Acceleration *, cocos2d::Event *)> arg0; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerAcceleration_init'", nullptr); return 0; } bool ret = cobj->init(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerAcceleration:init",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerAcceleration_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListenerAcceleration_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerAcceleration* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerAcceleration_constructor'", nullptr); return 0; } cobj = new cocos2d::EventListenerAcceleration(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventListenerAcceleration"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerAcceleration:EventListenerAcceleration",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerAcceleration_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventListenerAcceleration_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListenerAcceleration)"); return 0; } int lua_register_cocos2dx_EventListenerAcceleration(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventListenerAcceleration"); tolua_cclass(tolua_S,"EventListenerAcceleration","cc.EventListenerAcceleration","cc.EventListener",nullptr); tolua_beginmodule(tolua_S,"EventListenerAcceleration"); tolua_function(tolua_S,"new",lua_cocos2dx_EventListenerAcceleration_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_EventListenerAcceleration_init); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListenerAcceleration).name(); g_luaType[typeName] = "cc.EventListenerAcceleration"; g_typeCast["EventListenerAcceleration"] = "cc.EventListenerAcceleration"; return 1; } int lua_cocos2dx_EventListenerCustom_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerCustom* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerCustom_constructor'", nullptr); return 0; } cobj = new cocos2d::EventListenerCustom(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventListenerCustom"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerCustom:EventListenerCustom",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerCustom_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventListenerCustom_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListenerCustom)"); return 0; } int lua_register_cocos2dx_EventListenerCustom(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventListenerCustom"); tolua_cclass(tolua_S,"EventListenerCustom","cc.EventListenerCustom","cc.EventListener",nullptr); tolua_beginmodule(tolua_S,"EventListenerCustom"); tolua_function(tolua_S,"new",lua_cocos2dx_EventListenerCustom_constructor); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListenerCustom).name(); g_luaType[typeName] = "cc.EventListenerCustom"; g_typeCast["EventListenerCustom"] = "cc.EventListenerCustom"; return 1; } int lua_cocos2dx_EventListenerFocus_init(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerFocus* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListenerFocus",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListenerFocus*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListenerFocus_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerFocus_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerFocus:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerFocus_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListenerFocus_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerFocus* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerFocus_constructor'", nullptr); return 0; } cobj = new cocos2d::EventListenerFocus(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventListenerFocus"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerFocus:EventListenerFocus",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerFocus_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventListenerFocus_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListenerFocus)"); return 0; } int lua_register_cocos2dx_EventListenerFocus(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventListenerFocus"); tolua_cclass(tolua_S,"EventListenerFocus","cc.EventListenerFocus","cc.EventListener",nullptr); tolua_beginmodule(tolua_S,"EventListenerFocus"); tolua_function(tolua_S,"new",lua_cocos2dx_EventListenerFocus_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_EventListenerFocus_init); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListenerFocus).name(); g_luaType[typeName] = "cc.EventListenerFocus"; g_typeCast["EventListenerFocus"] = "cc.EventListenerFocus"; return 1; } #if CC_TARGET_PLATFORM != CC_PLATFORM_WIN32 int lua_cocos2dx_controller_Controller_receiveExternalKeyEvent(lua_State* tolua_S) { int argc = 0; cocos2d::Controller* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Controller*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_Controller_receiveExternalKeyEvent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { int arg0; bool arg1; ok &= luaval_to_int32(tolua_S, 2, (int*)&arg0, "cc.Controller:receiveExternalKeyEvent"); ok &= luaval_to_boolean(tolua_S, 3, &arg1, "cc.Controller:receiveExternalKeyEvent"); if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_receiveExternalKeyEvent'", nullptr); return 0; } cobj->receiveExternalKeyEvent(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Controller:receiveExternalKeyEvent", argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_receiveExternalKeyEvent'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_getDeviceName(lua_State* tolua_S) { int argc = 0; cocos2d::Controller* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Controller*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_Controller_getDeviceName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_getDeviceName'", nullptr); return 0; } const std::string& ret = cobj->getDeviceName(); lua_pushlstring(tolua_S, ret.c_str(), ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Controller:getDeviceName", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_getDeviceName'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_isConnected(lua_State* tolua_S) { int argc = 0; cocos2d::Controller* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Controller*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_Controller_isConnected'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_isConnected'", nullptr); return 0; } bool ret = cobj->isConnected(); tolua_pushboolean(tolua_S, (bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Controller:isConnected", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_isConnected'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_getDeviceId(lua_State* tolua_S) { int argc = 0; cocos2d::Controller* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Controller*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_Controller_getDeviceId'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_getDeviceId'", nullptr); return 0; } int ret = cobj->getDeviceId(); tolua_pushnumber(tolua_S, (lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Controller:getDeviceId", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_getDeviceId'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_setTag(lua_State* tolua_S) { int argc = 0; cocos2d::Controller* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Controller*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_Controller_setTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2, (int*)&arg0, "cc.Controller:setTag"); if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_setTag'", nullptr); return 0; } cobj->setTag(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Controller:setTag", argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_setTag'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_getTag(lua_State* tolua_S) { int argc = 0; cocos2d::Controller* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Controller*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_Controller_getTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_getTag'", nullptr); return 0; } int ret = cobj->getTag(); tolua_pushnumber(tolua_S, (lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Controller:getTag", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_getTag'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_startDiscoveryController(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_startDiscoveryController'", nullptr); return 0; } cocos2d::Controller::startDiscoveryController(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Controller:startDiscoveryController", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_startDiscoveryController'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_stopDiscoveryController(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_stopDiscoveryController'", nullptr); return 0; } cocos2d::Controller::stopDiscoveryController(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Controller:stopDiscoveryController", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_stopDiscoveryController'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_getControllerByDeviceId(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2, (int*)&arg0, "cc.Controller:getControllerByDeviceId"); if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_getControllerByDeviceId'", nullptr); return 0; } cocos2d::Controller* ret = cocos2d::Controller::getControllerByDeviceId(arg0); object_to_luaval<cocos2d::Controller>(tolua_S, "cc.Controller", (cocos2d::Controller*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Controller:getControllerByDeviceId", argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_getControllerByDeviceId'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_Controller_getControllerByTag(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S, 1, "cc.Controller", 0, &tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2, (int*)&arg0, "cc.Controller:getControllerByTag"); if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_Controller_getControllerByTag'", nullptr); return 0; } cocos2d::Controller* ret = cocos2d::Controller::getControllerByTag(arg0); object_to_luaval<cocos2d::Controller>(tolua_S, "cc.Controller", (cocos2d::Controller*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Controller:getControllerByTag", argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_Controller_getControllerByTag'.", &tolua_err); #endif return 0; } static int lua_cocos2dx_controller_Controller_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Controller)"); return 0; } int lua_register_cocos2dx_controller_Controller(lua_State* tolua_S) { tolua_usertype(tolua_S, "cc.Controller"); tolua_cclass(tolua_S, "Controller", "cc.Controller", "", nullptr); tolua_beginmodule(tolua_S, "Controller"); tolua_function(tolua_S, "receiveExternalKeyEvent", lua_cocos2dx_controller_Controller_receiveExternalKeyEvent); tolua_function(tolua_S, "getDeviceName", lua_cocos2dx_controller_Controller_getDeviceName); tolua_function(tolua_S, "isConnected", lua_cocos2dx_controller_Controller_isConnected); tolua_function(tolua_S, "getDeviceId", lua_cocos2dx_controller_Controller_getDeviceId); tolua_function(tolua_S, "setTag", lua_cocos2dx_controller_Controller_setTag); tolua_function(tolua_S, "getTag", lua_cocos2dx_controller_Controller_getTag); tolua_function(tolua_S, "startDiscoveryController", lua_cocos2dx_controller_Controller_startDiscoveryController); tolua_function(tolua_S, "stopDiscoveryController", lua_cocos2dx_controller_Controller_stopDiscoveryController); tolua_function(tolua_S, "getControllerByDeviceId", lua_cocos2dx_controller_Controller_getControllerByDeviceId); tolua_function(tolua_S, "getControllerByTag", lua_cocos2dx_controller_Controller_getControllerByTag); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Controller).name(); g_luaType[typeName] = "cc.Controller"; g_typeCast["Controller"] = "cc.Controller"; return 1; } int lua_cocos2dx_controller_EventController_getControllerEventType(lua_State* tolua_S) { int argc = 0; cocos2d::EventController* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.EventController", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventController*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_EventController_getControllerEventType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_EventController_getControllerEventType'", nullptr); return 0; } int ret = (int)cobj->getControllerEventType(); tolua_pushnumber(tolua_S, (lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventController:getControllerEventType", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_EventController_getControllerEventType'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_EventController_setConnectStatus(lua_State* tolua_S) { int argc = 0; cocos2d::EventController* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.EventController", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventController*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_EventController_setConnectStatus'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2, &arg0, "cc.EventController:setConnectStatus"); if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_EventController_setConnectStatus'", nullptr); return 0; } cobj->setConnectStatus(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventController:setConnectStatus", argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_EventController_setConnectStatus'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_EventController_isConnected(lua_State* tolua_S) { int argc = 0; cocos2d::EventController* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.EventController", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventController*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_EventController_isConnected'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_EventController_isConnected'", nullptr); return 0; } bool ret = cobj->isConnected(); tolua_pushboolean(tolua_S, (bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventController:isConnected", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_EventController_isConnected'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_EventController_setKeyCode(lua_State* tolua_S) { int argc = 0; cocos2d::EventController* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.EventController", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventController*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_EventController_setKeyCode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2, (int*)&arg0, "cc.EventController:setKeyCode"); if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_EventController_setKeyCode'", nullptr); return 0; } cobj->setKeyCode(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventController:setKeyCode", argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_EventController_setKeyCode'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_EventController_getController(lua_State* tolua_S) { int argc = 0; cocos2d::EventController* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.EventController", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventController*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_EventController_getController'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_EventController_getController'", nullptr); return 0; } cocos2d::Controller* ret = cobj->getController(); object_to_luaval<cocos2d::Controller>(tolua_S, "cc.Controller", (cocos2d::Controller*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventController:getController", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_EventController_getController'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_EventController_getKeyCode(lua_State* tolua_S) { int argc = 0; cocos2d::EventController* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.EventController", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventController*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_controller_EventController_getKeyCode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_EventController_getKeyCode'", nullptr); return 0; } int ret = cobj->getKeyCode(); tolua_pushnumber(tolua_S, (lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventController:getKeyCode", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_EventController_getKeyCode'.", &tolua_err); #endif return 0; } int lua_cocos2dx_controller_EventController_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventController* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S) - 1; do { if (argc == 3) { cocos2d::EventController::ControllerEventType arg0; ok &= luaval_to_int32(tolua_S, 2, (int*)&arg0, "cc.EventController:EventController"); if (!ok) { break; } cocos2d::Controller* arg1; ok &= luaval_to_object<cocos2d::Controller>(tolua_S, 3, "cc.Controller", &arg1, "cc.EventController:EventController"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4, &arg2, "cc.EventController:EventController"); if (!ok) { break; } cobj = new cocos2d::EventController(arg0, arg1, arg2); cobj->autorelease(); int ID = (int)cobj->_ID; int* luaID = &cobj->_luaID; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj, "cc.EventController"); return 1; } } while (0); ok = true; do { if (argc == 3) { cocos2d::EventController::ControllerEventType arg0; ok &= luaval_to_int32(tolua_S, 2, (int*)&arg0, "cc.EventController:EventController"); if (!ok) { break; } cocos2d::Controller* arg1; ok &= luaval_to_object<cocos2d::Controller>(tolua_S, 3, "cc.Controller", &arg1, "cc.EventController:EventController"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4, (int*)&arg2, "cc.EventController:EventController"); if (!ok) { break; } cobj = new cocos2d::EventController(arg0, arg1, arg2); cobj->autorelease(); int ID = (int)cobj->_ID; int* luaID = &cobj->_luaID; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj, "cc.EventController"); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventController:EventController", argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_EventController_constructor'.", &tolua_err); #endif return 0; } static int lua_cocos2dx_controller_EventController_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventController)"); return 0; } int lua_register_cocos2dx_controller_EventController(lua_State* tolua_S) { tolua_usertype(tolua_S, "cc.EventController"); tolua_cclass(tolua_S, "EventController", "cc.EventController", "cc.Event", nullptr); tolua_beginmodule(tolua_S, "EventController"); tolua_function(tolua_S, "new", lua_cocos2dx_controller_EventController_constructor); tolua_function(tolua_S, "getControllerEventType", lua_cocos2dx_controller_EventController_getControllerEventType); tolua_function(tolua_S, "setConnectStatus", lua_cocos2dx_controller_EventController_setConnectStatus); tolua_function(tolua_S, "isConnected", lua_cocos2dx_controller_EventController_isConnected); tolua_function(tolua_S, "setKeyCode", lua_cocos2dx_controller_EventController_setKeyCode); tolua_function(tolua_S, "getController", lua_cocos2dx_controller_EventController_getController); tolua_function(tolua_S, "getKeyCode", lua_cocos2dx_controller_EventController_getKeyCode); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventController).name(); g_luaType[typeName] = "cc.EventController"; g_typeCast["EventController"] = "cc.EventController"; return 1; } int lua_cocos2dx_controller_EventListenerController_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S, 1, "cc.EventListenerController", 0, &tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_controller_EventListenerController_create'", nullptr); return 0; } cocos2d::EventListenerController* ret = cocos2d::EventListenerController::create(); object_to_luaval<cocos2d::EventListenerController>(tolua_S, "cc.EventListenerController", (cocos2d::EventListenerController*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EventListenerController:create", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_controller_EventListenerController_create'.", &tolua_err); #endif return 0; } static int lua_cocos2dx_controller_EventListenerController_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListenerController)"); return 0; } int lua_register_cocos2dx_controller_EventListenerController(lua_State* tolua_S) { tolua_usertype(tolua_S, "cc.EventListenerController"); tolua_cclass(tolua_S, "EventListenerController", "cc.EventListenerController", "cc.EventListener", nullptr); tolua_beginmodule(tolua_S, "EventListenerController"); tolua_function(tolua_S, "create", lua_cocos2dx_controller_EventListenerController_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListenerController).name(); g_luaType[typeName] = "cc.EventListenerController"; g_typeCast["EventListenerController"] = "cc.EventListenerController"; return 1; } TOLUA_API int register_all_cocos2dx_controller(lua_State* tolua_S) { /* tolua_open(tolua_S); tolua_module(tolua_S, "cc", 0); tolua_beginmodule(tolua_S, "cc");*/ lua_register_cocos2dx_controller_EventListenerController(tolua_S); lua_register_cocos2dx_controller_Controller(tolua_S); lua_register_cocos2dx_controller_EventController(tolua_S); //tolua_endmodule(tolua_S); return 1; } #endif int lua_cocos2dx_EventListenerKeyboard_init(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerKeyboard* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListenerKeyboard",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListenerKeyboard*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListenerKeyboard_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerKeyboard_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerKeyboard:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerKeyboard_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListenerKeyboard_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerKeyboard* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerKeyboard_constructor'", nullptr); return 0; } cobj = new cocos2d::EventListenerKeyboard(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventListenerKeyboard"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerKeyboard:EventListenerKeyboard",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerKeyboard_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventListenerKeyboard_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListenerKeyboard)"); return 0; } int lua_register_cocos2dx_EventListenerKeyboard(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventListenerKeyboard"); tolua_cclass(tolua_S,"EventListenerKeyboard","cc.EventListenerKeyboard","cc.EventListener",nullptr); tolua_beginmodule(tolua_S,"EventListenerKeyboard"); tolua_function(tolua_S,"new",lua_cocos2dx_EventListenerKeyboard_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_EventListenerKeyboard_init); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListenerKeyboard).name(); g_luaType[typeName] = "cc.EventListenerKeyboard"; g_typeCast["EventListenerKeyboard"] = "cc.EventListenerKeyboard"; return 1; } int lua_cocos2dx_EventMouse_getPreviousLocationInView(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getPreviousLocationInView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getPreviousLocationInView'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getPreviousLocationInView(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getPreviousLocationInView",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getPreviousLocationInView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getLocation(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getLocation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getLocation'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getLocation(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getLocation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getLocation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getMouseButton(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getMouseButton'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getMouseButton'", nullptr); return 0; } int ret = (int)cobj->getMouseButton(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getMouseButton",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getMouseButton'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getPreviousLocation(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getPreviousLocation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getPreviousLocation'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getPreviousLocation(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getPreviousLocation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getPreviousLocation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getDelta(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getDelta'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getDelta'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getDelta(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getDelta",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getDelta'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_setScrollData(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_setScrollData'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; double arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.EventMouse:setScrollData"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EventMouse:setScrollData"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_setScrollData'", nullptr); return 0; } cobj->setScrollData(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:setScrollData",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_setScrollData'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getStartLocationInView(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getStartLocationInView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getStartLocationInView'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getStartLocationInView(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getStartLocationInView",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getStartLocationInView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getStartLocation(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getStartLocation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getStartLocation'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getStartLocation(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getStartLocation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getStartLocation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_setMouseButton(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_setMouseButton'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventMouse::MouseButton arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EventMouse:setMouseButton"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_setMouseButton'", nullptr); return 0; } cobj->setMouseButton(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:setMouseButton",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_setMouseButton'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getLocationInView(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getLocationInView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getLocationInView'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getLocationInView(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getLocationInView",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getLocationInView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getScrollY(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getScrollY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getScrollY'", nullptr); return 0; } double ret = cobj->getScrollY(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getScrollY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getScrollY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getScrollX(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getScrollX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getScrollX'", nullptr); return 0; } double ret = cobj->getScrollX(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getScrollX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getScrollX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getCursorX(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getCursorX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getCursorX'", nullptr); return 0; } double ret = cobj->getCursorX(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getCursorX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getCursorX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_getCursorY(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_getCursorY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_getCursorY'", nullptr); return 0; } double ret = cobj->getCursorY(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:getCursorY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_getCursorY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_setCursorPosition(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventMouse_setCursorPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; double arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.EventMouse:setCursorPosition"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EventMouse:setCursorPosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_setCursorPosition'", nullptr); return 0; } cobj->setCursorPosition(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:setCursorPosition",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_setCursorPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventMouse_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventMouse::MouseEventType arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EventMouse:EventMouse"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventMouse_constructor'", nullptr); return 0; } cobj = new cocos2d::EventMouse(arg0); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventMouse"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventMouse:EventMouse",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventMouse_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventMouse_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventMouse)"); return 0; } int lua_register_cocos2dx_EventMouse(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventMouse"); tolua_cclass(tolua_S,"EventMouse","cc.EventMouse","cc.Event",nullptr); tolua_beginmodule(tolua_S,"EventMouse"); tolua_function(tolua_S,"new",lua_cocos2dx_EventMouse_constructor); tolua_function(tolua_S,"getPreviousLocationInView",lua_cocos2dx_EventMouse_getPreviousLocationInView); tolua_function(tolua_S,"getLocation",lua_cocos2dx_EventMouse_getLocation); tolua_function(tolua_S,"getMouseButton",lua_cocos2dx_EventMouse_getMouseButton); tolua_function(tolua_S,"getPreviousLocation",lua_cocos2dx_EventMouse_getPreviousLocation); tolua_function(tolua_S,"getDelta",lua_cocos2dx_EventMouse_getDelta); tolua_function(tolua_S,"setScrollData",lua_cocos2dx_EventMouse_setScrollData); tolua_function(tolua_S,"getStartLocationInView",lua_cocos2dx_EventMouse_getStartLocationInView); tolua_function(tolua_S,"getStartLocation",lua_cocos2dx_EventMouse_getStartLocation); tolua_function(tolua_S,"setMouseButton",lua_cocos2dx_EventMouse_setMouseButton); tolua_function(tolua_S,"getLocationInView",lua_cocos2dx_EventMouse_getLocationInView); tolua_function(tolua_S,"getScrollY",lua_cocos2dx_EventMouse_getScrollY); tolua_function(tolua_S,"getScrollX",lua_cocos2dx_EventMouse_getScrollX); tolua_function(tolua_S,"getCursorX",lua_cocos2dx_EventMouse_getCursorX); tolua_function(tolua_S,"getCursorY",lua_cocos2dx_EventMouse_getCursorY); tolua_function(tolua_S,"setCursorPosition",lua_cocos2dx_EventMouse_setCursorPosition); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventMouse).name(); g_luaType[typeName] = "cc.EventMouse"; g_typeCast["EventMouse"] = "cc.EventMouse"; return 1; } int lua_cocos2dx_EventListenerMouse_init(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListenerMouse",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListenerMouse*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListenerMouse_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerMouse_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerMouse:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerMouse_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListenerMouse_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerMouse* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerMouse_constructor'", nullptr); return 0; } cobj = new cocos2d::EventListenerMouse(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventListenerMouse"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerMouse:EventListenerMouse",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerMouse_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventListenerMouse_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListenerMouse)"); return 0; } int lua_register_cocos2dx_EventListenerMouse(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventListenerMouse"); tolua_cclass(tolua_S,"EventListenerMouse","cc.EventListenerMouse","cc.EventListener",nullptr); tolua_beginmodule(tolua_S,"EventListenerMouse"); tolua_function(tolua_S,"new",lua_cocos2dx_EventListenerMouse_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_EventListenerMouse_init); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListenerMouse).name(); g_luaType[typeName] = "cc.EventListenerMouse"; g_typeCast["EventListenerMouse"] = "cc.EventListenerMouse"; return 1; } int lua_cocos2dx_EventListenerTouchOneByOne_isSwallowTouches(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerTouchOneByOne* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListenerTouchOneByOne",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListenerTouchOneByOne*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListenerTouchOneByOne_isSwallowTouches'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerTouchOneByOne_isSwallowTouches'", nullptr); return 0; } bool ret = cobj->isSwallowTouches(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerTouchOneByOne:isSwallowTouches",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerTouchOneByOne_isSwallowTouches'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListenerTouchOneByOne_setSwallowTouches(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerTouchOneByOne* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListenerTouchOneByOne",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListenerTouchOneByOne*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListenerTouchOneByOne_setSwallowTouches'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.EventListenerTouchOneByOne:setSwallowTouches"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerTouchOneByOne_setSwallowTouches'", nullptr); return 0; } cobj->setSwallowTouches(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerTouchOneByOne:setSwallowTouches",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerTouchOneByOne_setSwallowTouches'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListenerTouchOneByOne_init(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerTouchOneByOne* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListenerTouchOneByOne",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListenerTouchOneByOne*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListenerTouchOneByOne_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerTouchOneByOne_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerTouchOneByOne:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerTouchOneByOne_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListenerTouchOneByOne_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerTouchOneByOne* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerTouchOneByOne_constructor'", nullptr); return 0; } cobj = new cocos2d::EventListenerTouchOneByOne(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventListenerTouchOneByOne"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerTouchOneByOne:EventListenerTouchOneByOne",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerTouchOneByOne_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventListenerTouchOneByOne_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListenerTouchOneByOne)"); return 0; } int lua_register_cocos2dx_EventListenerTouchOneByOne(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventListenerTouchOneByOne"); tolua_cclass(tolua_S,"EventListenerTouchOneByOne","cc.EventListenerTouchOneByOne","cc.EventListener",nullptr); tolua_beginmodule(tolua_S,"EventListenerTouchOneByOne"); tolua_function(tolua_S,"new",lua_cocos2dx_EventListenerTouchOneByOne_constructor); tolua_function(tolua_S,"isSwallowTouches",lua_cocos2dx_EventListenerTouchOneByOne_isSwallowTouches); tolua_function(tolua_S,"setSwallowTouches",lua_cocos2dx_EventListenerTouchOneByOne_setSwallowTouches); tolua_function(tolua_S,"init",lua_cocos2dx_EventListenerTouchOneByOne_init); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListenerTouchOneByOne).name(); g_luaType[typeName] = "cc.EventListenerTouchOneByOne"; g_typeCast["EventListenerTouchOneByOne"] = "cc.EventListenerTouchOneByOne"; return 1; } int lua_cocos2dx_EventListenerTouchAllAtOnce_init(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerTouchAllAtOnce* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EventListenerTouchAllAtOnce",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EventListenerTouchAllAtOnce*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EventListenerTouchAllAtOnce_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerTouchAllAtOnce_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerTouchAllAtOnce:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerTouchAllAtOnce_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EventListenerTouchAllAtOnce_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EventListenerTouchAllAtOnce* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EventListenerTouchAllAtOnce_constructor'", nullptr); return 0; } cobj = new cocos2d::EventListenerTouchAllAtOnce(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EventListenerTouchAllAtOnce"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EventListenerTouchAllAtOnce:EventListenerTouchAllAtOnce",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EventListenerTouchAllAtOnce_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EventListenerTouchAllAtOnce_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EventListenerTouchAllAtOnce)"); return 0; } int lua_register_cocos2dx_EventListenerTouchAllAtOnce(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EventListenerTouchAllAtOnce"); tolua_cclass(tolua_S,"EventListenerTouchAllAtOnce","cc.EventListenerTouchAllAtOnce","cc.EventListener",nullptr); tolua_beginmodule(tolua_S,"EventListenerTouchAllAtOnce"); tolua_function(tolua_S,"new",lua_cocos2dx_EventListenerTouchAllAtOnce_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_EventListenerTouchAllAtOnce_init); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EventListenerTouchAllAtOnce).name(); g_luaType[typeName] = "cc.EventListenerTouchAllAtOnce"; g_typeCast["EventListenerTouchAllAtOnce"] = "cc.EventListenerTouchAllAtOnce"; return 1; } int lua_cocos2dx_ActionCamera_setEye(lua_State* tolua_S) { int argc = 0; cocos2d::ActionCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionCamera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionCamera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionCamera_setEye'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ActionCamera:setEye"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ActionCamera:setEye"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ActionCamera:setEye"); if (!ok) { break; } cobj->setEye(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.ActionCamera:setEye"); if (!ok) { break; } cobj->setEye(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionCamera:setEye",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionCamera_setEye'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionCamera_getEye(lua_State* tolua_S) { int argc = 0; cocos2d::ActionCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionCamera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionCamera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionCamera_getEye'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionCamera_getEye'", nullptr); return 0; } const cocos2d::Vec3& ret = cobj->getEye(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionCamera:getEye",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionCamera_getEye'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionCamera_setUp(lua_State* tolua_S) { int argc = 0; cocos2d::ActionCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionCamera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionCamera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionCamera_setUp'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.ActionCamera:setUp"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionCamera_setUp'", nullptr); return 0; } cobj->setUp(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionCamera:setUp",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionCamera_setUp'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionCamera_getCenter(lua_State* tolua_S) { int argc = 0; cocos2d::ActionCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionCamera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionCamera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionCamera_getCenter'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionCamera_getCenter'", nullptr); return 0; } const cocos2d::Vec3& ret = cobj->getCenter(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionCamera:getCenter",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionCamera_getCenter'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionCamera_setCenter(lua_State* tolua_S) { int argc = 0; cocos2d::ActionCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionCamera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionCamera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionCamera_setCenter'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.ActionCamera:setCenter"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionCamera_setCenter'", nullptr); return 0; } cobj->setCenter(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionCamera:setCenter",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionCamera_setCenter'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionCamera_getUp(lua_State* tolua_S) { int argc = 0; cocos2d::ActionCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionCamera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionCamera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionCamera_getUp'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionCamera_getUp'", nullptr); return 0; } const cocos2d::Vec3& ret = cobj->getUp(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionCamera:getUp",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionCamera_getUp'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionCamera_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ActionCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionCamera_constructor'", nullptr); return 0; } cobj = new cocos2d::ActionCamera(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ActionCamera"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionCamera:ActionCamera",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionCamera_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ActionCamera_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ActionCamera)"); return 0; } int lua_register_cocos2dx_ActionCamera(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ActionCamera"); tolua_cclass(tolua_S,"ActionCamera","cc.ActionCamera","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"ActionCamera"); tolua_function(tolua_S,"new",lua_cocos2dx_ActionCamera_constructor); tolua_function(tolua_S,"setEye",lua_cocos2dx_ActionCamera_setEye); tolua_function(tolua_S,"getEye",lua_cocos2dx_ActionCamera_getEye); tolua_function(tolua_S,"setUp",lua_cocos2dx_ActionCamera_setUp); tolua_function(tolua_S,"getCenter",lua_cocos2dx_ActionCamera_getCenter); tolua_function(tolua_S,"setCenter",lua_cocos2dx_ActionCamera_setCenter); tolua_function(tolua_S,"getUp",lua_cocos2dx_ActionCamera_getUp); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ActionCamera).name(); g_luaType[typeName] = "cc.ActionCamera"; g_typeCast["ActionCamera"] = "cc.ActionCamera"; return 1; } int lua_cocos2dx_OrbitCamera_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::OrbitCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.OrbitCamera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::OrbitCamera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_OrbitCamera_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 7) { double arg0; double arg1; double arg2; double arg3; double arg4; double arg5; double arg6; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.OrbitCamera:initWithDuration"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.OrbitCamera:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.OrbitCamera:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.OrbitCamera:initWithDuration"); ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.OrbitCamera:initWithDuration"); ok &= luaval_to_number(tolua_S, 7,&arg5, "cc.OrbitCamera:initWithDuration"); ok &= luaval_to_number(tolua_S, 8,&arg6, "cc.OrbitCamera:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_OrbitCamera_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3, arg4, arg5, arg6); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.OrbitCamera:initWithDuration",argc, 7); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_OrbitCamera_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_OrbitCamera_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.OrbitCamera",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 7) { double arg0; double arg1; double arg2; double arg3; double arg4; double arg5; double arg6; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.OrbitCamera:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.OrbitCamera:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.OrbitCamera:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.OrbitCamera:create"); ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.OrbitCamera:create"); ok &= luaval_to_number(tolua_S, 7,&arg5, "cc.OrbitCamera:create"); ok &= luaval_to_number(tolua_S, 8,&arg6, "cc.OrbitCamera:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_OrbitCamera_create'", nullptr); return 0; } cocos2d::OrbitCamera* ret = cocos2d::OrbitCamera::create(arg0, arg1, arg2, arg3, arg4, arg5, arg6); object_to_luaval<cocos2d::OrbitCamera>(tolua_S, "cc.OrbitCamera",(cocos2d::OrbitCamera*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.OrbitCamera:create",argc, 7); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_OrbitCamera_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_OrbitCamera_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::OrbitCamera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_OrbitCamera_constructor'", nullptr); return 0; } cobj = new cocos2d::OrbitCamera(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.OrbitCamera"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.OrbitCamera:OrbitCamera",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_OrbitCamera_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_OrbitCamera_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (OrbitCamera)"); return 0; } int lua_register_cocos2dx_OrbitCamera(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.OrbitCamera"); tolua_cclass(tolua_S,"OrbitCamera","cc.OrbitCamera","cc.ActionCamera",nullptr); tolua_beginmodule(tolua_S,"OrbitCamera"); tolua_function(tolua_S,"new",lua_cocos2dx_OrbitCamera_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_OrbitCamera_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_OrbitCamera_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::OrbitCamera).name(); g_luaType[typeName] = "cc.OrbitCamera"; g_typeCast["OrbitCamera"] = "cc.OrbitCamera"; return 1; } int lua_cocos2dx_CardinalSplineTo_getPoints(lua_State* tolua_S) { int argc = 0; cocos2d::CardinalSplineTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CardinalSplineTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CardinalSplineTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CardinalSplineTo_getPoints'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CardinalSplineTo_getPoints'", nullptr); return 0; } cocos2d::PointArray* ret = cobj->getPoints(); object_to_luaval<cocos2d::PointArray>(tolua_S, "cc.PointArray",(cocos2d::PointArray*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CardinalSplineTo:getPoints",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CardinalSplineTo_getPoints'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CardinalSplineTo_updatePosition(lua_State* tolua_S) { int argc = 0; cocos2d::CardinalSplineTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CardinalSplineTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CardinalSplineTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CardinalSplineTo_updatePosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.CardinalSplineTo:updatePosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CardinalSplineTo_updatePosition'", nullptr); return 0; } cobj->updatePosition(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CardinalSplineTo:updatePosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CardinalSplineTo_updatePosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CardinalSplineTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::CardinalSplineTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CardinalSplineTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CardinalSplineTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CardinalSplineTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; cocos2d::PointArray* arg1 = nullptr; double arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.CardinalSplineTo:initWithDuration"); ok &= luaval_to_object<cocos2d::PointArray>(tolua_S, 3, "cc.PointArray",&arg1, "cc.CardinalSplineTo:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.CardinalSplineTo:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CardinalSplineTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CardinalSplineTo:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CardinalSplineTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CardinalSplineTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::CardinalSplineTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CardinalSplineTo_constructor'", nullptr); return 0; } cobj = new cocos2d::CardinalSplineTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.CardinalSplineTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CardinalSplineTo:CardinalSplineTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CardinalSplineTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CardinalSplineTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CardinalSplineTo)"); return 0; } int lua_register_cocos2dx_CardinalSplineTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CardinalSplineTo"); tolua_cclass(tolua_S,"CardinalSplineTo","cc.CardinalSplineTo","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"CardinalSplineTo"); tolua_function(tolua_S,"new",lua_cocos2dx_CardinalSplineTo_constructor); tolua_function(tolua_S,"getPoints",lua_cocos2dx_CardinalSplineTo_getPoints); tolua_function(tolua_S,"updatePosition",lua_cocos2dx_CardinalSplineTo_updatePosition); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_CardinalSplineTo_initWithDuration); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CardinalSplineTo).name(); g_luaType[typeName] = "cc.CardinalSplineTo"; g_typeCast["CardinalSplineTo"] = "cc.CardinalSplineTo"; return 1; } int lua_cocos2dx_CardinalSplineBy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::CardinalSplineBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CardinalSplineBy_constructor'", nullptr); return 0; } cobj = new cocos2d::CardinalSplineBy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.CardinalSplineBy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CardinalSplineBy:CardinalSplineBy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CardinalSplineBy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CardinalSplineBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CardinalSplineBy)"); return 0; } int lua_register_cocos2dx_CardinalSplineBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CardinalSplineBy"); tolua_cclass(tolua_S,"CardinalSplineBy","cc.CardinalSplineBy","cc.CardinalSplineTo",nullptr); tolua_beginmodule(tolua_S,"CardinalSplineBy"); tolua_function(tolua_S,"new",lua_cocos2dx_CardinalSplineBy_constructor); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CardinalSplineBy).name(); g_luaType[typeName] = "cc.CardinalSplineBy"; g_typeCast["CardinalSplineBy"] = "cc.CardinalSplineBy"; return 1; } int lua_cocos2dx_CatmullRomTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::CatmullRomTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CatmullRomTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CatmullRomTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CatmullRomTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; cocos2d::PointArray* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.CatmullRomTo:initWithDuration"); ok &= luaval_to_object<cocos2d::PointArray>(tolua_S, 3, "cc.PointArray",&arg1, "cc.CatmullRomTo:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CatmullRomTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CatmullRomTo:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CatmullRomTo_initWithDuration'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CatmullRomTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CatmullRomTo)"); return 0; } int lua_register_cocos2dx_CatmullRomTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CatmullRomTo"); tolua_cclass(tolua_S,"CatmullRomTo","cc.CatmullRomTo","cc.CardinalSplineTo",nullptr); tolua_beginmodule(tolua_S,"CatmullRomTo"); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_CatmullRomTo_initWithDuration); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CatmullRomTo).name(); g_luaType[typeName] = "cc.CatmullRomTo"; g_typeCast["CatmullRomTo"] = "cc.CatmullRomTo"; return 1; } int lua_cocos2dx_CatmullRomBy_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::CatmullRomBy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CatmullRomBy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CatmullRomBy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CatmullRomBy_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; cocos2d::PointArray* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.CatmullRomBy:initWithDuration"); ok &= luaval_to_object<cocos2d::PointArray>(tolua_S, 3, "cc.PointArray",&arg1, "cc.CatmullRomBy:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CatmullRomBy_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CatmullRomBy:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CatmullRomBy_initWithDuration'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CatmullRomBy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CatmullRomBy)"); return 0; } int lua_register_cocos2dx_CatmullRomBy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CatmullRomBy"); tolua_cclass(tolua_S,"CatmullRomBy","cc.CatmullRomBy","cc.CardinalSplineBy",nullptr); tolua_beginmodule(tolua_S,"CatmullRomBy"); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_CatmullRomBy_initWithDuration); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CatmullRomBy).name(); g_luaType[typeName] = "cc.CatmullRomBy"; g_typeCast["CatmullRomBy"] = "cc.CatmullRomBy"; return 1; } int lua_cocos2dx_ActionEase_initWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::ActionEase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionEase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionEase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionEase_initWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.ActionEase:initWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionEase_initWithAction'", nullptr); return 0; } bool ret = cobj->initWithAction(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionEase:initWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionEase_initWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionEase_getInnerAction(lua_State* tolua_S) { int argc = 0; cocos2d::ActionEase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionEase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionEase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionEase_getInnerAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionEase_getInnerAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->getInnerAction(); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionEase:getInnerAction",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionEase_getInnerAction'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ActionEase_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ActionEase)"); return 0; } int lua_register_cocos2dx_ActionEase(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ActionEase"); tolua_cclass(tolua_S,"ActionEase","cc.ActionEase","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"ActionEase"); tolua_function(tolua_S,"initWithAction",lua_cocos2dx_ActionEase_initWithAction); tolua_function(tolua_S,"getInnerAction",lua_cocos2dx_ActionEase_getInnerAction); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ActionEase).name(); g_luaType[typeName] = "cc.ActionEase"; g_typeCast["ActionEase"] = "cc.ActionEase"; return 1; } int lua_cocos2dx_EaseRateAction_setRate(lua_State* tolua_S) { int argc = 0; cocos2d::EaseRateAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EaseRateAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EaseRateAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EaseRateAction_setRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.EaseRateAction:setRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseRateAction_setRate'", nullptr); return 0; } cobj->setRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseRateAction:setRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseRateAction_setRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseRateAction_initWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::EaseRateAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EaseRateAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EaseRateAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EaseRateAction_initWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseRateAction:initWithAction"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseRateAction:initWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseRateAction_initWithAction'", nullptr); return 0; } bool ret = cobj->initWithAction(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseRateAction:initWithAction",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseRateAction_initWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseRateAction_getRate(lua_State* tolua_S) { int argc = 0; cocos2d::EaseRateAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EaseRateAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EaseRateAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EaseRateAction_getRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseRateAction_getRate'", nullptr); return 0; } double ret = cobj->getRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseRateAction:getRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseRateAction_getRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseRateAction_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseRateAction",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseRateAction:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseRateAction:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseRateAction_create'", nullptr); return 0; } cocos2d::EaseRateAction* ret = cocos2d::EaseRateAction::create(arg0, arg1); object_to_luaval<cocos2d::EaseRateAction>(tolua_S, "cc.EaseRateAction",(cocos2d::EaseRateAction*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseRateAction:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseRateAction_create'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseRateAction_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseRateAction)"); return 0; } int lua_register_cocos2dx_EaseRateAction(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseRateAction"); tolua_cclass(tolua_S,"EaseRateAction","cc.EaseRateAction","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseRateAction"); tolua_function(tolua_S,"setRate",lua_cocos2dx_EaseRateAction_setRate); tolua_function(tolua_S,"initWithAction",lua_cocos2dx_EaseRateAction_initWithAction); tolua_function(tolua_S,"getRate",lua_cocos2dx_EaseRateAction_getRate); tolua_function(tolua_S,"create", lua_cocos2dx_EaseRateAction_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseRateAction).name(); g_luaType[typeName] = "cc.EaseRateAction"; g_typeCast["EaseRateAction"] = "cc.EaseRateAction"; return 1; } int lua_cocos2dx_EaseExponentialIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseExponentialIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseExponentialIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseExponentialIn_create'", nullptr); return 0; } cocos2d::EaseExponentialIn* ret = cocos2d::EaseExponentialIn::create(arg0); object_to_luaval<cocos2d::EaseExponentialIn>(tolua_S, "cc.EaseExponentialIn",(cocos2d::EaseExponentialIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseExponentialIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseExponentialIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseExponentialIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseExponentialIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseExponentialIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseExponentialIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseExponentialIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseExponentialIn:EaseExponentialIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseExponentialIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseExponentialIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseExponentialIn)"); return 0; } int lua_register_cocos2dx_EaseExponentialIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseExponentialIn"); tolua_cclass(tolua_S,"EaseExponentialIn","cc.EaseExponentialIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseExponentialIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseExponentialIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseExponentialIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseExponentialIn).name(); g_luaType[typeName] = "cc.EaseExponentialIn"; g_typeCast["EaseExponentialIn"] = "cc.EaseExponentialIn"; return 1; } int lua_cocos2dx_EaseExponentialOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseExponentialOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseExponentialOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseExponentialOut_create'", nullptr); return 0; } cocos2d::EaseExponentialOut* ret = cocos2d::EaseExponentialOut::create(arg0); object_to_luaval<cocos2d::EaseExponentialOut>(tolua_S, "cc.EaseExponentialOut",(cocos2d::EaseExponentialOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseExponentialOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseExponentialOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseExponentialOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseExponentialOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseExponentialOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseExponentialOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseExponentialOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseExponentialOut:EaseExponentialOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseExponentialOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseExponentialOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseExponentialOut)"); return 0; } int lua_register_cocos2dx_EaseExponentialOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseExponentialOut"); tolua_cclass(tolua_S,"EaseExponentialOut","cc.EaseExponentialOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseExponentialOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseExponentialOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseExponentialOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseExponentialOut).name(); g_luaType[typeName] = "cc.EaseExponentialOut"; g_typeCast["EaseExponentialOut"] = "cc.EaseExponentialOut"; return 1; } int lua_cocos2dx_EaseExponentialInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseExponentialInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseExponentialInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseExponentialInOut_create'", nullptr); return 0; } cocos2d::EaseExponentialInOut* ret = cocos2d::EaseExponentialInOut::create(arg0); object_to_luaval<cocos2d::EaseExponentialInOut>(tolua_S, "cc.EaseExponentialInOut",(cocos2d::EaseExponentialInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseExponentialInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseExponentialInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseExponentialInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseExponentialInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseExponentialInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseExponentialInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseExponentialInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseExponentialInOut:EaseExponentialInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseExponentialInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseExponentialInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseExponentialInOut)"); return 0; } int lua_register_cocos2dx_EaseExponentialInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseExponentialInOut"); tolua_cclass(tolua_S,"EaseExponentialInOut","cc.EaseExponentialInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseExponentialInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseExponentialInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseExponentialInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseExponentialInOut).name(); g_luaType[typeName] = "cc.EaseExponentialInOut"; g_typeCast["EaseExponentialInOut"] = "cc.EaseExponentialInOut"; return 1; } int lua_cocos2dx_EaseSineIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseSineIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseSineIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseSineIn_create'", nullptr); return 0; } cocos2d::EaseSineIn* ret = cocos2d::EaseSineIn::create(arg0); object_to_luaval<cocos2d::EaseSineIn>(tolua_S, "cc.EaseSineIn",(cocos2d::EaseSineIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseSineIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseSineIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseSineIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseSineIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseSineIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseSineIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseSineIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseSineIn:EaseSineIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseSineIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseSineIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseSineIn)"); return 0; } int lua_register_cocos2dx_EaseSineIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseSineIn"); tolua_cclass(tolua_S,"EaseSineIn","cc.EaseSineIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseSineIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseSineIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseSineIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseSineIn).name(); g_luaType[typeName] = "cc.EaseSineIn"; g_typeCast["EaseSineIn"] = "cc.EaseSineIn"; return 1; } int lua_cocos2dx_EaseSineOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseSineOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseSineOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseSineOut_create'", nullptr); return 0; } cocos2d::EaseSineOut* ret = cocos2d::EaseSineOut::create(arg0); object_to_luaval<cocos2d::EaseSineOut>(tolua_S, "cc.EaseSineOut",(cocos2d::EaseSineOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseSineOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseSineOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseSineOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseSineOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseSineOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseSineOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseSineOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseSineOut:EaseSineOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseSineOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseSineOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseSineOut)"); return 0; } int lua_register_cocos2dx_EaseSineOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseSineOut"); tolua_cclass(tolua_S,"EaseSineOut","cc.EaseSineOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseSineOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseSineOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseSineOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseSineOut).name(); g_luaType[typeName] = "cc.EaseSineOut"; g_typeCast["EaseSineOut"] = "cc.EaseSineOut"; return 1; } int lua_cocos2dx_EaseSineInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseSineInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseSineInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseSineInOut_create'", nullptr); return 0; } cocos2d::EaseSineInOut* ret = cocos2d::EaseSineInOut::create(arg0); object_to_luaval<cocos2d::EaseSineInOut>(tolua_S, "cc.EaseSineInOut",(cocos2d::EaseSineInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseSineInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseSineInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseSineInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseSineInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseSineInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseSineInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseSineInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseSineInOut:EaseSineInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseSineInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseSineInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseSineInOut)"); return 0; } int lua_register_cocos2dx_EaseSineInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseSineInOut"); tolua_cclass(tolua_S,"EaseSineInOut","cc.EaseSineInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseSineInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseSineInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseSineInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseSineInOut).name(); g_luaType[typeName] = "cc.EaseSineInOut"; g_typeCast["EaseSineInOut"] = "cc.EaseSineInOut"; return 1; } static int lua_cocos2dx_EaseBounce_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseBounce)"); return 0; } int lua_register_cocos2dx_EaseBounce(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseBounce"); tolua_cclass(tolua_S,"EaseBounce","cc.EaseBounce","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseBounce"); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseBounce).name(); g_luaType[typeName] = "cc.EaseBounce"; g_typeCast["EaseBounce"] = "cc.EaseBounce"; return 1; } int lua_cocos2dx_EaseBounceIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseBounceIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseBounceIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBounceIn_create'", nullptr); return 0; } cocos2d::EaseBounceIn* ret = cocos2d::EaseBounceIn::create(arg0); object_to_luaval<cocos2d::EaseBounceIn>(tolua_S, "cc.EaseBounceIn",(cocos2d::EaseBounceIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseBounceIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBounceIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseBounceIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseBounceIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBounceIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseBounceIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseBounceIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseBounceIn:EaseBounceIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBounceIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseBounceIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseBounceIn)"); return 0; } int lua_register_cocos2dx_EaseBounceIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseBounceIn"); tolua_cclass(tolua_S,"EaseBounceIn","cc.EaseBounceIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseBounceIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseBounceIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseBounceIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseBounceIn).name(); g_luaType[typeName] = "cc.EaseBounceIn"; g_typeCast["EaseBounceIn"] = "cc.EaseBounceIn"; return 1; } int lua_cocos2dx_EaseBounceOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseBounceOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseBounceOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBounceOut_create'", nullptr); return 0; } cocos2d::EaseBounceOut* ret = cocos2d::EaseBounceOut::create(arg0); object_to_luaval<cocos2d::EaseBounceOut>(tolua_S, "cc.EaseBounceOut",(cocos2d::EaseBounceOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseBounceOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBounceOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseBounceOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseBounceOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBounceOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseBounceOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseBounceOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseBounceOut:EaseBounceOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBounceOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseBounceOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseBounceOut)"); return 0; } int lua_register_cocos2dx_EaseBounceOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseBounceOut"); tolua_cclass(tolua_S,"EaseBounceOut","cc.EaseBounceOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseBounceOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseBounceOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseBounceOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseBounceOut).name(); g_luaType[typeName] = "cc.EaseBounceOut"; g_typeCast["EaseBounceOut"] = "cc.EaseBounceOut"; return 1; } int lua_cocos2dx_EaseBounceInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseBounceInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseBounceInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBounceInOut_create'", nullptr); return 0; } cocos2d::EaseBounceInOut* ret = cocos2d::EaseBounceInOut::create(arg0); object_to_luaval<cocos2d::EaseBounceInOut>(tolua_S, "cc.EaseBounceInOut",(cocos2d::EaseBounceInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseBounceInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBounceInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseBounceInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseBounceInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBounceInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseBounceInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseBounceInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseBounceInOut:EaseBounceInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBounceInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseBounceInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseBounceInOut)"); return 0; } int lua_register_cocos2dx_EaseBounceInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseBounceInOut"); tolua_cclass(tolua_S,"EaseBounceInOut","cc.EaseBounceInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseBounceInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseBounceInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseBounceInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseBounceInOut).name(); g_luaType[typeName] = "cc.EaseBounceInOut"; g_typeCast["EaseBounceInOut"] = "cc.EaseBounceInOut"; return 1; } int lua_cocos2dx_EaseBackIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseBackIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseBackIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBackIn_create'", nullptr); return 0; } cocos2d::EaseBackIn* ret = cocos2d::EaseBackIn::create(arg0); object_to_luaval<cocos2d::EaseBackIn>(tolua_S, "cc.EaseBackIn",(cocos2d::EaseBackIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseBackIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBackIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseBackIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseBackIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBackIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseBackIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseBackIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseBackIn:EaseBackIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBackIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseBackIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseBackIn)"); return 0; } int lua_register_cocos2dx_EaseBackIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseBackIn"); tolua_cclass(tolua_S,"EaseBackIn","cc.EaseBackIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseBackIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseBackIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseBackIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseBackIn).name(); g_luaType[typeName] = "cc.EaseBackIn"; g_typeCast["EaseBackIn"] = "cc.EaseBackIn"; return 1; } int lua_cocos2dx_EaseBackOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseBackOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseBackOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBackOut_create'", nullptr); return 0; } cocos2d::EaseBackOut* ret = cocos2d::EaseBackOut::create(arg0); object_to_luaval<cocos2d::EaseBackOut>(tolua_S, "cc.EaseBackOut",(cocos2d::EaseBackOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseBackOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBackOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseBackOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseBackOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBackOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseBackOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseBackOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseBackOut:EaseBackOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBackOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseBackOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseBackOut)"); return 0; } int lua_register_cocos2dx_EaseBackOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseBackOut"); tolua_cclass(tolua_S,"EaseBackOut","cc.EaseBackOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseBackOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseBackOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseBackOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseBackOut).name(); g_luaType[typeName] = "cc.EaseBackOut"; g_typeCast["EaseBackOut"] = "cc.EaseBackOut"; return 1; } int lua_cocos2dx_EaseBackInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseBackInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseBackInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBackInOut_create'", nullptr); return 0; } cocos2d::EaseBackInOut* ret = cocos2d::EaseBackInOut::create(arg0); object_to_luaval<cocos2d::EaseBackInOut>(tolua_S, "cc.EaseBackInOut",(cocos2d::EaseBackInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseBackInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBackInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseBackInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseBackInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBackInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseBackInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseBackInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseBackInOut:EaseBackInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBackInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseBackInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseBackInOut)"); return 0; } int lua_register_cocos2dx_EaseBackInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseBackInOut"); tolua_cclass(tolua_S,"EaseBackInOut","cc.EaseBackInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseBackInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseBackInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseBackInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseBackInOut).name(); g_luaType[typeName] = "cc.EaseBackInOut"; g_typeCast["EaseBackInOut"] = "cc.EaseBackInOut"; return 1; } int lua_cocos2dx_EaseQuadraticActionIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuadraticActionIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuadraticActionIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuadraticActionIn_create'", nullptr); return 0; } cocos2d::EaseQuadraticActionIn* ret = cocos2d::EaseQuadraticActionIn::create(arg0); object_to_luaval<cocos2d::EaseQuadraticActionIn>(tolua_S, "cc.EaseQuadraticActionIn",(cocos2d::EaseQuadraticActionIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuadraticActionIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuadraticActionIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuadraticActionIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuadraticActionIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuadraticActionIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuadraticActionIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuadraticActionIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuadraticActionIn:EaseQuadraticActionIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuadraticActionIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuadraticActionIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuadraticActionIn)"); return 0; } int lua_register_cocos2dx_EaseQuadraticActionIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuadraticActionIn"); tolua_cclass(tolua_S,"EaseQuadraticActionIn","cc.EaseQuadraticActionIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuadraticActionIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuadraticActionIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuadraticActionIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuadraticActionIn).name(); g_luaType[typeName] = "cc.EaseQuadraticActionIn"; g_typeCast["EaseQuadraticActionIn"] = "cc.EaseQuadraticActionIn"; return 1; } int lua_cocos2dx_EaseQuadraticActionOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuadraticActionOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuadraticActionOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuadraticActionOut_create'", nullptr); return 0; } cocos2d::EaseQuadraticActionOut* ret = cocos2d::EaseQuadraticActionOut::create(arg0); object_to_luaval<cocos2d::EaseQuadraticActionOut>(tolua_S, "cc.EaseQuadraticActionOut",(cocos2d::EaseQuadraticActionOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuadraticActionOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuadraticActionOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuadraticActionOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuadraticActionOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuadraticActionOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuadraticActionOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuadraticActionOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuadraticActionOut:EaseQuadraticActionOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuadraticActionOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuadraticActionOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuadraticActionOut)"); return 0; } int lua_register_cocos2dx_EaseQuadraticActionOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuadraticActionOut"); tolua_cclass(tolua_S,"EaseQuadraticActionOut","cc.EaseQuadraticActionOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuadraticActionOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuadraticActionOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuadraticActionOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuadraticActionOut).name(); g_luaType[typeName] = "cc.EaseQuadraticActionOut"; g_typeCast["EaseQuadraticActionOut"] = "cc.EaseQuadraticActionOut"; return 1; } int lua_cocos2dx_EaseQuadraticActionInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuadraticActionInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuadraticActionInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuadraticActionInOut_create'", nullptr); return 0; } cocos2d::EaseQuadraticActionInOut* ret = cocos2d::EaseQuadraticActionInOut::create(arg0); object_to_luaval<cocos2d::EaseQuadraticActionInOut>(tolua_S, "cc.EaseQuadraticActionInOut",(cocos2d::EaseQuadraticActionInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuadraticActionInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuadraticActionInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuadraticActionInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuadraticActionInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuadraticActionInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuadraticActionInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuadraticActionInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuadraticActionInOut:EaseQuadraticActionInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuadraticActionInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuadraticActionInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuadraticActionInOut)"); return 0; } int lua_register_cocos2dx_EaseQuadraticActionInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuadraticActionInOut"); tolua_cclass(tolua_S,"EaseQuadraticActionInOut","cc.EaseQuadraticActionInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuadraticActionInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuadraticActionInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuadraticActionInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuadraticActionInOut).name(); g_luaType[typeName] = "cc.EaseQuadraticActionInOut"; g_typeCast["EaseQuadraticActionInOut"] = "cc.EaseQuadraticActionInOut"; return 1; } int lua_cocos2dx_EaseQuarticActionIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuarticActionIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuarticActionIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuarticActionIn_create'", nullptr); return 0; } cocos2d::EaseQuarticActionIn* ret = cocos2d::EaseQuarticActionIn::create(arg0); object_to_luaval<cocos2d::EaseQuarticActionIn>(tolua_S, "cc.EaseQuarticActionIn",(cocos2d::EaseQuarticActionIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuarticActionIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuarticActionIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuarticActionIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuarticActionIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuarticActionIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuarticActionIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuarticActionIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuarticActionIn:EaseQuarticActionIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuarticActionIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuarticActionIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuarticActionIn)"); return 0; } int lua_register_cocos2dx_EaseQuarticActionIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuarticActionIn"); tolua_cclass(tolua_S,"EaseQuarticActionIn","cc.EaseQuarticActionIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuarticActionIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuarticActionIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuarticActionIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuarticActionIn).name(); g_luaType[typeName] = "cc.EaseQuarticActionIn"; g_typeCast["EaseQuarticActionIn"] = "cc.EaseQuarticActionIn"; return 1; } int lua_cocos2dx_EaseQuarticActionOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuarticActionOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuarticActionOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuarticActionOut_create'", nullptr); return 0; } cocos2d::EaseQuarticActionOut* ret = cocos2d::EaseQuarticActionOut::create(arg0); object_to_luaval<cocos2d::EaseQuarticActionOut>(tolua_S, "cc.EaseQuarticActionOut",(cocos2d::EaseQuarticActionOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuarticActionOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuarticActionOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuarticActionOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuarticActionOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuarticActionOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuarticActionOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuarticActionOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuarticActionOut:EaseQuarticActionOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuarticActionOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuarticActionOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuarticActionOut)"); return 0; } int lua_register_cocos2dx_EaseQuarticActionOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuarticActionOut"); tolua_cclass(tolua_S,"EaseQuarticActionOut","cc.EaseQuarticActionOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuarticActionOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuarticActionOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuarticActionOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuarticActionOut).name(); g_luaType[typeName] = "cc.EaseQuarticActionOut"; g_typeCast["EaseQuarticActionOut"] = "cc.EaseQuarticActionOut"; return 1; } int lua_cocos2dx_EaseQuarticActionInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuarticActionInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuarticActionInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuarticActionInOut_create'", nullptr); return 0; } cocos2d::EaseQuarticActionInOut* ret = cocos2d::EaseQuarticActionInOut::create(arg0); object_to_luaval<cocos2d::EaseQuarticActionInOut>(tolua_S, "cc.EaseQuarticActionInOut",(cocos2d::EaseQuarticActionInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuarticActionInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuarticActionInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuarticActionInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuarticActionInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuarticActionInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuarticActionInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuarticActionInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuarticActionInOut:EaseQuarticActionInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuarticActionInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuarticActionInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuarticActionInOut)"); return 0; } int lua_register_cocos2dx_EaseQuarticActionInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuarticActionInOut"); tolua_cclass(tolua_S,"EaseQuarticActionInOut","cc.EaseQuarticActionInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuarticActionInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuarticActionInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuarticActionInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuarticActionInOut).name(); g_luaType[typeName] = "cc.EaseQuarticActionInOut"; g_typeCast["EaseQuarticActionInOut"] = "cc.EaseQuarticActionInOut"; return 1; } int lua_cocos2dx_EaseQuinticActionIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuinticActionIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuinticActionIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuinticActionIn_create'", nullptr); return 0; } cocos2d::EaseQuinticActionIn* ret = cocos2d::EaseQuinticActionIn::create(arg0); object_to_luaval<cocos2d::EaseQuinticActionIn>(tolua_S, "cc.EaseQuinticActionIn",(cocos2d::EaseQuinticActionIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuinticActionIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuinticActionIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuinticActionIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuinticActionIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuinticActionIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuinticActionIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuinticActionIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuinticActionIn:EaseQuinticActionIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuinticActionIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuinticActionIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuinticActionIn)"); return 0; } int lua_register_cocos2dx_EaseQuinticActionIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuinticActionIn"); tolua_cclass(tolua_S,"EaseQuinticActionIn","cc.EaseQuinticActionIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuinticActionIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuinticActionIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuinticActionIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuinticActionIn).name(); g_luaType[typeName] = "cc.EaseQuinticActionIn"; g_typeCast["EaseQuinticActionIn"] = "cc.EaseQuinticActionIn"; return 1; } int lua_cocos2dx_EaseQuinticActionOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuinticActionOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuinticActionOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuinticActionOut_create'", nullptr); return 0; } cocos2d::EaseQuinticActionOut* ret = cocos2d::EaseQuinticActionOut::create(arg0); object_to_luaval<cocos2d::EaseQuinticActionOut>(tolua_S, "cc.EaseQuinticActionOut",(cocos2d::EaseQuinticActionOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuinticActionOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuinticActionOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuinticActionOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuinticActionOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuinticActionOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuinticActionOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuinticActionOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuinticActionOut:EaseQuinticActionOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuinticActionOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuinticActionOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuinticActionOut)"); return 0; } int lua_register_cocos2dx_EaseQuinticActionOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuinticActionOut"); tolua_cclass(tolua_S,"EaseQuinticActionOut","cc.EaseQuinticActionOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuinticActionOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuinticActionOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuinticActionOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuinticActionOut).name(); g_luaType[typeName] = "cc.EaseQuinticActionOut"; g_typeCast["EaseQuinticActionOut"] = "cc.EaseQuinticActionOut"; return 1; } int lua_cocos2dx_EaseQuinticActionInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseQuinticActionInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseQuinticActionInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuinticActionInOut_create'", nullptr); return 0; } cocos2d::EaseQuinticActionInOut* ret = cocos2d::EaseQuinticActionInOut::create(arg0); object_to_luaval<cocos2d::EaseQuinticActionInOut>(tolua_S, "cc.EaseQuinticActionInOut",(cocos2d::EaseQuinticActionInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseQuinticActionInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuinticActionInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseQuinticActionInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseQuinticActionInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseQuinticActionInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseQuinticActionInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseQuinticActionInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseQuinticActionInOut:EaseQuinticActionInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseQuinticActionInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseQuinticActionInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseQuinticActionInOut)"); return 0; } int lua_register_cocos2dx_EaseQuinticActionInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseQuinticActionInOut"); tolua_cclass(tolua_S,"EaseQuinticActionInOut","cc.EaseQuinticActionInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseQuinticActionInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseQuinticActionInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseQuinticActionInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseQuinticActionInOut).name(); g_luaType[typeName] = "cc.EaseQuinticActionInOut"; g_typeCast["EaseQuinticActionInOut"] = "cc.EaseQuinticActionInOut"; return 1; } int lua_cocos2dx_EaseCircleActionIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseCircleActionIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseCircleActionIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCircleActionIn_create'", nullptr); return 0; } cocos2d::EaseCircleActionIn* ret = cocos2d::EaseCircleActionIn::create(arg0); object_to_luaval<cocos2d::EaseCircleActionIn>(tolua_S, "cc.EaseCircleActionIn",(cocos2d::EaseCircleActionIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseCircleActionIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCircleActionIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseCircleActionIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseCircleActionIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCircleActionIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseCircleActionIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseCircleActionIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseCircleActionIn:EaseCircleActionIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCircleActionIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseCircleActionIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseCircleActionIn)"); return 0; } int lua_register_cocos2dx_EaseCircleActionIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseCircleActionIn"); tolua_cclass(tolua_S,"EaseCircleActionIn","cc.EaseCircleActionIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseCircleActionIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseCircleActionIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseCircleActionIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseCircleActionIn).name(); g_luaType[typeName] = "cc.EaseCircleActionIn"; g_typeCast["EaseCircleActionIn"] = "cc.EaseCircleActionIn"; return 1; } int lua_cocos2dx_EaseCircleActionOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseCircleActionOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseCircleActionOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCircleActionOut_create'", nullptr); return 0; } cocos2d::EaseCircleActionOut* ret = cocos2d::EaseCircleActionOut::create(arg0); object_to_luaval<cocos2d::EaseCircleActionOut>(tolua_S, "cc.EaseCircleActionOut",(cocos2d::EaseCircleActionOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseCircleActionOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCircleActionOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseCircleActionOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseCircleActionOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCircleActionOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseCircleActionOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseCircleActionOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseCircleActionOut:EaseCircleActionOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCircleActionOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseCircleActionOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseCircleActionOut)"); return 0; } int lua_register_cocos2dx_EaseCircleActionOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseCircleActionOut"); tolua_cclass(tolua_S,"EaseCircleActionOut","cc.EaseCircleActionOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseCircleActionOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseCircleActionOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseCircleActionOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseCircleActionOut).name(); g_luaType[typeName] = "cc.EaseCircleActionOut"; g_typeCast["EaseCircleActionOut"] = "cc.EaseCircleActionOut"; return 1; } int lua_cocos2dx_EaseCircleActionInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseCircleActionInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseCircleActionInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCircleActionInOut_create'", nullptr); return 0; } cocos2d::EaseCircleActionInOut* ret = cocos2d::EaseCircleActionInOut::create(arg0); object_to_luaval<cocos2d::EaseCircleActionInOut>(tolua_S, "cc.EaseCircleActionInOut",(cocos2d::EaseCircleActionInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseCircleActionInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCircleActionInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseCircleActionInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseCircleActionInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCircleActionInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseCircleActionInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseCircleActionInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseCircleActionInOut:EaseCircleActionInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCircleActionInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseCircleActionInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseCircleActionInOut)"); return 0; } int lua_register_cocos2dx_EaseCircleActionInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseCircleActionInOut"); tolua_cclass(tolua_S,"EaseCircleActionInOut","cc.EaseCircleActionInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseCircleActionInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseCircleActionInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseCircleActionInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseCircleActionInOut).name(); g_luaType[typeName] = "cc.EaseCircleActionInOut"; g_typeCast["EaseCircleActionInOut"] = "cc.EaseCircleActionInOut"; return 1; } int lua_cocos2dx_EaseCubicActionIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseCubicActionIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseCubicActionIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCubicActionIn_create'", nullptr); return 0; } cocos2d::EaseCubicActionIn* ret = cocos2d::EaseCubicActionIn::create(arg0); object_to_luaval<cocos2d::EaseCubicActionIn>(tolua_S, "cc.EaseCubicActionIn",(cocos2d::EaseCubicActionIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseCubicActionIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCubicActionIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseCubicActionIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseCubicActionIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCubicActionIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseCubicActionIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseCubicActionIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseCubicActionIn:EaseCubicActionIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCubicActionIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseCubicActionIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseCubicActionIn)"); return 0; } int lua_register_cocos2dx_EaseCubicActionIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseCubicActionIn"); tolua_cclass(tolua_S,"EaseCubicActionIn","cc.EaseCubicActionIn","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseCubicActionIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseCubicActionIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseCubicActionIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseCubicActionIn).name(); g_luaType[typeName] = "cc.EaseCubicActionIn"; g_typeCast["EaseCubicActionIn"] = "cc.EaseCubicActionIn"; return 1; } int lua_cocos2dx_EaseCubicActionOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseCubicActionOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseCubicActionOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCubicActionOut_create'", nullptr); return 0; } cocos2d::EaseCubicActionOut* ret = cocos2d::EaseCubicActionOut::create(arg0); object_to_luaval<cocos2d::EaseCubicActionOut>(tolua_S, "cc.EaseCubicActionOut",(cocos2d::EaseCubicActionOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseCubicActionOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCubicActionOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseCubicActionOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseCubicActionOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCubicActionOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseCubicActionOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseCubicActionOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseCubicActionOut:EaseCubicActionOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCubicActionOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseCubicActionOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseCubicActionOut)"); return 0; } int lua_register_cocos2dx_EaseCubicActionOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseCubicActionOut"); tolua_cclass(tolua_S,"EaseCubicActionOut","cc.EaseCubicActionOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseCubicActionOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseCubicActionOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseCubicActionOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseCubicActionOut).name(); g_luaType[typeName] = "cc.EaseCubicActionOut"; g_typeCast["EaseCubicActionOut"] = "cc.EaseCubicActionOut"; return 1; } int lua_cocos2dx_EaseCubicActionInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseCubicActionInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseCubicActionInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCubicActionInOut_create'", nullptr); return 0; } cocos2d::EaseCubicActionInOut* ret = cocos2d::EaseCubicActionInOut::create(arg0); object_to_luaval<cocos2d::EaseCubicActionInOut>(tolua_S, "cc.EaseCubicActionInOut",(cocos2d::EaseCubicActionInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseCubicActionInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCubicActionInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseCubicActionInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseCubicActionInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseCubicActionInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseCubicActionInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseCubicActionInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseCubicActionInOut:EaseCubicActionInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseCubicActionInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseCubicActionInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseCubicActionInOut)"); return 0; } int lua_register_cocos2dx_EaseCubicActionInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseCubicActionInOut"); tolua_cclass(tolua_S,"EaseCubicActionInOut","cc.EaseCubicActionInOut","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseCubicActionInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseCubicActionInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseCubicActionInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseCubicActionInOut).name(); g_luaType[typeName] = "cc.EaseCubicActionInOut"; g_typeCast["EaseCubicActionInOut"] = "cc.EaseCubicActionInOut"; return 1; } int lua_cocos2dx_EaseIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseIn:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseIn_create'", nullptr); return 0; } cocos2d::EaseIn* ret = cocos2d::EaseIn::create(arg0, arg1); object_to_luaval<cocos2d::EaseIn>(tolua_S, "cc.EaseIn",(cocos2d::EaseIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseIn:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseIn:EaseIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseIn)"); return 0; } int lua_register_cocos2dx_EaseIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseIn"); tolua_cclass(tolua_S,"EaseIn","cc.EaseIn","cc.EaseRateAction",nullptr); tolua_beginmodule(tolua_S,"EaseIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseIn).name(); g_luaType[typeName] = "cc.EaseIn"; g_typeCast["EaseIn"] = "cc.EaseIn"; return 1; } int lua_cocos2dx_EaseOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseOut:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseOut_create'", nullptr); return 0; } cocos2d::EaseOut* ret = cocos2d::EaseOut::create(arg0, arg1); object_to_luaval<cocos2d::EaseOut>(tolua_S, "cc.EaseOut",(cocos2d::EaseOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseOut:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseOut:EaseOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseOut)"); return 0; } int lua_register_cocos2dx_EaseOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseOut"); tolua_cclass(tolua_S,"EaseOut","cc.EaseOut","cc.EaseRateAction",nullptr); tolua_beginmodule(tolua_S,"EaseOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseOut).name(); g_luaType[typeName] = "cc.EaseOut"; g_typeCast["EaseOut"] = "cc.EaseOut"; return 1; } int lua_cocos2dx_EaseInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseInOut:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseInOut_create'", nullptr); return 0; } cocos2d::EaseInOut* ret = cocos2d::EaseInOut::create(arg0, arg1); object_to_luaval<cocos2d::EaseInOut>(tolua_S, "cc.EaseInOut",(cocos2d::EaseInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseInOut:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseInOut:EaseInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseInOut)"); return 0; } int lua_register_cocos2dx_EaseInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseInOut"); tolua_cclass(tolua_S,"EaseInOut","cc.EaseInOut","cc.EaseRateAction",nullptr); tolua_beginmodule(tolua_S,"EaseInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseInOut).name(); g_luaType[typeName] = "cc.EaseInOut"; g_typeCast["EaseInOut"] = "cc.EaseInOut"; return 1; } int lua_cocos2dx_EaseElastic_setPeriod(lua_State* tolua_S) { int argc = 0; cocos2d::EaseElastic* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EaseElastic",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EaseElastic*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EaseElastic_setPeriod'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.EaseElastic:setPeriod"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElastic_setPeriod'", nullptr); return 0; } cobj->setPeriod(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseElastic:setPeriod",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElastic_setPeriod'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseElastic_initWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::EaseElastic* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EaseElastic",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EaseElastic*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EaseElastic_initWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseElastic:initWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElastic_initWithAction'", nullptr); return 0; } bool ret = cobj->initWithAction(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseElastic:initWithAction"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseElastic:initWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElastic_initWithAction'", nullptr); return 0; } bool ret = cobj->initWithAction(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseElastic:initWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElastic_initWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseElastic_getPeriod(lua_State* tolua_S) { int argc = 0; cocos2d::EaseElastic* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EaseElastic",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EaseElastic*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EaseElastic_getPeriod'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElastic_getPeriod'", nullptr); return 0; } double ret = cobj->getPeriod(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseElastic:getPeriod",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElastic_getPeriod'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseElastic_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseElastic)"); return 0; } int lua_register_cocos2dx_EaseElastic(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseElastic"); tolua_cclass(tolua_S,"EaseElastic","cc.EaseElastic","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseElastic"); tolua_function(tolua_S,"setPeriod",lua_cocos2dx_EaseElastic_setPeriod); tolua_function(tolua_S,"initWithAction",lua_cocos2dx_EaseElastic_initWithAction); tolua_function(tolua_S,"getPeriod",lua_cocos2dx_EaseElastic_getPeriod); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseElastic).name(); g_luaType[typeName] = "cc.EaseElastic"; g_typeCast["EaseElastic"] = "cc.EaseElastic"; return 1; } int lua_cocos2dx_EaseElasticIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseElasticIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseElasticIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticIn_create'", nullptr); return 0; } cocos2d::EaseElasticIn* ret = cocos2d::EaseElasticIn::create(arg0); object_to_luaval<cocos2d::EaseElasticIn>(tolua_S, "cc.EaseElasticIn",(cocos2d::EaseElasticIn*)ret); return 1; } if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseElasticIn:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseElasticIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticIn_create'", nullptr); return 0; } cocos2d::EaseElasticIn* ret = cocos2d::EaseElasticIn::create(arg0, arg1); object_to_luaval<cocos2d::EaseElasticIn>(tolua_S, "cc.EaseElasticIn",(cocos2d::EaseElasticIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseElasticIn:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElasticIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseElasticIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseElasticIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticIn_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseElasticIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseElasticIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseElasticIn:EaseElasticIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElasticIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseElasticIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseElasticIn)"); return 0; } int lua_register_cocos2dx_EaseElasticIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseElasticIn"); tolua_cclass(tolua_S,"EaseElasticIn","cc.EaseElasticIn","cc.EaseElastic",nullptr); tolua_beginmodule(tolua_S,"EaseElasticIn"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseElasticIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseElasticIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseElasticIn).name(); g_luaType[typeName] = "cc.EaseElasticIn"; g_typeCast["EaseElasticIn"] = "cc.EaseElasticIn"; return 1; } int lua_cocos2dx_EaseElasticOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseElasticOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseElasticOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticOut_create'", nullptr); return 0; } cocos2d::EaseElasticOut* ret = cocos2d::EaseElasticOut::create(arg0); object_to_luaval<cocos2d::EaseElasticOut>(tolua_S, "cc.EaseElasticOut",(cocos2d::EaseElasticOut*)ret); return 1; } if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseElasticOut:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseElasticOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticOut_create'", nullptr); return 0; } cocos2d::EaseElasticOut* ret = cocos2d::EaseElasticOut::create(arg0, arg1); object_to_luaval<cocos2d::EaseElasticOut>(tolua_S, "cc.EaseElasticOut",(cocos2d::EaseElasticOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseElasticOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElasticOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseElasticOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseElasticOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseElasticOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseElasticOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseElasticOut:EaseElasticOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElasticOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseElasticOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseElasticOut)"); return 0; } int lua_register_cocos2dx_EaseElasticOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseElasticOut"); tolua_cclass(tolua_S,"EaseElasticOut","cc.EaseElasticOut","cc.EaseElastic",nullptr); tolua_beginmodule(tolua_S,"EaseElasticOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseElasticOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseElasticOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseElasticOut).name(); g_luaType[typeName] = "cc.EaseElasticOut"; g_typeCast["EaseElasticOut"] = "cc.EaseElasticOut"; return 1; } int lua_cocos2dx_EaseElasticInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseElasticInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseElasticInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticInOut_create'", nullptr); return 0; } cocos2d::EaseElasticInOut* ret = cocos2d::EaseElasticInOut::create(arg0); object_to_luaval<cocos2d::EaseElasticInOut>(tolua_S, "cc.EaseElasticInOut",(cocos2d::EaseElasticInOut*)ret); return 1; } if (argc == 2) { cocos2d::ActionInterval* arg0 = nullptr; double arg1; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseElasticInOut:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseElasticInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticInOut_create'", nullptr); return 0; } cocos2d::EaseElasticInOut* ret = cocos2d::EaseElasticInOut::create(arg0, arg1); object_to_luaval<cocos2d::EaseElasticInOut>(tolua_S, "cc.EaseElasticInOut",(cocos2d::EaseElasticInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseElasticInOut:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElasticInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseElasticInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseElasticInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseElasticInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseElasticInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseElasticInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseElasticInOut:EaseElasticInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseElasticInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseElasticInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseElasticInOut)"); return 0; } int lua_register_cocos2dx_EaseElasticInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseElasticInOut"); tolua_cclass(tolua_S,"EaseElasticInOut","cc.EaseElasticInOut","cc.EaseElastic",nullptr); tolua_beginmodule(tolua_S,"EaseElasticInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseElasticInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_EaseElasticInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseElasticInOut).name(); g_luaType[typeName] = "cc.EaseElasticInOut"; g_typeCast["EaseElasticInOut"] = "cc.EaseElasticInOut"; return 1; } int lua_cocos2dx_EaseBezierAction_setBezierParamer(lua_State* tolua_S) { int argc = 0; cocos2d::EaseBezierAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.EaseBezierAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::EaseBezierAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_EaseBezierAction_setBezierParamer'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; double arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.EaseBezierAction:setBezierParamer"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.EaseBezierAction:setBezierParamer"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.EaseBezierAction:setBezierParamer"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.EaseBezierAction:setBezierParamer"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBezierAction_setBezierParamer'", nullptr); return 0; } cobj->setBezierParamer(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseBezierAction:setBezierParamer",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBezierAction_setBezierParamer'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseBezierAction_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.EaseBezierAction",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.EaseBezierAction:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBezierAction_create'", nullptr); return 0; } cocos2d::EaseBezierAction* ret = cocos2d::EaseBezierAction::create(arg0); object_to_luaval<cocos2d::EaseBezierAction>(tolua_S, "cc.EaseBezierAction",(cocos2d::EaseBezierAction*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EaseBezierAction:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBezierAction_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_EaseBezierAction_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::EaseBezierAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_EaseBezierAction_constructor'", nullptr); return 0; } cobj = new cocos2d::EaseBezierAction(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EaseBezierAction"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.EaseBezierAction:EaseBezierAction",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_EaseBezierAction_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_EaseBezierAction_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (EaseBezierAction)"); return 0; } int lua_register_cocos2dx_EaseBezierAction(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.EaseBezierAction"); tolua_cclass(tolua_S,"EaseBezierAction","cc.EaseBezierAction","cc.ActionEase",nullptr); tolua_beginmodule(tolua_S,"EaseBezierAction"); tolua_function(tolua_S,"new",lua_cocos2dx_EaseBezierAction_constructor); tolua_function(tolua_S,"setBezierParamer",lua_cocos2dx_EaseBezierAction_setBezierParamer); tolua_function(tolua_S,"create", lua_cocos2dx_EaseBezierAction_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::EaseBezierAction).name(); g_luaType[typeName] = "cc.EaseBezierAction"; g_typeCast["EaseBezierAction"] = "cc.EaseBezierAction"; return 1; } static int lua_cocos2dx_ActionInstant_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ActionInstant)"); return 0; } int lua_register_cocos2dx_ActionInstant(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ActionInstant"); tolua_cclass(tolua_S,"ActionInstant","cc.ActionInstant","cc.FiniteTimeAction",nullptr); tolua_beginmodule(tolua_S,"ActionInstant"); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ActionInstant).name(); g_luaType[typeName] = "cc.ActionInstant"; g_typeCast["ActionInstant"] = "cc.ActionInstant"; return 1; } int lua_cocos2dx_Show_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Show",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Show_create'", nullptr); return 0; } cocos2d::Show* ret = cocos2d::Show::create(); object_to_luaval<cocos2d::Show>(tolua_S, "cc.Show",(cocos2d::Show*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Show:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Show_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Show_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Show* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Show_constructor'", nullptr); return 0; } cobj = new cocos2d::Show(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Show"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Show:Show",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Show_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Show_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Show)"); return 0; } int lua_register_cocos2dx_Show(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Show"); tolua_cclass(tolua_S,"Show","cc.Show","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"Show"); tolua_function(tolua_S,"new",lua_cocos2dx_Show_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_Show_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Show).name(); g_luaType[typeName] = "cc.Show"; g_typeCast["Show"] = "cc.Show"; return 1; } int lua_cocos2dx_Hide_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Hide",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Hide_create'", nullptr); return 0; } cocos2d::Hide* ret = cocos2d::Hide::create(); object_to_luaval<cocos2d::Hide>(tolua_S, "cc.Hide",(cocos2d::Hide*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Hide:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Hide_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Hide_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Hide* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Hide_constructor'", nullptr); return 0; } cobj = new cocos2d::Hide(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Hide"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Hide:Hide",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Hide_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Hide_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Hide)"); return 0; } int lua_register_cocos2dx_Hide(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Hide"); tolua_cclass(tolua_S,"Hide","cc.Hide","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"Hide"); tolua_function(tolua_S,"new",lua_cocos2dx_Hide_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_Hide_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Hide).name(); g_luaType[typeName] = "cc.Hide"; g_typeCast["Hide"] = "cc.Hide"; return 1; } int lua_cocos2dx_ToggleVisibility_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ToggleVisibility",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ToggleVisibility_create'", nullptr); return 0; } cocos2d::ToggleVisibility* ret = cocos2d::ToggleVisibility::create(); object_to_luaval<cocos2d::ToggleVisibility>(tolua_S, "cc.ToggleVisibility",(cocos2d::ToggleVisibility*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ToggleVisibility:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ToggleVisibility_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ToggleVisibility_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ToggleVisibility* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ToggleVisibility_constructor'", nullptr); return 0; } cobj = new cocos2d::ToggleVisibility(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ToggleVisibility"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ToggleVisibility:ToggleVisibility",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ToggleVisibility_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ToggleVisibility_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ToggleVisibility)"); return 0; } int lua_register_cocos2dx_ToggleVisibility(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ToggleVisibility"); tolua_cclass(tolua_S,"ToggleVisibility","cc.ToggleVisibility","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"ToggleVisibility"); tolua_function(tolua_S,"new",lua_cocos2dx_ToggleVisibility_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_ToggleVisibility_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ToggleVisibility).name(); g_luaType[typeName] = "cc.ToggleVisibility"; g_typeCast["ToggleVisibility"] = "cc.ToggleVisibility"; return 1; } int lua_cocos2dx_RemoveSelf_init(lua_State* tolua_S) { int argc = 0; cocos2d::RemoveSelf* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RemoveSelf",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RemoveSelf*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RemoveSelf_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.RemoveSelf:init"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RemoveSelf_init'", nullptr); return 0; } bool ret = cobj->init(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RemoveSelf:init",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RemoveSelf_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RemoveSelf_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.RemoveSelf",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RemoveSelf_create'", nullptr); return 0; } cocos2d::RemoveSelf* ret = cocos2d::RemoveSelf::create(); object_to_luaval<cocos2d::RemoveSelf>(tolua_S, "cc.RemoveSelf",(cocos2d::RemoveSelf*)ret); return 1; } if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.RemoveSelf:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RemoveSelf_create'", nullptr); return 0; } cocos2d::RemoveSelf* ret = cocos2d::RemoveSelf::create(arg0); object_to_luaval<cocos2d::RemoveSelf>(tolua_S, "cc.RemoveSelf",(cocos2d::RemoveSelf*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.RemoveSelf:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RemoveSelf_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RemoveSelf_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::RemoveSelf* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RemoveSelf_constructor'", nullptr); return 0; } cobj = new cocos2d::RemoveSelf(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.RemoveSelf"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RemoveSelf:RemoveSelf",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RemoveSelf_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_RemoveSelf_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (RemoveSelf)"); return 0; } int lua_register_cocos2dx_RemoveSelf(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.RemoveSelf"); tolua_cclass(tolua_S,"RemoveSelf","cc.RemoveSelf","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"RemoveSelf"); tolua_function(tolua_S,"new",lua_cocos2dx_RemoveSelf_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_RemoveSelf_init); tolua_function(tolua_S,"create", lua_cocos2dx_RemoveSelf_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::RemoveSelf).name(); g_luaType[typeName] = "cc.RemoveSelf"; g_typeCast["RemoveSelf"] = "cc.RemoveSelf"; return 1; } int lua_cocos2dx_FlipX_initWithFlipX(lua_State* tolua_S) { int argc = 0; cocos2d::FlipX* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FlipX",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FlipX*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FlipX_initWithFlipX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.FlipX:initWithFlipX"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipX_initWithFlipX'", nullptr); return 0; } bool ret = cobj->initWithFlipX(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FlipX:initWithFlipX",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipX_initWithFlipX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FlipX_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FlipX",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.FlipX:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipX_create'", nullptr); return 0; } cocos2d::FlipX* ret = cocos2d::FlipX::create(arg0); object_to_luaval<cocos2d::FlipX>(tolua_S, "cc.FlipX",(cocos2d::FlipX*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FlipX:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipX_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FlipX_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FlipX* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipX_constructor'", nullptr); return 0; } cobj = new cocos2d::FlipX(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FlipX"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FlipX:FlipX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipX_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FlipX_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FlipX)"); return 0; } int lua_register_cocos2dx_FlipX(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FlipX"); tolua_cclass(tolua_S,"FlipX","cc.FlipX","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"FlipX"); tolua_function(tolua_S,"new",lua_cocos2dx_FlipX_constructor); tolua_function(tolua_S,"initWithFlipX",lua_cocos2dx_FlipX_initWithFlipX); tolua_function(tolua_S,"create", lua_cocos2dx_FlipX_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FlipX).name(); g_luaType[typeName] = "cc.FlipX"; g_typeCast["FlipX"] = "cc.FlipX"; return 1; } int lua_cocos2dx_FlipY_initWithFlipY(lua_State* tolua_S) { int argc = 0; cocos2d::FlipY* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FlipY",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FlipY*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FlipY_initWithFlipY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.FlipY:initWithFlipY"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipY_initWithFlipY'", nullptr); return 0; } bool ret = cobj->initWithFlipY(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FlipY:initWithFlipY",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipY_initWithFlipY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FlipY_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FlipY",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.FlipY:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipY_create'", nullptr); return 0; } cocos2d::FlipY* ret = cocos2d::FlipY::create(arg0); object_to_luaval<cocos2d::FlipY>(tolua_S, "cc.FlipY",(cocos2d::FlipY*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FlipY:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipY_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FlipY_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FlipY* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipY_constructor'", nullptr); return 0; } cobj = new cocos2d::FlipY(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FlipY"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FlipY:FlipY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipY_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FlipY_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FlipY)"); return 0; } int lua_register_cocos2dx_FlipY(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FlipY"); tolua_cclass(tolua_S,"FlipY","cc.FlipY","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"FlipY"); tolua_function(tolua_S,"new",lua_cocos2dx_FlipY_constructor); tolua_function(tolua_S,"initWithFlipY",lua_cocos2dx_FlipY_initWithFlipY); tolua_function(tolua_S,"create", lua_cocos2dx_FlipY_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FlipY).name(); g_luaType[typeName] = "cc.FlipY"; g_typeCast["FlipY"] = "cc.FlipY"; return 1; } int lua_cocos2dx_Place_initWithPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Place* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Place",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Place*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Place_initWithPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Place:initWithPosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Place_initWithPosition'", nullptr); return 0; } bool ret = cobj->initWithPosition(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Place:initWithPosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Place_initWithPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Place_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Place",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Place:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Place_create'", nullptr); return 0; } cocos2d::Place* ret = cocos2d::Place::create(arg0); object_to_luaval<cocos2d::Place>(tolua_S, "cc.Place",(cocos2d::Place*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Place:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Place_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Place_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Place* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Place_constructor'", nullptr); return 0; } cobj = new cocos2d::Place(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Place"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Place:Place",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Place_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Place_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Place)"); return 0; } int lua_register_cocos2dx_Place(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Place"); tolua_cclass(tolua_S,"Place","cc.Place","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"Place"); tolua_function(tolua_S,"new",lua_cocos2dx_Place_constructor); tolua_function(tolua_S,"initWithPosition",lua_cocos2dx_Place_initWithPosition); tolua_function(tolua_S,"create", lua_cocos2dx_Place_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Place).name(); g_luaType[typeName] = "cc.Place"; g_typeCast["Place"] = "cc.Place"; return 1; } int lua_cocos2dx_CallFunc_execute(lua_State* tolua_S) { int argc = 0; cocos2d::CallFunc* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CallFunc",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CallFunc*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CallFunc_execute'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CallFunc_execute'", nullptr); return 0; } cobj->execute(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CallFunc:execute",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CallFunc_execute'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CallFunc_getTargetCallback(lua_State* tolua_S) { int argc = 0; cocos2d::CallFunc* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CallFunc",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CallFunc*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CallFunc_getTargetCallback'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CallFunc_getTargetCallback'", nullptr); return 0; } cocos2d::Ref* ret = cobj->getTargetCallback(); object_to_luaval<cocos2d::Ref>(tolua_S, "cc.Ref",(cocos2d::Ref*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CallFunc:getTargetCallback",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CallFunc_getTargetCallback'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CallFunc_setTargetCallback(lua_State* tolua_S) { int argc = 0; cocos2d::CallFunc* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CallFunc",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CallFunc*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CallFunc_setTargetCallback'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Ref* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Ref>(tolua_S, 2, "cc.Ref",&arg0, "cc.CallFunc:setTargetCallback"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CallFunc_setTargetCallback'", nullptr); return 0; } cobj->setTargetCallback(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CallFunc:setTargetCallback",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CallFunc_setTargetCallback'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CallFunc_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::CallFunc* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CallFunc_constructor'", nullptr); return 0; } cobj = new cocos2d::CallFunc(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.CallFunc"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CallFunc:CallFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CallFunc_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CallFunc_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CallFunc)"); return 0; } int lua_register_cocos2dx_CallFunc(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CallFunc"); tolua_cclass(tolua_S,"CallFunc","cc.CallFunc","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"CallFunc"); tolua_function(tolua_S,"new",lua_cocos2dx_CallFunc_constructor); tolua_function(tolua_S,"execute",lua_cocos2dx_CallFunc_execute); tolua_function(tolua_S,"getTargetCallback",lua_cocos2dx_CallFunc_getTargetCallback); tolua_function(tolua_S,"setTargetCallback",lua_cocos2dx_CallFunc_setTargetCallback); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CallFunc).name(); g_luaType[typeName] = "cc.CallFunc"; g_typeCast["CallFunc"] = "cc.CallFunc"; return 1; } int lua_cocos2dx_GridAction_getGrid(lua_State* tolua_S) { int argc = 0; cocos2d::GridAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridAction_getGrid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridAction_getGrid'", nullptr); return 0; } cocos2d::GridBase* ret = cobj->getGrid(); object_to_luaval<cocos2d::GridBase>(tolua_S, "cc.GridBase",(cocos2d::GridBase*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridAction:getGrid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridAction_getGrid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridAction_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::GridAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridAction_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; cocos2d::Size arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.GridAction:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.GridAction:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridAction_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridAction:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridAction_initWithDuration'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_GridAction_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (GridAction)"); return 0; } int lua_register_cocos2dx_GridAction(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.GridAction"); tolua_cclass(tolua_S,"GridAction","cc.GridAction","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"GridAction"); tolua_function(tolua_S,"getGrid",lua_cocos2dx_GridAction_getGrid); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_GridAction_initWithDuration); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::GridAction).name(); g_luaType[typeName] = "cc.GridAction"; g_typeCast["GridAction"] = "cc.GridAction"; return 1; } int lua_cocos2dx_Grid3DAction_getGridRect(lua_State* tolua_S) { int argc = 0; cocos2d::Grid3DAction* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Grid3DAction",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Grid3DAction*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Grid3DAction_getGridRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Grid3DAction_getGridRect'", nullptr); return 0; } cocos2d::Rect ret = cobj->getGridRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Grid3DAction:getGridRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Grid3DAction_getGridRect'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Grid3DAction_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Grid3DAction)"); return 0; } int lua_register_cocos2dx_Grid3DAction(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Grid3DAction"); tolua_cclass(tolua_S,"Grid3DAction","cc.Grid3DAction","cc.GridAction",nullptr); tolua_beginmodule(tolua_S,"Grid3DAction"); tolua_function(tolua_S,"getGridRect",lua_cocos2dx_Grid3DAction_getGridRect); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Grid3DAction).name(); g_luaType[typeName] = "cc.Grid3DAction"; g_typeCast["Grid3DAction"] = "cc.Grid3DAction"; return 1; } static int lua_cocos2dx_TiledGrid3DAction_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TiledGrid3DAction)"); return 0; } int lua_register_cocos2dx_TiledGrid3DAction(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TiledGrid3DAction"); tolua_cclass(tolua_S,"TiledGrid3DAction","cc.TiledGrid3DAction","cc.GridAction",nullptr); tolua_beginmodule(tolua_S,"TiledGrid3DAction"); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TiledGrid3DAction).name(); g_luaType[typeName] = "cc.TiledGrid3DAction"; g_typeCast["TiledGrid3DAction"] = "cc.TiledGrid3DAction"; return 1; } int lua_cocos2dx_StopGrid_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.StopGrid",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_StopGrid_create'", nullptr); return 0; } cocos2d::StopGrid* ret = cocos2d::StopGrid::create(); object_to_luaval<cocos2d::StopGrid>(tolua_S, "cc.StopGrid",(cocos2d::StopGrid*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.StopGrid:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_StopGrid_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_StopGrid_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::StopGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_StopGrid_constructor'", nullptr); return 0; } cobj = new cocos2d::StopGrid(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.StopGrid"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.StopGrid:StopGrid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_StopGrid_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_StopGrid_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (StopGrid)"); return 0; } int lua_register_cocos2dx_StopGrid(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.StopGrid"); tolua_cclass(tolua_S,"StopGrid","cc.StopGrid","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"StopGrid"); tolua_function(tolua_S,"new",lua_cocos2dx_StopGrid_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_StopGrid_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::StopGrid).name(); g_luaType[typeName] = "cc.StopGrid"; g_typeCast["StopGrid"] = "cc.StopGrid"; return 1; } int lua_cocos2dx_ReuseGrid_initWithTimes(lua_State* tolua_S) { int argc = 0; cocos2d::ReuseGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ReuseGrid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ReuseGrid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ReuseGrid_initWithTimes'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ReuseGrid:initWithTimes"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ReuseGrid_initWithTimes'", nullptr); return 0; } bool ret = cobj->initWithTimes(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ReuseGrid:initWithTimes",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ReuseGrid_initWithTimes'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ReuseGrid_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ReuseGrid",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ReuseGrid:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ReuseGrid_create'", nullptr); return 0; } cocos2d::ReuseGrid* ret = cocos2d::ReuseGrid::create(arg0); object_to_luaval<cocos2d::ReuseGrid>(tolua_S, "cc.ReuseGrid",(cocos2d::ReuseGrid*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ReuseGrid:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ReuseGrid_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ReuseGrid_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ReuseGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ReuseGrid_constructor'", nullptr); return 0; } cobj = new cocos2d::ReuseGrid(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ReuseGrid"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ReuseGrid:ReuseGrid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ReuseGrid_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ReuseGrid_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ReuseGrid)"); return 0; } int lua_register_cocos2dx_ReuseGrid(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ReuseGrid"); tolua_cclass(tolua_S,"ReuseGrid","cc.ReuseGrid","cc.ActionInstant",nullptr); tolua_beginmodule(tolua_S,"ReuseGrid"); tolua_function(tolua_S,"new",lua_cocos2dx_ReuseGrid_constructor); tolua_function(tolua_S,"initWithTimes",lua_cocos2dx_ReuseGrid_initWithTimes); tolua_function(tolua_S,"create", lua_cocos2dx_ReuseGrid_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ReuseGrid).name(); g_luaType[typeName] = "cc.ReuseGrid"; g_typeCast["ReuseGrid"] = "cc.ReuseGrid"; return 1; } int lua_cocos2dx_Waves3D_setAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Waves3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves3D_setAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Waves3D:setAmplitudeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves3D_setAmplitudeRate'", nullptr); return 0; } cobj->setAmplitudeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves3D:setAmplitudeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves3D_setAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Waves3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Waves3D:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Waves3D:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Waves3D:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Waves3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves3D:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves3D_getAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Waves3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves3D_getAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves3D_getAmplitude'", nullptr); return 0; } double ret = cobj->getAmplitude(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves3D:getAmplitude",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves3D_getAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves3D_getAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Waves3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves3D_getAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves3D_getAmplitudeRate'", nullptr); return 0; } double ret = cobj->getAmplitudeRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves3D:getAmplitudeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves3D_getAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves3D_setAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Waves3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves3D_setAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Waves3D:setAmplitude"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves3D_setAmplitude'", nullptr); return 0; } cobj->setAmplitude(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves3D:setAmplitude",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves3D_setAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Waves3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Waves3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Waves3D:create"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Waves3D:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Waves3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves3D_create'", nullptr); return 0; } cocos2d::Waves3D* ret = cocos2d::Waves3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Waves3D>(tolua_S, "cc.Waves3D",(cocos2d::Waves3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Waves3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Waves3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves3D_constructor'", nullptr); return 0; } cobj = new cocos2d::Waves3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Waves3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves3D:Waves3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Waves3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Waves3D)"); return 0; } int lua_register_cocos2dx_Waves3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Waves3D"); tolua_cclass(tolua_S,"Waves3D","cc.Waves3D","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"Waves3D"); tolua_function(tolua_S,"new",lua_cocos2dx_Waves3D_constructor); tolua_function(tolua_S,"setAmplitudeRate",lua_cocos2dx_Waves3D_setAmplitudeRate); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_Waves3D_initWithDuration); tolua_function(tolua_S,"getAmplitude",lua_cocos2dx_Waves3D_getAmplitude); tolua_function(tolua_S,"getAmplitudeRate",lua_cocos2dx_Waves3D_getAmplitudeRate); tolua_function(tolua_S,"setAmplitude",lua_cocos2dx_Waves3D_setAmplitude); tolua_function(tolua_S,"create", lua_cocos2dx_Waves3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Waves3D).name(); g_luaType[typeName] = "cc.Waves3D"; g_typeCast["Waves3D"] = "cc.Waves3D"; return 1; } int lua_cocos2dx_FlipX3D_initWithSize(lua_State* tolua_S) { int argc = 0; cocos2d::FlipX3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FlipX3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FlipX3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FlipX3D_initWithSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Size arg0; double arg1; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.FlipX3D:initWithSize"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.FlipX3D:initWithSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipX3D_initWithSize'", nullptr); return 0; } bool ret = cobj->initWithSize(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FlipX3D:initWithSize",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipX3D_initWithSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FlipX3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::FlipX3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FlipX3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FlipX3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FlipX3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FlipX3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipX3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FlipX3D:initWithDuration",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipX3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FlipX3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FlipX3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FlipX3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipX3D_create'", nullptr); return 0; } cocos2d::FlipX3D* ret = cocos2d::FlipX3D::create(arg0); object_to_luaval<cocos2d::FlipX3D>(tolua_S, "cc.FlipX3D",(cocos2d::FlipX3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FlipX3D:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipX3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FlipX3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FlipX3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipX3D_constructor'", nullptr); return 0; } cobj = new cocos2d::FlipX3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FlipX3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FlipX3D:FlipX3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipX3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FlipX3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FlipX3D)"); return 0; } int lua_register_cocos2dx_FlipX3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FlipX3D"); tolua_cclass(tolua_S,"FlipX3D","cc.FlipX3D","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"FlipX3D"); tolua_function(tolua_S,"new",lua_cocos2dx_FlipX3D_constructor); tolua_function(tolua_S,"initWithSize",lua_cocos2dx_FlipX3D_initWithSize); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_FlipX3D_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_FlipX3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FlipX3D).name(); g_luaType[typeName] = "cc.FlipX3D"; g_typeCast["FlipX3D"] = "cc.FlipX3D"; return 1; } int lua_cocos2dx_FlipY3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FlipY3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FlipY3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipY3D_create'", nullptr); return 0; } cocos2d::FlipY3D* ret = cocos2d::FlipY3D::create(arg0); object_to_luaval<cocos2d::FlipY3D>(tolua_S, "cc.FlipY3D",(cocos2d::FlipY3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FlipY3D:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipY3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FlipY3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FlipY3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FlipY3D_constructor'", nullptr); return 0; } cobj = new cocos2d::FlipY3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FlipY3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FlipY3D:FlipY3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FlipY3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FlipY3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FlipY3D)"); return 0; } int lua_register_cocos2dx_FlipY3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FlipY3D"); tolua_cclass(tolua_S,"FlipY3D","cc.FlipY3D","cc.FlipX3D",nullptr); tolua_beginmodule(tolua_S,"FlipY3D"); tolua_function(tolua_S,"new",lua_cocos2dx_FlipY3D_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_FlipY3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FlipY3D).name(); g_luaType[typeName] = "cc.FlipY3D"; g_typeCast["FlipY3D"] = "cc.FlipY3D"; return 1; } int lua_cocos2dx_Lens3D_setConcave(lua_State* tolua_S) { int argc = 0; cocos2d::Lens3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Lens3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Lens3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Lens3D_setConcave'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Lens3D:setConcave"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Lens3D_setConcave'", nullptr); return 0; } cobj->setConcave(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Lens3D:setConcave",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Lens3D_setConcave'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Lens3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Lens3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Lens3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Lens3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Lens3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Size arg1; cocos2d::Vec2 arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Lens3D:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Lens3D:initWithDuration"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.Lens3D:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Lens3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Lens3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Lens3D:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Lens3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Lens3D_setLensEffect(lua_State* tolua_S) { int argc = 0; cocos2d::Lens3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Lens3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Lens3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Lens3D_setLensEffect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Lens3D:setLensEffect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Lens3D_setLensEffect'", nullptr); return 0; } cobj->setLensEffect(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Lens3D:setLensEffect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Lens3D_setLensEffect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Lens3D_getLensEffect(lua_State* tolua_S) { int argc = 0; cocos2d::Lens3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Lens3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Lens3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Lens3D_getLensEffect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Lens3D_getLensEffect'", nullptr); return 0; } double ret = cobj->getLensEffect(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Lens3D:getLensEffect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Lens3D_getLensEffect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Lens3D_setPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Lens3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Lens3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Lens3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Lens3D_setPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Lens3D:setPosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Lens3D_setPosition'", nullptr); return 0; } cobj->setPosition(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Lens3D:setPosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Lens3D_setPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Lens3D_getPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Lens3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Lens3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Lens3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Lens3D_getPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Lens3D_getPosition'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getPosition(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Lens3D:getPosition",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Lens3D_getPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Lens3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Lens3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Size arg1; cocos2d::Vec2 arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Lens3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Lens3D:create"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.Lens3D:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Lens3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Lens3D_create'", nullptr); return 0; } cocos2d::Lens3D* ret = cocos2d::Lens3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Lens3D>(tolua_S, "cc.Lens3D",(cocos2d::Lens3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Lens3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Lens3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Lens3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Lens3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Lens3D_constructor'", nullptr); return 0; } cobj = new cocos2d::Lens3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Lens3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Lens3D:Lens3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Lens3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Lens3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Lens3D)"); return 0; } int lua_register_cocos2dx_Lens3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Lens3D"); tolua_cclass(tolua_S,"Lens3D","cc.Lens3D","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"Lens3D"); tolua_function(tolua_S,"new",lua_cocos2dx_Lens3D_constructor); tolua_function(tolua_S,"setConcave",lua_cocos2dx_Lens3D_setConcave); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_Lens3D_initWithDuration); tolua_function(tolua_S,"setLensEffect",lua_cocos2dx_Lens3D_setLensEffect); tolua_function(tolua_S,"getLensEffect",lua_cocos2dx_Lens3D_getLensEffect); tolua_function(tolua_S,"setPosition",lua_cocos2dx_Lens3D_setPosition); tolua_function(tolua_S,"getPosition",lua_cocos2dx_Lens3D_getPosition); tolua_function(tolua_S,"create", lua_cocos2dx_Lens3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Lens3D).name(); g_luaType[typeName] = "cc.Lens3D"; g_typeCast["Lens3D"] = "cc.Lens3D"; return 1; } int lua_cocos2dx_Ripple3D_setAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Ripple3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ripple3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ripple3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ripple3D_setAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Ripple3D:setAmplitudeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_setAmplitudeRate'", nullptr); return 0; } cobj->setAmplitudeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ripple3D:setAmplitudeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_setAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ripple3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Ripple3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ripple3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ripple3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ripple3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 6) { double arg0; cocos2d::Size arg1; cocos2d::Vec2 arg2; double arg3; unsigned int arg4; double arg5; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Ripple3D:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Ripple3D:initWithDuration"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.Ripple3D:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Ripple3D:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 6,&arg4, "cc.Ripple3D:initWithDuration"); ok &= luaval_to_number(tolua_S, 7,&arg5, "cc.Ripple3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3, arg4, arg5); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ripple3D:initWithDuration",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ripple3D_getAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Ripple3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ripple3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ripple3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ripple3D_getAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_getAmplitudeRate'", nullptr); return 0; } double ret = cobj->getAmplitudeRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ripple3D:getAmplitudeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_getAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ripple3D_setAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Ripple3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ripple3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ripple3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ripple3D_setAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Ripple3D:setAmplitude"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_setAmplitude'", nullptr); return 0; } cobj->setAmplitude(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ripple3D:setAmplitude",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_setAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ripple3D_getAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Ripple3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ripple3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ripple3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ripple3D_getAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_getAmplitude'", nullptr); return 0; } double ret = cobj->getAmplitude(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ripple3D:getAmplitude",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_getAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ripple3D_setPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Ripple3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ripple3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ripple3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ripple3D_setPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Ripple3D:setPosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_setPosition'", nullptr); return 0; } cobj->setPosition(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ripple3D:setPosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_setPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ripple3D_getPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Ripple3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Ripple3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Ripple3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Ripple3D_getPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_getPosition'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getPosition(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ripple3D:getPosition",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_getPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ripple3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Ripple3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 6) { double arg0; cocos2d::Size arg1; cocos2d::Vec2 arg2; double arg3; unsigned int arg4; double arg5; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Ripple3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Ripple3D:create"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.Ripple3D:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Ripple3D:create"); ok &= luaval_to_uint32(tolua_S, 6,&arg4, "cc.Ripple3D:create"); ok &= luaval_to_number(tolua_S, 7,&arg5, "cc.Ripple3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_create'", nullptr); return 0; } cocos2d::Ripple3D* ret = cocos2d::Ripple3D::create(arg0, arg1, arg2, arg3, arg4, arg5); object_to_luaval<cocos2d::Ripple3D>(tolua_S, "cc.Ripple3D",(cocos2d::Ripple3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Ripple3D:create",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Ripple3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Ripple3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Ripple3D_constructor'", nullptr); return 0; } cobj = new cocos2d::Ripple3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Ripple3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Ripple3D:Ripple3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Ripple3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Ripple3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Ripple3D)"); return 0; } int lua_register_cocos2dx_Ripple3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Ripple3D"); tolua_cclass(tolua_S,"Ripple3D","cc.Ripple3D","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"Ripple3D"); tolua_function(tolua_S,"new",lua_cocos2dx_Ripple3D_constructor); tolua_function(tolua_S,"setAmplitudeRate",lua_cocos2dx_Ripple3D_setAmplitudeRate); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_Ripple3D_initWithDuration); tolua_function(tolua_S,"getAmplitudeRate",lua_cocos2dx_Ripple3D_getAmplitudeRate); tolua_function(tolua_S,"setAmplitude",lua_cocos2dx_Ripple3D_setAmplitude); tolua_function(tolua_S,"getAmplitude",lua_cocos2dx_Ripple3D_getAmplitude); tolua_function(tolua_S,"setPosition",lua_cocos2dx_Ripple3D_setPosition); tolua_function(tolua_S,"getPosition",lua_cocos2dx_Ripple3D_getPosition); tolua_function(tolua_S,"create", lua_cocos2dx_Ripple3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Ripple3D).name(); g_luaType[typeName] = "cc.Ripple3D"; g_typeCast["Ripple3D"] = "cc.Ripple3D"; return 1; } int lua_cocos2dx_Shaky3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Shaky3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Shaky3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Shaky3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Shaky3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Size arg1; int arg2; bool arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Shaky3D:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Shaky3D:initWithDuration"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Shaky3D:initWithDuration"); ok &= luaval_to_boolean(tolua_S, 5,&arg3, "cc.Shaky3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Shaky3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Shaky3D:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Shaky3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Shaky3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Shaky3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Size arg1; int arg2; bool arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Shaky3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Shaky3D:create"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Shaky3D:create"); ok &= luaval_to_boolean(tolua_S, 5,&arg3, "cc.Shaky3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Shaky3D_create'", nullptr); return 0; } cocos2d::Shaky3D* ret = cocos2d::Shaky3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Shaky3D>(tolua_S, "cc.Shaky3D",(cocos2d::Shaky3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Shaky3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Shaky3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Shaky3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Shaky3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Shaky3D_constructor'", nullptr); return 0; } cobj = new cocos2d::Shaky3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Shaky3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Shaky3D:Shaky3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Shaky3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Shaky3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Shaky3D)"); return 0; } int lua_register_cocos2dx_Shaky3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Shaky3D"); tolua_cclass(tolua_S,"Shaky3D","cc.Shaky3D","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"Shaky3D"); tolua_function(tolua_S,"new",lua_cocos2dx_Shaky3D_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_Shaky3D_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_Shaky3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Shaky3D).name(); g_luaType[typeName] = "cc.Shaky3D"; g_typeCast["Shaky3D"] = "cc.Shaky3D"; return 1; } int lua_cocos2dx_Liquid_setAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Liquid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Liquid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Liquid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Liquid_setAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Liquid:setAmplitudeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Liquid_setAmplitudeRate'", nullptr); return 0; } cobj->setAmplitudeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Liquid:setAmplitudeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Liquid_setAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Liquid_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Liquid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Liquid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Liquid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Liquid_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Liquid:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Liquid:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Liquid:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Liquid:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Liquid_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Liquid:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Liquid_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Liquid_getAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Liquid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Liquid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Liquid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Liquid_getAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Liquid_getAmplitude'", nullptr); return 0; } double ret = cobj->getAmplitude(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Liquid:getAmplitude",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Liquid_getAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Liquid_getAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Liquid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Liquid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Liquid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Liquid_getAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Liquid_getAmplitudeRate'", nullptr); return 0; } double ret = cobj->getAmplitudeRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Liquid:getAmplitudeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Liquid_getAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Liquid_setAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Liquid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Liquid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Liquid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Liquid_setAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Liquid:setAmplitude"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Liquid_setAmplitude'", nullptr); return 0; } cobj->setAmplitude(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Liquid:setAmplitude",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Liquid_setAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Liquid_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Liquid",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Liquid:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Liquid:create"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Liquid:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Liquid:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Liquid_create'", nullptr); return 0; } cocos2d::Liquid* ret = cocos2d::Liquid::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Liquid>(tolua_S, "cc.Liquid",(cocos2d::Liquid*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Liquid:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Liquid_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Liquid_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Liquid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Liquid_constructor'", nullptr); return 0; } cobj = new cocos2d::Liquid(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Liquid"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Liquid:Liquid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Liquid_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Liquid_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Liquid)"); return 0; } int lua_register_cocos2dx_Liquid(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Liquid"); tolua_cclass(tolua_S,"Liquid","cc.Liquid","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"Liquid"); tolua_function(tolua_S,"new",lua_cocos2dx_Liquid_constructor); tolua_function(tolua_S,"setAmplitudeRate",lua_cocos2dx_Liquid_setAmplitudeRate); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_Liquid_initWithDuration); tolua_function(tolua_S,"getAmplitude",lua_cocos2dx_Liquid_getAmplitude); tolua_function(tolua_S,"getAmplitudeRate",lua_cocos2dx_Liquid_getAmplitudeRate); tolua_function(tolua_S,"setAmplitude",lua_cocos2dx_Liquid_setAmplitude); tolua_function(tolua_S,"create", lua_cocos2dx_Liquid_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Liquid).name(); g_luaType[typeName] = "cc.Liquid"; g_typeCast["Liquid"] = "cc.Liquid"; return 1; } int lua_cocos2dx_Waves_setAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Waves* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves_setAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Waves:setAmplitudeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves_setAmplitudeRate'", nullptr); return 0; } cobj->setAmplitudeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves:setAmplitudeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves_setAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Waves* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 6) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; bool arg4; bool arg5; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Waves:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Waves:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Waves:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Waves:initWithDuration"); ok &= luaval_to_boolean(tolua_S, 6,&arg4, "cc.Waves:initWithDuration"); ok &= luaval_to_boolean(tolua_S, 7,&arg5, "cc.Waves:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3, arg4, arg5); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves:initWithDuration",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves_getAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Waves* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves_getAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves_getAmplitude'", nullptr); return 0; } double ret = cobj->getAmplitude(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves:getAmplitude",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves_getAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves_getAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Waves* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves_getAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves_getAmplitudeRate'", nullptr); return 0; } double ret = cobj->getAmplitudeRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves:getAmplitudeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves_getAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves_setAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Waves* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Waves",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Waves*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Waves_setAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Waves:setAmplitude"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves_setAmplitude'", nullptr); return 0; } cobj->setAmplitude(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves:setAmplitude",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves_setAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Waves",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 6) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; bool arg4; bool arg5; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Waves:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Waves:create"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.Waves:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Waves:create"); ok &= luaval_to_boolean(tolua_S, 6,&arg4, "cc.Waves:create"); ok &= luaval_to_boolean(tolua_S, 7,&arg5, "cc.Waves:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves_create'", nullptr); return 0; } cocos2d::Waves* ret = cocos2d::Waves::create(arg0, arg1, arg2, arg3, arg4, arg5); object_to_luaval<cocos2d::Waves>(tolua_S, "cc.Waves",(cocos2d::Waves*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Waves:create",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Waves_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Waves* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Waves_constructor'", nullptr); return 0; } cobj = new cocos2d::Waves(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Waves"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Waves:Waves",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Waves_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Waves_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Waves)"); return 0; } int lua_register_cocos2dx_Waves(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Waves"); tolua_cclass(tolua_S,"Waves","cc.Waves","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"Waves"); tolua_function(tolua_S,"new",lua_cocos2dx_Waves_constructor); tolua_function(tolua_S,"setAmplitudeRate",lua_cocos2dx_Waves_setAmplitudeRate); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_Waves_initWithDuration); tolua_function(tolua_S,"getAmplitude",lua_cocos2dx_Waves_getAmplitude); tolua_function(tolua_S,"getAmplitudeRate",lua_cocos2dx_Waves_getAmplitudeRate); tolua_function(tolua_S,"setAmplitude",lua_cocos2dx_Waves_setAmplitude); tolua_function(tolua_S,"create", lua_cocos2dx_Waves_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Waves).name(); g_luaType[typeName] = "cc.Waves"; g_typeCast["Waves"] = "cc.Waves"; return 1; } int lua_cocos2dx_Twirl_setAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Twirl* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Twirl",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Twirl*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Twirl_setAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Twirl:setAmplitudeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_setAmplitudeRate'", nullptr); return 0; } cobj->setAmplitudeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Twirl:setAmplitudeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_setAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Twirl_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::Twirl* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Twirl",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Twirl*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Twirl_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 5) { double arg0; cocos2d::Size arg1; cocos2d::Vec2 arg2; unsigned int arg3; double arg4; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Twirl:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Twirl:initWithDuration"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.Twirl:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.Twirl:initWithDuration"); ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.Twirl:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Twirl:initWithDuration",argc, 5); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Twirl_getAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::Twirl* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Twirl",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Twirl*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Twirl_getAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_getAmplitudeRate'", nullptr); return 0; } double ret = cobj->getAmplitudeRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Twirl:getAmplitudeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_getAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Twirl_setAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Twirl* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Twirl",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Twirl*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Twirl_setAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Twirl:setAmplitude"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_setAmplitude'", nullptr); return 0; } cobj->setAmplitude(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Twirl:setAmplitude",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_setAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Twirl_getAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::Twirl* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Twirl",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Twirl*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Twirl_getAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_getAmplitude'", nullptr); return 0; } double ret = cobj->getAmplitude(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Twirl:getAmplitude",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_getAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Twirl_setPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Twirl* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Twirl",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Twirl*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Twirl_setPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.Twirl:setPosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_setPosition'", nullptr); return 0; } cobj->setPosition(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Twirl:setPosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_setPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Twirl_getPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Twirl* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Twirl",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Twirl*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Twirl_getPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_getPosition'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getPosition(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Twirl:getPosition",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_getPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Twirl_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Twirl",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 5) { double arg0; cocos2d::Size arg1; cocos2d::Vec2 arg2; unsigned int arg3; double arg4; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Twirl:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Twirl:create"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.Twirl:create"); ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.Twirl:create"); ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.Twirl:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_create'", nullptr); return 0; } cocos2d::Twirl* ret = cocos2d::Twirl::create(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::Twirl>(tolua_S, "cc.Twirl",(cocos2d::Twirl*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Twirl:create",argc, 5); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Twirl_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Twirl* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Twirl_constructor'", nullptr); return 0; } cobj = new cocos2d::Twirl(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Twirl"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Twirl:Twirl",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Twirl_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Twirl_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Twirl)"); return 0; } int lua_register_cocos2dx_Twirl(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Twirl"); tolua_cclass(tolua_S,"Twirl","cc.Twirl","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"Twirl"); tolua_function(tolua_S,"new",lua_cocos2dx_Twirl_constructor); tolua_function(tolua_S,"setAmplitudeRate",lua_cocos2dx_Twirl_setAmplitudeRate); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_Twirl_initWithDuration); tolua_function(tolua_S,"getAmplitudeRate",lua_cocos2dx_Twirl_getAmplitudeRate); tolua_function(tolua_S,"setAmplitude",lua_cocos2dx_Twirl_setAmplitude); tolua_function(tolua_S,"getAmplitude",lua_cocos2dx_Twirl_getAmplitude); tolua_function(tolua_S,"setPosition",lua_cocos2dx_Twirl_setPosition); tolua_function(tolua_S,"getPosition",lua_cocos2dx_Twirl_getPosition); tolua_function(tolua_S,"create", lua_cocos2dx_Twirl_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Twirl).name(); g_luaType[typeName] = "cc.Twirl"; g_typeCast["Twirl"] = "cc.Twirl"; return 1; } int lua_cocos2dx_ActionManager_getActionByTag(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_getActionByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { int arg0; const cocos2d::Node* arg1 = nullptr; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ActionManager:getActionByTag"); ok &= luaval_to_object<const cocos2d::Node>(tolua_S, 3, "cc.Node",&arg1, "cc.ActionManager:getActionByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_getActionByTag'", nullptr); return 0; } cocos2d::Action* ret = cobj->getActionByTag(arg0, arg1); object_to_luaval<cocos2d::Action>(tolua_S, "cc.Action",(cocos2d::Action*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:getActionByTag",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_getActionByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_removeActionByTag(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_removeActionByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { int arg0; cocos2d::Node* arg1 = nullptr; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ActionManager:removeActionByTag"); ok &= luaval_to_object<cocos2d::Node>(tolua_S, 3, "cc.Node",&arg1, "cc.ActionManager:removeActionByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_removeActionByTag'", nullptr); return 0; } cobj->removeActionByTag(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:removeActionByTag",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_removeActionByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_removeActionsByFlags(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_removeActionsByFlags'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { unsigned int arg0; cocos2d::Node* arg1 = nullptr; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.ActionManager:removeActionsByFlags"); ok &= luaval_to_object<cocos2d::Node>(tolua_S, 3, "cc.Node",&arg1, "cc.ActionManager:removeActionsByFlags"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_removeActionsByFlags'", nullptr); return 0; } cobj->removeActionsByFlags(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:removeActionsByFlags",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_removeActionsByFlags'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_removeAllActions(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_removeAllActions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_removeAllActions'", nullptr); return 0; } cobj->removeAllActions(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:removeAllActions",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_removeAllActions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_addAction(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_addAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Action* arg0 = nullptr; cocos2d::Node* arg1 = nullptr; bool arg2; ok &= luaval_to_object<cocos2d::Action>(tolua_S, 2, "cc.Action",&arg0, "cc.ActionManager:addAction"); ok &= luaval_to_object<cocos2d::Node>(tolua_S, 3, "cc.Node",&arg1, "cc.ActionManager:addAction"); ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.ActionManager:addAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_addAction'", nullptr); return 0; } cobj->addAction(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:addAction",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_addAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_resumeTarget(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_resumeTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ActionManager:resumeTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_resumeTarget'", nullptr); return 0; } cobj->resumeTarget(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:resumeTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_resumeTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_update(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_update'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ActionManager:update"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_update'", nullptr); return 0; } cobj->update(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:update",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_update'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_pauseTarget(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_pauseTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ActionManager:pauseTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_pauseTarget'", nullptr); return 0; } cobj->pauseTarget(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:pauseTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_pauseTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTarget(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { const cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<const cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ActionManager:getNumberOfRunningActionsInTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTarget'", nullptr); return 0; } ssize_t ret = cobj->getNumberOfRunningActionsInTarget(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:getNumberOfRunningActionsInTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_removeAllActionsFromTarget(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_removeAllActionsFromTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ActionManager:removeAllActionsFromTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_removeAllActionsFromTarget'", nullptr); return 0; } cobj->removeAllActionsFromTarget(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:removeAllActionsFromTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_removeAllActionsFromTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_resumeTargets(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_resumeTargets'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::Node *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.ActionManager:resumeTargets"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_resumeTargets'", nullptr); return 0; } cobj->resumeTargets(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:resumeTargets",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_resumeTargets'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_removeAction(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_removeAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Action* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Action>(tolua_S, 2, "cc.Action",&arg0, "cc.ActionManager:removeAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_removeAction'", nullptr); return 0; } cobj->removeAction(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:removeAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_removeAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_pauseAllRunningActions(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_pauseAllRunningActions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_pauseAllRunningActions'", nullptr); return 0; } cocos2d::Vector<cocos2d::Node *> ret = cobj->pauseAllRunningActions(); ccvector_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:pauseAllRunningActions",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_pauseAllRunningActions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_removeAllActionsByTag(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_removeAllActionsByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { int arg0; cocos2d::Node* arg1 = nullptr; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ActionManager:removeAllActionsByTag"); ok &= luaval_to_object<cocos2d::Node>(tolua_S, 3, "cc.Node",&arg1, "cc.ActionManager:removeAllActionsByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_removeAllActionsByTag'", nullptr); return 0; } cobj->removeAllActionsByTag(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:removeAllActionsByTag",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_removeAllActionsByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTargetByTag(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionManager",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionManager*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTargetByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { const cocos2d::Node* arg0 = nullptr; int arg1; ok &= luaval_to_object<const cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ActionManager:getNumberOfRunningActionsInTargetByTag"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ActionManager:getNumberOfRunningActionsInTargetByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTargetByTag'", nullptr); return 0; } unsigned long ret = cobj->getNumberOfRunningActionsInTargetByTag(arg0, arg1); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:getNumberOfRunningActionsInTargetByTag",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTargetByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionManager_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ActionManager* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionManager_constructor'", nullptr); return 0; } cobj = new cocos2d::ActionManager(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ActionManager"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionManager:ActionManager",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionManager_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ActionManager_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ActionManager)"); return 0; } int lua_register_cocos2dx_ActionManager(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ActionManager"); tolua_cclass(tolua_S,"ActionManager","cc.ActionManager","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"ActionManager"); tolua_function(tolua_S,"new",lua_cocos2dx_ActionManager_constructor); tolua_function(tolua_S,"getActionByTag",lua_cocos2dx_ActionManager_getActionByTag); tolua_function(tolua_S,"removeActionByTag",lua_cocos2dx_ActionManager_removeActionByTag); tolua_function(tolua_S,"removeActionsByFlags",lua_cocos2dx_ActionManager_removeActionsByFlags); tolua_function(tolua_S,"removeAllActions",lua_cocos2dx_ActionManager_removeAllActions); tolua_function(tolua_S,"addAction",lua_cocos2dx_ActionManager_addAction); tolua_function(tolua_S,"resumeTarget",lua_cocos2dx_ActionManager_resumeTarget); tolua_function(tolua_S,"update",lua_cocos2dx_ActionManager_update); tolua_function(tolua_S,"pauseTarget",lua_cocos2dx_ActionManager_pauseTarget); tolua_function(tolua_S,"getNumberOfRunningActionsInTarget",lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTarget); tolua_function(tolua_S,"removeAllActionsFromTarget",lua_cocos2dx_ActionManager_removeAllActionsFromTarget); tolua_function(tolua_S,"resumeTargets",lua_cocos2dx_ActionManager_resumeTargets); tolua_function(tolua_S,"removeAction",lua_cocos2dx_ActionManager_removeAction); tolua_function(tolua_S,"pauseAllRunningActions",lua_cocos2dx_ActionManager_pauseAllRunningActions); tolua_function(tolua_S,"removeAllActionsByTag",lua_cocos2dx_ActionManager_removeAllActionsByTag); tolua_function(tolua_S,"getNumberOfRunningActionsInTargetByTag",lua_cocos2dx_ActionManager_getNumberOfRunningActionsInTargetByTag); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ActionManager).name(); g_luaType[typeName] = "cc.ActionManager"; g_typeCast["ActionManager"] = "cc.ActionManager"; return 1; } int lua_cocos2dx_PageTurn3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.PageTurn3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Size arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.PageTurn3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.PageTurn3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PageTurn3D_create'", nullptr); return 0; } cocos2d::PageTurn3D* ret = cocos2d::PageTurn3D::create(arg0, arg1); object_to_luaval<cocos2d::PageTurn3D>(tolua_S, "cc.PageTurn3D",(cocos2d::PageTurn3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.PageTurn3D:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PageTurn3D_create'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_PageTurn3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (PageTurn3D)"); return 0; } int lua_register_cocos2dx_PageTurn3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.PageTurn3D"); tolua_cclass(tolua_S,"PageTurn3D","cc.PageTurn3D","cc.Grid3DAction",nullptr); tolua_beginmodule(tolua_S,"PageTurn3D"); tolua_function(tolua_S,"create", lua_cocos2dx_PageTurn3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::PageTurn3D).name(); g_luaType[typeName] = "cc.PageTurn3D"; g_typeCast["PageTurn3D"] = "cc.PageTurn3D"; return 1; } int lua_cocos2dx_ProgressTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; double arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ProgressTo:initWithDuration"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ProgressTo:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTo:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ProgressTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; double arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ProgressTo:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ProgressTo:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTo_create'", nullptr); return 0; } cocos2d::ProgressTo* ret = cocos2d::ProgressTo::create(arg0, arg1); object_to_luaval<cocos2d::ProgressTo>(tolua_S, "cc.ProgressTo",(cocos2d::ProgressTo*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ProgressTo:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTo_constructor'", nullptr); return 0; } cobj = new cocos2d::ProgressTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ProgressTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTo:ProgressTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ProgressTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ProgressTo)"); return 0; } int lua_register_cocos2dx_ProgressTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ProgressTo"); tolua_cclass(tolua_S,"ProgressTo","cc.ProgressTo","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"ProgressTo"); tolua_function(tolua_S,"new",lua_cocos2dx_ProgressTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ProgressTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_ProgressTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ProgressTo).name(); g_luaType[typeName] = "cc.ProgressTo"; g_typeCast["ProgressTo"] = "cc.ProgressTo"; return 1; } int lua_cocos2dx_ProgressFromTo_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressFromTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressFromTo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressFromTo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressFromTo_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; double arg1; double arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ProgressFromTo:initWithDuration"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ProgressFromTo:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ProgressFromTo:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressFromTo_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressFromTo:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressFromTo_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressFromTo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ProgressFromTo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { double arg0; double arg1; double arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ProgressFromTo:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.ProgressFromTo:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ProgressFromTo:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressFromTo_create'", nullptr); return 0; } cocos2d::ProgressFromTo* ret = cocos2d::ProgressFromTo::create(arg0, arg1, arg2); object_to_luaval<cocos2d::ProgressFromTo>(tolua_S, "cc.ProgressFromTo",(cocos2d::ProgressFromTo*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ProgressFromTo:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressFromTo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressFromTo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressFromTo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressFromTo_constructor'", nullptr); return 0; } cobj = new cocos2d::ProgressFromTo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ProgressFromTo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressFromTo:ProgressFromTo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressFromTo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ProgressFromTo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ProgressFromTo)"); return 0; } int lua_register_cocos2dx_ProgressFromTo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ProgressFromTo"); tolua_cclass(tolua_S,"ProgressFromTo","cc.ProgressFromTo","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"ProgressFromTo"); tolua_function(tolua_S,"new",lua_cocos2dx_ProgressFromTo_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ProgressFromTo_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_ProgressFromTo_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ProgressFromTo).name(); g_luaType[typeName] = "cc.ProgressFromTo"; g_typeCast["ProgressFromTo"] = "cc.ProgressFromTo"; return 1; } int lua_cocos2dx_ShakyTiles3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ShakyTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ShakyTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ShakyTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ShakyTiles3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Size arg1; int arg2; bool arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ShakyTiles3D:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.ShakyTiles3D:initWithDuration"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.ShakyTiles3D:initWithDuration"); ok &= luaval_to_boolean(tolua_S, 5,&arg3, "cc.ShakyTiles3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShakyTiles3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ShakyTiles3D:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShakyTiles3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ShakyTiles3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ShakyTiles3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Size arg1; int arg2; bool arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ShakyTiles3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.ShakyTiles3D:create"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.ShakyTiles3D:create"); ok &= luaval_to_boolean(tolua_S, 5,&arg3, "cc.ShakyTiles3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShakyTiles3D_create'", nullptr); return 0; } cocos2d::ShakyTiles3D* ret = cocos2d::ShakyTiles3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::ShakyTiles3D>(tolua_S, "cc.ShakyTiles3D",(cocos2d::ShakyTiles3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ShakyTiles3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShakyTiles3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ShakyTiles3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ShakyTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShakyTiles3D_constructor'", nullptr); return 0; } cobj = new cocos2d::ShakyTiles3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ShakyTiles3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ShakyTiles3D:ShakyTiles3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShakyTiles3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ShakyTiles3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ShakyTiles3D)"); return 0; } int lua_register_cocos2dx_ShakyTiles3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ShakyTiles3D"); tolua_cclass(tolua_S,"ShakyTiles3D","cc.ShakyTiles3D","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"ShakyTiles3D"); tolua_function(tolua_S,"new",lua_cocos2dx_ShakyTiles3D_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ShakyTiles3D_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_ShakyTiles3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ShakyTiles3D).name(); g_luaType[typeName] = "cc.ShakyTiles3D"; g_typeCast["ShakyTiles3D"] = "cc.ShakyTiles3D"; return 1; } int lua_cocos2dx_ShatteredTiles3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ShatteredTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ShatteredTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ShatteredTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ShatteredTiles3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Size arg1; int arg2; bool arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ShatteredTiles3D:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.ShatteredTiles3D:initWithDuration"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.ShatteredTiles3D:initWithDuration"); ok &= luaval_to_boolean(tolua_S, 5,&arg3, "cc.ShatteredTiles3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShatteredTiles3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ShatteredTiles3D:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShatteredTiles3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ShatteredTiles3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ShatteredTiles3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Size arg1; int arg2; bool arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ShatteredTiles3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.ShatteredTiles3D:create"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.ShatteredTiles3D:create"); ok &= luaval_to_boolean(tolua_S, 5,&arg3, "cc.ShatteredTiles3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShatteredTiles3D_create'", nullptr); return 0; } cocos2d::ShatteredTiles3D* ret = cocos2d::ShatteredTiles3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::ShatteredTiles3D>(tolua_S, "cc.ShatteredTiles3D",(cocos2d::ShatteredTiles3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ShatteredTiles3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShatteredTiles3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ShatteredTiles3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ShatteredTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShatteredTiles3D_constructor'", nullptr); return 0; } cobj = new cocos2d::ShatteredTiles3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ShatteredTiles3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ShatteredTiles3D:ShatteredTiles3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShatteredTiles3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ShatteredTiles3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ShatteredTiles3D)"); return 0; } int lua_register_cocos2dx_ShatteredTiles3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ShatteredTiles3D"); tolua_cclass(tolua_S,"ShatteredTiles3D","cc.ShatteredTiles3D","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"ShatteredTiles3D"); tolua_function(tolua_S,"new",lua_cocos2dx_ShatteredTiles3D_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ShatteredTiles3D_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_ShatteredTiles3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ShatteredTiles3D).name(); g_luaType[typeName] = "cc.ShatteredTiles3D"; g_typeCast["ShatteredTiles3D"] = "cc.ShatteredTiles3D"; return 1; } int lua_cocos2dx_ShuffleTiles_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ShuffleTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ShuffleTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ShuffleTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ShuffleTiles_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; cocos2d::Size arg1; unsigned int arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ShuffleTiles:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.ShuffleTiles:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.ShuffleTiles:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShuffleTiles_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ShuffleTiles:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShuffleTiles_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ShuffleTiles_getDelta(lua_State* tolua_S) { int argc = 0; cocos2d::ShuffleTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ShuffleTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ShuffleTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ShuffleTiles_getDelta'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.ShuffleTiles:getDelta"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShuffleTiles_getDelta'", nullptr); return 0; } cocos2d::Size ret = cobj->getDelta(arg0); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ShuffleTiles:getDelta",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShuffleTiles_getDelta'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ShuffleTiles_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ShuffleTiles",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { double arg0; cocos2d::Size arg1; unsigned int arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ShuffleTiles:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.ShuffleTiles:create"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.ShuffleTiles:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShuffleTiles_create'", nullptr); return 0; } cocos2d::ShuffleTiles* ret = cocos2d::ShuffleTiles::create(arg0, arg1, arg2); object_to_luaval<cocos2d::ShuffleTiles>(tolua_S, "cc.ShuffleTiles",(cocos2d::ShuffleTiles*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ShuffleTiles:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShuffleTiles_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ShuffleTiles_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ShuffleTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ShuffleTiles_constructor'", nullptr); return 0; } cobj = new cocos2d::ShuffleTiles(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ShuffleTiles"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ShuffleTiles:ShuffleTiles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ShuffleTiles_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ShuffleTiles_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ShuffleTiles)"); return 0; } int lua_register_cocos2dx_ShuffleTiles(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ShuffleTiles"); tolua_cclass(tolua_S,"ShuffleTiles","cc.ShuffleTiles","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"ShuffleTiles"); tolua_function(tolua_S,"new",lua_cocos2dx_ShuffleTiles_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ShuffleTiles_initWithDuration); tolua_function(tolua_S,"getDelta",lua_cocos2dx_ShuffleTiles_getDelta); tolua_function(tolua_S,"create", lua_cocos2dx_ShuffleTiles_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ShuffleTiles).name(); g_luaType[typeName] = "cc.ShuffleTiles"; g_typeCast["ShuffleTiles"] = "cc.ShuffleTiles"; return 1; } int lua_cocos2dx_FadeOutTRTiles_turnOnTile(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOutTRTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FadeOutTRTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FadeOutTRTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FadeOutTRTiles_turnOnTile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.FadeOutTRTiles:turnOnTile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutTRTiles_turnOnTile'", nullptr); return 0; } cobj->turnOnTile(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutTRTiles:turnOnTile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutTRTiles_turnOnTile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOutTRTiles_turnOffTile(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOutTRTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FadeOutTRTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FadeOutTRTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FadeOutTRTiles_turnOffTile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.FadeOutTRTiles:turnOffTile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutTRTiles_turnOffTile'", nullptr); return 0; } cobj->turnOffTile(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutTRTiles:turnOffTile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutTRTiles_turnOffTile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOutTRTiles_transformTile(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOutTRTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FadeOutTRTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FadeOutTRTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FadeOutTRTiles_transformTile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Vec2 arg0; double arg1; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.FadeOutTRTiles:transformTile"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.FadeOutTRTiles:transformTile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutTRTiles_transformTile'", nullptr); return 0; } cobj->transformTile(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutTRTiles:transformTile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutTRTiles_transformTile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOutTRTiles_testFunc(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOutTRTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.FadeOutTRTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FadeOutTRTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FadeOutTRTiles_testFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Size arg0; double arg1; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.FadeOutTRTiles:testFunc"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.FadeOutTRTiles:testFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutTRTiles_testFunc'", nullptr); return 0; } double ret = cobj->testFunc(arg0, arg1); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutTRTiles:testFunc",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutTRTiles_testFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOutTRTiles_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FadeOutTRTiles",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Size arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FadeOutTRTiles:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.FadeOutTRTiles:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutTRTiles_create'", nullptr); return 0; } cocos2d::FadeOutTRTiles* ret = cocos2d::FadeOutTRTiles::create(arg0, arg1); object_to_luaval<cocos2d::FadeOutTRTiles>(tolua_S, "cc.FadeOutTRTiles",(cocos2d::FadeOutTRTiles*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FadeOutTRTiles:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutTRTiles_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOutTRTiles_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOutTRTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutTRTiles_constructor'", nullptr); return 0; } cobj = new cocos2d::FadeOutTRTiles(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FadeOutTRTiles"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutTRTiles:FadeOutTRTiles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutTRTiles_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FadeOutTRTiles_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FadeOutTRTiles)"); return 0; } int lua_register_cocos2dx_FadeOutTRTiles(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FadeOutTRTiles"); tolua_cclass(tolua_S,"FadeOutTRTiles","cc.FadeOutTRTiles","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"FadeOutTRTiles"); tolua_function(tolua_S,"new",lua_cocos2dx_FadeOutTRTiles_constructor); tolua_function(tolua_S,"turnOnTile",lua_cocos2dx_FadeOutTRTiles_turnOnTile); tolua_function(tolua_S,"turnOffTile",lua_cocos2dx_FadeOutTRTiles_turnOffTile); tolua_function(tolua_S,"transformTile",lua_cocos2dx_FadeOutTRTiles_transformTile); tolua_function(tolua_S,"testFunc",lua_cocos2dx_FadeOutTRTiles_testFunc); tolua_function(tolua_S,"create", lua_cocos2dx_FadeOutTRTiles_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FadeOutTRTiles).name(); g_luaType[typeName] = "cc.FadeOutTRTiles"; g_typeCast["FadeOutTRTiles"] = "cc.FadeOutTRTiles"; return 1; } int lua_cocos2dx_FadeOutBLTiles_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FadeOutBLTiles",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Size arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FadeOutBLTiles:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.FadeOutBLTiles:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutBLTiles_create'", nullptr); return 0; } cocos2d::FadeOutBLTiles* ret = cocos2d::FadeOutBLTiles::create(arg0, arg1); object_to_luaval<cocos2d::FadeOutBLTiles>(tolua_S, "cc.FadeOutBLTiles",(cocos2d::FadeOutBLTiles*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FadeOutBLTiles:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutBLTiles_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOutBLTiles_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOutBLTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutBLTiles_constructor'", nullptr); return 0; } cobj = new cocos2d::FadeOutBLTiles(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FadeOutBLTiles"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutBLTiles:FadeOutBLTiles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutBLTiles_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FadeOutBLTiles_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FadeOutBLTiles)"); return 0; } int lua_register_cocos2dx_FadeOutBLTiles(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FadeOutBLTiles"); tolua_cclass(tolua_S,"FadeOutBLTiles","cc.FadeOutBLTiles","cc.FadeOutTRTiles",nullptr); tolua_beginmodule(tolua_S,"FadeOutBLTiles"); tolua_function(tolua_S,"new",lua_cocos2dx_FadeOutBLTiles_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_FadeOutBLTiles_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FadeOutBLTiles).name(); g_luaType[typeName] = "cc.FadeOutBLTiles"; g_typeCast["FadeOutBLTiles"] = "cc.FadeOutBLTiles"; return 1; } int lua_cocos2dx_FadeOutUpTiles_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FadeOutUpTiles",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Size arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FadeOutUpTiles:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.FadeOutUpTiles:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutUpTiles_create'", nullptr); return 0; } cocos2d::FadeOutUpTiles* ret = cocos2d::FadeOutUpTiles::create(arg0, arg1); object_to_luaval<cocos2d::FadeOutUpTiles>(tolua_S, "cc.FadeOutUpTiles",(cocos2d::FadeOutUpTiles*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FadeOutUpTiles:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutUpTiles_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOutUpTiles_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOutUpTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutUpTiles_constructor'", nullptr); return 0; } cobj = new cocos2d::FadeOutUpTiles(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FadeOutUpTiles"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutUpTiles:FadeOutUpTiles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutUpTiles_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FadeOutUpTiles_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FadeOutUpTiles)"); return 0; } int lua_register_cocos2dx_FadeOutUpTiles(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FadeOutUpTiles"); tolua_cclass(tolua_S,"FadeOutUpTiles","cc.FadeOutUpTiles","cc.FadeOutTRTiles",nullptr); tolua_beginmodule(tolua_S,"FadeOutUpTiles"); tolua_function(tolua_S,"new",lua_cocos2dx_FadeOutUpTiles_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_FadeOutUpTiles_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FadeOutUpTiles).name(); g_luaType[typeName] = "cc.FadeOutUpTiles"; g_typeCast["FadeOutUpTiles"] = "cc.FadeOutUpTiles"; return 1; } int lua_cocos2dx_FadeOutDownTiles_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.FadeOutDownTiles",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Size arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.FadeOutDownTiles:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.FadeOutDownTiles:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutDownTiles_create'", nullptr); return 0; } cocos2d::FadeOutDownTiles* ret = cocos2d::FadeOutDownTiles::create(arg0, arg1); object_to_luaval<cocos2d::FadeOutDownTiles>(tolua_S, "cc.FadeOutDownTiles",(cocos2d::FadeOutDownTiles*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.FadeOutDownTiles:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutDownTiles_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_FadeOutDownTiles_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::FadeOutDownTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_FadeOutDownTiles_constructor'", nullptr); return 0; } cobj = new cocos2d::FadeOutDownTiles(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FadeOutDownTiles"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FadeOutDownTiles:FadeOutDownTiles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FadeOutDownTiles_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_FadeOutDownTiles_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (FadeOutDownTiles)"); return 0; } int lua_register_cocos2dx_FadeOutDownTiles(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.FadeOutDownTiles"); tolua_cclass(tolua_S,"FadeOutDownTiles","cc.FadeOutDownTiles","cc.FadeOutUpTiles",nullptr); tolua_beginmodule(tolua_S,"FadeOutDownTiles"); tolua_function(tolua_S,"new",lua_cocos2dx_FadeOutDownTiles_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_FadeOutDownTiles_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FadeOutDownTiles).name(); g_luaType[typeName] = "cc.FadeOutDownTiles"; g_typeCast["FadeOutDownTiles"] = "cc.FadeOutDownTiles"; return 1; } int lua_cocos2dx_TurnOffTiles_turnOnTile(lua_State* tolua_S) { int argc = 0; cocos2d::TurnOffTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TurnOffTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TurnOffTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TurnOffTiles_turnOnTile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.TurnOffTiles:turnOnTile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TurnOffTiles_turnOnTile'", nullptr); return 0; } cobj->turnOnTile(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TurnOffTiles:turnOnTile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TurnOffTiles_turnOnTile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TurnOffTiles_turnOffTile(lua_State* tolua_S) { int argc = 0; cocos2d::TurnOffTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TurnOffTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TurnOffTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TurnOffTiles_turnOffTile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.TurnOffTiles:turnOffTile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TurnOffTiles_turnOffTile'", nullptr); return 0; } cobj->turnOffTile(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TurnOffTiles:turnOffTile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TurnOffTiles_turnOffTile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TurnOffTiles_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::TurnOffTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TurnOffTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TurnOffTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TurnOffTiles_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; cocos2d::Size arg1; unsigned int arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TurnOffTiles:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.TurnOffTiles:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.TurnOffTiles:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TurnOffTiles_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TurnOffTiles:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TurnOffTiles_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TurnOffTiles_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TurnOffTiles",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TurnOffTiles:create"); if (!ok) { break; } cocos2d::Size arg1; ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.TurnOffTiles:create"); if (!ok) { break; } unsigned int arg2; ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.TurnOffTiles:create"); if (!ok) { break; } cocos2d::TurnOffTiles* ret = cocos2d::TurnOffTiles::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TurnOffTiles>(tolua_S, "cc.TurnOffTiles",(cocos2d::TurnOffTiles*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TurnOffTiles:create"); if (!ok) { break; } cocos2d::Size arg1; ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.TurnOffTiles:create"); if (!ok) { break; } cocos2d::TurnOffTiles* ret = cocos2d::TurnOffTiles::create(arg0, arg1); object_to_luaval<cocos2d::TurnOffTiles>(tolua_S, "cc.TurnOffTiles",(cocos2d::TurnOffTiles*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TurnOffTiles:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TurnOffTiles_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TurnOffTiles_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TurnOffTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TurnOffTiles_constructor'", nullptr); return 0; } cobj = new cocos2d::TurnOffTiles(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TurnOffTiles"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TurnOffTiles:TurnOffTiles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TurnOffTiles_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TurnOffTiles_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TurnOffTiles)"); return 0; } int lua_register_cocos2dx_TurnOffTiles(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TurnOffTiles"); tolua_cclass(tolua_S,"TurnOffTiles","cc.TurnOffTiles","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"TurnOffTiles"); tolua_function(tolua_S,"new",lua_cocos2dx_TurnOffTiles_constructor); tolua_function(tolua_S,"turnOnTile",lua_cocos2dx_TurnOffTiles_turnOnTile); tolua_function(tolua_S,"turnOffTile",lua_cocos2dx_TurnOffTiles_turnOffTile); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TurnOffTiles_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_TurnOffTiles_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TurnOffTiles).name(); g_luaType[typeName] = "cc.TurnOffTiles"; g_typeCast["TurnOffTiles"] = "cc.TurnOffTiles"; return 1; } int lua_cocos2dx_WavesTiles3D_setAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::WavesTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.WavesTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::WavesTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_WavesTiles3D_setAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.WavesTiles3D:setAmplitudeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_WavesTiles3D_setAmplitudeRate'", nullptr); return 0; } cobj->setAmplitudeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.WavesTiles3D:setAmplitudeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_WavesTiles3D_setAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_WavesTiles3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::WavesTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.WavesTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::WavesTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_WavesTiles3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.WavesTiles3D:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.WavesTiles3D:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.WavesTiles3D:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.WavesTiles3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_WavesTiles3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.WavesTiles3D:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_WavesTiles3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_WavesTiles3D_getAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::WavesTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.WavesTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::WavesTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_WavesTiles3D_getAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_WavesTiles3D_getAmplitude'", nullptr); return 0; } double ret = cobj->getAmplitude(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.WavesTiles3D:getAmplitude",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_WavesTiles3D_getAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_WavesTiles3D_getAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::WavesTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.WavesTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::WavesTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_WavesTiles3D_getAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_WavesTiles3D_getAmplitudeRate'", nullptr); return 0; } double ret = cobj->getAmplitudeRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.WavesTiles3D:getAmplitudeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_WavesTiles3D_getAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_WavesTiles3D_setAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::WavesTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.WavesTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::WavesTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_WavesTiles3D_setAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.WavesTiles3D:setAmplitude"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_WavesTiles3D_setAmplitude'", nullptr); return 0; } cobj->setAmplitude(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.WavesTiles3D:setAmplitude",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_WavesTiles3D_setAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_WavesTiles3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.WavesTiles3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.WavesTiles3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.WavesTiles3D:create"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.WavesTiles3D:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.WavesTiles3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_WavesTiles3D_create'", nullptr); return 0; } cocos2d::WavesTiles3D* ret = cocos2d::WavesTiles3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::WavesTiles3D>(tolua_S, "cc.WavesTiles3D",(cocos2d::WavesTiles3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.WavesTiles3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_WavesTiles3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_WavesTiles3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::WavesTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_WavesTiles3D_constructor'", nullptr); return 0; } cobj = new cocos2d::WavesTiles3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.WavesTiles3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.WavesTiles3D:WavesTiles3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_WavesTiles3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_WavesTiles3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (WavesTiles3D)"); return 0; } int lua_register_cocos2dx_WavesTiles3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.WavesTiles3D"); tolua_cclass(tolua_S,"WavesTiles3D","cc.WavesTiles3D","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"WavesTiles3D"); tolua_function(tolua_S,"new",lua_cocos2dx_WavesTiles3D_constructor); tolua_function(tolua_S,"setAmplitudeRate",lua_cocos2dx_WavesTiles3D_setAmplitudeRate); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_WavesTiles3D_initWithDuration); tolua_function(tolua_S,"getAmplitude",lua_cocos2dx_WavesTiles3D_getAmplitude); tolua_function(tolua_S,"getAmplitudeRate",lua_cocos2dx_WavesTiles3D_getAmplitudeRate); tolua_function(tolua_S,"setAmplitude",lua_cocos2dx_WavesTiles3D_setAmplitude); tolua_function(tolua_S,"create", lua_cocos2dx_WavesTiles3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::WavesTiles3D).name(); g_luaType[typeName] = "cc.WavesTiles3D"; g_typeCast["WavesTiles3D"] = "cc.WavesTiles3D"; return 1; } int lua_cocos2dx_JumpTiles3D_setAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::JumpTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.JumpTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::JumpTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_JumpTiles3D_setAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.JumpTiles3D:setAmplitudeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTiles3D_setAmplitudeRate'", nullptr); return 0; } cobj->setAmplitudeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpTiles3D:setAmplitudeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTiles3D_setAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpTiles3D_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::JumpTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.JumpTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::JumpTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_JumpTiles3D_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.JumpTiles3D:initWithDuration"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.JumpTiles3D:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.JumpTiles3D:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.JumpTiles3D:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTiles3D_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpTiles3D:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTiles3D_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpTiles3D_getAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::JumpTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.JumpTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::JumpTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_JumpTiles3D_getAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTiles3D_getAmplitude'", nullptr); return 0; } double ret = cobj->getAmplitude(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpTiles3D:getAmplitude",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTiles3D_getAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpTiles3D_getAmplitudeRate(lua_State* tolua_S) { int argc = 0; cocos2d::JumpTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.JumpTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::JumpTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_JumpTiles3D_getAmplitudeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTiles3D_getAmplitudeRate'", nullptr); return 0; } double ret = cobj->getAmplitudeRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpTiles3D:getAmplitudeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTiles3D_getAmplitudeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpTiles3D_setAmplitude(lua_State* tolua_S) { int argc = 0; cocos2d::JumpTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.JumpTiles3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::JumpTiles3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_JumpTiles3D_setAmplitude'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.JumpTiles3D:setAmplitude"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTiles3D_setAmplitude'", nullptr); return 0; } cobj->setAmplitude(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpTiles3D:setAmplitude",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTiles3D_setAmplitude'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpTiles3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.JumpTiles3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; cocos2d::Size arg1; unsigned int arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.JumpTiles3D:create"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.JumpTiles3D:create"); ok &= luaval_to_uint32(tolua_S, 4,&arg2, "cc.JumpTiles3D:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.JumpTiles3D:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTiles3D_create'", nullptr); return 0; } cocos2d::JumpTiles3D* ret = cocos2d::JumpTiles3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::JumpTiles3D>(tolua_S, "cc.JumpTiles3D",(cocos2d::JumpTiles3D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.JumpTiles3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTiles3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_JumpTiles3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::JumpTiles3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_JumpTiles3D_constructor'", nullptr); return 0; } cobj = new cocos2d::JumpTiles3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.JumpTiles3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.JumpTiles3D:JumpTiles3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_JumpTiles3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_JumpTiles3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (JumpTiles3D)"); return 0; } int lua_register_cocos2dx_JumpTiles3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.JumpTiles3D"); tolua_cclass(tolua_S,"JumpTiles3D","cc.JumpTiles3D","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"JumpTiles3D"); tolua_function(tolua_S,"new",lua_cocos2dx_JumpTiles3D_constructor); tolua_function(tolua_S,"setAmplitudeRate",lua_cocos2dx_JumpTiles3D_setAmplitudeRate); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_JumpTiles3D_initWithDuration); tolua_function(tolua_S,"getAmplitude",lua_cocos2dx_JumpTiles3D_getAmplitude); tolua_function(tolua_S,"getAmplitudeRate",lua_cocos2dx_JumpTiles3D_getAmplitudeRate); tolua_function(tolua_S,"setAmplitude",lua_cocos2dx_JumpTiles3D_setAmplitude); tolua_function(tolua_S,"create", lua_cocos2dx_JumpTiles3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::JumpTiles3D).name(); g_luaType[typeName] = "cc.JumpTiles3D"; g_typeCast["JumpTiles3D"] = "cc.JumpTiles3D"; return 1; } int lua_cocos2dx_SplitRows_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::SplitRows* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SplitRows",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SplitRows*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SplitRows_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; unsigned int arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SplitRows:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.SplitRows:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SplitRows_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SplitRows:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SplitRows_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SplitRows_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SplitRows",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; unsigned int arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SplitRows:create"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.SplitRows:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SplitRows_create'", nullptr); return 0; } cocos2d::SplitRows* ret = cocos2d::SplitRows::create(arg0, arg1); object_to_luaval<cocos2d::SplitRows>(tolua_S, "cc.SplitRows",(cocos2d::SplitRows*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SplitRows:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SplitRows_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SplitRows_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::SplitRows* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SplitRows_constructor'", nullptr); return 0; } cobj = new cocos2d::SplitRows(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.SplitRows"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SplitRows:SplitRows",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SplitRows_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_SplitRows_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SplitRows)"); return 0; } int lua_register_cocos2dx_SplitRows(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.SplitRows"); tolua_cclass(tolua_S,"SplitRows","cc.SplitRows","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"SplitRows"); tolua_function(tolua_S,"new",lua_cocos2dx_SplitRows_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_SplitRows_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_SplitRows_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::SplitRows).name(); g_luaType[typeName] = "cc.SplitRows"; g_typeCast["SplitRows"] = "cc.SplitRows"; return 1; } int lua_cocos2dx_SplitCols_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::SplitCols* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SplitCols",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SplitCols*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SplitCols_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; unsigned int arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SplitCols:initWithDuration"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.SplitCols:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SplitCols_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SplitCols:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SplitCols_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SplitCols_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SplitCols",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; unsigned int arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SplitCols:create"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.SplitCols:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SplitCols_create'", nullptr); return 0; } cocos2d::SplitCols* ret = cocos2d::SplitCols::create(arg0, arg1); object_to_luaval<cocos2d::SplitCols>(tolua_S, "cc.SplitCols",(cocos2d::SplitCols*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SplitCols:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SplitCols_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SplitCols_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::SplitCols* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SplitCols_constructor'", nullptr); return 0; } cobj = new cocos2d::SplitCols(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.SplitCols"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SplitCols:SplitCols",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SplitCols_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_SplitCols_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SplitCols)"); return 0; } int lua_register_cocos2dx_SplitCols(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.SplitCols"); tolua_cclass(tolua_S,"SplitCols","cc.SplitCols","cc.TiledGrid3DAction",nullptr); tolua_beginmodule(tolua_S,"SplitCols"); tolua_function(tolua_S,"new",lua_cocos2dx_SplitCols_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_SplitCols_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_SplitCols_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::SplitCols).name(); g_luaType[typeName] = "cc.SplitCols"; g_typeCast["SplitCols"] = "cc.SplitCols"; return 1; } int lua_cocos2dx_ActionTween_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ActionTween* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ActionTween",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ActionTween*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ActionTween_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; std::string arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ActionTween:initWithDuration"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.ActionTween:initWithDuration"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ActionTween:initWithDuration"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.ActionTween:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionTween_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ActionTween:initWithDuration",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionTween_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ActionTween_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ActionTween",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; std::string arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ActionTween:create"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.ActionTween:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.ActionTween:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.ActionTween:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ActionTween_create'", nullptr); return 0; } cocos2d::ActionTween* ret = cocos2d::ActionTween::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::ActionTween>(tolua_S, "cc.ActionTween",(cocos2d::ActionTween*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ActionTween:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ActionTween_create'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ActionTween_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ActionTween)"); return 0; } int lua_register_cocos2dx_ActionTween(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ActionTween"); tolua_cclass(tolua_S,"ActionTween","cc.ActionTween","cc.ActionInterval",nullptr); tolua_beginmodule(tolua_S,"ActionTween"); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_ActionTween_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_ActionTween_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ActionTween).name(); g_luaType[typeName] = "cc.ActionTween"; g_typeCast["ActionTween"] = "cc.ActionTween"; return 1; } int lua_cocos2dx_AtlasNode_updateAtlasValues(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_updateAtlasValues'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_updateAtlasValues'", nullptr); return 0; } cobj->updateAtlasValues(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:updateAtlasValues",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_updateAtlasValues'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_initWithTileFile(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_initWithTileFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { std::string arg0; int arg1; int arg2; int arg3; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.AtlasNode:initWithTileFile"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.AtlasNode:initWithTileFile"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.AtlasNode:initWithTileFile"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.AtlasNode:initWithTileFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_initWithTileFile'", nullptr); return 0; } bool ret = cobj->initWithTileFile(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:initWithTileFile",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_initWithTileFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_setTextureAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_setTextureAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TextureAtlas* arg0 = nullptr; ok &= luaval_to_object<cocos2d::TextureAtlas>(tolua_S, 2, "cc.TextureAtlas",&arg0, "cc.AtlasNode:setTextureAtlas"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_setTextureAtlas'", nullptr); return 0; } cobj->setTextureAtlas(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:setTextureAtlas",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_setTextureAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.AtlasNode:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_getTextureAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_getTextureAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_getTextureAtlas'", nullptr); return 0; } cocos2d::TextureAtlas* ret = cobj->getTextureAtlas(); object_to_luaval<cocos2d::TextureAtlas>(tolua_S, "cc.TextureAtlas",(cocos2d::TextureAtlas*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:getTextureAtlas",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_getTextureAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_getQuadsToDraw(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_getQuadsToDraw'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_getQuadsToDraw'", nullptr); return 0; } ssize_t ret = cobj->getQuadsToDraw(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:getQuadsToDraw",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_getQuadsToDraw'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.AtlasNode:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_initWithTexture(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_initWithTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { cocos2d::Texture2D* arg0 = nullptr; int arg1; int arg2; int arg3; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.AtlasNode:initWithTexture"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.AtlasNode:initWithTexture"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.AtlasNode:initWithTexture"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.AtlasNode:initWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_initWithTexture'", nullptr); return 0; } bool ret = cobj->initWithTexture(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:initWithTexture",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_initWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_setQuadsToDraw(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AtlasNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AtlasNode_setQuadsToDraw'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { ssize_t arg0; ok &= luaval_to_ssize(tolua_S, 2, &arg0, "cc.AtlasNode:setQuadsToDraw"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_setQuadsToDraw'", nullptr); return 0; } cobj->setQuadsToDraw(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:setQuadsToDraw",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_setQuadsToDraw'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.AtlasNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { std::string arg0; int arg1; int arg2; int arg3; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.AtlasNode:create"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.AtlasNode:create"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.AtlasNode:create"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.AtlasNode:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_create'", nullptr); return 0; } cocos2d::AtlasNode* ret = cocos2d::AtlasNode::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::AtlasNode>(tolua_S, "cc.AtlasNode",(cocos2d::AtlasNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.AtlasNode:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AtlasNode_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::AtlasNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AtlasNode_constructor'", nullptr); return 0; } cobj = new cocos2d::AtlasNode(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.AtlasNode"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AtlasNode:AtlasNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AtlasNode_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_AtlasNode_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (AtlasNode)"); return 0; } int lua_register_cocos2dx_AtlasNode(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.AtlasNode"); tolua_cclass(tolua_S,"AtlasNode","cc.AtlasNode","cc.Node",nullptr); tolua_beginmodule(tolua_S,"AtlasNode"); tolua_function(tolua_S,"new",lua_cocos2dx_AtlasNode_constructor); tolua_function(tolua_S,"updateAtlasValues",lua_cocos2dx_AtlasNode_updateAtlasValues); tolua_function(tolua_S,"initWithTileFile",lua_cocos2dx_AtlasNode_initWithTileFile); tolua_function(tolua_S,"getTexture",lua_cocos2dx_AtlasNode_getTexture); tolua_function(tolua_S,"setTextureAtlas",lua_cocos2dx_AtlasNode_setTextureAtlas); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_AtlasNode_setBlendFunc); tolua_function(tolua_S,"getTextureAtlas",lua_cocos2dx_AtlasNode_getTextureAtlas); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_AtlasNode_getBlendFunc); tolua_function(tolua_S,"getQuadsToDraw",lua_cocos2dx_AtlasNode_getQuadsToDraw); tolua_function(tolua_S,"setTexture",lua_cocos2dx_AtlasNode_setTexture); tolua_function(tolua_S,"initWithTexture",lua_cocos2dx_AtlasNode_initWithTexture); tolua_function(tolua_S,"setQuadsToDraw",lua_cocos2dx_AtlasNode_setQuadsToDraw); tolua_function(tolua_S,"create", lua_cocos2dx_AtlasNode_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::AtlasNode).name(); g_luaType[typeName] = "cc.AtlasNode"; g_typeCast["AtlasNode"] = "cc.AtlasNode"; return 1; } int lua_cocos2dx_ClippingNode_hasContent(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingNode_hasContent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingNode_hasContent'", nullptr); return 0; } bool ret = cobj->hasContent(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingNode:hasContent",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_hasContent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingNode_setInverted(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingNode_setInverted'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ClippingNode:setInverted"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingNode_setInverted'", nullptr); return 0; } cobj->setInverted(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingNode:setInverted",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_setInverted'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingNode_setStencil(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingNode_setStencil'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ClippingNode:setStencil"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingNode_setStencil'", nullptr); return 0; } cobj->setStencil(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingNode:setStencil",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_setStencil'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingNode_getAlphaThreshold(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingNode_getAlphaThreshold'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingNode_getAlphaThreshold'", nullptr); return 0; } double ret = cobj->getAlphaThreshold(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingNode:getAlphaThreshold",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_getAlphaThreshold'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingNode_init(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingNode_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ClippingNode:init"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingNode_init'", nullptr); return 0; } bool ret = cobj->init(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingNode:init",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingNode_getStencil(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingNode_getStencil'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingNode_getStencil'", nullptr); return 0; } cocos2d::Node* ret = cobj->getStencil(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingNode:getStencil",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_getStencil'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingNode_setAlphaThreshold(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingNode_setAlphaThreshold'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ClippingNode:setAlphaThreshold"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingNode_setAlphaThreshold'", nullptr); return 0; } cobj->setAlphaThreshold(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingNode:setAlphaThreshold",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_setAlphaThreshold'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingNode_isInverted(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingNode_isInverted'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingNode_isInverted'", nullptr); return 0; } bool ret = cobj->isInverted(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingNode:isInverted",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_isInverted'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingNode_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ClippingNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ClippingNode:create"); if (!ok) { break; } cocos2d::ClippingNode* ret = cocos2d::ClippingNode::create(arg0); object_to_luaval<cocos2d::ClippingNode>(tolua_S, "cc.ClippingNode",(cocos2d::ClippingNode*)ret); return 1; } } while (0); ok = true; do { if (argc == 0) { cocos2d::ClippingNode* ret = cocos2d::ClippingNode::create(); object_to_luaval<cocos2d::ClippingNode>(tolua_S, "cc.ClippingNode",(cocos2d::ClippingNode*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.ClippingNode:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingNode_create'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ClippingNode_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ClippingNode)"); return 0; } int lua_register_cocos2dx_ClippingNode(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ClippingNode"); tolua_cclass(tolua_S,"ClippingNode","cc.ClippingNode","cc.Node",nullptr); tolua_beginmodule(tolua_S,"ClippingNode"); tolua_function(tolua_S,"hasContent",lua_cocos2dx_ClippingNode_hasContent); tolua_function(tolua_S,"setInverted",lua_cocos2dx_ClippingNode_setInverted); tolua_function(tolua_S,"setStencil",lua_cocos2dx_ClippingNode_setStencil); tolua_function(tolua_S,"getAlphaThreshold",lua_cocos2dx_ClippingNode_getAlphaThreshold); tolua_function(tolua_S,"init",lua_cocos2dx_ClippingNode_init); tolua_function(tolua_S,"getStencil",lua_cocos2dx_ClippingNode_getStencil); tolua_function(tolua_S,"setAlphaThreshold",lua_cocos2dx_ClippingNode_setAlphaThreshold); tolua_function(tolua_S,"isInverted",lua_cocos2dx_ClippingNode_isInverted); tolua_function(tolua_S,"create", lua_cocos2dx_ClippingNode_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ClippingNode).name(); g_luaType[typeName] = "cc.ClippingNode"; g_typeCast["ClippingNode"] = "cc.ClippingNode"; return 1; } int lua_cocos2dx_ClippingRectangleNode_isClippingEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingRectangleNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingRectangleNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingRectangleNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingRectangleNode_isClippingEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingRectangleNode_isClippingEnabled'", nullptr); return 0; } bool ret = cobj->isClippingEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingRectangleNode:isClippingEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingRectangleNode_isClippingEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingRectangleNode_setClippingEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingRectangleNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingRectangleNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingRectangleNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingRectangleNode_setClippingEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ClippingRectangleNode:setClippingEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingRectangleNode_setClippingEnabled'", nullptr); return 0; } cobj->setClippingEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingRectangleNode:setClippingEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingRectangleNode_setClippingEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingRectangleNode_getClippingRegion(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingRectangleNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingRectangleNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingRectangleNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingRectangleNode_getClippingRegion'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingRectangleNode_getClippingRegion'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getClippingRegion(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingRectangleNode:getClippingRegion",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingRectangleNode_getClippingRegion'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingRectangleNode_setClippingRegion(lua_State* tolua_S) { int argc = 0; cocos2d::ClippingRectangleNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ClippingRectangleNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ClippingRectangleNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ClippingRectangleNode_setClippingRegion'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.ClippingRectangleNode:setClippingRegion"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ClippingRectangleNode_setClippingRegion'", nullptr); return 0; } cobj->setClippingRegion(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ClippingRectangleNode:setClippingRegion",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingRectangleNode_setClippingRegion'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ClippingRectangleNode_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ClippingRectangleNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 0) { cocos2d::ClippingRectangleNode* ret = cocos2d::ClippingRectangleNode::create(); object_to_luaval<cocos2d::ClippingRectangleNode>(tolua_S, "cc.ClippingRectangleNode",(cocos2d::ClippingRectangleNode*)ret); return 1; } } while (0); ok = true; do { if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.ClippingRectangleNode:create"); if (!ok) { break; } cocos2d::ClippingRectangleNode* ret = cocos2d::ClippingRectangleNode::create(arg0); object_to_luaval<cocos2d::ClippingRectangleNode>(tolua_S, "cc.ClippingRectangleNode",(cocos2d::ClippingRectangleNode*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.ClippingRectangleNode:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ClippingRectangleNode_create'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ClippingRectangleNode_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ClippingRectangleNode)"); return 0; } int lua_register_cocos2dx_ClippingRectangleNode(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ClippingRectangleNode"); tolua_cclass(tolua_S,"ClippingRectangleNode","cc.ClippingRectangleNode","cc.Node",nullptr); tolua_beginmodule(tolua_S,"ClippingRectangleNode"); tolua_function(tolua_S,"isClippingEnabled",lua_cocos2dx_ClippingRectangleNode_isClippingEnabled); tolua_function(tolua_S,"setClippingEnabled",lua_cocos2dx_ClippingRectangleNode_setClippingEnabled); tolua_function(tolua_S,"getClippingRegion",lua_cocos2dx_ClippingRectangleNode_getClippingRegion); tolua_function(tolua_S,"setClippingRegion",lua_cocos2dx_ClippingRectangleNode_setClippingRegion); tolua_function(tolua_S,"create", lua_cocos2dx_ClippingRectangleNode_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ClippingRectangleNode).name(); g_luaType[typeName] = "cc.ClippingRectangleNode"; g_typeCast["ClippingRectangleNode"] = "cc.ClippingRectangleNode"; return 1; } int lua_cocos2dx_DrawNode_drawLine(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawLine'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Vec2 arg0; cocos2d::Vec2 arg1; cocos2d::Color4F arg2; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawLine"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.DrawNode:drawLine"); ok &=luaval_to_color4f(tolua_S, 4, &arg2, "cc.DrawNode:drawLine"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_drawLine'", nullptr); return 0; } cobj->drawLine(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawLine",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawLine'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawRect(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 5) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawRect"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.DrawNode:drawRect"); if (!ok) { break; } cocos2d::Vec2 arg2; ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.DrawNode:drawRect"); if (!ok) { break; } cocos2d::Vec2 arg3; ok &= luaval_to_vec2(tolua_S, 5, &arg3, "cc.DrawNode:drawRect"); if (!ok) { break; } cocos2d::Color4F arg4; ok &=luaval_to_color4f(tolua_S, 6, &arg4, "cc.DrawNode:drawRect"); if (!ok) { break; } cobj->drawRect(arg0, arg1, arg2, arg3, arg4); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawRect"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.DrawNode:drawRect"); if (!ok) { break; } cocos2d::Color4F arg2; ok &=luaval_to_color4f(tolua_S, 4, &arg2, "cc.DrawNode:drawRect"); if (!ok) { break; } cobj->drawRect(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawRect",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawSolidCircle(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawSolidCircle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 5) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } unsigned int arg3; ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } cocos2d::Color4F arg4; ok &=luaval_to_color4f(tolua_S, 6, &arg4, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } cobj->drawSolidCircle(arg0, arg1, arg2, arg3, arg4); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 7) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } unsigned int arg3; ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } double arg4; ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } double arg5; ok &= luaval_to_number(tolua_S, 7,&arg5, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } cocos2d::Color4F arg6; ok &=luaval_to_color4f(tolua_S, 8, &arg6, "cc.DrawNode:drawSolidCircle"); if (!ok) { break; } cobj->drawSolidCircle(arg0, arg1, arg2, arg3, arg4, arg5, arg6); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawSolidCircle",argc, 7); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawSolidCircle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_setLineWidth(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_setLineWidth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.DrawNode:setLineWidth"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_setLineWidth'", nullptr); return 0; } cobj->setLineWidth(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:setLineWidth",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_setLineWidth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_onDrawGLPoint(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_onDrawGLPoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Mat4 arg0; unsigned int arg1; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.DrawNode:onDrawGLPoint"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.DrawNode:onDrawGLPoint"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_onDrawGLPoint'", nullptr); return 0; } cobj->onDrawGLPoint(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:onDrawGLPoint",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_onDrawGLPoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawDot(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawDot'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Vec2 arg0; double arg1; cocos2d::Color4F arg2; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawDot"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.DrawNode:drawDot"); ok &=luaval_to_color4f(tolua_S, 4, &arg2, "cc.DrawNode:drawDot"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_drawDot'", nullptr); return 0; } cobj->drawDot(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawDot",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawDot'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawSegment(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawSegment'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { cocos2d::Vec2 arg0; cocos2d::Vec2 arg1; double arg2; cocos2d::Color4F arg3; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawSegment"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.DrawNode:drawSegment"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.DrawNode:drawSegment"); ok &=luaval_to_color4f(tolua_S, 5, &arg3, "cc.DrawNode:drawSegment"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_drawSegment'", nullptr); return 0; } cobj->drawSegment(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawSegment",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawSegment'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_onDraw(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_onDraw'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Mat4 arg0; unsigned int arg1; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.DrawNode:onDraw"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.DrawNode:onDraw"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_onDraw'", nullptr); return 0; } cobj->onDraw(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:onDraw",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_onDraw'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawCircle(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawCircle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 6) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawCircle"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.DrawNode:drawCircle"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.DrawNode:drawCircle"); if (!ok) { break; } unsigned int arg3; ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.DrawNode:drawCircle"); if (!ok) { break; } bool arg4; ok &= luaval_to_boolean(tolua_S, 6,&arg4, "cc.DrawNode:drawCircle"); if (!ok) { break; } cocos2d::Color4F arg5; ok &=luaval_to_color4f(tolua_S, 7, &arg5, "cc.DrawNode:drawCircle"); if (!ok) { break; } cobj->drawCircle(arg0, arg1, arg2, arg3, arg4, arg5); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 8) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawCircle"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.DrawNode:drawCircle"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.DrawNode:drawCircle"); if (!ok) { break; } unsigned int arg3; ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.DrawNode:drawCircle"); if (!ok) { break; } bool arg4; ok &= luaval_to_boolean(tolua_S, 6,&arg4, "cc.DrawNode:drawCircle"); if (!ok) { break; } double arg5; ok &= luaval_to_number(tolua_S, 7,&arg5, "cc.DrawNode:drawCircle"); if (!ok) { break; } double arg6; ok &= luaval_to_number(tolua_S, 8,&arg6, "cc.DrawNode:drawCircle"); if (!ok) { break; } cocos2d::Color4F arg7; ok &=luaval_to_color4f(tolua_S, 9, &arg7, "cc.DrawNode:drawCircle"); if (!ok) { break; } cobj->drawCircle(arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawCircle",argc, 8); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawCircle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawQuadBezier(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawQuadBezier'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 5) { cocos2d::Vec2 arg0; cocos2d::Vec2 arg1; cocos2d::Vec2 arg2; unsigned int arg3; cocos2d::Color4F arg4; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawQuadBezier"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.DrawNode:drawQuadBezier"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.DrawNode:drawQuadBezier"); ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.DrawNode:drawQuadBezier"); ok &=luaval_to_color4f(tolua_S, 6, &arg4, "cc.DrawNode:drawQuadBezier"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_drawQuadBezier'", nullptr); return 0; } cobj->drawQuadBezier(arg0, arg1, arg2, arg3, arg4); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawQuadBezier",argc, 5); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawQuadBezier'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_onDrawGLLine(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_onDrawGLLine'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Mat4 arg0; unsigned int arg1; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.DrawNode:onDrawGLLine"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.DrawNode:onDrawGLLine"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_onDrawGLLine'", nullptr); return 0; } cobj->onDrawGLLine(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:onDrawGLLine",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_onDrawGLLine'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawTriangle(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawTriangle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { cocos2d::Vec2 arg0; cocos2d::Vec2 arg1; cocos2d::Vec2 arg2; cocos2d::Color4F arg3; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawTriangle"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.DrawNode:drawTriangle"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.DrawNode:drawTriangle"); ok &=luaval_to_color4f(tolua_S, 5, &arg3, "cc.DrawNode:drawTriangle"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_drawTriangle'", nullptr); return 0; } cobj->drawTriangle(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawTriangle",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawTriangle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.DrawNode:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_clear(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_clear'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_clear'", nullptr); return 0; } cobj->clear(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:clear",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_clear'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawSolidRect(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawSolidRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Vec2 arg0; cocos2d::Vec2 arg1; cocos2d::Color4F arg2; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawSolidRect"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.DrawNode:drawSolidRect"); ok &=luaval_to_color4f(tolua_S, 4, &arg2, "cc.DrawNode:drawSolidRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_drawSolidRect'", nullptr); return 0; } cobj->drawSolidRect(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawSolidRect",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawSolidRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_getLineWidth(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_getLineWidth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_getLineWidth'", nullptr); return 0; } double ret = cobj->getLineWidth(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:getLineWidth",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_getLineWidth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawPoint(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawPoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Vec2 arg0; double arg1; cocos2d::Color4F arg2; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawPoint"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.DrawNode:drawPoint"); ok &=luaval_to_color4f(tolua_S, 4, &arg2, "cc.DrawNode:drawPoint"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_drawPoint'", nullptr); return 0; } cobj->drawPoint(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawPoint",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawPoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_drawCubicBezier(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DrawNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DrawNode_drawCubicBezier'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 6) { cocos2d::Vec2 arg0; cocos2d::Vec2 arg1; cocos2d::Vec2 arg2; cocos2d::Vec2 arg3; unsigned int arg4; cocos2d::Color4F arg5; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.DrawNode:drawCubicBezier"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.DrawNode:drawCubicBezier"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.DrawNode:drawCubicBezier"); ok &= luaval_to_vec2(tolua_S, 5, &arg3, "cc.DrawNode:drawCubicBezier"); ok &= luaval_to_uint32(tolua_S, 6,&arg4, "cc.DrawNode:drawCubicBezier"); ok &=luaval_to_color4f(tolua_S, 7, &arg5, "cc.DrawNode:drawCubicBezier"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_drawCubicBezier'", nullptr); return 0; } cobj->drawCubicBezier(arg0, arg1, arg2, arg3, arg4, arg5); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:drawCubicBezier",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_drawCubicBezier'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.DrawNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_create'", nullptr); return 0; } cocos2d::DrawNode* ret = cocos2d::DrawNode::create(); object_to_luaval<cocos2d::DrawNode>(tolua_S, "cc.DrawNode",(cocos2d::DrawNode*)ret); return 1; } if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.DrawNode:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_create'", nullptr); return 0; } cocos2d::DrawNode* ret = cocos2d::DrawNode::create(arg0); object_to_luaval<cocos2d::DrawNode>(tolua_S, "cc.DrawNode",(cocos2d::DrawNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.DrawNode:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DrawNode_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::DrawNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_constructor'", nullptr); return 0; } cobj = new cocos2d::DrawNode(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.DrawNode"); return 1; } if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.DrawNode:DrawNode"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DrawNode_constructor'", nullptr); return 0; } cobj = new cocos2d::DrawNode(arg0); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.DrawNode"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DrawNode:DrawNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DrawNode_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_DrawNode_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (DrawNode)"); return 0; } int lua_register_cocos2dx_DrawNode(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.DrawNode"); tolua_cclass(tolua_S,"DrawNode","cc.DrawNode","cc.Node",nullptr); tolua_beginmodule(tolua_S,"DrawNode"); tolua_function(tolua_S,"new",lua_cocos2dx_DrawNode_constructor); tolua_function(tolua_S,"drawLine",lua_cocos2dx_DrawNode_drawLine); tolua_function(tolua_S,"drawRect",lua_cocos2dx_DrawNode_drawRect); tolua_function(tolua_S,"drawSolidCircle",lua_cocos2dx_DrawNode_drawSolidCircle); tolua_function(tolua_S,"setLineWidth",lua_cocos2dx_DrawNode_setLineWidth); tolua_function(tolua_S,"onDrawGLPoint",lua_cocos2dx_DrawNode_onDrawGLPoint); tolua_function(tolua_S,"drawDot",lua_cocos2dx_DrawNode_drawDot); tolua_function(tolua_S,"drawSegment",lua_cocos2dx_DrawNode_drawSegment); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_DrawNode_getBlendFunc); tolua_function(tolua_S,"onDraw",lua_cocos2dx_DrawNode_onDraw); tolua_function(tolua_S,"drawCircle",lua_cocos2dx_DrawNode_drawCircle); tolua_function(tolua_S,"drawQuadBezier",lua_cocos2dx_DrawNode_drawQuadBezier); tolua_function(tolua_S,"onDrawGLLine",lua_cocos2dx_DrawNode_onDrawGLLine); tolua_function(tolua_S,"drawTriangle",lua_cocos2dx_DrawNode_drawTriangle); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_DrawNode_setBlendFunc); tolua_function(tolua_S,"clear",lua_cocos2dx_DrawNode_clear); tolua_function(tolua_S,"drawSolidRect",lua_cocos2dx_DrawNode_drawSolidRect); tolua_function(tolua_S,"getLineWidth",lua_cocos2dx_DrawNode_getLineWidth); tolua_function(tolua_S,"drawPoint",lua_cocos2dx_DrawNode_drawPoint); tolua_function(tolua_S,"drawCubicBezier",lua_cocos2dx_DrawNode_drawCubicBezier); tolua_function(tolua_S,"create", lua_cocos2dx_DrawNode_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::DrawNode).name(); g_luaType[typeName] = "cc.DrawNode"; g_typeCast["DrawNode"] = "cc.DrawNode"; return 1; } int lua_cocos2dx_Label_isClipMarginEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_isClipMarginEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_isClipMarginEnabled'", nullptr); return 0; } bool ret = cobj->isClipMarginEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:isClipMarginEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_isClipMarginEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_enableShadow(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_enableShadow'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableShadow'", nullptr); return 0; } cobj->enableShadow(); lua_settop(tolua_S, 1); return 1; } if (argc == 1) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.Label:enableShadow"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableShadow'", nullptr); return 0; } cobj->enableShadow(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { cocos2d::Color4B arg0; cocos2d::Size arg1; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.Label:enableShadow"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Label:enableShadow"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableShadow'", nullptr); return 0; } cobj->enableShadow(arg0, arg1); lua_settop(tolua_S, 1); return 1; } if (argc == 3) { cocos2d::Color4B arg0; cocos2d::Size arg1; int arg2; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.Label:enableShadow"); ok &= luaval_to_size(tolua_S, 3, &arg1, "cc.Label:enableShadow"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:enableShadow"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableShadow'", nullptr); return 0; } cobj->enableShadow(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:enableShadow",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_enableShadow'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setDimensions(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setDimensions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; double arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setDimensions"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Label:setDimensions"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setDimensions'", nullptr); return 0; } cobj->setDimensions(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setDimensions",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setDimensions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getWidth(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getWidth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getWidth'", nullptr); return 0; } double ret = cobj->getWidth(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getWidth",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getWidth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getString(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getString'", nullptr); return 0; } const std::string& ret = cobj->getString(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getString",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getHeight(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getHeight'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getHeight'", nullptr); return 0; } double ret = cobj->getHeight(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getHeight",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getHeight'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_disableEffect(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_disableEffect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { cocos2d::LabelEffect arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Label:disableEffect"); if (!ok) { break; } cobj->disableEffect(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 0) { cobj->disableEffect(); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:disableEffect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_disableEffect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setTTFConfig(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setTTFConfig'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::_ttfConfig arg0; ok &= luaval_to_ttfconfig(tolua_S, 2, &arg0, "cc.Label:setTTFConfig"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setTTFConfig'", nullptr); return 0; } bool ret = cobj->setTTFConfig(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setTTFConfig",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setTTFConfig'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getTextColor(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getTextColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getTextColor'", nullptr); return 0; } const cocos2d::Color4B& ret = cobj->getTextColor(); color4b_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getTextColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getTextColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_enableWrap(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_enableWrap'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Label:enableWrap"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableWrap'", nullptr); return 0; } cobj->enableWrap(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:enableWrap",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_enableWrap'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setWidth(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setWidth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setWidth"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setWidth'", nullptr); return 0; } cobj->setWidth(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setWidth",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setWidth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getAdditionalKerning(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getAdditionalKerning'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getAdditionalKerning'", nullptr); return 0; } double ret = cobj->getAdditionalKerning(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getAdditionalKerning",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getAdditionalKerning'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getBMFontSize(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getBMFontSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getBMFontSize'", nullptr); return 0; } double ret = cobj->getBMFontSize(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getBMFontSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getBMFontSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getMaxLineWidth(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getMaxLineWidth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getMaxLineWidth'", nullptr); return 0; } double ret = cobj->getMaxLineWidth(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getMaxLineWidth",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getMaxLineWidth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getHorizontalAlignment(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getHorizontalAlignment'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getHorizontalAlignment'", nullptr); return 0; } int ret = (int)cobj->getHorizontalAlignment(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getHorizontalAlignment",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getHorizontalAlignment'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getShadowOffset(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getShadowOffset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getShadowOffset'", nullptr); return 0; } cocos2d::Size ret = cobj->getShadowOffset(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getShadowOffset",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getShadowOffset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getLineSpacing(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getLineSpacing'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getLineSpacing'", nullptr); return 0; } double ret = cobj->getLineSpacing(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getLineSpacing",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getLineSpacing'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setClipMarginEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setClipMarginEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Label:setClipMarginEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setClipMarginEnabled'", nullptr); return 0; } cobj->setClipMarginEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setClipMarginEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setClipMarginEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setString(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:setString"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setString'", nullptr); return 0; } cobj->setString(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setString",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setSystemFontName(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setSystemFontName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:setSystemFontName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setSystemFontName'", nullptr); return 0; } cobj->setSystemFontName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setSystemFontName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setSystemFontName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_isWrapEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_isWrapEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_isWrapEnabled'", nullptr); return 0; } bool ret = cobj->isWrapEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:isWrapEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_isWrapEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getOutlineSize(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getOutlineSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getOutlineSize'", nullptr); return 0; } double ret = cobj->getOutlineSize(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getOutlineSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getOutlineSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setBMFontFilePath(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setBMFontFilePath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:setBMFontFilePath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setBMFontFilePath'", nullptr); return 0; } bool ret = cobj->setBMFontFilePath(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 2) { std::string arg0; cocos2d::Vec2 arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:setBMFontFilePath"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.Label:setBMFontFilePath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setBMFontFilePath'", nullptr); return 0; } bool ret = cobj->setBMFontFilePath(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 3) { std::string arg0; cocos2d::Vec2 arg1; double arg2; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:setBMFontFilePath"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.Label:setBMFontFilePath"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:setBMFontFilePath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setBMFontFilePath'", nullptr); return 0; } bool ret = cobj->setBMFontFilePath(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setBMFontFilePath",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setBMFontFilePath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_initWithTTF(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_initWithTTF'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::_ttfConfig arg0; ok &= luaval_to_ttfconfig(tolua_S, 2, &arg0, "cc.Label:initWithTTF"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:initWithTTF"); if (!ok) { break; } bool ret = cobj->initWithTTF(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::_ttfConfig arg0; ok &= luaval_to_ttfconfig(tolua_S, 2, &arg0, "cc.Label:initWithTTF"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:initWithTTF"); if (!ok) { break; } cocos2d::TextHAlignment arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:initWithTTF"); if (!ok) { break; } bool ret = cobj->initWithTTF(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { cocos2d::_ttfConfig arg0; ok &= luaval_to_ttfconfig(tolua_S, 2, &arg0, "cc.Label:initWithTTF"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:initWithTTF"); if (!ok) { break; } cocos2d::TextHAlignment arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:initWithTTF"); if (!ok) { break; } int arg3; ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.Label:initWithTTF"); if (!ok) { break; } bool ret = cobj->initWithTTF(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:initWithTTF"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:initWithTTF"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:initWithTTF"); if (!ok) { break; } bool ret = cobj->initWithTTF(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:initWithTTF"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:initWithTTF"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:initWithTTF"); if (!ok) { break; } cocos2d::Size arg3; ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Label:initWithTTF"); if (!ok) { break; } bool ret = cobj->initWithTTF(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 5) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:initWithTTF"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:initWithTTF"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:initWithTTF"); if (!ok) { break; } cocos2d::Size arg3; ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Label:initWithTTF"); if (!ok) { break; } cocos2d::TextHAlignment arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.Label:initWithTTF"); if (!ok) { break; } bool ret = cobj->initWithTTF(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 6) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:initWithTTF"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:initWithTTF"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:initWithTTF"); if (!ok) { break; } cocos2d::Size arg3; ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Label:initWithTTF"); if (!ok) { break; } cocos2d::TextHAlignment arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.Label:initWithTTF"); if (!ok) { break; } cocos2d::TextVAlignment arg5; ok &= luaval_to_int32(tolua_S, 7,(int *)&arg5, "cc.Label:initWithTTF"); if (!ok) { break; } bool ret = cobj->initWithTTF(arg0, arg1, arg2, arg3, arg4, arg5); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:initWithTTF",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_initWithTTF'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getFontAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getFontAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getFontAtlas'", nullptr); return 0; } cocos2d::FontAtlas* ret = cobj->getFontAtlas(); object_to_luaval<cocos2d::FontAtlas>(tolua_S, "cc.FontAtlas",(cocos2d::FontAtlas*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getFontAtlas",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getFontAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setLineHeight(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setLineHeight'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setLineHeight"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setLineHeight'", nullptr); return 0; } cobj->setLineHeight(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setLineHeight",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setLineHeight'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setSystemFontSize(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setSystemFontSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setSystemFontSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setSystemFontSize'", nullptr); return 0; } cobj->setSystemFontSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setSystemFontSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setSystemFontSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setOverflow(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setOverflow'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Label::Overflow arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Label:setOverflow"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setOverflow'", nullptr); return 0; } cobj->setOverflow(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setOverflow",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setOverflow'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_enableStrikethrough(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_enableStrikethrough'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableStrikethrough'", nullptr); return 0; } cobj->enableStrikethrough(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:enableStrikethrough",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_enableStrikethrough'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_updateContent(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_updateContent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_updateContent'", nullptr); return 0; } cobj->updateContent(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:updateContent",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_updateContent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getStringLength(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getStringLength'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getStringLength'", nullptr); return 0; } int ret = cobj->getStringLength(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getStringLength",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getStringLength'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setLineBreakWithoutSpace(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setLineBreakWithoutSpace'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Label:setLineBreakWithoutSpace"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setLineBreakWithoutSpace'", nullptr); return 0; } cobj->setLineBreakWithoutSpace(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setLineBreakWithoutSpace",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setLineBreakWithoutSpace'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getStringNumLines(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getStringNumLines'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getStringNumLines'", nullptr); return 0; } int ret = cobj->getStringNumLines(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getStringNumLines",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getStringNumLines'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_enableOutline(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_enableOutline'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.Label:enableOutline"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableOutline'", nullptr); return 0; } cobj->enableOutline(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { cocos2d::Color4B arg0; int arg1; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.Label:enableOutline"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Label:enableOutline"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableOutline'", nullptr); return 0; } cobj->enableOutline(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:enableOutline",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_enableOutline'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getShadowBlurRadius(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getShadowBlurRadius'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getShadowBlurRadius'", nullptr); return 0; } double ret = cobj->getShadowBlurRadius(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getShadowBlurRadius",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getShadowBlurRadius'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getEffectColor(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getEffectColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getEffectColor'", nullptr); return 0; } cocos2d::Color4F ret = cobj->getEffectColor(); color4f_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getEffectColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getEffectColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_removeAllChildrenWithCleanup(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_removeAllChildrenWithCleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Label:removeAllChildrenWithCleanup"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_removeAllChildrenWithCleanup'", nullptr); return 0; } cobj->removeAllChildrenWithCleanup(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:removeAllChildrenWithCleanup",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_removeAllChildrenWithCleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setCharMap(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setCharMap'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 4) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Label:setCharMap"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Label:setCharMap"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:setCharMap"); if (!ok) { break; } int arg3; ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.Label:setCharMap"); if (!ok) { break; } bool ret = cobj->setCharMap(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:setCharMap"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Label:setCharMap"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:setCharMap"); if (!ok) { break; } int arg3; ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.Label:setCharMap"); if (!ok) { break; } bool ret = cobj->setCharMap(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:setCharMap"); if (!ok) { break; } bool ret = cobj->setCharMap(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setCharMap",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setCharMap'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getDimensions(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getDimensions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getDimensions'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getDimensions(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getDimensions",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getDimensions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setMaxLineWidth(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setMaxLineWidth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setMaxLineWidth"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setMaxLineWidth'", nullptr); return 0; } cobj->setMaxLineWidth(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setMaxLineWidth",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setMaxLineWidth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getSystemFontName(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getSystemFontName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getSystemFontName'", nullptr); return 0; } const std::string& ret = cobj->getSystemFontName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getSystemFontName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getSystemFontName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setVerticalAlignment(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setVerticalAlignment'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TextVAlignment arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Label:setVerticalAlignment"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setVerticalAlignment'", nullptr); return 0; } cobj->setVerticalAlignment(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setVerticalAlignment",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setVerticalAlignment'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setLineSpacing(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setLineSpacing'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setLineSpacing"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setLineSpacing'", nullptr); return 0; } cobj->setLineSpacing(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setLineSpacing",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setLineSpacing'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getLineHeight(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getLineHeight'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getLineHeight'", nullptr); return 0; } double ret = cobj->getLineHeight(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getLineHeight",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getLineHeight'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getShadowColor(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getShadowColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getShadowColor'", nullptr); return 0; } cocos2d::Color4F ret = cobj->getShadowColor(); color4f_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getShadowColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getShadowColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getTTFConfig(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getTTFConfig'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getTTFConfig'", nullptr); return 0; } const cocos2d::_ttfConfig& ret = cobj->getTTFConfig(); ttfconfig_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getTTFConfig",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getTTFConfig'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_enableItalics(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_enableItalics'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableItalics'", nullptr); return 0; } cobj->enableItalics(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:enableItalics",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_enableItalics'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setTextColor(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setTextColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.Label:setTextColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setTextColor'", nullptr); return 0; } cobj->setTextColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setTextColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setTextColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getLetter(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getLetter'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Label:getLetter"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getLetter'", nullptr); return 0; } cocos2d::Sprite* ret = cobj->getLetter(arg0); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getLetter",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getLetter'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setHeight(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setHeight'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setHeight"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setHeight'", nullptr); return 0; } cobj->setHeight(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setHeight",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setHeight'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_isShadowEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_isShadowEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_isShadowEnabled'", nullptr); return 0; } bool ret = cobj->isShadowEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:isShadowEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_isShadowEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_enableGlow(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_enableGlow'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.Label:enableGlow"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableGlow'", nullptr); return 0; } cobj->enableGlow(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:enableGlow",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_enableGlow'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getOverflow(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getOverflow'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getOverflow'", nullptr); return 0; } int ret = (int)cobj->getOverflow(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getOverflow",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getOverflow'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getVerticalAlignment(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getVerticalAlignment'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getVerticalAlignment'", nullptr); return 0; } int ret = (int)cobj->getVerticalAlignment(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getVerticalAlignment",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getVerticalAlignment'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setAdditionalKerning(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setAdditionalKerning'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setAdditionalKerning"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setAdditionalKerning'", nullptr); return 0; } cobj->setAdditionalKerning(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setAdditionalKerning",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setAdditionalKerning'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getSystemFontSize(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getSystemFontSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getSystemFontSize'", nullptr); return 0; } double ret = cobj->getSystemFontSize(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getSystemFontSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getSystemFontSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.Label:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getTextAlignment(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getTextAlignment'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getTextAlignment'", nullptr); return 0; } int ret = (int)cobj->getTextAlignment(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getTextAlignment",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getTextAlignment'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getBMFontFilePath(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getBMFontFilePath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getBMFontFilePath'", nullptr); return 0; } const std::string& ret = cobj->getBMFontFilePath(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getBMFontFilePath",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getBMFontFilePath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setHorizontalAlignment(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setHorizontalAlignment'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TextHAlignment arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Label:setHorizontalAlignment"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setHorizontalAlignment'", nullptr); return 0; } cobj->setHorizontalAlignment(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setHorizontalAlignment",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setHorizontalAlignment'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_enableBold(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_enableBold'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableBold'", nullptr); return 0; } cobj->enableBold(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:enableBold",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_enableBold'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_enableUnderline(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_enableUnderline'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_enableUnderline'", nullptr); return 0; } cobj->enableUnderline(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:enableUnderline",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_enableUnderline'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_getLabelEffectType(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_getLabelEffectType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_getLabelEffectType'", nullptr); return 0; } int ret = (int)cobj->getLabelEffectType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:getLabelEffectType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_getLabelEffectType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setAlignment(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setAlignment'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::TextHAlignment arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Label:setAlignment"); if (!ok) { break; } cocos2d::TextVAlignment arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Label:setAlignment"); if (!ok) { break; } cobj->setAlignment(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::TextHAlignment arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Label:setAlignment"); if (!ok) { break; } cobj->setAlignment(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setAlignment",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setAlignment'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_requestSystemFontRefresh(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_requestSystemFontRefresh'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_requestSystemFontRefresh'", nullptr); return 0; } cobj->requestSystemFontRefresh(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:requestSystemFontRefresh",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_requestSystemFontRefresh'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_setBMFontSize(lua_State* tolua_S) { int argc = 0; cocos2d::Label* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Label*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Label_setBMFontSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Label:setBMFontSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_setBMFontSize'", nullptr); return 0; } cobj->setBMFontSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Label:setBMFontSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_setBMFontSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_createWithBMFont(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithBMFont"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:createWithBMFont"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_createWithBMFont'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::createWithBMFont(arg0, arg1); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } if (argc == 3) { std::string arg0; std::string arg1; cocos2d::TextHAlignment arg2; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithBMFont"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:createWithBMFont"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:createWithBMFont"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_createWithBMFont'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::createWithBMFont(arg0, arg1, arg2); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } if (argc == 4) { std::string arg0; std::string arg1; cocos2d::TextHAlignment arg2; int arg3; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithBMFont"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:createWithBMFont"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:createWithBMFont"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.Label:createWithBMFont"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_createWithBMFont'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::createWithBMFont(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } if (argc == 5) { std::string arg0; std::string arg1; cocos2d::TextHAlignment arg2; int arg3; cocos2d::Vec2 arg4; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithBMFont"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:createWithBMFont"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:createWithBMFont"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.Label:createWithBMFont"); ok &= luaval_to_vec2(tolua_S, 6, &arg4, "cc.Label:createWithBMFont"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_createWithBMFont'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::createWithBMFont(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Label:createWithBMFont",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_createWithBMFont'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_create'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::create(); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Label:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_createWithCharMap(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 4) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Label:createWithCharMap"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Label:createWithCharMap"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:createWithCharMap"); if (!ok) { break; } int arg3; ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.Label:createWithCharMap"); if (!ok) { break; } cocos2d::Label* ret = cocos2d::Label::createWithCharMap(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithCharMap"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.Label:createWithCharMap"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.Label:createWithCharMap"); if (!ok) { break; } int arg3; ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.Label:createWithCharMap"); if (!ok) { break; } cocos2d::Label* ret = cocos2d::Label::createWithCharMap(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } } while (0); ok = true; do { if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithCharMap"); if (!ok) { break; } cocos2d::Label* ret = cocos2d::Label::createWithCharMap(arg0); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.Label:createWithCharMap",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_createWithCharMap'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Label_createWithSystemFont(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Label",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { std::string arg0; std::string arg1; double arg2; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithSystemFont"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:createWithSystemFont"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:createWithSystemFont"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_createWithSystemFont'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::createWithSystemFont(arg0, arg1, arg2); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } if (argc == 4) { std::string arg0; std::string arg1; double arg2; cocos2d::Size arg3; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithSystemFont"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:createWithSystemFont"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:createWithSystemFont"); ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Label:createWithSystemFont"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_createWithSystemFont'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::createWithSystemFont(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } if (argc == 5) { std::string arg0; std::string arg1; double arg2; cocos2d::Size arg3; cocos2d::TextHAlignment arg4; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithSystemFont"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:createWithSystemFont"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:createWithSystemFont"); ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Label:createWithSystemFont"); ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.Label:createWithSystemFont"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_createWithSystemFont'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::createWithSystemFont(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } if (argc == 6) { std::string arg0; std::string arg1; double arg2; cocos2d::Size arg3; cocos2d::TextHAlignment arg4; cocos2d::TextVAlignment arg5; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Label:createWithSystemFont"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Label:createWithSystemFont"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Label:createWithSystemFont"); ok &= luaval_to_size(tolua_S, 5, &arg3, "cc.Label:createWithSystemFont"); ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.Label:createWithSystemFont"); ok &= luaval_to_int32(tolua_S, 7,(int *)&arg5, "cc.Label:createWithSystemFont"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Label_createWithSystemFont'", nullptr); return 0; } cocos2d::Label* ret = cocos2d::Label::createWithSystemFont(arg0, arg1, arg2, arg3, arg4, arg5); object_to_luaval<cocos2d::Label>(tolua_S, "cc.Label",(cocos2d::Label*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Label:createWithSystemFont",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Label_createWithSystemFont'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Label_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Label)"); return 0; } int lua_register_cocos2dx_Label(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Label"); tolua_cclass(tolua_S,"Label","cc.Label","cc.Node",nullptr); tolua_beginmodule(tolua_S,"Label"); tolua_function(tolua_S,"isClipMarginEnabled",lua_cocos2dx_Label_isClipMarginEnabled); tolua_function(tolua_S,"enableShadow",lua_cocos2dx_Label_enableShadow); tolua_function(tolua_S,"setDimensions",lua_cocos2dx_Label_setDimensions); tolua_function(tolua_S,"getWidth",lua_cocos2dx_Label_getWidth); tolua_function(tolua_S,"getString",lua_cocos2dx_Label_getString); tolua_function(tolua_S,"getHeight",lua_cocos2dx_Label_getHeight); tolua_function(tolua_S,"disableEffect",lua_cocos2dx_Label_disableEffect); tolua_function(tolua_S,"setTTFConfig",lua_cocos2dx_Label_setTTFConfig); tolua_function(tolua_S,"getTextColor",lua_cocos2dx_Label_getTextColor); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_Label_getBlendFunc); tolua_function(tolua_S,"enableWrap",lua_cocos2dx_Label_enableWrap); tolua_function(tolua_S,"setWidth",lua_cocos2dx_Label_setWidth); tolua_function(tolua_S,"getAdditionalKerning",lua_cocos2dx_Label_getAdditionalKerning); tolua_function(tolua_S,"getBMFontSize",lua_cocos2dx_Label_getBMFontSize); tolua_function(tolua_S,"getMaxLineWidth",lua_cocos2dx_Label_getMaxLineWidth); tolua_function(tolua_S,"getHorizontalAlignment",lua_cocos2dx_Label_getHorizontalAlignment); tolua_function(tolua_S,"getShadowOffset",lua_cocos2dx_Label_getShadowOffset); tolua_function(tolua_S,"getLineSpacing",lua_cocos2dx_Label_getLineSpacing); tolua_function(tolua_S,"setClipMarginEnabled",lua_cocos2dx_Label_setClipMarginEnabled); tolua_function(tolua_S,"setString",lua_cocos2dx_Label_setString); tolua_function(tolua_S,"setSystemFontName",lua_cocos2dx_Label_setSystemFontName); tolua_function(tolua_S,"isWrapEnabled",lua_cocos2dx_Label_isWrapEnabled); tolua_function(tolua_S,"getOutlineSize",lua_cocos2dx_Label_getOutlineSize); tolua_function(tolua_S,"setBMFontFilePath",lua_cocos2dx_Label_setBMFontFilePath); tolua_function(tolua_S,"initWithTTF",lua_cocos2dx_Label_initWithTTF); tolua_function(tolua_S,"getFontAtlas",lua_cocos2dx_Label_getFontAtlas); tolua_function(tolua_S,"setLineHeight",lua_cocos2dx_Label_setLineHeight); tolua_function(tolua_S,"setSystemFontSize",lua_cocos2dx_Label_setSystemFontSize); tolua_function(tolua_S,"setOverflow",lua_cocos2dx_Label_setOverflow); tolua_function(tolua_S,"enableStrikethrough",lua_cocos2dx_Label_enableStrikethrough); tolua_function(tolua_S,"updateContent",lua_cocos2dx_Label_updateContent); tolua_function(tolua_S,"getStringLength",lua_cocos2dx_Label_getStringLength); tolua_function(tolua_S,"setLineBreakWithoutSpace",lua_cocos2dx_Label_setLineBreakWithoutSpace); tolua_function(tolua_S,"getStringNumLines",lua_cocos2dx_Label_getStringNumLines); tolua_function(tolua_S,"enableOutline",lua_cocos2dx_Label_enableOutline); tolua_function(tolua_S,"getShadowBlurRadius",lua_cocos2dx_Label_getShadowBlurRadius); tolua_function(tolua_S,"getEffectColor",lua_cocos2dx_Label_getEffectColor); tolua_function(tolua_S,"removeAllChildrenWithCleanup",lua_cocos2dx_Label_removeAllChildrenWithCleanup); tolua_function(tolua_S,"setCharMap",lua_cocos2dx_Label_setCharMap); tolua_function(tolua_S,"getDimensions",lua_cocos2dx_Label_getDimensions); tolua_function(tolua_S,"setMaxLineWidth",lua_cocos2dx_Label_setMaxLineWidth); tolua_function(tolua_S,"getSystemFontName",lua_cocos2dx_Label_getSystemFontName); tolua_function(tolua_S,"setVerticalAlignment",lua_cocos2dx_Label_setVerticalAlignment); tolua_function(tolua_S,"setLineSpacing",lua_cocos2dx_Label_setLineSpacing); tolua_function(tolua_S,"getLineHeight",lua_cocos2dx_Label_getLineHeight); tolua_function(tolua_S,"getShadowColor",lua_cocos2dx_Label_getShadowColor); tolua_function(tolua_S,"getTTFConfig",lua_cocos2dx_Label_getTTFConfig); tolua_function(tolua_S,"enableItalics",lua_cocos2dx_Label_enableItalics); tolua_function(tolua_S,"setTextColor",lua_cocos2dx_Label_setTextColor); tolua_function(tolua_S,"getLetter",lua_cocos2dx_Label_getLetter); tolua_function(tolua_S,"setHeight",lua_cocos2dx_Label_setHeight); tolua_function(tolua_S,"isShadowEnabled",lua_cocos2dx_Label_isShadowEnabled); tolua_function(tolua_S,"enableGlow",lua_cocos2dx_Label_enableGlow); tolua_function(tolua_S,"getOverflow",lua_cocos2dx_Label_getOverflow); tolua_function(tolua_S,"getVerticalAlignment",lua_cocos2dx_Label_getVerticalAlignment); tolua_function(tolua_S,"setAdditionalKerning",lua_cocos2dx_Label_setAdditionalKerning); tolua_function(tolua_S,"getSystemFontSize",lua_cocos2dx_Label_getSystemFontSize); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_Label_setBlendFunc); tolua_function(tolua_S,"getTextAlignment",lua_cocos2dx_Label_getTextAlignment); tolua_function(tolua_S,"getBMFontFilePath",lua_cocos2dx_Label_getBMFontFilePath); tolua_function(tolua_S,"setHorizontalAlignment",lua_cocos2dx_Label_setHorizontalAlignment); tolua_function(tolua_S,"enableBold",lua_cocos2dx_Label_enableBold); tolua_function(tolua_S,"enableUnderline",lua_cocos2dx_Label_enableUnderline); tolua_function(tolua_S,"getLabelEffectType",lua_cocos2dx_Label_getLabelEffectType); tolua_function(tolua_S,"setAlignment",lua_cocos2dx_Label_setAlignment); tolua_function(tolua_S,"requestSystemFontRefresh",lua_cocos2dx_Label_requestSystemFontRefresh); tolua_function(tolua_S,"setBMFontSize",lua_cocos2dx_Label_setBMFontSize); tolua_function(tolua_S,"createWithBMFont", lua_cocos2dx_Label_createWithBMFont); tolua_function(tolua_S,"create", lua_cocos2dx_Label_create); tolua_function(tolua_S,"createWithCharMap", lua_cocos2dx_Label_createWithCharMap); tolua_function(tolua_S,"createWithSystemFont", lua_cocos2dx_Label_createWithSystemFont); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Label).name(); g_luaType[typeName] = "cc.Label"; g_typeCast["Label"] = "cc.Label"; return 1; } int lua_cocos2dx_FontAtlas_setAliasTexParameters(lua_State* tolua_S) { int argc = 0; cocos2d::FontAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S, 1, "cc.FontAtlas", 0, &tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::FontAtlas*)tolua_tousertype(tolua_S, 1, 0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S, "invalid 'cobj' in function 'lua_cocos2dx_FontAtlas_setAliasTexParameters'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if (!ok) { tolua_error(tolua_S, "invalid arguments in function 'lua_cocos2dx_FontAtlas_setAliasTexParameters'", nullptr); return 0; } cobj->setAliasTexParameters(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.FontAtlas:setAliasTexParameters", argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S, "#ferror in function 'lua_cocos2dx_FontAtlas_setAliasTexParameters'.", &tolua_err); #endif return 0; } int lua_register_cocos2dx_FontAtlas(lua_State* tolua_S) { tolua_usertype(tolua_S, "cc.FontAtlas"); tolua_cclass(tolua_S, "FontAtlas", "cc.FontAtlas", "cc.Node", nullptr); tolua_beginmodule(tolua_S, "FontAtlas"); tolua_function(tolua_S, "setAliasTexParameters", lua_cocos2dx_FontAtlas_setAliasTexParameters); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::FontAtlas).name(); g_luaType[typeName] = "cc.FontAtlas"; g_typeCast["FontAtlas"] = "cc.FontAtlas"; return 1; } int lua_cocos2dx_LabelAtlas_setString(lua_State* tolua_S) { int argc = 0; cocos2d::LabelAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LabelAtlas",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LabelAtlas*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LabelAtlas_setString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.LabelAtlas:setString"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LabelAtlas_setString'", nullptr); return 0; } cobj->setString(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LabelAtlas:setString",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LabelAtlas_setString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LabelAtlas_initWithString(lua_State* tolua_S) { int argc = 0; cocos2d::LabelAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LabelAtlas",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LabelAtlas*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LabelAtlas_initWithString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.LabelAtlas:initWithString"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.LabelAtlas:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 5) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.LabelAtlas:initWithString"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.LabelAtlas:initWithString"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.LabelAtlas:initWithString"); if (!ok) { break; } int arg3; ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.LabelAtlas:initWithString"); if (!ok) { break; } int arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.LabelAtlas:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 5) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.LabelAtlas:initWithString"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.LabelAtlas:initWithString"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.LabelAtlas:initWithString"); if (!ok) { break; } int arg3; ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.LabelAtlas:initWithString"); if (!ok) { break; } int arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.LabelAtlas:initWithString"); if (!ok) { break; } bool ret = cobj->initWithString(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LabelAtlas:initWithString",argc, 5); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LabelAtlas_initWithString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LabelAtlas_getString(lua_State* tolua_S) { int argc = 0; cocos2d::LabelAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LabelAtlas",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LabelAtlas*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LabelAtlas_getString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LabelAtlas_getString'", nullptr); return 0; } const std::string& ret = cobj->getString(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LabelAtlas:getString",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LabelAtlas_getString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LabelAtlas_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.LabelAtlas",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 5) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.LabelAtlas:create"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.LabelAtlas:create"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.LabelAtlas:create"); if (!ok) { break; } int arg3; ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.LabelAtlas:create"); if (!ok) { break; } int arg4; ok &= luaval_to_int32(tolua_S, 6,(int *)&arg4, "cc.LabelAtlas:create"); if (!ok) { break; } cocos2d::LabelAtlas* ret = cocos2d::LabelAtlas::create(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::LabelAtlas>(tolua_S, "cc.LabelAtlas",(cocos2d::LabelAtlas*)ret); return 1; } } while (0); ok = true; do { if (argc == 0) { cocos2d::LabelAtlas* ret = cocos2d::LabelAtlas::create(); object_to_luaval<cocos2d::LabelAtlas>(tolua_S, "cc.LabelAtlas",(cocos2d::LabelAtlas*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.LabelAtlas:create"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.LabelAtlas:create"); if (!ok) { break; } cocos2d::LabelAtlas* ret = cocos2d::LabelAtlas::create(arg0, arg1); object_to_luaval<cocos2d::LabelAtlas>(tolua_S, "cc.LabelAtlas",(cocos2d::LabelAtlas*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.LabelAtlas:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LabelAtlas_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LabelAtlas_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::LabelAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LabelAtlas_constructor'", nullptr); return 0; } cobj = new cocos2d::LabelAtlas(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.LabelAtlas"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LabelAtlas:LabelAtlas",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LabelAtlas_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_LabelAtlas_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (LabelAtlas)"); return 0; } int lua_register_cocos2dx_LabelAtlas(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.LabelAtlas"); tolua_cclass(tolua_S,"LabelAtlas","cc.LabelAtlas","cc.AtlasNode",nullptr); tolua_beginmodule(tolua_S,"LabelAtlas"); tolua_function(tolua_S,"new",lua_cocos2dx_LabelAtlas_constructor); tolua_function(tolua_S,"setString",lua_cocos2dx_LabelAtlas_setString); tolua_function(tolua_S,"initWithString",lua_cocos2dx_LabelAtlas_initWithString); tolua_function(tolua_S,"getString",lua_cocos2dx_LabelAtlas_getString); tolua_function(tolua_S,"_create", lua_cocos2dx_LabelAtlas_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::LabelAtlas).name(); g_luaType[typeName] = "cc.LabelAtlas"; g_typeCast["LabelAtlas"] = "cc.LabelAtlas"; return 1; } int lua_cocos2dx_Layer_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Layer",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Layer_create'", nullptr); return 0; } cocos2d::Layer* ret = cocos2d::Layer::create(); object_to_luaval<cocos2d::Layer>(tolua_S, "cc.Layer",(cocos2d::Layer*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Layer:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Layer_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Layer_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Layer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Layer_constructor'", nullptr); return 0; } cobj = new cocos2d::Layer(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Layer"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Layer:Layer",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Layer_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Layer_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Layer)"); return 0; } int lua_register_cocos2dx_Layer(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Layer"); tolua_cclass(tolua_S,"Layer","cc.Layer","cc.Node",nullptr); tolua_beginmodule(tolua_S,"Layer"); tolua_function(tolua_S,"new",lua_cocos2dx_Layer_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_Layer_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Layer).name(); g_luaType[typeName] = "cc.Layer"; g_typeCast["Layer"] = "cc.Layer"; return 1; } int lua_cocos2dx_LayerColor_changeWidthAndHeight(lua_State* tolua_S) { int argc = 0; cocos2d::LayerColor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerColor",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerColor*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerColor_changeWidthAndHeight'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; double arg1; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.LayerColor:changeWidthAndHeight"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.LayerColor:changeWidthAndHeight"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerColor_changeWidthAndHeight'", nullptr); return 0; } cobj->changeWidthAndHeight(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerColor:changeWidthAndHeight",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerColor_changeWidthAndHeight'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerColor_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::LayerColor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerColor",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerColor*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerColor_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerColor_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerColor:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerColor_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerColor_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::LayerColor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerColor",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerColor*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerColor_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.LayerColor:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerColor_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerColor:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerColor_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerColor_changeWidth(lua_State* tolua_S) { int argc = 0; cocos2d::LayerColor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerColor",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerColor*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerColor_changeWidth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.LayerColor:changeWidth"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerColor_changeWidth'", nullptr); return 0; } cobj->changeWidth(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerColor:changeWidth",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerColor_changeWidth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerColor_initWithColor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerColor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerColor",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerColor*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerColor_initWithColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.LayerColor:initWithColor"); if (!ok) { break; } bool ret = cobj->initWithColor(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.LayerColor:initWithColor"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.LayerColor:initWithColor"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.LayerColor:initWithColor"); if (!ok) { break; } bool ret = cobj->initWithColor(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerColor:initWithColor",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerColor_initWithColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerColor_changeHeight(lua_State* tolua_S) { int argc = 0; cocos2d::LayerColor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerColor",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerColor*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerColor_changeHeight'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.LayerColor:changeHeight"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerColor_changeHeight'", nullptr); return 0; } cobj->changeHeight(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerColor:changeHeight",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerColor_changeHeight'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerColor_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.LayerColor",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 3) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.LayerColor:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.LayerColor:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.LayerColor:create"); if (!ok) { break; } cocos2d::LayerColor* ret = cocos2d::LayerColor::create(arg0, arg1, arg2); object_to_luaval<cocos2d::LayerColor>(tolua_S, "cc.LayerColor",(cocos2d::LayerColor*)ret); return 1; } } while (0); ok = true; do { if (argc == 0) { cocos2d::LayerColor* ret = cocos2d::LayerColor::create(); object_to_luaval<cocos2d::LayerColor>(tolua_S, "cc.LayerColor",(cocos2d::LayerColor*)ret); return 1; } } while (0); ok = true; do { if (argc == 1) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.LayerColor:create"); if (!ok) { break; } cocos2d::LayerColor* ret = cocos2d::LayerColor::create(arg0); object_to_luaval<cocos2d::LayerColor>(tolua_S, "cc.LayerColor",(cocos2d::LayerColor*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.LayerColor:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerColor_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerColor_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerColor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerColor_constructor'", nullptr); return 0; } cobj = new cocos2d::LayerColor(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.LayerColor"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerColor:LayerColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerColor_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_LayerColor_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (LayerColor)"); return 0; } int lua_register_cocos2dx_LayerColor(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.LayerColor"); tolua_cclass(tolua_S,"LayerColor","cc.LayerColor","cc.Layer",nullptr); tolua_beginmodule(tolua_S,"LayerColor"); tolua_function(tolua_S,"new",lua_cocos2dx_LayerColor_constructor); tolua_function(tolua_S,"changeWidthAndHeight",lua_cocos2dx_LayerColor_changeWidthAndHeight); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_LayerColor_getBlendFunc); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_LayerColor_setBlendFunc); tolua_function(tolua_S,"changeWidth",lua_cocos2dx_LayerColor_changeWidth); tolua_function(tolua_S,"initWithColor",lua_cocos2dx_LayerColor_initWithColor); tolua_function(tolua_S,"changeHeight",lua_cocos2dx_LayerColor_changeHeight); tolua_function(tolua_S,"create", lua_cocos2dx_LayerColor_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::LayerColor).name(); g_luaType[typeName] = "cc.LayerColor"; g_typeCast["LayerColor"] = "cc.LayerColor"; return 1; } int lua_cocos2dx_LayerGradient_getStartColor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_getStartColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_getStartColor'", nullptr); return 0; } const cocos2d::Color3B& ret = cobj->getStartColor(); color3b_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:getStartColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_getStartColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_isCompressedInterpolation(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_isCompressedInterpolation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_isCompressedInterpolation'", nullptr); return 0; } bool ret = cobj->isCompressedInterpolation(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:isCompressedInterpolation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_isCompressedInterpolation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_getStartOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_getStartOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_getStartOpacity'", nullptr); return 0; } uint16_t ret = cobj->getStartOpacity(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:getStartOpacity",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_getStartOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_setVector(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_setVector'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.LayerGradient:setVector"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_setVector'", nullptr); return 0; } cobj->setVector(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:setVector",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_setVector'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_setStartOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_setStartOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { uint16_t arg0; ok &= luaval_to_uint16(tolua_S, 2,&arg0, "cc.LayerGradient:setStartOpacity"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_setStartOpacity'", nullptr); return 0; } cobj->setStartOpacity(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:setStartOpacity",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_setStartOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_setCompressedInterpolation(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_setCompressedInterpolation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.LayerGradient:setCompressedInterpolation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_setCompressedInterpolation'", nullptr); return 0; } cobj->setCompressedInterpolation(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:setCompressedInterpolation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_setCompressedInterpolation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_setEndOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_setEndOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { uint16_t arg0; ok &= luaval_to_uint16(tolua_S, 2,&arg0, "cc.LayerGradient:setEndOpacity"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_setEndOpacity'", nullptr); return 0; } cobj->setEndOpacity(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:setEndOpacity",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_setEndOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_getVector(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_getVector'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_getVector'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getVector(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:getVector",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_getVector'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_setEndColor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_setEndColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color3B arg0; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.LayerGradient:setEndColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_setEndColor'", nullptr); return 0; } cobj->setEndColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:setEndColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_setEndColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_initWithColor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_initWithColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.LayerGradient:initWithColor"); if (!ok) { break; } cocos2d::Color4B arg1; ok &=luaval_to_color4b(tolua_S, 3, &arg1, "cc.LayerGradient:initWithColor"); if (!ok) { break; } cocos2d::Vec2 arg2; ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.LayerGradient:initWithColor"); if (!ok) { break; } bool ret = cobj->initWithColor(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.LayerGradient:initWithColor"); if (!ok) { break; } cocos2d::Color4B arg1; ok &=luaval_to_color4b(tolua_S, 3, &arg1, "cc.LayerGradient:initWithColor"); if (!ok) { break; } bool ret = cobj->initWithColor(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:initWithColor",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_initWithColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_getEndColor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_getEndColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_getEndColor'", nullptr); return 0; } const cocos2d::Color3B& ret = cobj->getEndColor(); color3b_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:getEndColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_getEndColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_getEndOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_getEndOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_getEndOpacity'", nullptr); return 0; } uint16_t ret = cobj->getEndOpacity(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:getEndOpacity",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_getEndOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_setStartColor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerGradient*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerGradient_setStartColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color3B arg0; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.LayerGradient:setStartColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_setStartColor'", nullptr); return 0; } cobj->setStartColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:setStartColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_setStartColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.LayerGradient",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.LayerGradient:create"); if (!ok) { break; } cocos2d::Color4B arg1; ok &=luaval_to_color4b(tolua_S, 3, &arg1, "cc.LayerGradient:create"); if (!ok) { break; } cocos2d::LayerGradient* ret = cocos2d::LayerGradient::create(arg0, arg1); object_to_luaval<cocos2d::LayerGradient>(tolua_S, "cc.LayerGradient",(cocos2d::LayerGradient*)ret); return 1; } } while (0); ok = true; do { if (argc == 0) { cocos2d::LayerGradient* ret = cocos2d::LayerGradient::create(); object_to_luaval<cocos2d::LayerGradient>(tolua_S, "cc.LayerGradient",(cocos2d::LayerGradient*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { cocos2d::Color4B arg0; ok &=luaval_to_color4b(tolua_S, 2, &arg0, "cc.LayerGradient:create"); if (!ok) { break; } cocos2d::Color4B arg1; ok &=luaval_to_color4b(tolua_S, 3, &arg1, "cc.LayerGradient:create"); if (!ok) { break; } cocos2d::Vec2 arg2; ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.LayerGradient:create"); if (!ok) { break; } cocos2d::LayerGradient* ret = cocos2d::LayerGradient::create(arg0, arg1, arg2); object_to_luaval<cocos2d::LayerGradient>(tolua_S, "cc.LayerGradient",(cocos2d::LayerGradient*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.LayerGradient:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerGradient_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerGradient* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerGradient_constructor'", nullptr); return 0; } cobj = new cocos2d::LayerGradient(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.LayerGradient"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerGradient:LayerGradient",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerGradient_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_LayerGradient_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (LayerGradient)"); return 0; } int lua_register_cocos2dx_LayerGradient(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.LayerGradient"); tolua_cclass(tolua_S,"LayerGradient","cc.LayerGradient","cc.LayerColor",nullptr); tolua_beginmodule(tolua_S,"LayerGradient"); tolua_function(tolua_S,"new",lua_cocos2dx_LayerGradient_constructor); tolua_function(tolua_S,"getStartColor",lua_cocos2dx_LayerGradient_getStartColor); tolua_function(tolua_S,"isCompressedInterpolation",lua_cocos2dx_LayerGradient_isCompressedInterpolation); tolua_function(tolua_S,"getStartOpacity",lua_cocos2dx_LayerGradient_getStartOpacity); tolua_function(tolua_S,"setVector",lua_cocos2dx_LayerGradient_setVector); tolua_function(tolua_S,"setStartOpacity",lua_cocos2dx_LayerGradient_setStartOpacity); tolua_function(tolua_S,"setCompressedInterpolation",lua_cocos2dx_LayerGradient_setCompressedInterpolation); tolua_function(tolua_S,"setEndOpacity",lua_cocos2dx_LayerGradient_setEndOpacity); tolua_function(tolua_S,"getVector",lua_cocos2dx_LayerGradient_getVector); tolua_function(tolua_S,"setEndColor",lua_cocos2dx_LayerGradient_setEndColor); tolua_function(tolua_S,"initWithColor",lua_cocos2dx_LayerGradient_initWithColor); tolua_function(tolua_S,"getEndColor",lua_cocos2dx_LayerGradient_getEndColor); tolua_function(tolua_S,"getEndOpacity",lua_cocos2dx_LayerGradient_getEndOpacity); tolua_function(tolua_S,"setStartColor",lua_cocos2dx_LayerGradient_setStartColor); tolua_function(tolua_S,"create", lua_cocos2dx_LayerGradient_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::LayerGradient).name(); g_luaType[typeName] = "cc.LayerGradient"; g_typeCast["LayerGradient"] = "cc.LayerGradient"; return 1; } int lua_cocos2dx_LayerMultiplex_initWithArray(lua_State* tolua_S) { int argc = 0; cocos2d::LayerMultiplex* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerMultiplex",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerMultiplex*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerMultiplex_initWithArray'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::Layer *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.LayerMultiplex:initWithArray"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerMultiplex_initWithArray'", nullptr); return 0; } bool ret = cobj->initWithArray(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerMultiplex:initWithArray",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerMultiplex_initWithArray'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerMultiplex_switchToAndReleaseMe(lua_State* tolua_S) { int argc = 0; cocos2d::LayerMultiplex* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerMultiplex",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerMultiplex*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerMultiplex_switchToAndReleaseMe'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.LayerMultiplex:switchToAndReleaseMe"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerMultiplex_switchToAndReleaseMe'", nullptr); return 0; } cobj->switchToAndReleaseMe(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerMultiplex:switchToAndReleaseMe",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerMultiplex_switchToAndReleaseMe'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerMultiplex_addLayer(lua_State* tolua_S) { int argc = 0; cocos2d::LayerMultiplex* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerMultiplex",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerMultiplex*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerMultiplex_addLayer'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Layer* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Layer>(tolua_S, 2, "cc.Layer",&arg0, "cc.LayerMultiplex:addLayer"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerMultiplex_addLayer'", nullptr); return 0; } cobj->addLayer(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerMultiplex:addLayer",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerMultiplex_addLayer'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerMultiplex_switchTo(lua_State* tolua_S) { int argc = 0; cocos2d::LayerMultiplex* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.LayerMultiplex",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::LayerMultiplex*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_LayerMultiplex_switchTo'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.LayerMultiplex:switchTo"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerMultiplex_switchTo'", nullptr); return 0; } cobj->switchTo(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerMultiplex:switchTo",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerMultiplex_switchTo'.",&tolua_err); #endif return 0; } int lua_cocos2dx_LayerMultiplex_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::LayerMultiplex* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_LayerMultiplex_constructor'", nullptr); return 0; } cobj = new cocos2d::LayerMultiplex(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.LayerMultiplex"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.LayerMultiplex:LayerMultiplex",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_LayerMultiplex_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_LayerMultiplex_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (LayerMultiplex)"); return 0; } int lua_register_cocos2dx_LayerMultiplex(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.LayerMultiplex"); tolua_cclass(tolua_S,"LayerMultiplex","cc.LayerMultiplex","cc.Layer",nullptr); tolua_beginmodule(tolua_S,"LayerMultiplex"); tolua_function(tolua_S,"new",lua_cocos2dx_LayerMultiplex_constructor); tolua_function(tolua_S,"initWithArray",lua_cocos2dx_LayerMultiplex_initWithArray); tolua_function(tolua_S,"switchToAndReleaseMe",lua_cocos2dx_LayerMultiplex_switchToAndReleaseMe); tolua_function(tolua_S,"addLayer",lua_cocos2dx_LayerMultiplex_addLayer); tolua_function(tolua_S,"switchTo",lua_cocos2dx_LayerMultiplex_switchTo); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::LayerMultiplex).name(); g_luaType[typeName] = "cc.LayerMultiplex"; g_typeCast["LayerMultiplex"] = "cc.LayerMultiplex"; return 1; } int lua_cocos2dx_MenuItem_setEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItem_setEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.MenuItem:setEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItem_setEnabled'", nullptr); return 0; } cobj->setEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItem:setEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItem_setEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItem_activate(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItem_activate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItem_activate'", nullptr); return 0; } cobj->activate(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItem:activate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItem_activate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItem_isEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItem_isEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItem_isEnabled'", nullptr); return 0; } bool ret = cobj->isEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItem:isEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItem_isEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItem_selected(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItem_selected'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItem_selected'", nullptr); return 0; } cobj->selected(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItem:selected",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItem_selected'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItem_isSelected(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItem_isSelected'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItem_isSelected'", nullptr); return 0; } bool ret = cobj->isSelected(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItem:isSelected",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItem_isSelected'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItem_unselected(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItem_unselected'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItem_unselected'", nullptr); return 0; } cobj->unselected(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItem:unselected",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItem_unselected'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItem_rect(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItem_rect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItem_rect'", nullptr); return 0; } cocos2d::Rect ret = cobj->rect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItem:rect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItem_rect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItem_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItem_constructor'", nullptr); return 0; } cobj = new cocos2d::MenuItem(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MenuItem"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItem:MenuItem",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItem_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MenuItem_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MenuItem)"); return 0; } int lua_register_cocos2dx_MenuItem(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MenuItem"); tolua_cclass(tolua_S,"MenuItem","cc.MenuItem","cc.Node",nullptr); tolua_beginmodule(tolua_S,"MenuItem"); tolua_function(tolua_S,"new",lua_cocos2dx_MenuItem_constructor); tolua_function(tolua_S,"setEnabled",lua_cocos2dx_MenuItem_setEnabled); tolua_function(tolua_S,"activate",lua_cocos2dx_MenuItem_activate); tolua_function(tolua_S,"isEnabled",lua_cocos2dx_MenuItem_isEnabled); tolua_function(tolua_S,"selected",lua_cocos2dx_MenuItem_selected); tolua_function(tolua_S,"isSelected",lua_cocos2dx_MenuItem_isSelected); tolua_function(tolua_S,"unselected",lua_cocos2dx_MenuItem_unselected); tolua_function(tolua_S,"rect",lua_cocos2dx_MenuItem_rect); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MenuItem).name(); g_luaType[typeName] = "cc.MenuItem"; g_typeCast["MenuItem"] = "cc.MenuItem"; return 1; } int lua_cocos2dx_MenuItemLabel_setLabel(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemLabel* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemLabel",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemLabel*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemLabel_setLabel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.MenuItemLabel:setLabel"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemLabel_setLabel'", nullptr); return 0; } cobj->setLabel(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemLabel:setLabel",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemLabel_setLabel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemLabel_getString(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemLabel* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemLabel",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemLabel*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemLabel_getString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemLabel_getString'", nullptr); return 0; } std::string ret = cobj->getString(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemLabel:getString",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemLabel_getString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemLabel_getDisabledColor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemLabel* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemLabel",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemLabel*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemLabel_getDisabledColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemLabel_getDisabledColor'", nullptr); return 0; } const cocos2d::Color3B& ret = cobj->getDisabledColor(); color3b_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemLabel:getDisabledColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemLabel_getDisabledColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemLabel_setString(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemLabel* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemLabel",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemLabel*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemLabel_setString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.MenuItemLabel:setString"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemLabel_setString'", nullptr); return 0; } cobj->setString(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemLabel:setString",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemLabel_setString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemLabel_initWithLabel(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemLabel* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemLabel",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemLabel*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemLabel_initWithLabel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Node* arg0 = nullptr; std::function<void (cocos2d::Ref *)> arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.MenuItemLabel:initWithLabel"); do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemLabel_initWithLabel'", nullptr); return 0; } bool ret = cobj->initWithLabel(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemLabel:initWithLabel",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemLabel_initWithLabel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemLabel_setDisabledColor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemLabel* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemLabel",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemLabel*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemLabel_setDisabledColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color3B arg0; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.MenuItemLabel:setDisabledColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemLabel_setDisabledColor'", nullptr); return 0; } cobj->setDisabledColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemLabel:setDisabledColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemLabel_setDisabledColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemLabel_getLabel(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemLabel* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemLabel",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemLabel*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemLabel_getLabel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemLabel_getLabel'", nullptr); return 0; } cocos2d::Node* ret = cobj->getLabel(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemLabel:getLabel",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemLabel_getLabel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemLabel_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemLabel* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemLabel_constructor'", nullptr); return 0; } cobj = new cocos2d::MenuItemLabel(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MenuItemLabel"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemLabel:MenuItemLabel",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemLabel_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MenuItemLabel_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MenuItemLabel)"); return 0; } int lua_register_cocos2dx_MenuItemLabel(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MenuItemLabel"); tolua_cclass(tolua_S,"MenuItemLabel","cc.MenuItemLabel","cc.MenuItem",nullptr); tolua_beginmodule(tolua_S,"MenuItemLabel"); tolua_function(tolua_S,"new",lua_cocos2dx_MenuItemLabel_constructor); tolua_function(tolua_S,"setLabel",lua_cocos2dx_MenuItemLabel_setLabel); tolua_function(tolua_S,"getString",lua_cocos2dx_MenuItemLabel_getString); tolua_function(tolua_S,"getDisabledColor",lua_cocos2dx_MenuItemLabel_getDisabledColor); tolua_function(tolua_S,"setString",lua_cocos2dx_MenuItemLabel_setString); tolua_function(tolua_S,"initWithLabel",lua_cocos2dx_MenuItemLabel_initWithLabel); tolua_function(tolua_S,"setDisabledColor",lua_cocos2dx_MenuItemLabel_setDisabledColor); tolua_function(tolua_S,"getLabel",lua_cocos2dx_MenuItemLabel_getLabel); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MenuItemLabel).name(); g_luaType[typeName] = "cc.MenuItemLabel"; g_typeCast["MenuItemLabel"] = "cc.MenuItemLabel"; return 1; } int lua_cocos2dx_MenuItemAtlasFont_initWithString(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemAtlasFont* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemAtlasFont",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemAtlasFont*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemAtlasFont_initWithString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 6) { std::string arg0; std::string arg1; int arg2; int arg3; int32_t arg4; std::function<void (cocos2d::Ref *)> arg5; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.MenuItemAtlasFont:initWithString"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.MenuItemAtlasFont:initWithString"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.MenuItemAtlasFont:initWithString"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.MenuItemAtlasFont:initWithString"); ok &= luaval_to_int32(tolua_S, 6,&arg4, "cc.MenuItemAtlasFont:initWithString"); do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemAtlasFont_initWithString'", nullptr); return 0; } bool ret = cobj->initWithString(arg0, arg1, arg2, arg3, arg4, arg5); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemAtlasFont:initWithString",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemAtlasFont_initWithString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemAtlasFont_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemAtlasFont* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemAtlasFont_constructor'", nullptr); return 0; } cobj = new cocos2d::MenuItemAtlasFont(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MenuItemAtlasFont"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemAtlasFont:MenuItemAtlasFont",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemAtlasFont_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MenuItemAtlasFont_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MenuItemAtlasFont)"); return 0; } int lua_register_cocos2dx_MenuItemAtlasFont(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MenuItemAtlasFont"); tolua_cclass(tolua_S,"MenuItemAtlasFont","cc.MenuItemAtlasFont","cc.MenuItemLabel",nullptr); tolua_beginmodule(tolua_S,"MenuItemAtlasFont"); tolua_function(tolua_S,"new",lua_cocos2dx_MenuItemAtlasFont_constructor); tolua_function(tolua_S,"initWithString",lua_cocos2dx_MenuItemAtlasFont_initWithString); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MenuItemAtlasFont).name(); g_luaType[typeName] = "cc.MenuItemAtlasFont"; g_typeCast["MenuItemAtlasFont"] = "cc.MenuItemAtlasFont"; return 1; } int lua_cocos2dx_MenuItemFont_getFontNameObj(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemFont* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemFont*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemFont_getFontNameObj'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_getFontNameObj'", nullptr); return 0; } const std::string& ret = cobj->getFontNameObj(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemFont:getFontNameObj",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_getFontNameObj'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_setFontNameObj(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemFont* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemFont*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemFont_setFontNameObj'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.MenuItemFont:setFontNameObj"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_setFontNameObj'", nullptr); return 0; } cobj->setFontNameObj(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemFont:setFontNameObj",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_setFontNameObj'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_initWithString(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemFont* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemFont*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemFont_initWithString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::function<void (cocos2d::Ref *)> arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.MenuItemFont:initWithString"); do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_initWithString'", nullptr); return 0; } bool ret = cobj->initWithString(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemFont:initWithString",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_initWithString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_getFontSizeObj(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemFont* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemFont*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemFont_getFontSizeObj'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_getFontSizeObj'", nullptr); return 0; } int ret = cobj->getFontSizeObj(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemFont:getFontSizeObj",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_getFontSizeObj'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_setFontSizeObj(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemFont* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemFont*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemFont_setFontSizeObj'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.MenuItemFont:setFontSizeObj"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_setFontSizeObj'", nullptr); return 0; } cobj->setFontSizeObj(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemFont:setFontSizeObj",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_setFontSizeObj'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_setFontName(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.MenuItemFont:setFontName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_setFontName'", nullptr); return 0; } cocos2d::MenuItemFont::setFontName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.MenuItemFont:setFontName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_setFontName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_getFontSize(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_getFontSize'", nullptr); return 0; } int ret = cocos2d::MenuItemFont::getFontSize(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.MenuItemFont:getFontSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_getFontSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_getFontName(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_getFontName'", nullptr); return 0; } const std::string& ret = cocos2d::MenuItemFont::getFontName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.MenuItemFont:getFontName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_getFontName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_setFontSize(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.MenuItemFont",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.MenuItemFont:setFontSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_setFontSize'", nullptr); return 0; } cocos2d::MenuItemFont::setFontSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.MenuItemFont:setFontSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_setFontSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemFont_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemFont* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemFont_constructor'", nullptr); return 0; } cobj = new cocos2d::MenuItemFont(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MenuItemFont"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemFont:MenuItemFont",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemFont_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MenuItemFont_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MenuItemFont)"); return 0; } int lua_register_cocos2dx_MenuItemFont(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MenuItemFont"); tolua_cclass(tolua_S,"MenuItemFont","cc.MenuItemFont","cc.MenuItemLabel",nullptr); tolua_beginmodule(tolua_S,"MenuItemFont"); tolua_function(tolua_S,"new",lua_cocos2dx_MenuItemFont_constructor); tolua_function(tolua_S,"getFontNameObj",lua_cocos2dx_MenuItemFont_getFontNameObj); tolua_function(tolua_S,"setFontNameObj",lua_cocos2dx_MenuItemFont_setFontNameObj); tolua_function(tolua_S,"initWithString",lua_cocos2dx_MenuItemFont_initWithString); tolua_function(tolua_S,"getFontSizeObj",lua_cocos2dx_MenuItemFont_getFontSizeObj); tolua_function(tolua_S,"setFontSizeObj",lua_cocos2dx_MenuItemFont_setFontSizeObj); tolua_function(tolua_S,"setFontName", lua_cocos2dx_MenuItemFont_setFontName); tolua_function(tolua_S,"getFontSize", lua_cocos2dx_MenuItemFont_getFontSize); tolua_function(tolua_S,"getFontName", lua_cocos2dx_MenuItemFont_getFontName); tolua_function(tolua_S,"setFontSize", lua_cocos2dx_MenuItemFont_setFontSize); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MenuItemFont).name(); g_luaType[typeName] = "cc.MenuItemFont"; g_typeCast["MenuItemFont"] = "cc.MenuItemFont"; return 1; } int lua_cocos2dx_MenuItemSprite_setEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_setEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.MenuItemSprite:setEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_setEnabled'", nullptr); return 0; } cobj->setEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:setEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_setEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_selected(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_selected'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_selected'", nullptr); return 0; } cobj->selected(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:selected",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_selected'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_setNormalImage(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_setNormalImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.MenuItemSprite:setNormalImage"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_setNormalImage'", nullptr); return 0; } cobj->setNormalImage(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:setNormalImage",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_setNormalImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_setDisabledImage(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_setDisabledImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.MenuItemSprite:setDisabledImage"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_setDisabledImage'", nullptr); return 0; } cobj->setDisabledImage(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:setDisabledImage",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_setDisabledImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_initWithNormalSprite(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_initWithNormalSprite'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { cocos2d::Node* arg0 = nullptr; cocos2d::Node* arg1 = nullptr; cocos2d::Node* arg2 = nullptr; std::function<void (cocos2d::Ref *)> arg3; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.MenuItemSprite:initWithNormalSprite"); ok &= luaval_to_object<cocos2d::Node>(tolua_S, 3, "cc.Node",&arg1, "cc.MenuItemSprite:initWithNormalSprite"); ok &= luaval_to_object<cocos2d::Node>(tolua_S, 4, "cc.Node",&arg2, "cc.MenuItemSprite:initWithNormalSprite"); do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_initWithNormalSprite'", nullptr); return 0; } bool ret = cobj->initWithNormalSprite(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:initWithNormalSprite",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_initWithNormalSprite'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_setSelectedImage(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_setSelectedImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.MenuItemSprite:setSelectedImage"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_setSelectedImage'", nullptr); return 0; } cobj->setSelectedImage(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:setSelectedImage",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_setSelectedImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_getDisabledImage(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_getDisabledImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_getDisabledImage'", nullptr); return 0; } cocos2d::Node* ret = cobj->getDisabledImage(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:getDisabledImage",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_getDisabledImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_getSelectedImage(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_getSelectedImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_getSelectedImage'", nullptr); return 0; } cocos2d::Node* ret = cobj->getSelectedImage(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:getSelectedImage",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_getSelectedImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_getNormalImage(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_getNormalImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_getNormalImage'", nullptr); return 0; } cocos2d::Node* ret = cobj->getNormalImage(); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:getNormalImage",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_getNormalImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_unselected(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemSprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemSprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemSprite_unselected'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_unselected'", nullptr); return 0; } cobj->unselected(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:unselected",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_unselected'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemSprite_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemSprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemSprite_constructor'", nullptr); return 0; } cobj = new cocos2d::MenuItemSprite(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MenuItemSprite"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemSprite:MenuItemSprite",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemSprite_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MenuItemSprite_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MenuItemSprite)"); return 0; } int lua_register_cocos2dx_MenuItemSprite(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MenuItemSprite"); tolua_cclass(tolua_S,"MenuItemSprite","cc.MenuItemSprite","cc.MenuItem",nullptr); tolua_beginmodule(tolua_S,"MenuItemSprite"); tolua_function(tolua_S,"new",lua_cocos2dx_MenuItemSprite_constructor); tolua_function(tolua_S,"setEnabled",lua_cocos2dx_MenuItemSprite_setEnabled); tolua_function(tolua_S,"selected",lua_cocos2dx_MenuItemSprite_selected); tolua_function(tolua_S,"setNormalImage",lua_cocos2dx_MenuItemSprite_setNormalImage); tolua_function(tolua_S,"setDisabledImage",lua_cocos2dx_MenuItemSprite_setDisabledImage); tolua_function(tolua_S,"initWithNormalSprite",lua_cocos2dx_MenuItemSprite_initWithNormalSprite); tolua_function(tolua_S,"setSelectedImage",lua_cocos2dx_MenuItemSprite_setSelectedImage); tolua_function(tolua_S,"getDisabledImage",lua_cocos2dx_MenuItemSprite_getDisabledImage); tolua_function(tolua_S,"getSelectedImage",lua_cocos2dx_MenuItemSprite_getSelectedImage); tolua_function(tolua_S,"getNormalImage",lua_cocos2dx_MenuItemSprite_getNormalImage); tolua_function(tolua_S,"unselected",lua_cocos2dx_MenuItemSprite_unselected); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MenuItemSprite).name(); g_luaType[typeName] = "cc.MenuItemSprite"; g_typeCast["MenuItemSprite"] = "cc.MenuItemSprite"; return 1; } int lua_cocos2dx_MenuItemImage_setDisabledSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemImage* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemImage",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemImage*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemImage_setDisabledSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.MenuItemImage:setDisabledSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemImage_setDisabledSpriteFrame'", nullptr); return 0; } cobj->setDisabledSpriteFrame(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemImage:setDisabledSpriteFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemImage_setDisabledSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemImage_setSelectedSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemImage* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemImage",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemImage*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemImage_setSelectedSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.MenuItemImage:setSelectedSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemImage_setSelectedSpriteFrame'", nullptr); return 0; } cobj->setSelectedSpriteFrame(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemImage:setSelectedSpriteFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemImage_setSelectedSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemImage_setNormalSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemImage* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemImage",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemImage*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemImage_setNormalSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.MenuItemImage:setNormalSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemImage_setNormalSpriteFrame'", nullptr); return 0; } cobj->setNormalSpriteFrame(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemImage:setNormalSpriteFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemImage_setNormalSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemImage_init(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemImage* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemImage",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemImage*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemImage_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemImage_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemImage:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemImage_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemImage_initWithNormalImage(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemImage* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemImage",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemImage*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemImage_initWithNormalImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { std::string arg0; std::string arg1; std::string arg2; std::function<void (cocos2d::Ref *)> arg3; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.MenuItemImage:initWithNormalImage"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.MenuItemImage:initWithNormalImage"); ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.MenuItemImage:initWithNormalImage"); do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemImage_initWithNormalImage'", nullptr); return 0; } bool ret = cobj->initWithNormalImage(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemImage:initWithNormalImage",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemImage_initWithNormalImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemImage_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemImage* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemImage_constructor'", nullptr); return 0; } cobj = new cocos2d::MenuItemImage(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MenuItemImage"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemImage:MenuItemImage",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemImage_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MenuItemImage_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MenuItemImage)"); return 0; } int lua_register_cocos2dx_MenuItemImage(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MenuItemImage"); tolua_cclass(tolua_S,"MenuItemImage","cc.MenuItemImage","cc.MenuItemSprite",nullptr); tolua_beginmodule(tolua_S,"MenuItemImage"); tolua_function(tolua_S,"new",lua_cocos2dx_MenuItemImage_constructor); tolua_function(tolua_S,"setDisabledSpriteFrame",lua_cocos2dx_MenuItemImage_setDisabledSpriteFrame); tolua_function(tolua_S,"setSelectedSpriteFrame",lua_cocos2dx_MenuItemImage_setSelectedSpriteFrame); tolua_function(tolua_S,"setNormalSpriteFrame",lua_cocos2dx_MenuItemImage_setNormalSpriteFrame); tolua_function(tolua_S,"init",lua_cocos2dx_MenuItemImage_init); tolua_function(tolua_S,"initWithNormalImage",lua_cocos2dx_MenuItemImage_initWithNormalImage); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MenuItemImage).name(); g_luaType[typeName] = "cc.MenuItemImage"; g_typeCast["MenuItemImage"] = "cc.MenuItemImage"; return 1; } int lua_cocos2dx_MenuItemToggle_setSubItems(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemToggle* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemToggle",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemToggle*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemToggle_setSubItems'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::MenuItem *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.MenuItemToggle:setSubItems"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemToggle_setSubItems'", nullptr); return 0; } cobj->setSubItems(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemToggle:setSubItems",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemToggle_setSubItems'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemToggle_initWithItem(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemToggle* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemToggle",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemToggle*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemToggle_initWithItem'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::MenuItem* arg0 = nullptr; ok &= luaval_to_object<cocos2d::MenuItem>(tolua_S, 2, "cc.MenuItem",&arg0, "cc.MenuItemToggle:initWithItem"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemToggle_initWithItem'", nullptr); return 0; } bool ret = cobj->initWithItem(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemToggle:initWithItem",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemToggle_initWithItem'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemToggle_getSelectedIndex(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemToggle* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemToggle",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemToggle*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemToggle_getSelectedIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemToggle_getSelectedIndex'", nullptr); return 0; } unsigned int ret = cobj->getSelectedIndex(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemToggle:getSelectedIndex",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemToggle_getSelectedIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemToggle_addSubItem(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemToggle* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemToggle",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemToggle*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemToggle_addSubItem'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::MenuItem* arg0 = nullptr; ok &= luaval_to_object<cocos2d::MenuItem>(tolua_S, 2, "cc.MenuItem",&arg0, "cc.MenuItemToggle:addSubItem"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemToggle_addSubItem'", nullptr); return 0; } cobj->addSubItem(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemToggle:addSubItem",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemToggle_addSubItem'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemToggle_getSelectedItem(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemToggle* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemToggle",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemToggle*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemToggle_getSelectedItem'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemToggle_getSelectedItem'", nullptr); return 0; } cocos2d::MenuItem* ret = cobj->getSelectedItem(); object_to_luaval<cocos2d::MenuItem>(tolua_S, "cc.MenuItem",(cocos2d::MenuItem*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemToggle:getSelectedItem",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemToggle_getSelectedItem'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemToggle_setSelectedIndex(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemToggle* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MenuItemToggle",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MenuItemToggle*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MenuItemToggle_setSelectedIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned int arg0; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.MenuItemToggle:setSelectedIndex"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemToggle_setSelectedIndex'", nullptr); return 0; } cobj->setSelectedIndex(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemToggle:setSelectedIndex",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemToggle_setSelectedIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MenuItemToggle_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MenuItemToggle* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MenuItemToggle_constructor'", nullptr); return 0; } cobj = new cocos2d::MenuItemToggle(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MenuItemToggle"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MenuItemToggle:MenuItemToggle",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MenuItemToggle_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MenuItemToggle_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MenuItemToggle)"); return 0; } int lua_register_cocos2dx_MenuItemToggle(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MenuItemToggle"); tolua_cclass(tolua_S,"MenuItemToggle","cc.MenuItemToggle","cc.MenuItem",nullptr); tolua_beginmodule(tolua_S,"MenuItemToggle"); tolua_function(tolua_S,"new",lua_cocos2dx_MenuItemToggle_constructor); tolua_function(tolua_S,"setSubItems",lua_cocos2dx_MenuItemToggle_setSubItems); tolua_function(tolua_S,"initWithItem",lua_cocos2dx_MenuItemToggle_initWithItem); tolua_function(tolua_S,"getSelectedIndex",lua_cocos2dx_MenuItemToggle_getSelectedIndex); tolua_function(tolua_S,"addSubItem",lua_cocos2dx_MenuItemToggle_addSubItem); tolua_function(tolua_S,"getSelectedItem",lua_cocos2dx_MenuItemToggle_getSelectedItem); tolua_function(tolua_S,"setSelectedIndex",lua_cocos2dx_MenuItemToggle_setSelectedIndex); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MenuItemToggle).name(); g_luaType[typeName] = "cc.MenuItemToggle"; g_typeCast["MenuItemToggle"] = "cc.MenuItemToggle"; return 1; } int lua_cocos2dx_Menu_initWithArray(lua_State* tolua_S) { int argc = 0; cocos2d::Menu* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Menu",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Menu*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Menu_initWithArray'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::MenuItem *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.Menu:initWithArray"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Menu_initWithArray'", nullptr); return 0; } bool ret = cobj->initWithArray(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Menu:initWithArray",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Menu_initWithArray'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Menu_setEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Menu* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Menu",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Menu*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Menu_setEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Menu:setEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Menu_setEnabled'", nullptr); return 0; } cobj->setEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Menu:setEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Menu_setEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Menu_alignItemsVertically(lua_State* tolua_S) { int argc = 0; cocos2d::Menu* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Menu",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Menu*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Menu_alignItemsVertically'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Menu_alignItemsVertically'", nullptr); return 0; } cobj->alignItemsVertically(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Menu:alignItemsVertically",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Menu_alignItemsVertically'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Menu_isEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Menu* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Menu",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Menu*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Menu_isEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Menu_isEnabled'", nullptr); return 0; } bool ret = cobj->isEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Menu:isEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Menu_isEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Menu_alignItemsHorizontallyWithPadding(lua_State* tolua_S) { int argc = 0; cocos2d::Menu* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Menu",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Menu*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Menu_alignItemsHorizontallyWithPadding'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Menu:alignItemsHorizontallyWithPadding"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Menu_alignItemsHorizontallyWithPadding'", nullptr); return 0; } cobj->alignItemsHorizontallyWithPadding(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Menu:alignItemsHorizontallyWithPadding",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Menu_alignItemsHorizontallyWithPadding'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Menu_alignItemsVerticallyWithPadding(lua_State* tolua_S) { int argc = 0; cocos2d::Menu* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Menu",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Menu*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Menu_alignItemsVerticallyWithPadding'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Menu:alignItemsVerticallyWithPadding"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Menu_alignItemsVerticallyWithPadding'", nullptr); return 0; } cobj->alignItemsVerticallyWithPadding(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Menu:alignItemsVerticallyWithPadding",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Menu_alignItemsVerticallyWithPadding'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Menu_alignItemsHorizontally(lua_State* tolua_S) { int argc = 0; cocos2d::Menu* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Menu",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Menu*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Menu_alignItemsHorizontally'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Menu_alignItemsHorizontally'", nullptr); return 0; } cobj->alignItemsHorizontally(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Menu:alignItemsHorizontally",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Menu_alignItemsHorizontally'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Menu_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Menu* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Menu_constructor'", nullptr); return 0; } cobj = new cocos2d::Menu(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Menu"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Menu:Menu",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Menu_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Menu_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Menu)"); return 0; } int lua_register_cocos2dx_Menu(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Menu"); tolua_cclass(tolua_S,"Menu","cc.Menu","cc.Layer",nullptr); tolua_beginmodule(tolua_S,"Menu"); tolua_function(tolua_S,"new",lua_cocos2dx_Menu_constructor); tolua_function(tolua_S,"initWithArray",lua_cocos2dx_Menu_initWithArray); tolua_function(tolua_S,"setEnabled",lua_cocos2dx_Menu_setEnabled); tolua_function(tolua_S,"alignItemsVertically",lua_cocos2dx_Menu_alignItemsVertically); tolua_function(tolua_S,"isEnabled",lua_cocos2dx_Menu_isEnabled); tolua_function(tolua_S,"alignItemsHorizontallyWithPadding",lua_cocos2dx_Menu_alignItemsHorizontallyWithPadding); tolua_function(tolua_S,"alignItemsVerticallyWithPadding",lua_cocos2dx_Menu_alignItemsVerticallyWithPadding); tolua_function(tolua_S,"alignItemsHorizontally",lua_cocos2dx_Menu_alignItemsHorizontally); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Menu).name(); g_luaType[typeName] = "cc.Menu"; g_typeCast["Menu"] = "cc.Menu"; return 1; } int lua_cocos2dx_MotionStreak_reset(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_reset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_reset'", nullptr); return 0; } cobj->reset(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:reset",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_reset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.MotionStreak:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_tintWithColor(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_tintWithColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color3B arg0; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.MotionStreak:tintWithColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_tintWithColor'", nullptr); return 0; } cobj->tintWithColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:tintWithColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_tintWithColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.MotionStreak:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_setStartingPositionInitialized(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_setStartingPositionInitialized'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.MotionStreak:setStartingPositionInitialized"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_setStartingPositionInitialized'", nullptr); return 0; } cobj->setStartingPositionInitialized(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:setStartingPositionInitialized",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_setStartingPositionInitialized'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_isStartingPositionInitialized(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_isStartingPositionInitialized'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_isStartingPositionInitialized'", nullptr); return 0; } bool ret = cobj->isStartingPositionInitialized(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:isStartingPositionInitialized",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_isStartingPositionInitialized'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_isFastMode(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_isFastMode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_isFastMode'", nullptr); return 0; } bool ret = cobj->isFastMode(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:isFastMode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_isFastMode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_getStroke(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_getStroke'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_getStroke'", nullptr); return 0; } double ret = cobj->getStroke(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:getStroke",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_getStroke'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_initWithFade(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_initWithFade'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak:initWithFade"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.MotionStreak:initWithFade"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.MotionStreak:initWithFade"); if (!ok) { break; } cocos2d::Color3B arg3; ok &= luaval_to_color3b(tolua_S, 5, &arg3, "cc.MotionStreak:initWithFade"); if (!ok) { break; } cocos2d::Texture2D* arg4; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 6, "cc.Texture2D",&arg4, "cc.MotionStreak:initWithFade"); if (!ok) { break; } bool ret = cobj->initWithFade(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak:initWithFade"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.MotionStreak:initWithFade"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.MotionStreak:initWithFade"); if (!ok) { break; } cocos2d::Color3B arg3; ok &= luaval_to_color3b(tolua_S, 5, &arg3, "cc.MotionStreak:initWithFade"); if (!ok) { break; } std::string arg4; ok &= luaval_to_std_string(tolua_S, 6,&arg4, "cc.MotionStreak:initWithFade"); if (!ok) { break; } bool ret = cobj->initWithFade(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:initWithFade",argc, 5); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_initWithFade'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_setFastMode(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_setFastMode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.MotionStreak:setFastMode"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_setFastMode'", nullptr); return 0; } cobj->setFastMode(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:setFastMode",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_setFastMode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_setStroke(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak_setStroke'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak:setStroke"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_setStroke'", nullptr); return 0; } cobj->setStroke(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:setStroke",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_setStroke'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.MotionStreak",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.MotionStreak:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.MotionStreak:create"); if (!ok) { break; } cocos2d::Color3B arg3; ok &= luaval_to_color3b(tolua_S, 5, &arg3, "cc.MotionStreak:create"); if (!ok) { break; } cocos2d::Texture2D* arg4; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 6, "cc.Texture2D",&arg4, "cc.MotionStreak:create"); if (!ok) { break; } cocos2d::MotionStreak* ret = cocos2d::MotionStreak::create(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::MotionStreak>(tolua_S, "cc.MotionStreak",(cocos2d::MotionStreak*)ret); return 1; } } while (0); ok = true; do { if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.MotionStreak:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.MotionStreak:create"); if (!ok) { break; } cocos2d::Color3B arg3; ok &= luaval_to_color3b(tolua_S, 5, &arg3, "cc.MotionStreak:create"); if (!ok) { break; } std::string arg4; ok &= luaval_to_std_string(tolua_S, 6,&arg4, "cc.MotionStreak:create"); if (!ok) { break; } cocos2d::MotionStreak* ret = cocos2d::MotionStreak::create(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::MotionStreak>(tolua_S, "cc.MotionStreak",(cocos2d::MotionStreak*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.MotionStreak:create",argc, 5); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak_constructor'", nullptr); return 0; } cobj = new cocos2d::MotionStreak(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MotionStreak"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak:MotionStreak",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MotionStreak_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MotionStreak)"); return 0; } int lua_register_cocos2dx_MotionStreak(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MotionStreak"); tolua_cclass(tolua_S,"MotionStreak","cc.MotionStreak","cc.Node",nullptr); tolua_beginmodule(tolua_S,"MotionStreak"); tolua_function(tolua_S,"new",lua_cocos2dx_MotionStreak_constructor); tolua_function(tolua_S,"reset",lua_cocos2dx_MotionStreak_reset); tolua_function(tolua_S,"setTexture",lua_cocos2dx_MotionStreak_setTexture); tolua_function(tolua_S,"getTexture",lua_cocos2dx_MotionStreak_getTexture); tolua_function(tolua_S,"tintWithColor",lua_cocos2dx_MotionStreak_tintWithColor); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_MotionStreak_setBlendFunc); tolua_function(tolua_S,"setStartingPositionInitialized",lua_cocos2dx_MotionStreak_setStartingPositionInitialized); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_MotionStreak_getBlendFunc); tolua_function(tolua_S,"isStartingPositionInitialized",lua_cocos2dx_MotionStreak_isStartingPositionInitialized); tolua_function(tolua_S,"isFastMode",lua_cocos2dx_MotionStreak_isFastMode); tolua_function(tolua_S,"getStroke",lua_cocos2dx_MotionStreak_getStroke); tolua_function(tolua_S,"initWithFade",lua_cocos2dx_MotionStreak_initWithFade); tolua_function(tolua_S,"setFastMode",lua_cocos2dx_MotionStreak_setFastMode); tolua_function(tolua_S,"setStroke",lua_cocos2dx_MotionStreak_setStroke); tolua_function(tolua_S,"create", lua_cocos2dx_MotionStreak_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MotionStreak).name(); g_luaType[typeName] = "cc.MotionStreak"; g_typeCast["MotionStreak"] = "cc.MotionStreak"; return 1; } int lua_cocos2dx_NodeGrid_setGridRect(lua_State* tolua_S) { int argc = 0; cocos2d::NodeGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.NodeGrid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::NodeGrid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_NodeGrid_setGridRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.NodeGrid:setGridRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_NodeGrid_setGridRect'", nullptr); return 0; } cobj->setGridRect(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.NodeGrid:setGridRect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_NodeGrid_setGridRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_NodeGrid_setTarget(lua_State* tolua_S) { int argc = 0; cocos2d::NodeGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.NodeGrid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::NodeGrid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_NodeGrid_setTarget'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.NodeGrid:setTarget"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_NodeGrid_setTarget'", nullptr); return 0; } cobj->setTarget(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.NodeGrid:setTarget",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_NodeGrid_setTarget'.",&tolua_err); #endif return 0; } int lua_cocos2dx_NodeGrid_setGrid(lua_State* tolua_S) { int argc = 0; cocos2d::NodeGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.NodeGrid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::NodeGrid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_NodeGrid_setGrid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::GridBase* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GridBase>(tolua_S, 2, "cc.GridBase",&arg0, "cc.NodeGrid:setGrid"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_NodeGrid_setGrid'", nullptr); return 0; } cobj->setGrid(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.NodeGrid:setGrid",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_NodeGrid_setGrid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_NodeGrid_getGrid(lua_State* tolua_S) { int argc = 0; cocos2d::NodeGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.NodeGrid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::NodeGrid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_NodeGrid_getGrid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { const cocos2d::GridBase* ret = cobj->getGrid(); object_to_luaval<cocos2d::GridBase>(tolua_S, "cc.GridBase",(cocos2d::GridBase*)ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { cocos2d::GridBase* ret = cobj->getGrid(); object_to_luaval<cocos2d::GridBase>(tolua_S, "cc.GridBase",(cocos2d::GridBase*)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.NodeGrid:getGrid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_NodeGrid_getGrid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_NodeGrid_getGridRect(lua_State* tolua_S) { int argc = 0; cocos2d::NodeGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.NodeGrid",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::NodeGrid*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_NodeGrid_getGridRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_NodeGrid_getGridRect'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getGridRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.NodeGrid:getGridRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_NodeGrid_getGridRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_NodeGrid_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.NodeGrid",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.NodeGrid:create"); if (!ok) { break; } cocos2d::NodeGrid* ret = cocos2d::NodeGrid::create(arg0); object_to_luaval<cocos2d::NodeGrid>(tolua_S, "cc.NodeGrid",(cocos2d::NodeGrid*)ret); return 1; } } while (0); ok = true; do { if (argc == 0) { cocos2d::NodeGrid* ret = cocos2d::NodeGrid::create(); object_to_luaval<cocos2d::NodeGrid>(tolua_S, "cc.NodeGrid",(cocos2d::NodeGrid*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.NodeGrid:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_NodeGrid_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_NodeGrid_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::NodeGrid* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_NodeGrid_constructor'", nullptr); return 0; } cobj = new cocos2d::NodeGrid(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.NodeGrid"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.NodeGrid:NodeGrid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_NodeGrid_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_NodeGrid_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (NodeGrid)"); return 0; } int lua_register_cocos2dx_NodeGrid(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.NodeGrid"); tolua_cclass(tolua_S,"NodeGrid","cc.NodeGrid","cc.Node",nullptr); tolua_beginmodule(tolua_S,"NodeGrid"); tolua_function(tolua_S,"new",lua_cocos2dx_NodeGrid_constructor); tolua_function(tolua_S,"setGridRect",lua_cocos2dx_NodeGrid_setGridRect); tolua_function(tolua_S,"setTarget",lua_cocos2dx_NodeGrid_setTarget); tolua_function(tolua_S,"setGrid",lua_cocos2dx_NodeGrid_setGrid); tolua_function(tolua_S,"getGrid",lua_cocos2dx_NodeGrid_getGrid); tolua_function(tolua_S,"getGridRect",lua_cocos2dx_NodeGrid_getGridRect); tolua_function(tolua_S,"create", lua_cocos2dx_NodeGrid_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::NodeGrid).name(); g_luaType[typeName] = "cc.NodeGrid"; g_typeCast["NodeGrid"] = "cc.NodeGrid"; return 1; } int lua_cocos2dx_ParticleBatchNode_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.ParticleBatchNode:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_initWithTexture(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_initWithTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; int arg1; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.ParticleBatchNode:initWithTexture"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ParticleBatchNode:initWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_initWithTexture'", nullptr); return 0; } bool ret = cobj->initWithTexture(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:initWithTexture",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_initWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_disableParticle(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_disableParticle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleBatchNode:disableParticle"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_disableParticle'", nullptr); return 0; } cobj->disableParticle(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:disableParticle",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_disableParticle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_setTextureAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_setTextureAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TextureAtlas* arg0 = nullptr; ok &= luaval_to_object<cocos2d::TextureAtlas>(tolua_S, 2, "cc.TextureAtlas",&arg0, "cc.ParticleBatchNode:setTextureAtlas"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_setTextureAtlas'", nullptr); return 0; } cobj->setTextureAtlas(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:setTextureAtlas",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_setTextureAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_initWithFile(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_initWithFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; int arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.ParticleBatchNode:initWithFile"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ParticleBatchNode:initWithFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_initWithFile'", nullptr); return 0; } bool ret = cobj->initWithFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:initWithFile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_initWithFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.ParticleBatchNode:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_removeAllChildrenWithCleanup(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_removeAllChildrenWithCleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ParticleBatchNode:removeAllChildrenWithCleanup"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_removeAllChildrenWithCleanup'", nullptr); return 0; } cobj->removeAllChildrenWithCleanup(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:removeAllChildrenWithCleanup",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_removeAllChildrenWithCleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_getTextureAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_getTextureAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_getTextureAtlas'", nullptr); return 0; } cocos2d::TextureAtlas* ret = cobj->getTextureAtlas(); object_to_luaval<cocos2d::TextureAtlas>(tolua_S, "cc.TextureAtlas",(cocos2d::TextureAtlas*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:getTextureAtlas",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_getTextureAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_insertChild(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_insertChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::ParticleSystem* arg0 = nullptr; int arg1; ok &= luaval_to_object<cocos2d::ParticleSystem>(tolua_S, 2, "cc.ParticleSystem",&arg0, "cc.ParticleBatchNode:insertChild"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ParticleBatchNode:insertChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_insertChild'", nullptr); return 0; } cobj->insertChild(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:insertChild",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_insertChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_removeChildAtIndex(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleBatchNode_removeChildAtIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { int arg0; bool arg1; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleBatchNode:removeChildAtIndex"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.ParticleBatchNode:removeChildAtIndex"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_removeChildAtIndex'", nullptr); return 0; } cobj->removeChildAtIndex(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:removeChildAtIndex",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_removeChildAtIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.ParticleBatchNode:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_create'", nullptr); return 0; } cocos2d::ParticleBatchNode* ret = cocos2d::ParticleBatchNode::create(arg0); object_to_luaval<cocos2d::ParticleBatchNode>(tolua_S, "cc.ParticleBatchNode",(cocos2d::ParticleBatchNode*)ret); return 1; } if (argc == 2) { std::string arg0; int arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.ParticleBatchNode:create"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ParticleBatchNode:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_create'", nullptr); return 0; } cocos2d::ParticleBatchNode* ret = cocos2d::ParticleBatchNode::create(arg0, arg1); object_to_luaval<cocos2d::ParticleBatchNode>(tolua_S, "cc.ParticleBatchNode",(cocos2d::ParticleBatchNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleBatchNode:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_createWithTexture(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleBatchNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.ParticleBatchNode:createWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_createWithTexture'", nullptr); return 0; } cocos2d::ParticleBatchNode* ret = cocos2d::ParticleBatchNode::createWithTexture(arg0); object_to_luaval<cocos2d::ParticleBatchNode>(tolua_S, "cc.ParticleBatchNode",(cocos2d::ParticleBatchNode*)ret); return 1; } if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; int arg1; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.ParticleBatchNode:createWithTexture"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ParticleBatchNode:createWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_createWithTexture'", nullptr); return 0; } cocos2d::ParticleBatchNode* ret = cocos2d::ParticleBatchNode::createWithTexture(arg0, arg1); object_to_luaval<cocos2d::ParticleBatchNode>(tolua_S, "cc.ParticleBatchNode",(cocos2d::ParticleBatchNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleBatchNode:createWithTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_createWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleBatchNode_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleBatchNode_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleBatchNode(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleBatchNode"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleBatchNode:ParticleBatchNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleBatchNode_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleBatchNode_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleBatchNode)"); return 0; } int lua_register_cocos2dx_ParticleBatchNode(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleBatchNode"); tolua_cclass(tolua_S,"ParticleBatchNode","cc.ParticleBatchNode","cc.Node",nullptr); tolua_beginmodule(tolua_S,"ParticleBatchNode"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleBatchNode_constructor); tolua_function(tolua_S,"setTexture",lua_cocos2dx_ParticleBatchNode_setTexture); tolua_function(tolua_S,"initWithTexture",lua_cocos2dx_ParticleBatchNode_initWithTexture); tolua_function(tolua_S,"disableParticle",lua_cocos2dx_ParticleBatchNode_disableParticle); tolua_function(tolua_S,"getTexture",lua_cocos2dx_ParticleBatchNode_getTexture); tolua_function(tolua_S,"setTextureAtlas",lua_cocos2dx_ParticleBatchNode_setTextureAtlas); tolua_function(tolua_S,"initWithFile",lua_cocos2dx_ParticleBatchNode_initWithFile); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_ParticleBatchNode_setBlendFunc); tolua_function(tolua_S,"removeAllChildrenWithCleanup",lua_cocos2dx_ParticleBatchNode_removeAllChildrenWithCleanup); tolua_function(tolua_S,"getTextureAtlas",lua_cocos2dx_ParticleBatchNode_getTextureAtlas); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_ParticleBatchNode_getBlendFunc); tolua_function(tolua_S,"insertChild",lua_cocos2dx_ParticleBatchNode_insertChild); tolua_function(tolua_S,"removeChildAtIndex",lua_cocos2dx_ParticleBatchNode_removeChildAtIndex); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleBatchNode_create); tolua_function(tolua_S,"createWithTexture", lua_cocos2dx_ParticleBatchNode_createWithTexture); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleBatchNode).name(); g_luaType[typeName] = "cc.ParticleBatchNode"; g_typeCast["ParticleBatchNode"] = "cc.ParticleBatchNode"; return 1; } int lua_cocos2dx_ParticleData_release(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleData* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleData",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleData*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleData_release'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleData_release'", nullptr); return 0; } cobj->release(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleData:release",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleData_release'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleData_getMaxCount(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleData* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleData",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleData*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleData_getMaxCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleData_getMaxCount'", nullptr); return 0; } unsigned int ret = cobj->getMaxCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleData:getMaxCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleData_getMaxCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleData_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleData* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleData",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleData*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleData_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleData:init"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleData_init'", nullptr); return 0; } bool ret = cobj->init(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleData:init",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleData_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleData_copyParticle(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleData* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleData",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleData*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleData_copyParticle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { int arg0; int arg1; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleData:copyParticle"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ParticleData:copyParticle"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleData_copyParticle'", nullptr); return 0; } cobj->copyParticle(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleData:copyParticle",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleData_copyParticle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleData_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleData* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleData_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleData(); tolua_pushusertype(tolua_S,(void*)cobj,"cc.ParticleData"); tolua_register_gc(tolua_S,lua_gettop(tolua_S)); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleData:ParticleData",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleData_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleData_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleData)"); return 0; } int lua_register_cocos2dx_ParticleData(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleData"); tolua_cclass(tolua_S,"ParticleData","cc.ParticleData","",nullptr); tolua_beginmodule(tolua_S,"ParticleData"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleData_constructor); tolua_function(tolua_S,"release",lua_cocos2dx_ParticleData_release); tolua_function(tolua_S,"getMaxCount",lua_cocos2dx_ParticleData_getMaxCount); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleData_init); tolua_function(tolua_S,"copyParticle",lua_cocos2dx_ParticleData_copyParticle); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleData).name(); g_luaType[typeName] = "cc.ParticleData"; g_typeCast["ParticleData"] = "cc.ParticleData"; return 1; } int lua_cocos2dx_ParticleSystem_getStartSizeVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getStartSizeVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getStartSizeVar'", nullptr); return 0; } double ret = cobj->getStartSizeVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getStartSizeVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getStartSizeVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_isFull(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_isFull'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_isFull'", nullptr); return 0; } bool ret = cobj->isFull(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:isFull",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_isFull'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getBatchNode(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getBatchNode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getBatchNode'", nullptr); return 0; } cocos2d::ParticleBatchNode* ret = cobj->getBatchNode(); object_to_luaval<cocos2d::ParticleBatchNode>(tolua_S, "cc.ParticleBatchNode",(cocos2d::ParticleBatchNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getBatchNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getBatchNode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getStartColor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getStartColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getStartColor'", nullptr); return 0; } const cocos2d::Color4F& ret = cobj->getStartColor(); color4f_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getStartColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getStartColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getPositionType(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getPositionType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getPositionType'", nullptr); return 0; } int ret = (int)cobj->getPositionType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getPositionType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getPositionType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setPosVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setPosVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.ParticleSystem:setPosVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setPosVar'", nullptr); return 0; } cobj->setPosVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setPosVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setPosVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEndSpin(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEndSpin'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEndSpin'", nullptr); return 0; } double ret = cobj->getEndSpin(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEndSpin",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEndSpin'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setRotatePerSecondVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setRotatePerSecondVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setRotatePerSecondVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setRotatePerSecondVar'", nullptr); return 0; } cobj->setRotatePerSecondVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setRotatePerSecondVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setRotatePerSecondVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getStartSpinVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getStartSpinVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getStartSpinVar'", nullptr); return 0; } double ret = cobj->getStartSpinVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getStartSpinVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getStartSpinVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getRadialAccelVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getRadialAccelVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getRadialAccelVar'", nullptr); return 0; } double ret = cobj->getRadialAccelVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getRadialAccelVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getRadialAccelVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEndSizeVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEndSizeVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEndSizeVar'", nullptr); return 0; } double ret = cobj->getEndSizeVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEndSizeVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEndSizeVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setTangentialAccel(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setTangentialAccel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setTangentialAccel"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setTangentialAccel'", nullptr); return 0; } cobj->setTangentialAccel(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setTangentialAccel",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setTangentialAccel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getRadialAccel(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getRadialAccel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getRadialAccel'", nullptr); return 0; } double ret = cobj->getRadialAccel(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getRadialAccel",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getRadialAccel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setStartRadius(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setStartRadius'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setStartRadius"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setStartRadius'", nullptr); return 0; } cobj->setStartRadius(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setStartRadius",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setStartRadius'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setRotatePerSecond(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setRotatePerSecond'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setRotatePerSecond"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setRotatePerSecond'", nullptr); return 0; } cobj->setRotatePerSecond(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setRotatePerSecond",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setRotatePerSecond'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEndSize(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEndSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setEndSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEndSize'", nullptr); return 0; } cobj->setEndSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEndSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEndSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getGravity(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getGravity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getGravity'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getGravity(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getGravity",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getGravity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_resumeEmissions(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_resumeEmissions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_resumeEmissions'", nullptr); return 0; } cobj->resumeEmissions(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:resumeEmissions",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_resumeEmissions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getTangentialAccel(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getTangentialAccel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getTangentialAccel'", nullptr); return 0; } double ret = cobj->getTangentialAccel(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getTangentialAccel",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getTangentialAccel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEndRadius(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEndRadius'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setEndRadius"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEndRadius'", nullptr); return 0; } cobj->setEndRadius(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEndRadius",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEndRadius'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getSpeed(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getSpeed'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getSpeed'", nullptr); return 0; } double ret = cobj->getSpeed(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getSpeed",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getSpeed'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_pauseEmissions(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_pauseEmissions'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_pauseEmissions'", nullptr); return 0; } cobj->pauseEmissions(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:pauseEmissions",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_pauseEmissions'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getAngle(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getAngle'", nullptr); return 0; } double ret = cobj->getAngle(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getAngle",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEndColor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEndColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4F arg0; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.ParticleSystem:setEndColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEndColor'", nullptr); return 0; } cobj->setEndColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEndColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEndColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setStartSpin(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setStartSpin'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setStartSpin"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setStartSpin'", nullptr); return 0; } cobj->setStartSpin(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setStartSpin",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setStartSpin'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setDuration'", nullptr); return 0; } cobj->setDuration(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setDuration",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSystem:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_addParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_addParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSystem:addParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_addParticles'", nullptr); return 0; } cobj->addParticles(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:addParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_addParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.ParticleSystem:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getPosVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getPosVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getPosVar'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getPosVar(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getPosVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getPosVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_updateWithNoTime(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_updateWithNoTime'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_updateWithNoTime'", nullptr); return 0; } cobj->updateWithNoTime(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:updateWithNoTime",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_updateWithNoTime'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_isBlendAdditive(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_isBlendAdditive'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_isBlendAdditive'", nullptr); return 0; } bool ret = cobj->isBlendAdditive(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:isBlendAdditive",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_isBlendAdditive'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getSpeedVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getSpeedVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getSpeedVar'", nullptr); return 0; } double ret = cobj->getSpeedVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getSpeedVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getSpeedVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setPositionType(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setPositionType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ParticleSystem::PositionType arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSystem:setPositionType"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setPositionType'", nullptr); return 0; } cobj->setPositionType(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setPositionType",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setPositionType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_stopSystem(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_stopSystem'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_stopSystem'", nullptr); return 0; } cobj->stopSystem(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:stopSystem",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_stopSystem'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getSourcePosition(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getSourcePosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getSourcePosition'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getSourcePosition(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getSourcePosition",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getSourcePosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setLifeVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setLifeVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setLifeVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setLifeVar'", nullptr); return 0; } cobj->setLifeVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setLifeVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setLifeVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSystem:setTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setTotalParticles'", nullptr); return 0; } cobj->setTotalParticles(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEndColorVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEndColorVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4F arg0; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.ParticleSystem:setEndColorVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEndColorVar'", nullptr); return 0; } cobj->setEndColorVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEndColorVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEndColorVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getAtlasIndex(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getAtlasIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getAtlasIndex'", nullptr); return 0; } int ret = cobj->getAtlasIndex(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getAtlasIndex",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getAtlasIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getStartSize(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getStartSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getStartSize'", nullptr); return 0; } double ret = cobj->getStartSize(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getStartSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getStartSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setStartSpinVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setStartSpinVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setStartSpinVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setStartSpinVar'", nullptr); return 0; } cobj->setStartSpinVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setStartSpinVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setStartSpinVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_resetSystem(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_resetSystem'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_resetSystem'", nullptr); return 0; } cobj->resetSystem(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:resetSystem",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_resetSystem'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setAtlasIndex(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setAtlasIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSystem:setAtlasIndex"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setAtlasIndex'", nullptr); return 0; } cobj->setAtlasIndex(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setAtlasIndex",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setAtlasIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setTangentialAccelVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setTangentialAccelVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setTangentialAccelVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setTangentialAccelVar'", nullptr); return 0; } cobj->setTangentialAccelVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setTangentialAccelVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setTangentialAccelVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEndRadiusVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEndRadiusVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setEndRadiusVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEndRadiusVar'", nullptr); return 0; } cobj->setEndRadiusVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEndRadiusVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEndRadiusVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEndRadius(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEndRadius'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEndRadius'", nullptr); return 0; } double ret = cobj->getEndRadius(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEndRadius",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEndRadius'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_isActive(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_isActive'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_isActive'", nullptr); return 0; } bool ret = cobj->isActive(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:isActive",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_isActive'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setRadialAccelVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setRadialAccelVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setRadialAccelVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setRadialAccelVar'", nullptr); return 0; } cobj->setRadialAccelVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setRadialAccelVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setRadialAccelVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setStartSize(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setStartSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setStartSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setStartSize'", nullptr); return 0; } cobj->setStartSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setStartSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setStartSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setSpeed(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setSpeed'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setSpeed"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setSpeed'", nullptr); return 0; } cobj->setSpeed(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setSpeed",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setSpeed'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getStartSpin(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getStartSpin'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getStartSpin'", nullptr); return 0; } double ret = cobj->getStartSpin(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getStartSpin",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getStartSpin'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getResourceFile(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getResourceFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getResourceFile'", nullptr); return 0; } const std::string& ret = cobj->getResourceFile(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getResourceFile",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getResourceFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getRotatePerSecond(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getRotatePerSecond'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getRotatePerSecond'", nullptr); return 0; } double ret = cobj->getRotatePerSecond(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getRotatePerSecond",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getRotatePerSecond'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEmitterMode(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEmitterMode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ParticleSystem::Mode arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSystem:setEmitterMode"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEmitterMode'", nullptr); return 0; } cobj->setEmitterMode(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEmitterMode",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEmitterMode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getDuration(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getDuration'", nullptr); return 0; } double ret = cobj->getDuration(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getDuration",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setSourcePosition(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setSourcePosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.ParticleSystem:setSourcePosition"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setSourcePosition'", nullptr); return 0; } cobj->setSourcePosition(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setSourcePosition",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setSourcePosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_stop(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_stop'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_stop'", nullptr); return 0; } cobj->stop(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:stop",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_stop'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_updateParticleQuads(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_updateParticleQuads'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_updateParticleQuads'", nullptr); return 0; } cobj->updateParticleQuads(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:updateParticleQuads",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_updateParticleQuads'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEndSpinVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEndSpinVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEndSpinVar'", nullptr); return 0; } double ret = cobj->getEndSpinVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEndSpinVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEndSpinVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setBlendAdditive(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setBlendAdditive'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ParticleSystem:setBlendAdditive"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setBlendAdditive'", nullptr); return 0; } cobj->setBlendAdditive(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setBlendAdditive",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setBlendAdditive'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setLife(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setLife'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setLife"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setLife'", nullptr); return 0; } cobj->setLife(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setLife",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setLife'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setAngleVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setAngleVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setAngleVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setAngleVar'", nullptr); return 0; } cobj->setAngleVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setAngleVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setAngleVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setRotationIsDir(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setRotationIsDir'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ParticleSystem:setRotationIsDir"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setRotationIsDir'", nullptr); return 0; } cobj->setRotationIsDir(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setRotationIsDir",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setRotationIsDir'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_start(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_start'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_start'", nullptr); return 0; } cobj->start(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:start",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_start'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEndSizeVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEndSizeVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setEndSizeVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEndSizeVar'", nullptr); return 0; } cobj->setEndSizeVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEndSizeVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEndSizeVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setAngle(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setAngle"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setAngle'", nullptr); return 0; } cobj->setAngle(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setAngle",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setBatchNode(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setBatchNode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ParticleBatchNode* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ParticleBatchNode>(tolua_S, 2, "cc.ParticleBatchNode",&arg0, "cc.ParticleSystem:setBatchNode"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setBatchNode'", nullptr); return 0; } cobj->setBatchNode(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setBatchNode",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setBatchNode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getTangentialAccelVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getTangentialAccelVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getTangentialAccelVar'", nullptr); return 0; } double ret = cobj->getTangentialAccelVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getTangentialAccelVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getTangentialAccelVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEmitterMode(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEmitterMode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEmitterMode'", nullptr); return 0; } int ret = (int)cobj->getEmitterMode(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEmitterMode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEmitterMode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEndSpinVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEndSpinVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setEndSpinVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEndSpinVar'", nullptr); return 0; } cobj->setEndSpinVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEndSpinVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEndSpinVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_initWithFile(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_initWithFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.ParticleSystem:initWithFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_initWithFile'", nullptr); return 0; } bool ret = cobj->initWithFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:initWithFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_initWithFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getAngleVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getAngleVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getAngleVar'", nullptr); return 0; } double ret = cobj->getAngleVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getAngleVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getAngleVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setStartColor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setStartColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4F arg0; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.ParticleSystem:setStartColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setStartColor'", nullptr); return 0; } cobj->setStartColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setStartColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setStartColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getRotatePerSecondVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getRotatePerSecondVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getRotatePerSecondVar'", nullptr); return 0; } double ret = cobj->getRotatePerSecondVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getRotatePerSecondVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getRotatePerSecondVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEndSize(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEndSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEndSize'", nullptr); return 0; } double ret = cobj->getEndSize(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEndSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEndSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getLife(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getLife'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getLife'", nullptr); return 0; } double ret = cobj->getLife(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getLife",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getLife'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_isPaused(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_isPaused'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_isPaused'", nullptr); return 0; } bool ret = cobj->isPaused(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:isPaused",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_isPaused'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setSpeedVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setSpeedVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setSpeedVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setSpeedVar'", nullptr); return 0; } cobj->setSpeedVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setSpeedVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setSpeedVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setAutoRemoveOnFinish(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setAutoRemoveOnFinish'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ParticleSystem:setAutoRemoveOnFinish"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setAutoRemoveOnFinish'", nullptr); return 0; } cobj->setAutoRemoveOnFinish(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setAutoRemoveOnFinish",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setAutoRemoveOnFinish'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setGravity(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setGravity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.ParticleSystem:setGravity"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setGravity'", nullptr); return 0; } cobj->setGravity(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setGravity",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setGravity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_postStep(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_postStep'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_postStep'", nullptr); return 0; } cobj->postStep(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:postStep",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_postStep'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEmissionRate(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEmissionRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setEmissionRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEmissionRate'", nullptr); return 0; } cobj->setEmissionRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEmissionRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEmissionRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEndColorVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEndColorVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEndColorVar'", nullptr); return 0; } const cocos2d::Color4F& ret = cobj->getEndColorVar(); color4f_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEndColorVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEndColorVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getRotationIsDir(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getRotationIsDir'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getRotationIsDir'", nullptr); return 0; } bool ret = cobj->getRotationIsDir(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getRotationIsDir",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getRotationIsDir'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEmissionRate(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEmissionRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEmissionRate'", nullptr); return 0; } double ret = cobj->getEmissionRate(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEmissionRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEmissionRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEndColor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEndColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEndColor'", nullptr); return 0; } const cocos2d::Color4F& ret = cobj->getEndColor(); color4f_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEndColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEndColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getLifeVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getLifeVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getLifeVar'", nullptr); return 0; } double ret = cobj->getLifeVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getLifeVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getLifeVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setStartSizeVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setStartSizeVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setStartSizeVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setStartSizeVar'", nullptr); return 0; } cobj->setStartSizeVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setStartSizeVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setStartSizeVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getStartRadius(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getStartRadius'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getStartRadius'", nullptr); return 0; } double ret = cobj->getStartRadius(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getStartRadius",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getStartRadius'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getParticleCount(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getParticleCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getParticleCount'", nullptr); return 0; } unsigned int ret = cobj->getParticleCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getParticleCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getParticleCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getStartRadiusVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getStartRadiusVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getStartRadiusVar'", nullptr); return 0; } double ret = cobj->getStartRadiusVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getStartRadiusVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getStartRadiusVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setStartColorVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setStartColorVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4F arg0; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.ParticleSystem:setStartColorVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setStartColorVar'", nullptr); return 0; } cobj->setStartColorVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setStartColorVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setStartColorVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setEndSpin(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setEndSpin'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setEndSpin"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setEndSpin'", nullptr); return 0; } cobj->setEndSpin(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setEndSpin",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setEndSpin'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setRadialAccel(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setRadialAccel'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setRadialAccel"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setRadialAccel'", nullptr); return 0; } cobj->setRadialAccel(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setRadialAccel",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setRadialAccel'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_initWithDictionary(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_initWithDictionary'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.ParticleSystem:initWithDictionary"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.ParticleSystem:initWithDictionary"); if (!ok) { break; } bool ret = cobj->initWithDictionary(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.ParticleSystem:initWithDictionary"); if (!ok) { break; } bool ret = cobj->initWithDictionary(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:initWithDictionary",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_initWithDictionary'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_isAutoRemoveOnFinish(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_isAutoRemoveOnFinish'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_isAutoRemoveOnFinish'", nullptr); return 0; } bool ret = cobj->isAutoRemoveOnFinish(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:isAutoRemoveOnFinish",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_isAutoRemoveOnFinish'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getTotalParticles'", nullptr); return 0; } int ret = cobj->getTotalParticles(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getTotalParticles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setStartRadiusVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setStartRadiusVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ParticleSystem:setStartRadiusVar"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setStartRadiusVar'", nullptr); return 0; } cobj->setStartRadiusVar(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setStartRadiusVar",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setStartRadiusVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.ParticleSystem:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getEndRadiusVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getEndRadiusVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getEndRadiusVar'", nullptr); return 0; } double ret = cobj->getEndRadiusVar(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getEndRadiusVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getEndRadiusVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_getStartColorVar(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystem*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystem_getStartColorVar'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_getStartColorVar'", nullptr); return 0; } const cocos2d::Color4F& ret = cobj->getStartColorVar(); color4f_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:getStartColorVar",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_getStartColorVar'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.ParticleSystem:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_create'", nullptr); return 0; } cocos2d::ParticleSystem* ret = cocos2d::ParticleSystem::create(arg0); object_to_luaval<cocos2d::ParticleSystem>(tolua_S, "cc.ParticleSystem",(cocos2d::ParticleSystem*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSystem:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSystem",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSystem:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleSystem* ret = cocos2d::ParticleSystem::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleSystem>(tolua_S, "cc.ParticleSystem",(cocos2d::ParticleSystem*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSystem:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystem_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystem* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystem_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleSystem(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleSystem"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystem:ParticleSystem",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystem_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleSystem_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleSystem)"); return 0; } int lua_register_cocos2dx_ParticleSystem(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleSystem"); tolua_cclass(tolua_S,"ParticleSystem","cc.ParticleSystem","cc.Node",nullptr); tolua_beginmodule(tolua_S,"ParticleSystem"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleSystem_constructor); tolua_function(tolua_S,"getStartSizeVar",lua_cocos2dx_ParticleSystem_getStartSizeVar); tolua_function(tolua_S,"getTexture",lua_cocos2dx_ParticleSystem_getTexture); tolua_function(tolua_S,"isFull",lua_cocos2dx_ParticleSystem_isFull); tolua_function(tolua_S,"getBatchNode",lua_cocos2dx_ParticleSystem_getBatchNode); tolua_function(tolua_S,"getStartColor",lua_cocos2dx_ParticleSystem_getStartColor); tolua_function(tolua_S,"getPositionType",lua_cocos2dx_ParticleSystem_getPositionType); tolua_function(tolua_S,"setPosVar",lua_cocos2dx_ParticleSystem_setPosVar); tolua_function(tolua_S,"getEndSpin",lua_cocos2dx_ParticleSystem_getEndSpin); tolua_function(tolua_S,"setRotatePerSecondVar",lua_cocos2dx_ParticleSystem_setRotatePerSecondVar); tolua_function(tolua_S,"getStartSpinVar",lua_cocos2dx_ParticleSystem_getStartSpinVar); tolua_function(tolua_S,"getRadialAccelVar",lua_cocos2dx_ParticleSystem_getRadialAccelVar); tolua_function(tolua_S,"getEndSizeVar",lua_cocos2dx_ParticleSystem_getEndSizeVar); tolua_function(tolua_S,"setTangentialAccel",lua_cocos2dx_ParticleSystem_setTangentialAccel); tolua_function(tolua_S,"getRadialAccel",lua_cocos2dx_ParticleSystem_getRadialAccel); tolua_function(tolua_S,"setStartRadius",lua_cocos2dx_ParticleSystem_setStartRadius); tolua_function(tolua_S,"setRotatePerSecond",lua_cocos2dx_ParticleSystem_setRotatePerSecond); tolua_function(tolua_S,"setEndSize",lua_cocos2dx_ParticleSystem_setEndSize); tolua_function(tolua_S,"getGravity",lua_cocos2dx_ParticleSystem_getGravity); tolua_function(tolua_S,"resumeEmissions",lua_cocos2dx_ParticleSystem_resumeEmissions); tolua_function(tolua_S,"getTangentialAccel",lua_cocos2dx_ParticleSystem_getTangentialAccel); tolua_function(tolua_S,"setEndRadius",lua_cocos2dx_ParticleSystem_setEndRadius); tolua_function(tolua_S,"getSpeed",lua_cocos2dx_ParticleSystem_getSpeed); tolua_function(tolua_S,"pauseEmissions",lua_cocos2dx_ParticleSystem_pauseEmissions); tolua_function(tolua_S,"getAngle",lua_cocos2dx_ParticleSystem_getAngle); tolua_function(tolua_S,"setEndColor",lua_cocos2dx_ParticleSystem_setEndColor); tolua_function(tolua_S,"setStartSpin",lua_cocos2dx_ParticleSystem_setStartSpin); tolua_function(tolua_S,"setDuration",lua_cocos2dx_ParticleSystem_setDuration); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleSystem_initWithTotalParticles); tolua_function(tolua_S,"addParticles",lua_cocos2dx_ParticleSystem_addParticles); tolua_function(tolua_S,"setTexture",lua_cocos2dx_ParticleSystem_setTexture); tolua_function(tolua_S,"getPosVar",lua_cocos2dx_ParticleSystem_getPosVar); tolua_function(tolua_S,"updateWithNoTime",lua_cocos2dx_ParticleSystem_updateWithNoTime); tolua_function(tolua_S,"isBlendAdditive",lua_cocos2dx_ParticleSystem_isBlendAdditive); tolua_function(tolua_S,"getSpeedVar",lua_cocos2dx_ParticleSystem_getSpeedVar); tolua_function(tolua_S,"setPositionType",lua_cocos2dx_ParticleSystem_setPositionType); tolua_function(tolua_S,"stopSystem",lua_cocos2dx_ParticleSystem_stopSystem); tolua_function(tolua_S,"getSourcePosition",lua_cocos2dx_ParticleSystem_getSourcePosition); tolua_function(tolua_S,"setLifeVar",lua_cocos2dx_ParticleSystem_setLifeVar); tolua_function(tolua_S,"setTotalParticles",lua_cocos2dx_ParticleSystem_setTotalParticles); tolua_function(tolua_S,"setEndColorVar",lua_cocos2dx_ParticleSystem_setEndColorVar); tolua_function(tolua_S,"getAtlasIndex",lua_cocos2dx_ParticleSystem_getAtlasIndex); tolua_function(tolua_S,"getStartSize",lua_cocos2dx_ParticleSystem_getStartSize); tolua_function(tolua_S,"setStartSpinVar",lua_cocos2dx_ParticleSystem_setStartSpinVar); tolua_function(tolua_S,"resetSystem",lua_cocos2dx_ParticleSystem_resetSystem); tolua_function(tolua_S,"setAtlasIndex",lua_cocos2dx_ParticleSystem_setAtlasIndex); tolua_function(tolua_S,"setTangentialAccelVar",lua_cocos2dx_ParticleSystem_setTangentialAccelVar); tolua_function(tolua_S,"setEndRadiusVar",lua_cocos2dx_ParticleSystem_setEndRadiusVar); tolua_function(tolua_S,"getEndRadius",lua_cocos2dx_ParticleSystem_getEndRadius); tolua_function(tolua_S,"isActive",lua_cocos2dx_ParticleSystem_isActive); tolua_function(tolua_S,"setRadialAccelVar",lua_cocos2dx_ParticleSystem_setRadialAccelVar); tolua_function(tolua_S,"setStartSize",lua_cocos2dx_ParticleSystem_setStartSize); tolua_function(tolua_S,"setSpeed",lua_cocos2dx_ParticleSystem_setSpeed); tolua_function(tolua_S,"getStartSpin",lua_cocos2dx_ParticleSystem_getStartSpin); tolua_function(tolua_S,"getResourceFile",lua_cocos2dx_ParticleSystem_getResourceFile); tolua_function(tolua_S,"getRotatePerSecond",lua_cocos2dx_ParticleSystem_getRotatePerSecond); tolua_function(tolua_S,"setEmitterMode",lua_cocos2dx_ParticleSystem_setEmitterMode); tolua_function(tolua_S,"getDuration",lua_cocos2dx_ParticleSystem_getDuration); tolua_function(tolua_S,"setSourcePosition",lua_cocos2dx_ParticleSystem_setSourcePosition); tolua_function(tolua_S,"stop",lua_cocos2dx_ParticleSystem_stop); tolua_function(tolua_S,"updateParticleQuads",lua_cocos2dx_ParticleSystem_updateParticleQuads); tolua_function(tolua_S,"getEndSpinVar",lua_cocos2dx_ParticleSystem_getEndSpinVar); tolua_function(tolua_S,"setBlendAdditive",lua_cocos2dx_ParticleSystem_setBlendAdditive); tolua_function(tolua_S,"setLife",lua_cocos2dx_ParticleSystem_setLife); tolua_function(tolua_S,"setAngleVar",lua_cocos2dx_ParticleSystem_setAngleVar); tolua_function(tolua_S,"setRotationIsDir",lua_cocos2dx_ParticleSystem_setRotationIsDir); tolua_function(tolua_S,"start",lua_cocos2dx_ParticleSystem_start); tolua_function(tolua_S,"setEndSizeVar",lua_cocos2dx_ParticleSystem_setEndSizeVar); tolua_function(tolua_S,"setAngle",lua_cocos2dx_ParticleSystem_setAngle); tolua_function(tolua_S,"setBatchNode",lua_cocos2dx_ParticleSystem_setBatchNode); tolua_function(tolua_S,"getTangentialAccelVar",lua_cocos2dx_ParticleSystem_getTangentialAccelVar); tolua_function(tolua_S,"getEmitterMode",lua_cocos2dx_ParticleSystem_getEmitterMode); tolua_function(tolua_S,"setEndSpinVar",lua_cocos2dx_ParticleSystem_setEndSpinVar); tolua_function(tolua_S,"initWithFile",lua_cocos2dx_ParticleSystem_initWithFile); tolua_function(tolua_S,"getAngleVar",lua_cocos2dx_ParticleSystem_getAngleVar); tolua_function(tolua_S,"setStartColor",lua_cocos2dx_ParticleSystem_setStartColor); tolua_function(tolua_S,"getRotatePerSecondVar",lua_cocos2dx_ParticleSystem_getRotatePerSecondVar); tolua_function(tolua_S,"getEndSize",lua_cocos2dx_ParticleSystem_getEndSize); tolua_function(tolua_S,"getLife",lua_cocos2dx_ParticleSystem_getLife); tolua_function(tolua_S,"isPaused",lua_cocos2dx_ParticleSystem_isPaused); tolua_function(tolua_S,"setSpeedVar",lua_cocos2dx_ParticleSystem_setSpeedVar); tolua_function(tolua_S,"setAutoRemoveOnFinish",lua_cocos2dx_ParticleSystem_setAutoRemoveOnFinish); tolua_function(tolua_S,"setGravity",lua_cocos2dx_ParticleSystem_setGravity); tolua_function(tolua_S,"postStep",lua_cocos2dx_ParticleSystem_postStep); tolua_function(tolua_S,"setEmissionRate",lua_cocos2dx_ParticleSystem_setEmissionRate); tolua_function(tolua_S,"getEndColorVar",lua_cocos2dx_ParticleSystem_getEndColorVar); tolua_function(tolua_S,"getRotationIsDir",lua_cocos2dx_ParticleSystem_getRotationIsDir); tolua_function(tolua_S,"getEmissionRate",lua_cocos2dx_ParticleSystem_getEmissionRate); tolua_function(tolua_S,"getEndColor",lua_cocos2dx_ParticleSystem_getEndColor); tolua_function(tolua_S,"getLifeVar",lua_cocos2dx_ParticleSystem_getLifeVar); tolua_function(tolua_S,"setStartSizeVar",lua_cocos2dx_ParticleSystem_setStartSizeVar); tolua_function(tolua_S,"getStartRadius",lua_cocos2dx_ParticleSystem_getStartRadius); tolua_function(tolua_S,"getParticleCount",lua_cocos2dx_ParticleSystem_getParticleCount); tolua_function(tolua_S,"getStartRadiusVar",lua_cocos2dx_ParticleSystem_getStartRadiusVar); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_ParticleSystem_getBlendFunc); tolua_function(tolua_S,"setStartColorVar",lua_cocos2dx_ParticleSystem_setStartColorVar); tolua_function(tolua_S,"setEndSpin",lua_cocos2dx_ParticleSystem_setEndSpin); tolua_function(tolua_S,"setRadialAccel",lua_cocos2dx_ParticleSystem_setRadialAccel); tolua_function(tolua_S,"initWithDictionary",lua_cocos2dx_ParticleSystem_initWithDictionary); tolua_function(tolua_S,"isAutoRemoveOnFinish",lua_cocos2dx_ParticleSystem_isAutoRemoveOnFinish); tolua_function(tolua_S,"getTotalParticles",lua_cocos2dx_ParticleSystem_getTotalParticles); tolua_function(tolua_S,"setStartRadiusVar",lua_cocos2dx_ParticleSystem_setStartRadiusVar); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_ParticleSystem_setBlendFunc); tolua_function(tolua_S,"getEndRadiusVar",lua_cocos2dx_ParticleSystem_getEndRadiusVar); tolua_function(tolua_S,"getStartColorVar",lua_cocos2dx_ParticleSystem_getStartColorVar); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleSystem_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleSystem_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleSystem).name(); g_luaType[typeName] = "cc.ParticleSystem"; g_typeCast["ParticleSystem"] = "cc.ParticleSystem"; return 1; } int lua_cocos2dx_ParticleSystemQuad_setDisplayFrame(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystemQuad* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystemQuad",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystemQuad*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystemQuad_setDisplayFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.ParticleSystemQuad:setDisplayFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystemQuad_setDisplayFrame'", nullptr); return 0; } cobj->setDisplayFrame(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystemQuad:setDisplayFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystemQuad_setDisplayFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystemQuad_setTextureWithRect(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystemQuad* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystemQuad",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystemQuad*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystemQuad_setTextureWithRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; cocos2d::Rect arg1; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.ParticleSystemQuad:setTextureWithRect"); ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.ParticleSystemQuad:setTextureWithRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystemQuad_setTextureWithRect'", nullptr); return 0; } cobj->setTextureWithRect(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystemQuad:setTextureWithRect",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystemQuad_setTextureWithRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystemQuad_listenRendererRecreated(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystemQuad* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSystemQuad",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSystemQuad*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSystemQuad_listenRendererRecreated'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::EventCustom* arg0 = nullptr; ok &= luaval_to_object<cocos2d::EventCustom>(tolua_S, 2, "cc.EventCustom",&arg0, "cc.ParticleSystemQuad:listenRendererRecreated"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystemQuad_listenRendererRecreated'", nullptr); return 0; } cobj->listenRendererRecreated(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystemQuad:listenRendererRecreated",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystemQuad_listenRendererRecreated'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystemQuad_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSystemQuad",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.ParticleSystemQuad:create"); if (!ok) { break; } cocos2d::ParticleSystemQuad* ret = cocos2d::ParticleSystemQuad::create(arg0); object_to_luaval<cocos2d::ParticleSystemQuad>(tolua_S, "cc.ParticleSystemQuad",(cocos2d::ParticleSystemQuad*)ret); return 1; } } while (0); ok = true; do { if (argc == 0) { cocos2d::ParticleSystemQuad* ret = cocos2d::ParticleSystemQuad::create(); object_to_luaval<cocos2d::ParticleSystemQuad>(tolua_S, "cc.ParticleSystemQuad",(cocos2d::ParticleSystemQuad*)ret); return 1; } } while (0); ok = true; do { if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.ParticleSystemQuad:create"); if (!ok) { break; } cocos2d::ParticleSystemQuad* ret = cocos2d::ParticleSystemQuad::create(arg0); object_to_luaval<cocos2d::ParticleSystemQuad>(tolua_S, "cc.ParticleSystemQuad",(cocos2d::ParticleSystemQuad*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.ParticleSystemQuad:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystemQuad_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystemQuad_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSystemQuad",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSystemQuad:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystemQuad_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleSystemQuad* ret = cocos2d::ParticleSystemQuad::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleSystemQuad>(tolua_S, "cc.ParticleSystemQuad",(cocos2d::ParticleSystemQuad*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSystemQuad:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystemQuad_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSystemQuad_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSystemQuad* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSystemQuad_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleSystemQuad(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleSystemQuad"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSystemQuad:ParticleSystemQuad",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSystemQuad_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleSystemQuad_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleSystemQuad)"); return 0; } int lua_register_cocos2dx_ParticleSystemQuad(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleSystemQuad"); tolua_cclass(tolua_S,"ParticleSystemQuad","cc.ParticleSystemQuad","cc.ParticleSystem",nullptr); tolua_beginmodule(tolua_S,"ParticleSystemQuad"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleSystemQuad_constructor); tolua_function(tolua_S,"setDisplayFrame",lua_cocos2dx_ParticleSystemQuad_setDisplayFrame); tolua_function(tolua_S,"setTextureWithRect",lua_cocos2dx_ParticleSystemQuad_setTextureWithRect); tolua_function(tolua_S,"listenRendererRecreated",lua_cocos2dx_ParticleSystemQuad_listenRendererRecreated); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleSystemQuad_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleSystemQuad_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleSystemQuad).name(); g_luaType[typeName] = "cc.ParticleSystemQuad"; g_typeCast["ParticleSystemQuad"] = "cc.ParticleSystemQuad"; return 1; } int lua_cocos2dx_ParticleFire_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleFire",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFire_create'", nullptr); return 0; } cocos2d::ParticleFire* ret = cocos2d::ParticleFire::create(); object_to_luaval<cocos2d::ParticleFire>(tolua_S, "cc.ParticleFire",(cocos2d::ParticleFire*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleFire:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFire_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFire_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleFire",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleFire:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFire_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleFire* ret = cocos2d::ParticleFire::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleFire>(tolua_S, "cc.ParticleFire",(cocos2d::ParticleFire*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleFire:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFire_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFire_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleFire* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFire_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleFire(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleFire"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleFire:ParticleFire",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFire_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleFire_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleFire)"); return 0; } int lua_register_cocos2dx_ParticleFire(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleFire"); tolua_cclass(tolua_S,"ParticleFire","cc.ParticleFire","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleFire"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleFire_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleFire_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleFire_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleFire).name(); g_luaType[typeName] = "cc.ParticleFire"; g_typeCast["ParticleFire"] = "cc.ParticleFire"; return 1; } int lua_cocos2dx_ParticleFireworks_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleFireworks* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleFireworks",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleFireworks*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleFireworks_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFireworks_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleFireworks:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFireworks_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFireworks_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleFireworks* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleFireworks",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleFireworks*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleFireworks_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleFireworks:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFireworks_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleFireworks:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFireworks_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFireworks_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleFireworks",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFireworks_create'", nullptr); return 0; } cocos2d::ParticleFireworks* ret = cocos2d::ParticleFireworks::create(); object_to_luaval<cocos2d::ParticleFireworks>(tolua_S, "cc.ParticleFireworks",(cocos2d::ParticleFireworks*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleFireworks:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFireworks_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFireworks_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleFireworks",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleFireworks:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFireworks_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleFireworks* ret = cocos2d::ParticleFireworks::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleFireworks>(tolua_S, "cc.ParticleFireworks",(cocos2d::ParticleFireworks*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleFireworks:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFireworks_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFireworks_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleFireworks* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFireworks_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleFireworks(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleFireworks"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleFireworks:ParticleFireworks",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFireworks_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleFireworks_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleFireworks)"); return 0; } int lua_register_cocos2dx_ParticleFireworks(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleFireworks"); tolua_cclass(tolua_S,"ParticleFireworks","cc.ParticleFireworks","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleFireworks"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleFireworks_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleFireworks_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleFireworks_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleFireworks_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleFireworks_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleFireworks).name(); g_luaType[typeName] = "cc.ParticleFireworks"; g_typeCast["ParticleFireworks"] = "cc.ParticleFireworks"; return 1; } int lua_cocos2dx_ParticleSun_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSun* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSun",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSun*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSun_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSun_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSun:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSun_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSun_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSun* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSun",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSun*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSun_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSun:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSun_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSun:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSun_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSun_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSun",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSun_create'", nullptr); return 0; } cocos2d::ParticleSun* ret = cocos2d::ParticleSun::create(); object_to_luaval<cocos2d::ParticleSun>(tolua_S, "cc.ParticleSun",(cocos2d::ParticleSun*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSun:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSun_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSun_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSun",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSun:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSun_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleSun* ret = cocos2d::ParticleSun::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleSun>(tolua_S, "cc.ParticleSun",(cocos2d::ParticleSun*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSun:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSun_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSun_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSun* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSun_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleSun(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleSun"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSun:ParticleSun",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSun_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleSun_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleSun)"); return 0; } int lua_register_cocos2dx_ParticleSun(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleSun"); tolua_cclass(tolua_S,"ParticleSun","cc.ParticleSun","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleSun"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleSun_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleSun_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleSun_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleSun_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleSun_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleSun).name(); g_luaType[typeName] = "cc.ParticleSun"; g_typeCast["ParticleSun"] = "cc.ParticleSun"; return 1; } int lua_cocos2dx_ParticleGalaxy_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleGalaxy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleGalaxy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleGalaxy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleGalaxy_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleGalaxy_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleGalaxy:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleGalaxy_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleGalaxy_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleGalaxy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleGalaxy",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleGalaxy*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleGalaxy_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleGalaxy:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleGalaxy_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleGalaxy:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleGalaxy_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleGalaxy_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleGalaxy",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleGalaxy_create'", nullptr); return 0; } cocos2d::ParticleGalaxy* ret = cocos2d::ParticleGalaxy::create(); object_to_luaval<cocos2d::ParticleGalaxy>(tolua_S, "cc.ParticleGalaxy",(cocos2d::ParticleGalaxy*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleGalaxy:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleGalaxy_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleGalaxy_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleGalaxy",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleGalaxy:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleGalaxy_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleGalaxy* ret = cocos2d::ParticleGalaxy::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleGalaxy>(tolua_S, "cc.ParticleGalaxy",(cocos2d::ParticleGalaxy*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleGalaxy:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleGalaxy_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleGalaxy_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleGalaxy* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleGalaxy_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleGalaxy(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleGalaxy"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleGalaxy:ParticleGalaxy",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleGalaxy_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleGalaxy_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleGalaxy)"); return 0; } int lua_register_cocos2dx_ParticleGalaxy(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleGalaxy"); tolua_cclass(tolua_S,"ParticleGalaxy","cc.ParticleGalaxy","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleGalaxy"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleGalaxy_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleGalaxy_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleGalaxy_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleGalaxy_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleGalaxy_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleGalaxy).name(); g_luaType[typeName] = "cc.ParticleGalaxy"; g_typeCast["ParticleGalaxy"] = "cc.ParticleGalaxy"; return 1; } int lua_cocos2dx_ParticleFlower_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleFlower* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleFlower",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleFlower*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleFlower_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFlower_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleFlower:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFlower_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFlower_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleFlower* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleFlower",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleFlower*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleFlower_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleFlower:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFlower_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleFlower:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFlower_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFlower_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleFlower",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFlower_create'", nullptr); return 0; } cocos2d::ParticleFlower* ret = cocos2d::ParticleFlower::create(); object_to_luaval<cocos2d::ParticleFlower>(tolua_S, "cc.ParticleFlower",(cocos2d::ParticleFlower*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleFlower:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFlower_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFlower_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleFlower",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleFlower:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFlower_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleFlower* ret = cocos2d::ParticleFlower::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleFlower>(tolua_S, "cc.ParticleFlower",(cocos2d::ParticleFlower*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleFlower:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFlower_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleFlower_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleFlower* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleFlower_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleFlower(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleFlower"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleFlower:ParticleFlower",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleFlower_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleFlower_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleFlower)"); return 0; } int lua_register_cocos2dx_ParticleFlower(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleFlower"); tolua_cclass(tolua_S,"ParticleFlower","cc.ParticleFlower","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleFlower"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleFlower_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleFlower_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleFlower_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleFlower_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleFlower_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleFlower).name(); g_luaType[typeName] = "cc.ParticleFlower"; g_typeCast["ParticleFlower"] = "cc.ParticleFlower"; return 1; } int lua_cocos2dx_ParticleMeteor_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleMeteor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleMeteor",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleMeteor*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleMeteor_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleMeteor_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleMeteor:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleMeteor_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleMeteor_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleMeteor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleMeteor",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleMeteor*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleMeteor_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleMeteor:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleMeteor_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleMeteor:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleMeteor_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleMeteor_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleMeteor",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleMeteor_create'", nullptr); return 0; } cocos2d::ParticleMeteor* ret = cocos2d::ParticleMeteor::create(); object_to_luaval<cocos2d::ParticleMeteor>(tolua_S, "cc.ParticleMeteor",(cocos2d::ParticleMeteor*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleMeteor:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleMeteor_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleMeteor_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleMeteor",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleMeteor:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleMeteor_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleMeteor* ret = cocos2d::ParticleMeteor::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleMeteor>(tolua_S, "cc.ParticleMeteor",(cocos2d::ParticleMeteor*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleMeteor:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleMeteor_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleMeteor_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleMeteor* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleMeteor_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleMeteor(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleMeteor"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleMeteor:ParticleMeteor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleMeteor_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleMeteor_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleMeteor)"); return 0; } int lua_register_cocos2dx_ParticleMeteor(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleMeteor"); tolua_cclass(tolua_S,"ParticleMeteor","cc.ParticleMeteor","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleMeteor"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleMeteor_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleMeteor_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleMeteor_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleMeteor_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleMeteor_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleMeteor).name(); g_luaType[typeName] = "cc.ParticleMeteor"; g_typeCast["ParticleMeteor"] = "cc.ParticleMeteor"; return 1; } int lua_cocos2dx_ParticleSpiral_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSpiral* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSpiral",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSpiral*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSpiral_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSpiral_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSpiral:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSpiral_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSpiral_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSpiral* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSpiral",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSpiral*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSpiral_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSpiral:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSpiral_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSpiral:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSpiral_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSpiral_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSpiral",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSpiral_create'", nullptr); return 0; } cocos2d::ParticleSpiral* ret = cocos2d::ParticleSpiral::create(); object_to_luaval<cocos2d::ParticleSpiral>(tolua_S, "cc.ParticleSpiral",(cocos2d::ParticleSpiral*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSpiral:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSpiral_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSpiral_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSpiral",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSpiral:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSpiral_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleSpiral* ret = cocos2d::ParticleSpiral::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleSpiral>(tolua_S, "cc.ParticleSpiral",(cocos2d::ParticleSpiral*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSpiral:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSpiral_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSpiral_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSpiral* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSpiral_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleSpiral(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleSpiral"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSpiral:ParticleSpiral",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSpiral_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleSpiral_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleSpiral)"); return 0; } int lua_register_cocos2dx_ParticleSpiral(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleSpiral"); tolua_cclass(tolua_S,"ParticleSpiral","cc.ParticleSpiral","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleSpiral"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleSpiral_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleSpiral_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleSpiral_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleSpiral_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleSpiral_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleSpiral).name(); g_luaType[typeName] = "cc.ParticleSpiral"; g_typeCast["ParticleSpiral"] = "cc.ParticleSpiral"; return 1; } int lua_cocos2dx_ParticleExplosion_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleExplosion* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleExplosion",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleExplosion*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleExplosion_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleExplosion_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleExplosion:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleExplosion_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleExplosion_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleExplosion* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleExplosion",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleExplosion*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleExplosion_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleExplosion:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleExplosion_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleExplosion:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleExplosion_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleExplosion_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleExplosion",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleExplosion_create'", nullptr); return 0; } cocos2d::ParticleExplosion* ret = cocos2d::ParticleExplosion::create(); object_to_luaval<cocos2d::ParticleExplosion>(tolua_S, "cc.ParticleExplosion",(cocos2d::ParticleExplosion*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleExplosion:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleExplosion_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleExplosion_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleExplosion",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleExplosion:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleExplosion_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleExplosion* ret = cocos2d::ParticleExplosion::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleExplosion>(tolua_S, "cc.ParticleExplosion",(cocos2d::ParticleExplosion*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleExplosion:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleExplosion_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleExplosion_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleExplosion* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleExplosion_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleExplosion(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleExplosion"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleExplosion:ParticleExplosion",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleExplosion_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleExplosion_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleExplosion)"); return 0; } int lua_register_cocos2dx_ParticleExplosion(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleExplosion"); tolua_cclass(tolua_S,"ParticleExplosion","cc.ParticleExplosion","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleExplosion"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleExplosion_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleExplosion_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleExplosion_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleExplosion_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleExplosion_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleExplosion).name(); g_luaType[typeName] = "cc.ParticleExplosion"; g_typeCast["ParticleExplosion"] = "cc.ParticleExplosion"; return 1; } int lua_cocos2dx_ParticleSmoke_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSmoke* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSmoke",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSmoke*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSmoke_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSmoke_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSmoke:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSmoke_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSmoke_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSmoke* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSmoke",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSmoke*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSmoke_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSmoke:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSmoke_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSmoke:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSmoke_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSmoke_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSmoke",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSmoke_create'", nullptr); return 0; } cocos2d::ParticleSmoke* ret = cocos2d::ParticleSmoke::create(); object_to_luaval<cocos2d::ParticleSmoke>(tolua_S, "cc.ParticleSmoke",(cocos2d::ParticleSmoke*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSmoke:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSmoke_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSmoke_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSmoke",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSmoke:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSmoke_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleSmoke* ret = cocos2d::ParticleSmoke::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleSmoke>(tolua_S, "cc.ParticleSmoke",(cocos2d::ParticleSmoke*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSmoke:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSmoke_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSmoke_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSmoke* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSmoke_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleSmoke(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleSmoke"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSmoke:ParticleSmoke",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSmoke_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleSmoke_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleSmoke)"); return 0; } int lua_register_cocos2dx_ParticleSmoke(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleSmoke"); tolua_cclass(tolua_S,"ParticleSmoke","cc.ParticleSmoke","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleSmoke"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleSmoke_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleSmoke_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleSmoke_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleSmoke_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleSmoke_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleSmoke).name(); g_luaType[typeName] = "cc.ParticleSmoke"; g_typeCast["ParticleSmoke"] = "cc.ParticleSmoke"; return 1; } int lua_cocos2dx_ParticleSnow_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSnow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSnow",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSnow*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSnow_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSnow_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSnow:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSnow_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSnow_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSnow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleSnow",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleSnow*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleSnow_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSnow:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSnow_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSnow:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSnow_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSnow_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSnow",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSnow_create'", nullptr); return 0; } cocos2d::ParticleSnow* ret = cocos2d::ParticleSnow::create(); object_to_luaval<cocos2d::ParticleSnow>(tolua_S, "cc.ParticleSnow",(cocos2d::ParticleSnow*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSnow:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSnow_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSnow_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleSnow",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleSnow:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSnow_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleSnow* ret = cocos2d::ParticleSnow::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleSnow>(tolua_S, "cc.ParticleSnow",(cocos2d::ParticleSnow*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleSnow:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSnow_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleSnow_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleSnow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleSnow_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleSnow(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleSnow"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleSnow:ParticleSnow",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleSnow_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleSnow_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleSnow)"); return 0; } int lua_register_cocos2dx_ParticleSnow(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleSnow"); tolua_cclass(tolua_S,"ParticleSnow","cc.ParticleSnow","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleSnow"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleSnow_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleSnow_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleSnow_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleSnow_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleSnow_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleSnow).name(); g_luaType[typeName] = "cc.ParticleSnow"; g_typeCast["ParticleSnow"] = "cc.ParticleSnow"; return 1; } int lua_cocos2dx_ParticleRain_init(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleRain* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleRain",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleRain*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleRain_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleRain_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleRain:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleRain_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleRain_initWithTotalParticles(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleRain* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParticleRain",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParticleRain*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParticleRain_initWithTotalParticles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleRain:initWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleRain_initWithTotalParticles'", nullptr); return 0; } bool ret = cobj->initWithTotalParticles(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleRain:initWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleRain_initWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleRain_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleRain",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleRain_create'", nullptr); return 0; } cocos2d::ParticleRain* ret = cocos2d::ParticleRain::create(); object_to_luaval<cocos2d::ParticleRain>(tolua_S, "cc.ParticleRain",(cocos2d::ParticleRain*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleRain:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleRain_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleRain_createWithTotalParticles(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParticleRain",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ParticleRain:createWithTotalParticles"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleRain_createWithTotalParticles'", nullptr); return 0; } cocos2d::ParticleRain* ret = cocos2d::ParticleRain::createWithTotalParticles(arg0); object_to_luaval<cocos2d::ParticleRain>(tolua_S, "cc.ParticleRain",(cocos2d::ParticleRain*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParticleRain:createWithTotalParticles",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleRain_createWithTotalParticles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParticleRain_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParticleRain* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParticleRain_constructor'", nullptr); return 0; } cobj = new cocos2d::ParticleRain(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParticleRain"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParticleRain:ParticleRain",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParticleRain_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParticleRain_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParticleRain)"); return 0; } int lua_register_cocos2dx_ParticleRain(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParticleRain"); tolua_cclass(tolua_S,"ParticleRain","cc.ParticleRain","cc.ParticleSystemQuad",nullptr); tolua_beginmodule(tolua_S,"ParticleRain"); tolua_function(tolua_S,"new",lua_cocos2dx_ParticleRain_constructor); tolua_function(tolua_S,"init",lua_cocos2dx_ParticleRain_init); tolua_function(tolua_S,"initWithTotalParticles",lua_cocos2dx_ParticleRain_initWithTotalParticles); tolua_function(tolua_S,"create", lua_cocos2dx_ParticleRain_create); tolua_function(tolua_S,"createWithTotalParticles", lua_cocos2dx_ParticleRain_createWithTotalParticles); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParticleRain).name(); g_luaType[typeName] = "cc.ParticleRain"; g_typeCast["ParticleRain"] = "cc.ParticleRain"; return 1; } int lua_cocos2dx_ProgressTimer_initWithSprite(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_initWithSprite'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Sprite* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.ProgressTimer:initWithSprite"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_initWithSprite'", nullptr); return 0; } bool ret = cobj->initWithSprite(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:initWithSprite",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_initWithSprite'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_isReverseDirection(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_isReverseDirection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_isReverseDirection'", nullptr); return 0; } bool ret = cobj->isReverseDirection(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:isReverseDirection",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_isReverseDirection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_setBarChangeRate(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_setBarChangeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.ProgressTimer:setBarChangeRate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_setBarChangeRate'", nullptr); return 0; } cobj->setBarChangeRate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:setBarChangeRate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_setBarChangeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_getPercentage(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_getPercentage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_getPercentage'", nullptr); return 0; } double ret = cobj->getPercentage(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:getPercentage",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_getPercentage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_setSprite(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_setSprite'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Sprite* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.ProgressTimer:setSprite"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_setSprite'", nullptr); return 0; } cobj->setSprite(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:setSprite",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_setSprite'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_getType(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_getType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_getType'", nullptr); return 0; } int ret = (int)cobj->getType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:getType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_getType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_getSprite(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_getSprite'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_getSprite'", nullptr); return 0; } cocos2d::Sprite* ret = cobj->getSprite(); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:getSprite",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_getSprite'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_setMidpoint(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_setMidpoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.ProgressTimer:setMidpoint"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_setMidpoint'", nullptr); return 0; } cobj->setMidpoint(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:setMidpoint",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_setMidpoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_getBarChangeRate(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_getBarChangeRate'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_getBarChangeRate'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getBarChangeRate(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:getBarChangeRate",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_getBarChangeRate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_setReverseDirection(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_setReverseDirection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ProgressTimer:setReverseDirection"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_setReverseDirection'", nullptr); return 0; } cobj->setReverseDirection(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:setReverseDirection",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_setReverseDirection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_getMidpoint(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_getMidpoint'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_getMidpoint'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getMidpoint(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:getMidpoint",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_getMidpoint'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_setPercentage(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_setPercentage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ProgressTimer:setPercentage"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_setPercentage'", nullptr); return 0; } cobj->setPercentage(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:setPercentage",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_setPercentage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_setType(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProgressTimer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProgressTimer_setType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ProgressTimer::Type arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ProgressTimer:setType"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_setType'", nullptr); return 0; } cobj->setType(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:setType",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_setType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ProgressTimer",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Sprite* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.ProgressTimer:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_create'", nullptr); return 0; } cocos2d::ProgressTimer* ret = cocos2d::ProgressTimer::create(arg0); object_to_luaval<cocos2d::ProgressTimer>(tolua_S, "cc.ProgressTimer",(cocos2d::ProgressTimer*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ProgressTimer:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProgressTimer_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ProgressTimer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProgressTimer_constructor'", nullptr); return 0; } cobj = new cocos2d::ProgressTimer(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ProgressTimer"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProgressTimer:ProgressTimer",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProgressTimer_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ProgressTimer_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ProgressTimer)"); return 0; } int lua_register_cocos2dx_ProgressTimer(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ProgressTimer"); tolua_cclass(tolua_S,"ProgressTimer","cc.ProgressTimer","cc.Node",nullptr); tolua_beginmodule(tolua_S,"ProgressTimer"); tolua_function(tolua_S,"new",lua_cocos2dx_ProgressTimer_constructor); tolua_function(tolua_S,"initWithSprite",lua_cocos2dx_ProgressTimer_initWithSprite); tolua_function(tolua_S,"isReverseDirection",lua_cocos2dx_ProgressTimer_isReverseDirection); tolua_function(tolua_S,"setBarChangeRate",lua_cocos2dx_ProgressTimer_setBarChangeRate); tolua_function(tolua_S,"getPercentage",lua_cocos2dx_ProgressTimer_getPercentage); tolua_function(tolua_S,"setSprite",lua_cocos2dx_ProgressTimer_setSprite); tolua_function(tolua_S,"getType",lua_cocos2dx_ProgressTimer_getType); tolua_function(tolua_S,"getSprite",lua_cocos2dx_ProgressTimer_getSprite); tolua_function(tolua_S,"setMidpoint",lua_cocos2dx_ProgressTimer_setMidpoint); tolua_function(tolua_S,"getBarChangeRate",lua_cocos2dx_ProgressTimer_getBarChangeRate); tolua_function(tolua_S,"setReverseDirection",lua_cocos2dx_ProgressTimer_setReverseDirection); tolua_function(tolua_S,"getMidpoint",lua_cocos2dx_ProgressTimer_getMidpoint); tolua_function(tolua_S,"setPercentage",lua_cocos2dx_ProgressTimer_setPercentage); tolua_function(tolua_S,"setType",lua_cocos2dx_ProgressTimer_setType); tolua_function(tolua_S,"create", lua_cocos2dx_ProgressTimer_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ProgressTimer).name(); g_luaType[typeName] = "cc.ProgressTimer"; g_typeCast["ProgressTimer"] = "cc.ProgressTimer"; return 1; } int lua_cocos2dx_ProtectedNode_addProtectedChild(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_addProtectedChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ProtectedNode:addProtectedChild"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ProtectedNode:addProtectedChild"); if (!ok) { break; } cobj->addProtectedChild(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ProtectedNode:addProtectedChild"); if (!ok) { break; } cobj->addProtectedChild(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ProtectedNode:addProtectedChild"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ProtectedNode:addProtectedChild"); if (!ok) { break; } int arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.ProtectedNode:addProtectedChild"); if (!ok) { break; } cobj->addProtectedChild(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:addProtectedChild",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_addProtectedChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_disableCascadeColor(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_disableCascadeColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_disableCascadeColor'", nullptr); return 0; } cobj->disableCascadeColor(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:disableCascadeColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_disableCascadeColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_removeProtectedChildByTag(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_removeProtectedChildByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ProtectedNode:removeProtectedChildByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_removeProtectedChildByTag'", nullptr); return 0; } cobj->removeProtectedChildByTag(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { int arg0; bool arg1; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ProtectedNode:removeProtectedChildByTag"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.ProtectedNode:removeProtectedChildByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_removeProtectedChildByTag'", nullptr); return 0; } cobj->removeProtectedChildByTag(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:removeProtectedChildByTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_removeProtectedChildByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_reorderProtectedChild(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_reorderProtectedChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Node* arg0 = nullptr; int arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ProtectedNode:reorderProtectedChild"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ProtectedNode:reorderProtectedChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_reorderProtectedChild'", nullptr); return 0; } cobj->reorderProtectedChild(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:reorderProtectedChild",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_reorderProtectedChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_removeAllProtectedChildrenWithCleanup(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_removeAllProtectedChildrenWithCleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ProtectedNode:removeAllProtectedChildrenWithCleanup"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_removeAllProtectedChildrenWithCleanup'", nullptr); return 0; } cobj->removeAllProtectedChildrenWithCleanup(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:removeAllProtectedChildrenWithCleanup",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_removeAllProtectedChildrenWithCleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_disableCascadeOpacity(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_disableCascadeOpacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_disableCascadeOpacity'", nullptr); return 0; } cobj->disableCascadeOpacity(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:disableCascadeOpacity",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_disableCascadeOpacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_sortAllProtectedChildren(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_sortAllProtectedChildren'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_sortAllProtectedChildren'", nullptr); return 0; } cobj->sortAllProtectedChildren(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:sortAllProtectedChildren",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_sortAllProtectedChildren'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_getProtectedChildByTag(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_getProtectedChildByTag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ProtectedNode:getProtectedChildByTag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_getProtectedChildByTag'", nullptr); return 0; } cocos2d::Node* ret = cobj->getProtectedChildByTag(arg0); object_to_luaval<cocos2d::Node>(tolua_S, "cc.Node",(cocos2d::Node*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:getProtectedChildByTag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_getProtectedChildByTag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_removeProtectedChild(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_removeProtectedChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ProtectedNode:removeProtectedChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_removeProtectedChild'", nullptr); return 0; } cobj->removeProtectedChild(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { cocos2d::Node* arg0 = nullptr; bool arg1; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ProtectedNode:removeProtectedChild"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.ProtectedNode:removeProtectedChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_removeProtectedChild'", nullptr); return 0; } cobj->removeProtectedChild(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:removeProtectedChild",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_removeProtectedChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_removeAllProtectedChildren(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ProtectedNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ProtectedNode_removeAllProtectedChildren'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_removeAllProtectedChildren'", nullptr); return 0; } cobj->removeAllProtectedChildren(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:removeAllProtectedChildren",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_removeAllProtectedChildren'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ProtectedNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_create'", nullptr); return 0; } cocos2d::ProtectedNode* ret = cocos2d::ProtectedNode::create(); object_to_luaval<cocos2d::ProtectedNode>(tolua_S, "cc.ProtectedNode",(cocos2d::ProtectedNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ProtectedNode:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ProtectedNode_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ProtectedNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ProtectedNode_constructor'", nullptr); return 0; } cobj = new cocos2d::ProtectedNode(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ProtectedNode"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ProtectedNode:ProtectedNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ProtectedNode_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ProtectedNode_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ProtectedNode)"); return 0; } int lua_register_cocos2dx_ProtectedNode(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ProtectedNode"); tolua_cclass(tolua_S,"ProtectedNode","cc.ProtectedNode","cc.Node",nullptr); tolua_beginmodule(tolua_S,"ProtectedNode"); tolua_function(tolua_S,"new",lua_cocos2dx_ProtectedNode_constructor); tolua_function(tolua_S,"addProtectedChild",lua_cocos2dx_ProtectedNode_addProtectedChild); tolua_function(tolua_S,"disableCascadeColor",lua_cocos2dx_ProtectedNode_disableCascadeColor); tolua_function(tolua_S,"removeProtectedChildByTag",lua_cocos2dx_ProtectedNode_removeProtectedChildByTag); tolua_function(tolua_S,"reorderProtectedChild",lua_cocos2dx_ProtectedNode_reorderProtectedChild); tolua_function(tolua_S,"removeAllProtectedChildrenWithCleanup",lua_cocos2dx_ProtectedNode_removeAllProtectedChildrenWithCleanup); tolua_function(tolua_S,"disableCascadeOpacity",lua_cocos2dx_ProtectedNode_disableCascadeOpacity); tolua_function(tolua_S,"sortAllProtectedChildren",lua_cocos2dx_ProtectedNode_sortAllProtectedChildren); tolua_function(tolua_S,"getProtectedChildByTag",lua_cocos2dx_ProtectedNode_getProtectedChildByTag); tolua_function(tolua_S,"removeProtectedChild",lua_cocos2dx_ProtectedNode_removeProtectedChild); tolua_function(tolua_S,"removeAllProtectedChildren",lua_cocos2dx_ProtectedNode_removeAllProtectedChildren); tolua_function(tolua_S,"create", lua_cocos2dx_ProtectedNode_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ProtectedNode).name(); g_luaType[typeName] = "cc.ProtectedNode"; g_typeCast["ProtectedNode"] = "cc.ProtectedNode"; return 1; } int lua_cocos2dx_Sprite_setSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.Sprite:setSpriteFrame"); if (!ok) { break; } cobj->setSpriteFrame(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Sprite:setSpriteFrame"); if (!ok) { break; } cobj->setSpriteFrame(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setSpriteFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Sprite:setTexture"); if (!ok) { break; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Sprite:setTexture"); if (!ok) { break; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setFlippedY(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setFlippedY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Sprite:setFlippedY"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setFlippedY'", nullptr); return 0; } cobj->setFlippedY(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setFlippedY",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setFlippedY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setFlippedX(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setFlippedX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Sprite:setFlippedX"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setFlippedX'", nullptr); return 0; } cobj->setFlippedX(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setFlippedX",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setFlippedX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getResourceType(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getResourceType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getResourceType'", nullptr); return 0; } int ret = cobj->getResourceType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getResourceType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getResourceType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setDisplayFrameWithAnimationName(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setDisplayFrameWithAnimationName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; ssize_t arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Sprite:setDisplayFrameWithAnimationName"); ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.Sprite:setDisplayFrameWithAnimationName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setDisplayFrameWithAnimationName'", nullptr); return 0; } cobj->setDisplayFrameWithAnimationName(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setDisplayFrameWithAnimationName",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setDisplayFrameWithAnimationName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getBatchNode(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getBatchNode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getBatchNode'", nullptr); return 0; } cocos2d::SpriteBatchNode* ret = cobj->getBatchNode(); object_to_luaval<cocos2d::SpriteBatchNode>(tolua_S, "cc.SpriteBatchNode",(cocos2d::SpriteBatchNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getBatchNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getBatchNode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getOffsetPosition(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getOffsetPosition'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getOffsetPosition'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getOffsetPosition(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getOffsetPosition",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getOffsetPosition'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getCenterRect(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getCenterRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getCenterRect'", nullptr); return 0; } cocos2d::Rect ret = cobj->getCenterRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getCenterRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getCenterRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_removeAllChildrenWithCleanup(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_removeAllChildrenWithCleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Sprite:removeAllChildrenWithCleanup"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_removeAllChildrenWithCleanup'", nullptr); return 0; } cobj->removeAllChildrenWithCleanup(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:removeAllChildrenWithCleanup",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_removeAllChildrenWithCleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setCenterRectNormalized(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setCenterRectNormalized'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Sprite:setCenterRectNormalized"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setCenterRectNormalized'", nullptr); return 0; } cobj->setCenterRectNormalized(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setCenterRectNormalized",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setCenterRectNormalized'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_isStretchEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_isStretchEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_isStretchEnabled'", nullptr); return 0; } bool ret = cobj->isStretchEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:isStretchEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_isStretchEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setTextureRect(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setTextureRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Sprite:setTextureRect"); if (!ok) { break; } bool arg1; ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Sprite:setTextureRect"); if (!ok) { break; } cocos2d::Size arg2; ok &= luaval_to_size(tolua_S, 4, &arg2, "cc.Sprite:setTextureRect"); if (!ok) { break; } cobj->setTextureRect(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Sprite:setTextureRect"); if (!ok) { break; } cobj->setTextureRect(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setTextureRect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setTextureRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_initWithSpriteFrameName(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_initWithSpriteFrameName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Sprite:initWithSpriteFrameName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_initWithSpriteFrameName'", nullptr); return 0; } bool ret = cobj->initWithSpriteFrameName(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:initWithSpriteFrameName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_initWithSpriteFrameName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setStretchEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setStretchEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Sprite:setStretchEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setStretchEnabled'", nullptr); return 0; } cobj->setStretchEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setStretchEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setStretchEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_isFrameDisplayed(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_isFrameDisplayed'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.Sprite:isFrameDisplayed"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_isFrameDisplayed'", nullptr); return 0; } bool ret = cobj->isFrameDisplayed(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:isFrameDisplayed",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_isFrameDisplayed'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getAtlasIndex(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getAtlasIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getAtlasIndex'", nullptr); return 0; } ssize_t ret = cobj->getAtlasIndex(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getAtlasIndex",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getAtlasIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setBatchNode(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setBatchNode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteBatchNode* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteBatchNode>(tolua_S, 2, "cc.SpriteBatchNode",&arg0, "cc.Sprite:setBatchNode"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setBatchNode'", nullptr); return 0; } cobj->setBatchNode(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setBatchNode",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setBatchNode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setCenterRect(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setCenterRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Sprite:setCenterRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setCenterRect'", nullptr); return 0; } cobj->setCenterRect(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setCenterRect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setCenterRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setTextureAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setTextureAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TextureAtlas* arg0 = nullptr; ok &= luaval_to_object<cocos2d::TextureAtlas>(tolua_S, 2, "cc.TextureAtlas",&arg0, "cc.Sprite:setTextureAtlas"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setTextureAtlas'", nullptr); return 0; } cobj->setTextureAtlas(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setTextureAtlas",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setTextureAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getSpriteFrame'", nullptr); return 0; } cocos2d::SpriteFrame* ret = cobj->getSpriteFrame(); object_to_luaval<cocos2d::SpriteFrame>(tolua_S, "cc.SpriteFrame",(cocos2d::SpriteFrame*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getSpriteFrame",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getResourceName(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getResourceName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getResourceName'", nullptr); return 0; } const std::string& ret = cobj->getResourceName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getResourceName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getResourceName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_isDirty(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_isDirty'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_isDirty'", nullptr); return 0; } bool ret = cobj->isDirty(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:isDirty",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_isDirty'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getCenterRectNormalized(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getCenterRectNormalized'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getCenterRectNormalized'", nullptr); return 0; } cocos2d::Rect ret = cobj->getCenterRectNormalized(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getCenterRectNormalized",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getCenterRectNormalized'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setAtlasIndex(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setAtlasIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { ssize_t arg0; ok &= luaval_to_ssize(tolua_S, 2, &arg0, "cc.Sprite:setAtlasIndex"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setAtlasIndex'", nullptr); return 0; } cobj->setAtlasIndex(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setAtlasIndex",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setAtlasIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_initWithTexture(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_initWithTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Sprite:initWithTexture"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Sprite:initWithTexture"); if (!ok) { break; } bool ret = cobj->initWithTexture(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Sprite:initWithTexture"); if (!ok) { break; } bool ret = cobj->initWithTexture(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Sprite:initWithTexture"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Sprite:initWithTexture"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.Sprite:initWithTexture"); if (!ok) { break; } bool ret = cobj->initWithTexture(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:initWithTexture",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_initWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setDirty(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setDirty'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Sprite:setDirty"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setDirty'", nullptr); return 0; } cobj->setDirty(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setDirty",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setDirty'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_isTextureRectRotated(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_isTextureRectRotated'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_isTextureRectRotated'", nullptr); return 0; } bool ret = cobj->isTextureRectRotated(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:isTextureRectRotated",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_isTextureRectRotated'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getTextureRect(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getTextureRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getTextureRect'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getTextureRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getTextureRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getTextureRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_initWithFile(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_initWithFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Sprite:initWithFile"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Sprite:initWithFile"); if (!ok) { break; } bool ret = cobj->initWithFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Sprite:initWithFile"); if (!ok) { break; } bool ret = cobj->initWithFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:initWithFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_initWithFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.Sprite:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_getTextureAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_getTextureAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_getTextureAtlas'", nullptr); return 0; } cocos2d::TextureAtlas* ret = cobj->getTextureAtlas(); object_to_luaval<cocos2d::TextureAtlas>(tolua_S, "cc.TextureAtlas",(cocos2d::TextureAtlas*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:getTextureAtlas",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_getTextureAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_initWithSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_initWithSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.Sprite:initWithSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_initWithSpriteFrame'", nullptr); return 0; } bool ret = cobj->initWithSpriteFrame(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:initWithSpriteFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_initWithSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_isFlippedX(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_isFlippedX'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_isFlippedX'", nullptr); return 0; } bool ret = cobj->isFlippedX(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:isFlippedX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_isFlippedX'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_isFlippedY(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_isFlippedY'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_isFlippedY'", nullptr); return 0; } bool ret = cobj->isFlippedY(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:isFlippedY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_isFlippedY'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_setVertexRect(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Sprite*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Sprite_setVertexRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Sprite:setVertexRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_setVertexRect'", nullptr); return 0; } cobj->setVertexRect(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:setVertexRect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_setVertexRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_createWithTexture(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Sprite:createWithTexture"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Sprite:createWithTexture"); if (!ok) { break; } cocos2d::Sprite* ret = cocos2d::Sprite::createWithTexture(arg0, arg1); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Sprite:createWithTexture"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Sprite:createWithTexture"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.Sprite:createWithTexture"); if (!ok) { break; } cocos2d::Sprite* ret = cocos2d::Sprite::createWithTexture(arg0, arg1, arg2); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } } while (0); ok = true; do { if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.Sprite:createWithTexture"); if (!ok) { break; } cocos2d::Sprite* ret = cocos2d::Sprite::createWithTexture(arg0); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.Sprite:createWithTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_createWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_createWithSpriteFrameName(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Sprite:createWithSpriteFrameName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_createWithSpriteFrameName'", nullptr); return 0; } cocos2d::Sprite* ret = cocos2d::Sprite::createWithSpriteFrameName(arg0); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Sprite:createWithSpriteFrameName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_createWithSpriteFrameName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_createWithSpriteFrame(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Sprite",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::SpriteFrame* arg0 = nullptr; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.Sprite:createWithSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_createWithSpriteFrame'", nullptr); return 0; } cocos2d::Sprite* ret = cocos2d::Sprite::createWithSpriteFrame(arg0); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Sprite:createWithSpriteFrame",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_createWithSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Sprite_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Sprite* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Sprite_constructor'", nullptr); return 0; } cobj = new cocos2d::Sprite(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Sprite"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Sprite:Sprite",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Sprite_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Sprite_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Sprite)"); return 0; } int lua_register_cocos2dx_Sprite(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Sprite"); tolua_cclass(tolua_S,"Sprite","cc.Sprite","cc.Node",nullptr); tolua_beginmodule(tolua_S,"Sprite"); tolua_function(tolua_S,"new",lua_cocos2dx_Sprite_constructor); tolua_function(tolua_S,"setSpriteFrame",lua_cocos2dx_Sprite_setSpriteFrame); tolua_function(tolua_S,"setTexture",lua_cocos2dx_Sprite_setTexture); tolua_function(tolua_S,"getTexture",lua_cocos2dx_Sprite_getTexture); tolua_function(tolua_S,"setFlippedY",lua_cocos2dx_Sprite_setFlippedY); tolua_function(tolua_S,"setFlippedX",lua_cocos2dx_Sprite_setFlippedX); tolua_function(tolua_S,"getResourceType",lua_cocos2dx_Sprite_getResourceType); tolua_function(tolua_S,"setDisplayFrameWithAnimationName",lua_cocos2dx_Sprite_setDisplayFrameWithAnimationName); tolua_function(tolua_S,"getBatchNode",lua_cocos2dx_Sprite_getBatchNode); tolua_function(tolua_S,"getOffsetPosition",lua_cocos2dx_Sprite_getOffsetPosition); tolua_function(tolua_S,"getCenterRect",lua_cocos2dx_Sprite_getCenterRect); tolua_function(tolua_S,"removeAllChildrenWithCleanup",lua_cocos2dx_Sprite_removeAllChildrenWithCleanup); tolua_function(tolua_S,"setCenterRectNormalized",lua_cocos2dx_Sprite_setCenterRectNormalized); tolua_function(tolua_S,"isStretchEnabled",lua_cocos2dx_Sprite_isStretchEnabled); tolua_function(tolua_S,"setTextureRect",lua_cocos2dx_Sprite_setTextureRect); tolua_function(tolua_S,"initWithSpriteFrameName",lua_cocos2dx_Sprite_initWithSpriteFrameName); tolua_function(tolua_S,"setStretchEnabled",lua_cocos2dx_Sprite_setStretchEnabled); tolua_function(tolua_S,"isFrameDisplayed",lua_cocos2dx_Sprite_isFrameDisplayed); tolua_function(tolua_S,"getAtlasIndex",lua_cocos2dx_Sprite_getAtlasIndex); tolua_function(tolua_S,"setBatchNode",lua_cocos2dx_Sprite_setBatchNode); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_Sprite_getBlendFunc); tolua_function(tolua_S,"setCenterRect",lua_cocos2dx_Sprite_setCenterRect); tolua_function(tolua_S,"setTextureAtlas",lua_cocos2dx_Sprite_setTextureAtlas); tolua_function(tolua_S,"getSpriteFrame",lua_cocos2dx_Sprite_getSpriteFrame); tolua_function(tolua_S,"getResourceName",lua_cocos2dx_Sprite_getResourceName); tolua_function(tolua_S,"isDirty",lua_cocos2dx_Sprite_isDirty); tolua_function(tolua_S,"getCenterRectNormalized",lua_cocos2dx_Sprite_getCenterRectNormalized); tolua_function(tolua_S,"setAtlasIndex",lua_cocos2dx_Sprite_setAtlasIndex); tolua_function(tolua_S,"initWithTexture",lua_cocos2dx_Sprite_initWithTexture); tolua_function(tolua_S,"setDirty",lua_cocos2dx_Sprite_setDirty); tolua_function(tolua_S,"isTextureRectRotated",lua_cocos2dx_Sprite_isTextureRectRotated); tolua_function(tolua_S,"getTextureRect",lua_cocos2dx_Sprite_getTextureRect); tolua_function(tolua_S,"initWithFile",lua_cocos2dx_Sprite_initWithFile); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_Sprite_setBlendFunc); tolua_function(tolua_S,"getTextureAtlas",lua_cocos2dx_Sprite_getTextureAtlas); tolua_function(tolua_S,"initWithSpriteFrame",lua_cocos2dx_Sprite_initWithSpriteFrame); tolua_function(tolua_S,"isFlippedX",lua_cocos2dx_Sprite_isFlippedX); tolua_function(tolua_S,"isFlippedY",lua_cocos2dx_Sprite_isFlippedY); tolua_function(tolua_S,"setVertexRect",lua_cocos2dx_Sprite_setVertexRect); tolua_function(tolua_S,"createWithTexture", lua_cocos2dx_Sprite_createWithTexture); tolua_function(tolua_S,"createWithSpriteFrameName", lua_cocos2dx_Sprite_createWithSpriteFrameName); tolua_function(tolua_S,"createWithSpriteFrame", lua_cocos2dx_Sprite_createWithSpriteFrame); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Sprite).name(); g_luaType[typeName] = "cc.Sprite"; g_typeCast["Sprite"] = "cc.Sprite"; return 1; } int lua_cocos2dx_RenderTexture_setVirtualViewport(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_setVirtualViewport'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Vec2 arg0; cocos2d::Rect arg1; cocos2d::Rect arg2; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.RenderTexture:setVirtualViewport"); ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.RenderTexture:setVirtualViewport"); ok &= luaval_to_rect(tolua_S, 4, &arg2, "cc.RenderTexture:setVirtualViewport"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_setVirtualViewport'", nullptr); return 0; } cobj->setVirtualViewport(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:setVirtualViewport",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_setVirtualViewport'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_clearStencil(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_clearStencil'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.RenderTexture:clearStencil"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_clearStencil'", nullptr); return 0; } cobj->clearStencil(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:clearStencil",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_clearStencil'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_getClearDepth(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_getClearDepth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_getClearDepth'", nullptr); return 0; } double ret = cobj->getClearDepth(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:getClearDepth",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_getClearDepth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_getClearStencil(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_getClearStencil'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_getClearStencil'", nullptr); return 0; } int ret = cobj->getClearStencil(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:getClearStencil",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_getClearStencil'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_setClearStencil(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_setClearStencil'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.RenderTexture:setClearStencil"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_setClearStencil'", nullptr); return 0; } cobj->setClearStencil(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:setClearStencil",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_setClearStencil'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_setSprite(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_setSprite'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Sprite* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.RenderTexture:setSprite"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_setSprite'", nullptr); return 0; } cobj->setSprite(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:setSprite",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_setSprite'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_getSprite(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_getSprite'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_getSprite'", nullptr); return 0; } cocos2d::Sprite* ret = cobj->getSprite(); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:getSprite",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_getSprite'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_isAutoDraw(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_isAutoDraw'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_isAutoDraw'", nullptr); return 0; } bool ret = cobj->isAutoDraw(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:isAutoDraw",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_isAutoDraw'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_setKeepMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_setKeepMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.RenderTexture:setKeepMatrix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_setKeepMatrix'", nullptr); return 0; } cobj->setKeepMatrix(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:setKeepMatrix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_setKeepMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_setClearFlags(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_setClearFlags'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned int arg0; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.RenderTexture:setClearFlags"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_setClearFlags'", nullptr); return 0; } cobj->setClearFlags(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:setClearFlags",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_setClearFlags'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_begin(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_begin'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_begin'", nullptr); return 0; } cobj->begin(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:begin",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_begin'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_saveToFile(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_saveToFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.RenderTexture:saveToFile"); if (!ok) { break; } cocos2d::Image::Format arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.RenderTexture:saveToFile"); if (!ok) { break; } bool ret = cobj->saveToFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.RenderTexture:saveToFile"); if (!ok) { break; } cocos2d::Image::Format arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.RenderTexture:saveToFile"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.RenderTexture:saveToFile"); if (!ok) { break; } bool ret = cobj->saveToFile(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.RenderTexture:saveToFile"); if (!ok) { break; } cocos2d::Image::Format arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.RenderTexture:saveToFile"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.RenderTexture:saveToFile"); if (!ok) { break; } std::function<void (cocos2d::RenderTexture *, const std::basic_string<char> &)> arg3; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } bool ret = cobj->saveToFile(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.RenderTexture:saveToFile"); if (!ok) { break; } bool ret = cobj->saveToFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.RenderTexture:saveToFile"); if (!ok) { break; } bool arg1; ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.RenderTexture:saveToFile"); if (!ok) { break; } bool ret = cobj->saveToFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.RenderTexture:saveToFile"); if (!ok) { break; } bool arg1; ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.RenderTexture:saveToFile"); if (!ok) { break; } std::function<void (cocos2d::RenderTexture *, const std::basic_string<char> &)> arg2; do { // Lambda binding for lua is not supported. assert(false); } while(0) ; if (!ok) { break; } bool ret = cobj->saveToFile(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:saveToFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_saveToFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_setAutoDraw(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_setAutoDraw'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.RenderTexture:setAutoDraw"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_setAutoDraw'", nullptr); return 0; } cobj->setAutoDraw(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:setAutoDraw",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_setAutoDraw'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_setClearColor(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_setClearColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4F arg0; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.RenderTexture:setClearColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_setClearColor'", nullptr); return 0; } cobj->setClearColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:setClearColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_setClearColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_end(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_end'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_end'", nullptr); return 0; } cobj->end(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:end",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_end'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_beginWithClear(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_beginWithClear'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg3; ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg4; ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } cobj->beginWithClear(arg0, arg1, arg2, arg3, arg4); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 4) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg3; ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } cobj->beginWithClear(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 6) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg3; ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } double arg4; ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } int arg5; ok &= luaval_to_int32(tolua_S, 7,(int *)&arg5, "cc.RenderTexture:beginWithClear"); if (!ok) { break; } cobj->beginWithClear(arg0, arg1, arg2, arg3, arg4, arg5); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:beginWithClear",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_beginWithClear'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_clearDepth(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_clearDepth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RenderTexture:clearDepth"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_clearDepth'", nullptr); return 0; } cobj->clearDepth(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:clearDepth",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_clearDepth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_getClearColor(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_getClearColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_getClearColor'", nullptr); return 0; } const cocos2d::Color4F& ret = cobj->getClearColor(); color4f_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:getClearColor",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_getClearColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_clear(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_clear'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; double arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RenderTexture:clear"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.RenderTexture:clear"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.RenderTexture:clear"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.RenderTexture:clear"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_clear'", nullptr); return 0; } cobj->clear(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:clear",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_clear'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_getClearFlags(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_getClearFlags'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_getClearFlags'", nullptr); return 0; } unsigned int ret = cobj->getClearFlags(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:getClearFlags",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_getClearFlags'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_newImage(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_newImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_newImage'", nullptr); return 0; } cocos2d::Image* ret = cobj->newImage(); object_to_luaval<cocos2d::Image>(tolua_S, "cc.Image",(cocos2d::Image*)ret); return 1; } if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.RenderTexture:newImage"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_newImage'", nullptr); return 0; } cocos2d::Image* ret = cobj->newImage(arg0); object_to_luaval<cocos2d::Image>(tolua_S, "cc.Image",(cocos2d::Image*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:newImage",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_newImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_setClearDepth(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_setClearDepth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.RenderTexture:setClearDepth"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_setClearDepth'", nullptr); return 0; } cobj->setClearDepth(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:setClearDepth",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_setClearDepth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_initWithWidthAndHeight(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderTexture*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderTexture_initWithWidthAndHeight'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 4) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.RenderTexture:initWithWidthAndHeight"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.RenderTexture:initWithWidthAndHeight"); if (!ok) { break; } cocos2d::Texture2D::PixelFormat arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.RenderTexture:initWithWidthAndHeight"); if (!ok) { break; } unsigned int arg3; ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.RenderTexture:initWithWidthAndHeight"); if (!ok) { break; } bool ret = cobj->initWithWidthAndHeight(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.RenderTexture:initWithWidthAndHeight"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.RenderTexture:initWithWidthAndHeight"); if (!ok) { break; } cocos2d::Texture2D::PixelFormat arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.RenderTexture:initWithWidthAndHeight"); if (!ok) { break; } bool ret = cobj->initWithWidthAndHeight(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:initWithWidthAndHeight",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_initWithWidthAndHeight'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.RenderTexture",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 3) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.RenderTexture:create"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.RenderTexture:create"); if (!ok) { break; } cocos2d::Texture2D::PixelFormat arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.RenderTexture:create"); if (!ok) { break; } cocos2d::RenderTexture* ret = cocos2d::RenderTexture::create(arg0, arg1, arg2); object_to_luaval<cocos2d::RenderTexture>(tolua_S, "cc.RenderTexture",(cocos2d::RenderTexture*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.RenderTexture:create"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.RenderTexture:create"); if (!ok) { break; } cocos2d::Texture2D::PixelFormat arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.RenderTexture:create"); if (!ok) { break; } unsigned int arg3; ok &= luaval_to_uint32(tolua_S, 5,&arg3, "cc.RenderTexture:create"); if (!ok) { break; } cocos2d::RenderTexture* ret = cocos2d::RenderTexture::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::RenderTexture>(tolua_S, "cc.RenderTexture",(cocos2d::RenderTexture*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.RenderTexture:create"); if (!ok) { break; } int arg1; ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.RenderTexture:create"); if (!ok) { break; } cocos2d::RenderTexture* ret = cocos2d::RenderTexture::create(arg0, arg1); object_to_luaval<cocos2d::RenderTexture>(tolua_S, "cc.RenderTexture",(cocos2d::RenderTexture*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.RenderTexture:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderTexture_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::RenderTexture* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderTexture_constructor'", nullptr); return 0; } cobj = new cocos2d::RenderTexture(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.RenderTexture"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderTexture:RenderTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderTexture_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_RenderTexture_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (RenderTexture)"); return 0; } int lua_register_cocos2dx_RenderTexture(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.RenderTexture"); tolua_cclass(tolua_S,"RenderTexture","cc.RenderTexture","cc.Node",nullptr); tolua_beginmodule(tolua_S,"RenderTexture"); tolua_function(tolua_S,"new",lua_cocos2dx_RenderTexture_constructor); tolua_function(tolua_S,"setVirtualViewport",lua_cocos2dx_RenderTexture_setVirtualViewport); tolua_function(tolua_S,"clearStencil",lua_cocos2dx_RenderTexture_clearStencil); tolua_function(tolua_S,"getClearDepth",lua_cocos2dx_RenderTexture_getClearDepth); tolua_function(tolua_S,"getClearStencil",lua_cocos2dx_RenderTexture_getClearStencil); tolua_function(tolua_S,"setClearStencil",lua_cocos2dx_RenderTexture_setClearStencil); tolua_function(tolua_S,"setSprite",lua_cocos2dx_RenderTexture_setSprite); tolua_function(tolua_S,"getSprite",lua_cocos2dx_RenderTexture_getSprite); tolua_function(tolua_S,"isAutoDraw",lua_cocos2dx_RenderTexture_isAutoDraw); tolua_function(tolua_S,"setKeepMatrix",lua_cocos2dx_RenderTexture_setKeepMatrix); tolua_function(tolua_S,"setClearFlags",lua_cocos2dx_RenderTexture_setClearFlags); tolua_function(tolua_S,"begin",lua_cocos2dx_RenderTexture_begin); tolua_function(tolua_S,"saveToFile",lua_cocos2dx_RenderTexture_saveToFile); tolua_function(tolua_S,"setAutoDraw",lua_cocos2dx_RenderTexture_setAutoDraw); tolua_function(tolua_S,"setClearColor",lua_cocos2dx_RenderTexture_setClearColor); tolua_function(tolua_S,"endToLua",lua_cocos2dx_RenderTexture_end); tolua_function(tolua_S,"beginWithClear",lua_cocos2dx_RenderTexture_beginWithClear); tolua_function(tolua_S,"clearDepth",lua_cocos2dx_RenderTexture_clearDepth); tolua_function(tolua_S,"getClearColor",lua_cocos2dx_RenderTexture_getClearColor); tolua_function(tolua_S,"clear",lua_cocos2dx_RenderTexture_clear); tolua_function(tolua_S,"getClearFlags",lua_cocos2dx_RenderTexture_getClearFlags); tolua_function(tolua_S,"newImage",lua_cocos2dx_RenderTexture_newImage); tolua_function(tolua_S,"setClearDepth",lua_cocos2dx_RenderTexture_setClearDepth); tolua_function(tolua_S,"initWithWidthAndHeight",lua_cocos2dx_RenderTexture_initWithWidthAndHeight); tolua_function(tolua_S,"create", lua_cocos2dx_RenderTexture_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::RenderTexture).name(); g_luaType[typeName] = "cc.RenderTexture"; g_typeCast["RenderTexture"] = "cc.RenderTexture"; return 1; } int lua_cocos2dx_TransitionEaseScene_easeActionWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionEaseScene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionEaseScene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionEaseScene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionEaseScene_easeActionWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.TransitionEaseScene:easeActionWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionEaseScene_easeActionWithAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->easeActionWithAction(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionEaseScene:easeActionWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionEaseScene_easeActionWithAction'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionEaseScene_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionEaseScene)"); return 0; } int lua_register_cocos2dx_TransitionEaseScene(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionEaseScene"); tolua_cclass(tolua_S,"TransitionEaseScene","cc.TransitionEaseScene","",nullptr); tolua_beginmodule(tolua_S,"TransitionEaseScene"); tolua_function(tolua_S,"easeActionWithAction",lua_cocos2dx_TransitionEaseScene_easeActionWithAction); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionEaseScene).name(); g_luaType[typeName] = "cc.TransitionEaseScene"; g_typeCast["TransitionEaseScene"] = "cc.TransitionEaseScene"; return 1; } int lua_cocos2dx_TransitionScene_getInScene(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionScene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionScene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionScene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionScene_getInScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionScene_getInScene'", nullptr); return 0; } cocos2d::Scene* ret = cobj->getInScene(); object_to_luaval<cocos2d::Scene>(tolua_S, "cc.Scene",(cocos2d::Scene*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionScene:getInScene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionScene_getInScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionScene_finish(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionScene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionScene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionScene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionScene_finish'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionScene_finish'", nullptr); return 0; } cobj->finish(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionScene:finish",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionScene_finish'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionScene_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionScene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionScene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionScene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionScene_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionScene:initWithDuration"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionScene:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionScene_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionScene:initWithDuration",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionScene_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionScene_getDuration(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionScene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionScene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionScene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionScene_getDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionScene_getDuration'", nullptr); return 0; } double ret = cobj->getDuration(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionScene:getDuration",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionScene_getDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionScene_hideOutShowIn(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionScene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionScene",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionScene*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionScene_hideOutShowIn'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionScene_hideOutShowIn'", nullptr); return 0; } cobj->hideOutShowIn(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionScene:hideOutShowIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionScene_hideOutShowIn'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionScene_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionScene",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionScene:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionScene:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionScene_create'", nullptr); return 0; } cocos2d::TransitionScene* ret = cocos2d::TransitionScene::create(arg0, arg1); object_to_luaval<cocos2d::TransitionScene>(tolua_S, "cc.TransitionScene",(cocos2d::TransitionScene*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionScene:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionScene_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionScene_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionScene* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionScene_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionScene(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionScene"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionScene:TransitionScene",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionScene_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionScene_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionScene)"); return 0; } int lua_register_cocos2dx_TransitionScene(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionScene"); tolua_cclass(tolua_S,"TransitionScene","cc.TransitionScene","cc.Scene",nullptr); tolua_beginmodule(tolua_S,"TransitionScene"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionScene_constructor); tolua_function(tolua_S,"getInScene",lua_cocos2dx_TransitionScene_getInScene); tolua_function(tolua_S,"finish",lua_cocos2dx_TransitionScene_finish); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TransitionScene_initWithDuration); tolua_function(tolua_S,"getDuration",lua_cocos2dx_TransitionScene_getDuration); tolua_function(tolua_S,"hideOutShowIn",lua_cocos2dx_TransitionScene_hideOutShowIn); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionScene_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionScene).name(); g_luaType[typeName] = "cc.TransitionScene"; g_typeCast["TransitionScene"] = "cc.TransitionScene"; return 1; } int lua_cocos2dx_TransitionSceneOriented_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSceneOriented* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionSceneOriented",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionSceneOriented*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionSceneOriented_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; cocos2d::Scene* arg1 = nullptr; cocos2d::TransitionScene::Orientation arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionSceneOriented:initWithDuration"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionSceneOriented:initWithDuration"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TransitionSceneOriented:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSceneOriented_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSceneOriented:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSceneOriented_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSceneOriented_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionSceneOriented",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { double arg0; cocos2d::Scene* arg1 = nullptr; cocos2d::TransitionScene::Orientation arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionSceneOriented:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionSceneOriented:create"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TransitionSceneOriented:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSceneOriented_create'", nullptr); return 0; } cocos2d::TransitionSceneOriented* ret = cocos2d::TransitionSceneOriented::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionSceneOriented>(tolua_S, "cc.TransitionSceneOriented",(cocos2d::TransitionSceneOriented*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionSceneOriented:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSceneOriented_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSceneOriented_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSceneOriented* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSceneOriented_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionSceneOriented(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionSceneOriented"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSceneOriented:TransitionSceneOriented",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSceneOriented_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionSceneOriented_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionSceneOriented)"); return 0; } int lua_register_cocos2dx_TransitionSceneOriented(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionSceneOriented"); tolua_cclass(tolua_S,"TransitionSceneOriented","cc.TransitionSceneOriented","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionSceneOriented"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionSceneOriented_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TransitionSceneOriented_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSceneOriented_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionSceneOriented).name(); g_luaType[typeName] = "cc.TransitionSceneOriented"; g_typeCast["TransitionSceneOriented"] = "cc.TransitionSceneOriented"; return 1; } int lua_cocos2dx_TransitionRotoZoom_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionRotoZoom",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionRotoZoom:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionRotoZoom:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionRotoZoom_create'", nullptr); return 0; } cocos2d::TransitionRotoZoom* ret = cocos2d::TransitionRotoZoom::create(arg0, arg1); object_to_luaval<cocos2d::TransitionRotoZoom>(tolua_S, "cc.TransitionRotoZoom",(cocos2d::TransitionRotoZoom*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionRotoZoom:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionRotoZoom_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionRotoZoom_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionRotoZoom* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionRotoZoom_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionRotoZoom(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionRotoZoom"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionRotoZoom:TransitionRotoZoom",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionRotoZoom_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionRotoZoom_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionRotoZoom)"); return 0; } int lua_register_cocos2dx_TransitionRotoZoom(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionRotoZoom"); tolua_cclass(tolua_S,"TransitionRotoZoom","cc.TransitionRotoZoom","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionRotoZoom"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionRotoZoom_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionRotoZoom_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionRotoZoom).name(); g_luaType[typeName] = "cc.TransitionRotoZoom"; g_typeCast["TransitionRotoZoom"] = "cc.TransitionRotoZoom"; return 1; } int lua_cocos2dx_TransitionJumpZoom_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionJumpZoom",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionJumpZoom:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionJumpZoom:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionJumpZoom_create'", nullptr); return 0; } cocos2d::TransitionJumpZoom* ret = cocos2d::TransitionJumpZoom::create(arg0, arg1); object_to_luaval<cocos2d::TransitionJumpZoom>(tolua_S, "cc.TransitionJumpZoom",(cocos2d::TransitionJumpZoom*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionJumpZoom:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionJumpZoom_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionJumpZoom_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionJumpZoom* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionJumpZoom_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionJumpZoom(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionJumpZoom"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionJumpZoom:TransitionJumpZoom",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionJumpZoom_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionJumpZoom_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionJumpZoom)"); return 0; } int lua_register_cocos2dx_TransitionJumpZoom(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionJumpZoom"); tolua_cclass(tolua_S,"TransitionJumpZoom","cc.TransitionJumpZoom","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionJumpZoom"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionJumpZoom_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionJumpZoom_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionJumpZoom).name(); g_luaType[typeName] = "cc.TransitionJumpZoom"; g_typeCast["TransitionJumpZoom"] = "cc.TransitionJumpZoom"; return 1; } int lua_cocos2dx_TransitionMoveInL_action(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionMoveInL* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionMoveInL",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionMoveInL*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionMoveInL_action'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInL_action'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->action(); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionMoveInL:action",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInL_action'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionMoveInL_easeActionWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionMoveInL* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionMoveInL",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionMoveInL*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionMoveInL_easeActionWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.TransitionMoveInL:easeActionWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInL_easeActionWithAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->easeActionWithAction(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionMoveInL:easeActionWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInL_easeActionWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionMoveInL_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionMoveInL",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionMoveInL:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionMoveInL:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInL_create'", nullptr); return 0; } cocos2d::TransitionMoveInL* ret = cocos2d::TransitionMoveInL::create(arg0, arg1); object_to_luaval<cocos2d::TransitionMoveInL>(tolua_S, "cc.TransitionMoveInL",(cocos2d::TransitionMoveInL*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionMoveInL:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInL_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionMoveInL_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionMoveInL* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInL_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionMoveInL(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionMoveInL"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionMoveInL:TransitionMoveInL",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInL_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionMoveInL_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionMoveInL)"); return 0; } int lua_register_cocos2dx_TransitionMoveInL(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionMoveInL"); tolua_cclass(tolua_S,"TransitionMoveInL","cc.TransitionMoveInL","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionMoveInL"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionMoveInL_constructor); tolua_function(tolua_S,"action",lua_cocos2dx_TransitionMoveInL_action); tolua_function(tolua_S,"easeActionWithAction",lua_cocos2dx_TransitionMoveInL_easeActionWithAction); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionMoveInL_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionMoveInL).name(); g_luaType[typeName] = "cc.TransitionMoveInL"; g_typeCast["TransitionMoveInL"] = "cc.TransitionMoveInL"; return 1; } int lua_cocos2dx_TransitionMoveInR_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionMoveInR",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionMoveInR:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionMoveInR:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInR_create'", nullptr); return 0; } cocos2d::TransitionMoveInR* ret = cocos2d::TransitionMoveInR::create(arg0, arg1); object_to_luaval<cocos2d::TransitionMoveInR>(tolua_S, "cc.TransitionMoveInR",(cocos2d::TransitionMoveInR*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionMoveInR:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInR_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionMoveInR_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionMoveInR* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInR_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionMoveInR(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionMoveInR"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionMoveInR:TransitionMoveInR",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInR_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionMoveInR_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionMoveInR)"); return 0; } int lua_register_cocos2dx_TransitionMoveInR(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionMoveInR"); tolua_cclass(tolua_S,"TransitionMoveInR","cc.TransitionMoveInR","cc.TransitionMoveInL",nullptr); tolua_beginmodule(tolua_S,"TransitionMoveInR"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionMoveInR_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionMoveInR_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionMoveInR).name(); g_luaType[typeName] = "cc.TransitionMoveInR"; g_typeCast["TransitionMoveInR"] = "cc.TransitionMoveInR"; return 1; } int lua_cocos2dx_TransitionMoveInT_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionMoveInT",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionMoveInT:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionMoveInT:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInT_create'", nullptr); return 0; } cocos2d::TransitionMoveInT* ret = cocos2d::TransitionMoveInT::create(arg0, arg1); object_to_luaval<cocos2d::TransitionMoveInT>(tolua_S, "cc.TransitionMoveInT",(cocos2d::TransitionMoveInT*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionMoveInT:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInT_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionMoveInT_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionMoveInT* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInT_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionMoveInT(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionMoveInT"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionMoveInT:TransitionMoveInT",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInT_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionMoveInT_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionMoveInT)"); return 0; } int lua_register_cocos2dx_TransitionMoveInT(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionMoveInT"); tolua_cclass(tolua_S,"TransitionMoveInT","cc.TransitionMoveInT","cc.TransitionMoveInL",nullptr); tolua_beginmodule(tolua_S,"TransitionMoveInT"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionMoveInT_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionMoveInT_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionMoveInT).name(); g_luaType[typeName] = "cc.TransitionMoveInT"; g_typeCast["TransitionMoveInT"] = "cc.TransitionMoveInT"; return 1; } int lua_cocos2dx_TransitionMoveInB_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionMoveInB",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionMoveInB:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionMoveInB:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInB_create'", nullptr); return 0; } cocos2d::TransitionMoveInB* ret = cocos2d::TransitionMoveInB::create(arg0, arg1); object_to_luaval<cocos2d::TransitionMoveInB>(tolua_S, "cc.TransitionMoveInB",(cocos2d::TransitionMoveInB*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionMoveInB:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInB_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionMoveInB_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionMoveInB* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionMoveInB_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionMoveInB(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionMoveInB"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionMoveInB:TransitionMoveInB",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionMoveInB_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionMoveInB_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionMoveInB)"); return 0; } int lua_register_cocos2dx_TransitionMoveInB(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionMoveInB"); tolua_cclass(tolua_S,"TransitionMoveInB","cc.TransitionMoveInB","cc.TransitionMoveInL",nullptr); tolua_beginmodule(tolua_S,"TransitionMoveInB"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionMoveInB_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionMoveInB_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionMoveInB).name(); g_luaType[typeName] = "cc.TransitionMoveInB"; g_typeCast["TransitionMoveInB"] = "cc.TransitionMoveInB"; return 1; } int lua_cocos2dx_TransitionSlideInL_action(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSlideInL* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionSlideInL",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionSlideInL*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionSlideInL_action'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInL_action'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->action(); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInL:action",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInL_action'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSlideInL_easeActionWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSlideInL* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionSlideInL",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionSlideInL*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionSlideInL_easeActionWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.TransitionSlideInL:easeActionWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInL_easeActionWithAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->easeActionWithAction(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInL:easeActionWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInL_easeActionWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSlideInL_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionSlideInL",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionSlideInL:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionSlideInL:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInL_create'", nullptr); return 0; } cocos2d::TransitionSlideInL* ret = cocos2d::TransitionSlideInL::create(arg0, arg1); object_to_luaval<cocos2d::TransitionSlideInL>(tolua_S, "cc.TransitionSlideInL",(cocos2d::TransitionSlideInL*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionSlideInL:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInL_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSlideInL_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSlideInL* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInL_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionSlideInL(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionSlideInL"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInL:TransitionSlideInL",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInL_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionSlideInL_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionSlideInL)"); return 0; } int lua_register_cocos2dx_TransitionSlideInL(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionSlideInL"); tolua_cclass(tolua_S,"TransitionSlideInL","cc.TransitionSlideInL","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionSlideInL"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionSlideInL_constructor); tolua_function(tolua_S,"action",lua_cocos2dx_TransitionSlideInL_action); tolua_function(tolua_S,"easeActionWithAction",lua_cocos2dx_TransitionSlideInL_easeActionWithAction); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSlideInL_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionSlideInL).name(); g_luaType[typeName] = "cc.TransitionSlideInL"; g_typeCast["TransitionSlideInL"] = "cc.TransitionSlideInL"; return 1; } int lua_cocos2dx_TransitionSlideInR_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionSlideInR",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionSlideInR:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionSlideInR:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInR_create'", nullptr); return 0; } cocos2d::TransitionSlideInR* ret = cocos2d::TransitionSlideInR::create(arg0, arg1); object_to_luaval<cocos2d::TransitionSlideInR>(tolua_S, "cc.TransitionSlideInR",(cocos2d::TransitionSlideInR*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionSlideInR:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInR_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSlideInR_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSlideInR* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInR_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionSlideInR(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionSlideInR"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInR:TransitionSlideInR",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInR_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionSlideInR_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionSlideInR)"); return 0; } int lua_register_cocos2dx_TransitionSlideInR(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionSlideInR"); tolua_cclass(tolua_S,"TransitionSlideInR","cc.TransitionSlideInR","cc.TransitionSlideInL",nullptr); tolua_beginmodule(tolua_S,"TransitionSlideInR"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionSlideInR_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSlideInR_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionSlideInR).name(); g_luaType[typeName] = "cc.TransitionSlideInR"; g_typeCast["TransitionSlideInR"] = "cc.TransitionSlideInR"; return 1; } int lua_cocos2dx_TransitionSlideInB_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionSlideInB",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionSlideInB:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionSlideInB:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInB_create'", nullptr); return 0; } cocos2d::TransitionSlideInB* ret = cocos2d::TransitionSlideInB::create(arg0, arg1); object_to_luaval<cocos2d::TransitionSlideInB>(tolua_S, "cc.TransitionSlideInB",(cocos2d::TransitionSlideInB*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionSlideInB:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInB_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSlideInB_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSlideInB* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInB_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionSlideInB(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionSlideInB"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInB:TransitionSlideInB",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInB_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionSlideInB_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionSlideInB)"); return 0; } int lua_register_cocos2dx_TransitionSlideInB(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionSlideInB"); tolua_cclass(tolua_S,"TransitionSlideInB","cc.TransitionSlideInB","cc.TransitionSlideInL",nullptr); tolua_beginmodule(tolua_S,"TransitionSlideInB"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionSlideInB_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSlideInB_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionSlideInB).name(); g_luaType[typeName] = "cc.TransitionSlideInB"; g_typeCast["TransitionSlideInB"] = "cc.TransitionSlideInB"; return 1; } int lua_cocos2dx_TransitionSlideInT_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionSlideInT",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionSlideInT:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionSlideInT:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInT_create'", nullptr); return 0; } cocos2d::TransitionSlideInT* ret = cocos2d::TransitionSlideInT::create(arg0, arg1); object_to_luaval<cocos2d::TransitionSlideInT>(tolua_S, "cc.TransitionSlideInT",(cocos2d::TransitionSlideInT*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionSlideInT:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInT_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSlideInT_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSlideInT* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSlideInT_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionSlideInT(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionSlideInT"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSlideInT:TransitionSlideInT",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSlideInT_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionSlideInT_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionSlideInT)"); return 0; } int lua_register_cocos2dx_TransitionSlideInT(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionSlideInT"); tolua_cclass(tolua_S,"TransitionSlideInT","cc.TransitionSlideInT","cc.TransitionSlideInL",nullptr); tolua_beginmodule(tolua_S,"TransitionSlideInT"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionSlideInT_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSlideInT_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionSlideInT).name(); g_luaType[typeName] = "cc.TransitionSlideInT"; g_typeCast["TransitionSlideInT"] = "cc.TransitionSlideInT"; return 1; } int lua_cocos2dx_TransitionShrinkGrow_easeActionWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionShrinkGrow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionShrinkGrow",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionShrinkGrow*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionShrinkGrow_easeActionWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.TransitionShrinkGrow:easeActionWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionShrinkGrow_easeActionWithAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->easeActionWithAction(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionShrinkGrow:easeActionWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionShrinkGrow_easeActionWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionShrinkGrow_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionShrinkGrow",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionShrinkGrow:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionShrinkGrow:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionShrinkGrow_create'", nullptr); return 0; } cocos2d::TransitionShrinkGrow* ret = cocos2d::TransitionShrinkGrow::create(arg0, arg1); object_to_luaval<cocos2d::TransitionShrinkGrow>(tolua_S, "cc.TransitionShrinkGrow",(cocos2d::TransitionShrinkGrow*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionShrinkGrow:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionShrinkGrow_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionShrinkGrow_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionShrinkGrow* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionShrinkGrow_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionShrinkGrow(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionShrinkGrow"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionShrinkGrow:TransitionShrinkGrow",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionShrinkGrow_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionShrinkGrow_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionShrinkGrow)"); return 0; } int lua_register_cocos2dx_TransitionShrinkGrow(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionShrinkGrow"); tolua_cclass(tolua_S,"TransitionShrinkGrow","cc.TransitionShrinkGrow","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionShrinkGrow"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionShrinkGrow_constructor); tolua_function(tolua_S,"easeActionWithAction",lua_cocos2dx_TransitionShrinkGrow_easeActionWithAction); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionShrinkGrow_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionShrinkGrow).name(); g_luaType[typeName] = "cc.TransitionShrinkGrow"; g_typeCast["TransitionShrinkGrow"] = "cc.TransitionShrinkGrow"; return 1; } int lua_cocos2dx_TransitionFlipX_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionFlipX",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFlipX:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFlipX:create"); if (!ok) { break; } cocos2d::TransitionFlipX* ret = cocos2d::TransitionFlipX::create(arg0, arg1); object_to_luaval<cocos2d::TransitionFlipX>(tolua_S, "cc.TransitionFlipX",(cocos2d::TransitionFlipX*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFlipX:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFlipX:create"); if (!ok) { break; } cocos2d::TransitionScene::Orientation arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TransitionFlipX:create"); if (!ok) { break; } cocos2d::TransitionFlipX* ret = cocos2d::TransitionFlipX::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionFlipX>(tolua_S, "cc.TransitionFlipX",(cocos2d::TransitionFlipX*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TransitionFlipX:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFlipX_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFlipX_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFlipX* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFlipX_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionFlipX(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionFlipX"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFlipX:TransitionFlipX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFlipX_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionFlipX_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionFlipX)"); return 0; } int lua_register_cocos2dx_TransitionFlipX(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionFlipX"); tolua_cclass(tolua_S,"TransitionFlipX","cc.TransitionFlipX","cc.TransitionSceneOriented",nullptr); tolua_beginmodule(tolua_S,"TransitionFlipX"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionFlipX_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionFlipX_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionFlipX).name(); g_luaType[typeName] = "cc.TransitionFlipX"; g_typeCast["TransitionFlipX"] = "cc.TransitionFlipX"; return 1; } int lua_cocos2dx_TransitionFlipY_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionFlipY",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFlipY:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFlipY:create"); if (!ok) { break; } cocos2d::TransitionFlipY* ret = cocos2d::TransitionFlipY::create(arg0, arg1); object_to_luaval<cocos2d::TransitionFlipY>(tolua_S, "cc.TransitionFlipY",(cocos2d::TransitionFlipY*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFlipY:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFlipY:create"); if (!ok) { break; } cocos2d::TransitionScene::Orientation arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TransitionFlipY:create"); if (!ok) { break; } cocos2d::TransitionFlipY* ret = cocos2d::TransitionFlipY::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionFlipY>(tolua_S, "cc.TransitionFlipY",(cocos2d::TransitionFlipY*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TransitionFlipY:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFlipY_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFlipY_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFlipY* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFlipY_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionFlipY(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionFlipY"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFlipY:TransitionFlipY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFlipY_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionFlipY_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionFlipY)"); return 0; } int lua_register_cocos2dx_TransitionFlipY(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionFlipY"); tolua_cclass(tolua_S,"TransitionFlipY","cc.TransitionFlipY","cc.TransitionSceneOriented",nullptr); tolua_beginmodule(tolua_S,"TransitionFlipY"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionFlipY_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionFlipY_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionFlipY).name(); g_luaType[typeName] = "cc.TransitionFlipY"; g_typeCast["TransitionFlipY"] = "cc.TransitionFlipY"; return 1; } int lua_cocos2dx_TransitionFlipAngular_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionFlipAngular",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFlipAngular:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFlipAngular:create"); if (!ok) { break; } cocos2d::TransitionFlipAngular* ret = cocos2d::TransitionFlipAngular::create(arg0, arg1); object_to_luaval<cocos2d::TransitionFlipAngular>(tolua_S, "cc.TransitionFlipAngular",(cocos2d::TransitionFlipAngular*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFlipAngular:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFlipAngular:create"); if (!ok) { break; } cocos2d::TransitionScene::Orientation arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TransitionFlipAngular:create"); if (!ok) { break; } cocos2d::TransitionFlipAngular* ret = cocos2d::TransitionFlipAngular::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionFlipAngular>(tolua_S, "cc.TransitionFlipAngular",(cocos2d::TransitionFlipAngular*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TransitionFlipAngular:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFlipAngular_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFlipAngular_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFlipAngular* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFlipAngular_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionFlipAngular(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionFlipAngular"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFlipAngular:TransitionFlipAngular",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFlipAngular_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionFlipAngular_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionFlipAngular)"); return 0; } int lua_register_cocos2dx_TransitionFlipAngular(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionFlipAngular"); tolua_cclass(tolua_S,"TransitionFlipAngular","cc.TransitionFlipAngular","cc.TransitionSceneOriented",nullptr); tolua_beginmodule(tolua_S,"TransitionFlipAngular"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionFlipAngular_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionFlipAngular_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionFlipAngular).name(); g_luaType[typeName] = "cc.TransitionFlipAngular"; g_typeCast["TransitionFlipAngular"] = "cc.TransitionFlipAngular"; return 1; } int lua_cocos2dx_TransitionZoomFlipX_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionZoomFlipX",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionZoomFlipX:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionZoomFlipX:create"); if (!ok) { break; } cocos2d::TransitionZoomFlipX* ret = cocos2d::TransitionZoomFlipX::create(arg0, arg1); object_to_luaval<cocos2d::TransitionZoomFlipX>(tolua_S, "cc.TransitionZoomFlipX",(cocos2d::TransitionZoomFlipX*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionZoomFlipX:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionZoomFlipX:create"); if (!ok) { break; } cocos2d::TransitionScene::Orientation arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TransitionZoomFlipX:create"); if (!ok) { break; } cocos2d::TransitionZoomFlipX* ret = cocos2d::TransitionZoomFlipX::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionZoomFlipX>(tolua_S, "cc.TransitionZoomFlipX",(cocos2d::TransitionZoomFlipX*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TransitionZoomFlipX:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionZoomFlipX_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionZoomFlipX_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionZoomFlipX* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionZoomFlipX_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionZoomFlipX(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionZoomFlipX"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionZoomFlipX:TransitionZoomFlipX",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionZoomFlipX_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionZoomFlipX_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionZoomFlipX)"); return 0; } int lua_register_cocos2dx_TransitionZoomFlipX(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionZoomFlipX"); tolua_cclass(tolua_S,"TransitionZoomFlipX","cc.TransitionZoomFlipX","cc.TransitionSceneOriented",nullptr); tolua_beginmodule(tolua_S,"TransitionZoomFlipX"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionZoomFlipX_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionZoomFlipX_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionZoomFlipX).name(); g_luaType[typeName] = "cc.TransitionZoomFlipX"; g_typeCast["TransitionZoomFlipX"] = "cc.TransitionZoomFlipX"; return 1; } int lua_cocos2dx_TransitionZoomFlipY_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionZoomFlipY",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionZoomFlipY:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionZoomFlipY:create"); if (!ok) { break; } cocos2d::TransitionZoomFlipY* ret = cocos2d::TransitionZoomFlipY::create(arg0, arg1); object_to_luaval<cocos2d::TransitionZoomFlipY>(tolua_S, "cc.TransitionZoomFlipY",(cocos2d::TransitionZoomFlipY*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionZoomFlipY:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionZoomFlipY:create"); if (!ok) { break; } cocos2d::TransitionScene::Orientation arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TransitionZoomFlipY:create"); if (!ok) { break; } cocos2d::TransitionZoomFlipY* ret = cocos2d::TransitionZoomFlipY::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionZoomFlipY>(tolua_S, "cc.TransitionZoomFlipY",(cocos2d::TransitionZoomFlipY*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TransitionZoomFlipY:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionZoomFlipY_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionZoomFlipY_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionZoomFlipY* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionZoomFlipY_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionZoomFlipY(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionZoomFlipY"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionZoomFlipY:TransitionZoomFlipY",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionZoomFlipY_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionZoomFlipY_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionZoomFlipY)"); return 0; } int lua_register_cocos2dx_TransitionZoomFlipY(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionZoomFlipY"); tolua_cclass(tolua_S,"TransitionZoomFlipY","cc.TransitionZoomFlipY","cc.TransitionSceneOriented",nullptr); tolua_beginmodule(tolua_S,"TransitionZoomFlipY"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionZoomFlipY_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionZoomFlipY_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionZoomFlipY).name(); g_luaType[typeName] = "cc.TransitionZoomFlipY"; g_typeCast["TransitionZoomFlipY"] = "cc.TransitionZoomFlipY"; return 1; } int lua_cocos2dx_TransitionZoomFlipAngular_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionZoomFlipAngular",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionZoomFlipAngular:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionZoomFlipAngular:create"); if (!ok) { break; } cocos2d::TransitionZoomFlipAngular* ret = cocos2d::TransitionZoomFlipAngular::create(arg0, arg1); object_to_luaval<cocos2d::TransitionZoomFlipAngular>(tolua_S, "cc.TransitionZoomFlipAngular",(cocos2d::TransitionZoomFlipAngular*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionZoomFlipAngular:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionZoomFlipAngular:create"); if (!ok) { break; } cocos2d::TransitionScene::Orientation arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TransitionZoomFlipAngular:create"); if (!ok) { break; } cocos2d::TransitionZoomFlipAngular* ret = cocos2d::TransitionZoomFlipAngular::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionZoomFlipAngular>(tolua_S, "cc.TransitionZoomFlipAngular",(cocos2d::TransitionZoomFlipAngular*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TransitionZoomFlipAngular:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionZoomFlipAngular_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionZoomFlipAngular_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionZoomFlipAngular* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionZoomFlipAngular_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionZoomFlipAngular(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionZoomFlipAngular"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionZoomFlipAngular:TransitionZoomFlipAngular",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionZoomFlipAngular_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionZoomFlipAngular_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionZoomFlipAngular)"); return 0; } int lua_register_cocos2dx_TransitionZoomFlipAngular(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionZoomFlipAngular"); tolua_cclass(tolua_S,"TransitionZoomFlipAngular","cc.TransitionZoomFlipAngular","cc.TransitionSceneOriented",nullptr); tolua_beginmodule(tolua_S,"TransitionZoomFlipAngular"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionZoomFlipAngular_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionZoomFlipAngular_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionZoomFlipAngular).name(); g_luaType[typeName] = "cc.TransitionZoomFlipAngular"; g_typeCast["TransitionZoomFlipAngular"] = "cc.TransitionZoomFlipAngular"; return 1; } int lua_cocos2dx_TransitionFade_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFade* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionFade",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionFade*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionFade_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFade:initWithDuration"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFade:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFade:initWithDuration"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFade:initWithDuration"); if (!ok) { break; } cocos2d::Color3B arg2; ok &= luaval_to_color3b(tolua_S, 4, &arg2, "cc.TransitionFade:initWithDuration"); if (!ok) { break; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFade:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFade_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFade_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionFade",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFade:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFade:create"); if (!ok) { break; } cocos2d::TransitionFade* ret = cocos2d::TransitionFade::create(arg0, arg1); object_to_luaval<cocos2d::TransitionFade>(tolua_S, "cc.TransitionFade",(cocos2d::TransitionFade*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFade:create"); if (!ok) { break; } cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFade:create"); if (!ok) { break; } cocos2d::Color3B arg2; ok &= luaval_to_color3b(tolua_S, 4, &arg2, "cc.TransitionFade:create"); if (!ok) { break; } cocos2d::TransitionFade* ret = cocos2d::TransitionFade::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionFade>(tolua_S, "cc.TransitionFade",(cocos2d::TransitionFade*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TransitionFade:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFade_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFade_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFade* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFade_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionFade(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionFade"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFade:TransitionFade",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFade_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionFade_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionFade)"); return 0; } int lua_register_cocos2dx_TransitionFade(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionFade"); tolua_cclass(tolua_S,"TransitionFade","cc.TransitionFade","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionFade"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionFade_constructor); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TransitionFade_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionFade_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionFade).name(); g_luaType[typeName] = "cc.TransitionFade"; g_typeCast["TransitionFade"] = "cc.TransitionFade"; return 1; } int lua_cocos2dx_TransitionCrossFade_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionCrossFade",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionCrossFade:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionCrossFade:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionCrossFade_create'", nullptr); return 0; } cocos2d::TransitionCrossFade* ret = cocos2d::TransitionCrossFade::create(arg0, arg1); object_to_luaval<cocos2d::TransitionCrossFade>(tolua_S, "cc.TransitionCrossFade",(cocos2d::TransitionCrossFade*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionCrossFade:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionCrossFade_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionCrossFade_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionCrossFade* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionCrossFade_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionCrossFade(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionCrossFade"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionCrossFade:TransitionCrossFade",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionCrossFade_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionCrossFade_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionCrossFade)"); return 0; } int lua_register_cocos2dx_TransitionCrossFade(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionCrossFade"); tolua_cclass(tolua_S,"TransitionCrossFade","cc.TransitionCrossFade","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionCrossFade"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionCrossFade_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionCrossFade_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionCrossFade).name(); g_luaType[typeName] = "cc.TransitionCrossFade"; g_typeCast["TransitionCrossFade"] = "cc.TransitionCrossFade"; return 1; } int lua_cocos2dx_TransitionTurnOffTiles_easeActionWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionTurnOffTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionTurnOffTiles",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionTurnOffTiles*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionTurnOffTiles_easeActionWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.TransitionTurnOffTiles:easeActionWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionTurnOffTiles_easeActionWithAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->easeActionWithAction(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionTurnOffTiles:easeActionWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionTurnOffTiles_easeActionWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionTurnOffTiles_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionTurnOffTiles",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionTurnOffTiles:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionTurnOffTiles:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionTurnOffTiles_create'", nullptr); return 0; } cocos2d::TransitionTurnOffTiles* ret = cocos2d::TransitionTurnOffTiles::create(arg0, arg1); object_to_luaval<cocos2d::TransitionTurnOffTiles>(tolua_S, "cc.TransitionTurnOffTiles",(cocos2d::TransitionTurnOffTiles*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionTurnOffTiles:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionTurnOffTiles_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionTurnOffTiles_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionTurnOffTiles* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionTurnOffTiles_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionTurnOffTiles(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionTurnOffTiles"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionTurnOffTiles:TransitionTurnOffTiles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionTurnOffTiles_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionTurnOffTiles_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionTurnOffTiles)"); return 0; } int lua_register_cocos2dx_TransitionTurnOffTiles(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionTurnOffTiles"); tolua_cclass(tolua_S,"TransitionTurnOffTiles","cc.TransitionTurnOffTiles","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionTurnOffTiles"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionTurnOffTiles_constructor); tolua_function(tolua_S,"easeActionWithAction",lua_cocos2dx_TransitionTurnOffTiles_easeActionWithAction); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionTurnOffTiles_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionTurnOffTiles).name(); g_luaType[typeName] = "cc.TransitionTurnOffTiles"; g_typeCast["TransitionTurnOffTiles"] = "cc.TransitionTurnOffTiles"; return 1; } int lua_cocos2dx_TransitionSplitCols_action(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSplitCols* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionSplitCols",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionSplitCols*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionSplitCols_action'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSplitCols_action'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->action(); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSplitCols:action",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSplitCols_action'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSplitCols_easeActionWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSplitCols* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionSplitCols",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionSplitCols*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionSplitCols_easeActionWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.TransitionSplitCols:easeActionWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSplitCols_easeActionWithAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->easeActionWithAction(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSplitCols:easeActionWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSplitCols_easeActionWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSplitCols_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionSplitCols",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionSplitCols:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionSplitCols:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSplitCols_create'", nullptr); return 0; } cocos2d::TransitionSplitCols* ret = cocos2d::TransitionSplitCols::create(arg0, arg1); object_to_luaval<cocos2d::TransitionSplitCols>(tolua_S, "cc.TransitionSplitCols",(cocos2d::TransitionSplitCols*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionSplitCols:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSplitCols_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSplitCols_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSplitCols* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSplitCols_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionSplitCols(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionSplitCols"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSplitCols:TransitionSplitCols",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSplitCols_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionSplitCols_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionSplitCols)"); return 0; } int lua_register_cocos2dx_TransitionSplitCols(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionSplitCols"); tolua_cclass(tolua_S,"TransitionSplitCols","cc.TransitionSplitCols","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionSplitCols"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionSplitCols_constructor); tolua_function(tolua_S,"action",lua_cocos2dx_TransitionSplitCols_action); tolua_function(tolua_S,"easeActionWithAction",lua_cocos2dx_TransitionSplitCols_easeActionWithAction); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSplitCols_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionSplitCols).name(); g_luaType[typeName] = "cc.TransitionSplitCols"; g_typeCast["TransitionSplitCols"] = "cc.TransitionSplitCols"; return 1; } int lua_cocos2dx_TransitionSplitRows_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionSplitRows",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionSplitRows:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionSplitRows:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSplitRows_create'", nullptr); return 0; } cocos2d::TransitionSplitRows* ret = cocos2d::TransitionSplitRows::create(arg0, arg1); object_to_luaval<cocos2d::TransitionSplitRows>(tolua_S, "cc.TransitionSplitRows",(cocos2d::TransitionSplitRows*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionSplitRows:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSplitRows_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionSplitRows_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionSplitRows* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionSplitRows_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionSplitRows(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionSplitRows"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionSplitRows:TransitionSplitRows",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionSplitRows_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionSplitRows_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionSplitRows)"); return 0; } int lua_register_cocos2dx_TransitionSplitRows(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionSplitRows"); tolua_cclass(tolua_S,"TransitionSplitRows","cc.TransitionSplitRows","cc.TransitionSplitCols",nullptr); tolua_beginmodule(tolua_S,"TransitionSplitRows"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionSplitRows_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionSplitRows_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionSplitRows).name(); g_luaType[typeName] = "cc.TransitionSplitRows"; g_typeCast["TransitionSplitRows"] = "cc.TransitionSplitRows"; return 1; } int lua_cocos2dx_TransitionFadeTR_easeActionWithAction(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFadeTR* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionFadeTR",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionFadeTR*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionFadeTR_easeActionWithAction'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ActionInterval* arg0 = nullptr; ok &= luaval_to_object<cocos2d::ActionInterval>(tolua_S, 2, "cc.ActionInterval",&arg0, "cc.TransitionFadeTR:easeActionWithAction"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeTR_easeActionWithAction'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->easeActionWithAction(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFadeTR:easeActionWithAction",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeTR_easeActionWithAction'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFadeTR_actionWithSize(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFadeTR* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionFadeTR",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionFadeTR*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionFadeTR_actionWithSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TransitionFadeTR:actionWithSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeTR_actionWithSize'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->actionWithSize(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFadeTR:actionWithSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeTR_actionWithSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFadeTR_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionFadeTR",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFadeTR:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFadeTR:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeTR_create'", nullptr); return 0; } cocos2d::TransitionFadeTR* ret = cocos2d::TransitionFadeTR::create(arg0, arg1); object_to_luaval<cocos2d::TransitionFadeTR>(tolua_S, "cc.TransitionFadeTR",(cocos2d::TransitionFadeTR*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionFadeTR:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeTR_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFadeTR_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFadeTR* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeTR_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionFadeTR(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionFadeTR"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFadeTR:TransitionFadeTR",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeTR_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionFadeTR_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionFadeTR)"); return 0; } int lua_register_cocos2dx_TransitionFadeTR(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionFadeTR"); tolua_cclass(tolua_S,"TransitionFadeTR","cc.TransitionFadeTR","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionFadeTR"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionFadeTR_constructor); tolua_function(tolua_S,"easeActionWithAction",lua_cocos2dx_TransitionFadeTR_easeActionWithAction); tolua_function(tolua_S,"actionWithSize",lua_cocos2dx_TransitionFadeTR_actionWithSize); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionFadeTR_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionFadeTR).name(); g_luaType[typeName] = "cc.TransitionFadeTR"; g_typeCast["TransitionFadeTR"] = "cc.TransitionFadeTR"; return 1; } int lua_cocos2dx_TransitionFadeBL_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionFadeBL",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFadeBL:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFadeBL:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeBL_create'", nullptr); return 0; } cocos2d::TransitionFadeBL* ret = cocos2d::TransitionFadeBL::create(arg0, arg1); object_to_luaval<cocos2d::TransitionFadeBL>(tolua_S, "cc.TransitionFadeBL",(cocos2d::TransitionFadeBL*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionFadeBL:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeBL_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFadeBL_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFadeBL* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeBL_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionFadeBL(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionFadeBL"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFadeBL:TransitionFadeBL",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeBL_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionFadeBL_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionFadeBL)"); return 0; } int lua_register_cocos2dx_TransitionFadeBL(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionFadeBL"); tolua_cclass(tolua_S,"TransitionFadeBL","cc.TransitionFadeBL","cc.TransitionFadeTR",nullptr); tolua_beginmodule(tolua_S,"TransitionFadeBL"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionFadeBL_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionFadeBL_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionFadeBL).name(); g_luaType[typeName] = "cc.TransitionFadeBL"; g_typeCast["TransitionFadeBL"] = "cc.TransitionFadeBL"; return 1; } int lua_cocos2dx_TransitionFadeUp_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionFadeUp",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFadeUp:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFadeUp:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeUp_create'", nullptr); return 0; } cocos2d::TransitionFadeUp* ret = cocos2d::TransitionFadeUp::create(arg0, arg1); object_to_luaval<cocos2d::TransitionFadeUp>(tolua_S, "cc.TransitionFadeUp",(cocos2d::TransitionFadeUp*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionFadeUp:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeUp_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFadeUp_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFadeUp* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeUp_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionFadeUp(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionFadeUp"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFadeUp:TransitionFadeUp",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeUp_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionFadeUp_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionFadeUp)"); return 0; } int lua_register_cocos2dx_TransitionFadeUp(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionFadeUp"); tolua_cclass(tolua_S,"TransitionFadeUp","cc.TransitionFadeUp","cc.TransitionFadeTR",nullptr); tolua_beginmodule(tolua_S,"TransitionFadeUp"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionFadeUp_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionFadeUp_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionFadeUp).name(); g_luaType[typeName] = "cc.TransitionFadeUp"; g_typeCast["TransitionFadeUp"] = "cc.TransitionFadeUp"; return 1; } int lua_cocos2dx_TransitionFadeDown_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionFadeDown",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionFadeDown:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionFadeDown:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeDown_create'", nullptr); return 0; } cocos2d::TransitionFadeDown* ret = cocos2d::TransitionFadeDown::create(arg0, arg1); object_to_luaval<cocos2d::TransitionFadeDown>(tolua_S, "cc.TransitionFadeDown",(cocos2d::TransitionFadeDown*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionFadeDown:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeDown_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionFadeDown_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionFadeDown* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionFadeDown_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionFadeDown(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionFadeDown"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionFadeDown:TransitionFadeDown",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionFadeDown_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionFadeDown_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionFadeDown)"); return 0; } int lua_register_cocos2dx_TransitionFadeDown(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionFadeDown"); tolua_cclass(tolua_S,"TransitionFadeDown","cc.TransitionFadeDown","cc.TransitionFadeTR",nullptr); tolua_beginmodule(tolua_S,"TransitionFadeDown"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionFadeDown_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionFadeDown_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionFadeDown).name(); g_luaType[typeName] = "cc.TransitionFadeDown"; g_typeCast["TransitionFadeDown"] = "cc.TransitionFadeDown"; return 1; } int lua_cocos2dx_TransitionPageTurn_actionWithSize(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionPageTurn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionPageTurn",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionPageTurn*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionPageTurn_actionWithSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TransitionPageTurn:actionWithSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionPageTurn_actionWithSize'", nullptr); return 0; } cocos2d::ActionInterval* ret = cobj->actionWithSize(arg0); object_to_luaval<cocos2d::ActionInterval>(tolua_S, "cc.ActionInterval",(cocos2d::ActionInterval*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionPageTurn:actionWithSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionPageTurn_actionWithSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionPageTurn_initWithDuration(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionPageTurn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TransitionPageTurn",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TransitionPageTurn*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TransitionPageTurn_initWithDuration'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { double arg0; cocos2d::Scene* arg1 = nullptr; bool arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionPageTurn:initWithDuration"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionPageTurn:initWithDuration"); ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.TransitionPageTurn:initWithDuration"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionPageTurn_initWithDuration'", nullptr); return 0; } bool ret = cobj->initWithDuration(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionPageTurn:initWithDuration",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionPageTurn_initWithDuration'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionPageTurn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionPageTurn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { double arg0; cocos2d::Scene* arg1 = nullptr; bool arg2; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionPageTurn:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionPageTurn:create"); ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.TransitionPageTurn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionPageTurn_create'", nullptr); return 0; } cocos2d::TransitionPageTurn* ret = cocos2d::TransitionPageTurn::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TransitionPageTurn>(tolua_S, "cc.TransitionPageTurn",(cocos2d::TransitionPageTurn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionPageTurn:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionPageTurn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionPageTurn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionPageTurn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionPageTurn_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionPageTurn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionPageTurn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionPageTurn:TransitionPageTurn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionPageTurn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionPageTurn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionPageTurn)"); return 0; } int lua_register_cocos2dx_TransitionPageTurn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionPageTurn"); tolua_cclass(tolua_S,"TransitionPageTurn","cc.TransitionPageTurn","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionPageTurn"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionPageTurn_constructor); tolua_function(tolua_S,"actionWithSize",lua_cocos2dx_TransitionPageTurn_actionWithSize); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TransitionPageTurn_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionPageTurn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionPageTurn).name(); g_luaType[typeName] = "cc.TransitionPageTurn"; g_typeCast["TransitionPageTurn"] = "cc.TransitionPageTurn"; return 1; } int lua_cocos2dx_TransitionProgress_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionProgress",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionProgress:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionProgress:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgress_create'", nullptr); return 0; } cocos2d::TransitionProgress* ret = cocos2d::TransitionProgress::create(arg0, arg1); object_to_luaval<cocos2d::TransitionProgress>(tolua_S, "cc.TransitionProgress",(cocos2d::TransitionProgress*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionProgress:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgress_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionProgress_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionProgress* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgress_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionProgress(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgress"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionProgress:TransitionProgress",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgress_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionProgress_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgress)"); return 0; } int lua_register_cocos2dx_TransitionProgress(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionProgress"); tolua_cclass(tolua_S,"TransitionProgress","cc.TransitionProgress","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionProgress"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgress_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgress_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgress).name(); g_luaType[typeName] = "cc.TransitionProgress"; g_typeCast["TransitionProgress"] = "cc.TransitionProgress"; return 1; } int lua_cocos2dx_TransitionProgressRadialCCW_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionProgressRadialCCW",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionProgressRadialCCW:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionProgressRadialCCW:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressRadialCCW_create'", nullptr); return 0; } cocos2d::TransitionProgressRadialCCW* ret = cocos2d::TransitionProgressRadialCCW::create(arg0, arg1); object_to_luaval<cocos2d::TransitionProgressRadialCCW>(tolua_S, "cc.TransitionProgressRadialCCW",(cocos2d::TransitionProgressRadialCCW*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionProgressRadialCCW:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressRadialCCW_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionProgressRadialCCW_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionProgressRadialCCW* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressRadialCCW_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionProgressRadialCCW(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgressRadialCCW"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionProgressRadialCCW:TransitionProgressRadialCCW",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressRadialCCW_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionProgressRadialCCW_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgressRadialCCW)"); return 0; } int lua_register_cocos2dx_TransitionProgressRadialCCW(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionProgressRadialCCW"); tolua_cclass(tolua_S,"TransitionProgressRadialCCW","cc.TransitionProgressRadialCCW","cc.TransitionProgress",nullptr); tolua_beginmodule(tolua_S,"TransitionProgressRadialCCW"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgressRadialCCW_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgressRadialCCW_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgressRadialCCW).name(); g_luaType[typeName] = "cc.TransitionProgressRadialCCW"; g_typeCast["TransitionProgressRadialCCW"] = "cc.TransitionProgressRadialCCW"; return 1; } int lua_cocos2dx_TransitionProgressRadialCW_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionProgressRadialCW",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionProgressRadialCW:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionProgressRadialCW:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressRadialCW_create'", nullptr); return 0; } cocos2d::TransitionProgressRadialCW* ret = cocos2d::TransitionProgressRadialCW::create(arg0, arg1); object_to_luaval<cocos2d::TransitionProgressRadialCW>(tolua_S, "cc.TransitionProgressRadialCW",(cocos2d::TransitionProgressRadialCW*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionProgressRadialCW:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressRadialCW_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionProgressRadialCW_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionProgressRadialCW* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressRadialCW_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionProgressRadialCW(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgressRadialCW"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionProgressRadialCW:TransitionProgressRadialCW",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressRadialCW_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionProgressRadialCW_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgressRadialCW)"); return 0; } int lua_register_cocos2dx_TransitionProgressRadialCW(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionProgressRadialCW"); tolua_cclass(tolua_S,"TransitionProgressRadialCW","cc.TransitionProgressRadialCW","cc.TransitionProgress",nullptr); tolua_beginmodule(tolua_S,"TransitionProgressRadialCW"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgressRadialCW_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgressRadialCW_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgressRadialCW).name(); g_luaType[typeName] = "cc.TransitionProgressRadialCW"; g_typeCast["TransitionProgressRadialCW"] = "cc.TransitionProgressRadialCW"; return 1; } int lua_cocos2dx_TransitionProgressHorizontal_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionProgressHorizontal",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionProgressHorizontal:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionProgressHorizontal:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressHorizontal_create'", nullptr); return 0; } cocos2d::TransitionProgressHorizontal* ret = cocos2d::TransitionProgressHorizontal::create(arg0, arg1); object_to_luaval<cocos2d::TransitionProgressHorizontal>(tolua_S, "cc.TransitionProgressHorizontal",(cocos2d::TransitionProgressHorizontal*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionProgressHorizontal:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressHorizontal_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionProgressHorizontal_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionProgressHorizontal* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressHorizontal_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionProgressHorizontal(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgressHorizontal"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionProgressHorizontal:TransitionProgressHorizontal",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressHorizontal_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionProgressHorizontal_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgressHorizontal)"); return 0; } int lua_register_cocos2dx_TransitionProgressHorizontal(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionProgressHorizontal"); tolua_cclass(tolua_S,"TransitionProgressHorizontal","cc.TransitionProgressHorizontal","cc.TransitionProgress",nullptr); tolua_beginmodule(tolua_S,"TransitionProgressHorizontal"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgressHorizontal_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgressHorizontal_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgressHorizontal).name(); g_luaType[typeName] = "cc.TransitionProgressHorizontal"; g_typeCast["TransitionProgressHorizontal"] = "cc.TransitionProgressHorizontal"; return 1; } int lua_cocos2dx_TransitionProgressVertical_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionProgressVertical",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionProgressVertical:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionProgressVertical:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressVertical_create'", nullptr); return 0; } cocos2d::TransitionProgressVertical* ret = cocos2d::TransitionProgressVertical::create(arg0, arg1); object_to_luaval<cocos2d::TransitionProgressVertical>(tolua_S, "cc.TransitionProgressVertical",(cocos2d::TransitionProgressVertical*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionProgressVertical:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressVertical_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionProgressVertical_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionProgressVertical* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressVertical_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionProgressVertical(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgressVertical"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionProgressVertical:TransitionProgressVertical",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressVertical_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionProgressVertical_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgressVertical)"); return 0; } int lua_register_cocos2dx_TransitionProgressVertical(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionProgressVertical"); tolua_cclass(tolua_S,"TransitionProgressVertical","cc.TransitionProgressVertical","cc.TransitionProgress",nullptr); tolua_beginmodule(tolua_S,"TransitionProgressVertical"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgressVertical_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgressVertical_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgressVertical).name(); g_luaType[typeName] = "cc.TransitionProgressVertical"; g_typeCast["TransitionProgressVertical"] = "cc.TransitionProgressVertical"; return 1; } int lua_cocos2dx_TransitionProgressInOut_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionProgressInOut",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionProgressInOut:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionProgressInOut:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressInOut_create'", nullptr); return 0; } cocos2d::TransitionProgressInOut* ret = cocos2d::TransitionProgressInOut::create(arg0, arg1); object_to_luaval<cocos2d::TransitionProgressInOut>(tolua_S, "cc.TransitionProgressInOut",(cocos2d::TransitionProgressInOut*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionProgressInOut:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressInOut_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionProgressInOut_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionProgressInOut* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressInOut_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionProgressInOut(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgressInOut"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionProgressInOut:TransitionProgressInOut",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressInOut_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionProgressInOut_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgressInOut)"); return 0; } int lua_register_cocos2dx_TransitionProgressInOut(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionProgressInOut"); tolua_cclass(tolua_S,"TransitionProgressInOut","cc.TransitionProgressInOut","cc.TransitionProgress",nullptr); tolua_beginmodule(tolua_S,"TransitionProgressInOut"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgressInOut_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgressInOut_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgressInOut).name(); g_luaType[typeName] = "cc.TransitionProgressInOut"; g_typeCast["TransitionProgressInOut"] = "cc.TransitionProgressInOut"; return 1; } int lua_cocos2dx_TransitionProgressOutIn_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TransitionProgressOutIn",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { double arg0; cocos2d::Scene* arg1 = nullptr; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.TransitionProgressOutIn:create"); ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 3, "cc.Scene",&arg1, "cc.TransitionProgressOutIn:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressOutIn_create'", nullptr); return 0; } cocos2d::TransitionProgressOutIn* ret = cocos2d::TransitionProgressOutIn::create(arg0, arg1); object_to_luaval<cocos2d::TransitionProgressOutIn>(tolua_S, "cc.TransitionProgressOutIn",(cocos2d::TransitionProgressOutIn*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TransitionProgressOutIn:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressOutIn_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TransitionProgressOutIn_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TransitionProgressOutIn* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TransitionProgressOutIn_constructor'", nullptr); return 0; } cobj = new cocos2d::TransitionProgressOutIn(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgressOutIn"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TransitionProgressOutIn:TransitionProgressOutIn",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgressOutIn_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TransitionProgressOutIn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgressOutIn)"); return 0; } int lua_register_cocos2dx_TransitionProgressOutIn(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TransitionProgressOutIn"); tolua_cclass(tolua_S,"TransitionProgressOutIn","cc.TransitionProgressOutIn","cc.TransitionProgress",nullptr); tolua_beginmodule(tolua_S,"TransitionProgressOutIn"); tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgressOutIn_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgressOutIn_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgressOutIn).name(); g_luaType[typeName] = "cc.TransitionProgressOutIn"; g_typeCast["TransitionProgressOutIn"] = "cc.TransitionProgressOutIn"; return 1; } int lua_cocos2dx_Camera_restore(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_restore'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_restore'", nullptr); return 0; } cobj->restore(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:restore",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_restore'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getDepth(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getDepth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getDepth'", nullptr); return 0; } int32_t ret = cobj->getDepth(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getDepth",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getDepth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getViewProjectionMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getViewProjectionMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getViewProjectionMatrix'", nullptr); return 0; } const cocos2d::Mat4& ret = cobj->getViewProjectionMatrix(); mat4_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getViewProjectionMatrix",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getViewProjectionMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_applyViewport(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_applyViewport'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_applyViewport'", nullptr); return 0; } cobj->applyViewport(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:applyViewport",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_applyViewport'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_setBackgroundBrush(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_setBackgroundBrush'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::CameraBackgroundBrush* arg0 = nullptr; ok &= luaval_to_object<cocos2d::CameraBackgroundBrush>(tolua_S, 2, "cc.CameraBackgroundBrush",&arg0, "cc.Camera:setBackgroundBrush"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_setBackgroundBrush'", nullptr); return 0; } cobj->setBackgroundBrush(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:setBackgroundBrush",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_setBackgroundBrush'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_lookAt(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_lookAt'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.Camera:lookAt"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_lookAt'", nullptr); return 0; } cobj->lookAt(arg0); lua_settop(tolua_S, 1); return 1; } if (argc == 2) { cocos2d::Vec3 arg0; cocos2d::Vec3 arg1; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.Camera:lookAt"); ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.Camera:lookAt"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_lookAt'", nullptr); return 0; } cobj->lookAt(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:lookAt",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_lookAt'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_apply(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_apply'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_apply'", nullptr); return 0; } cobj->apply(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:apply",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_apply'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getBackgroundBrush(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getBackgroundBrush'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getBackgroundBrush'", nullptr); return 0; } cocos2d::CameraBackgroundBrush* ret = cobj->getBackgroundBrush(); object_to_luaval<cocos2d::CameraBackgroundBrush>(tolua_S, "cc.CameraBackgroundBrush",(cocos2d::CameraBackgroundBrush*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getBackgroundBrush",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getBackgroundBrush'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getProjectionMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getProjectionMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getProjectionMatrix'", nullptr); return 0; } const cocos2d::Mat4& ret = cobj->getProjectionMatrix(); mat4_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getProjectionMatrix",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getProjectionMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_isBrushValid(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_isBrushValid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_isBrushValid'", nullptr); return 0; } bool ret = cobj->isBrushValid(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:isBrushValid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_isBrushValid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getDepthInView(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getDepthInView'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Mat4 arg0; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.Camera:getDepthInView"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getDepthInView'", nullptr); return 0; } double ret = cobj->getDepthInView(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getDepthInView",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getDepthInView'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_restoreViewport(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_restoreViewport'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_restoreViewport'", nullptr); return 0; } cobj->restoreViewport(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:restoreViewport",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_restoreViewport'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_clearBackground(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_clearBackground'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_clearBackground'", nullptr); return 0; } cobj->clearBackground(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:clearBackground",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_clearBackground'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_setAdditionalProjection(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_setAdditionalProjection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Mat4 arg0; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.Camera:setAdditionalProjection"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_setAdditionalProjection'", nullptr); return 0; } cobj->setAdditionalProjection(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:setAdditionalProjection",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_setAdditionalProjection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_setViewport(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_setViewport'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::experimental::Viewport arg0; #pragma warning NO CONVERSION TO NATIVE FOR Viewport ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_setViewport'", nullptr); return 0; } cobj->setViewport(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:setViewport",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_setViewport'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_initDefault(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_initDefault'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_initDefault'", nullptr); return 0; } bool ret = cobj->initDefault(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:initDefault",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_initDefault'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getCameraFlag(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getCameraFlag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getCameraFlag'", nullptr); return 0; } int ret = (int)cobj->getCameraFlag(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getCameraFlag",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getCameraFlag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getType(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getType'", nullptr); return 0; } int ret = (int)cobj->getType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_initOrthographic(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_initOrthographic'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; double arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Camera:initOrthographic"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Camera:initOrthographic"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Camera:initOrthographic"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Camera:initOrthographic"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_initOrthographic'", nullptr); return 0; } bool ret = cobj->initOrthographic(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:initOrthographic",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_initOrthographic'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getRenderOrder(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getRenderOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getRenderOrder'", nullptr); return 0; } int ret = cobj->getRenderOrder(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getRenderOrder",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getRenderOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_isVisibleInFrustum(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_isVisibleInFrustum'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { const cocos2d::AABB* arg0 = nullptr; ok &= luaval_to_object<const cocos2d::AABB>(tolua_S, 2, "cc.AABB",&arg0, "cc.Camera:isVisibleInFrustum"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_isVisibleInFrustum'", nullptr); return 0; } bool ret = cobj->isVisibleInFrustum(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:isVisibleInFrustum",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_isVisibleInFrustum'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_setDepth(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_setDepth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int32_t arg0; ok &= luaval_to_int32(tolua_S, 2,&arg0, "cc.Camera:setDepth"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_setDepth'", nullptr); return 0; } cobj->setDepth(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:setDepth",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_setDepth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_setScene(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_setScene'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Scene* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Scene>(tolua_S, 2, "cc.Scene",&arg0, "cc.Camera:setScene"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_setScene'", nullptr); return 0; } cobj->setScene(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:setScene",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_setScene'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_projectGL(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_projectGL'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.Camera:projectGL"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_projectGL'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->projectGL(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:projectGL",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_projectGL'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_restoreFrameBufferObject(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_restoreFrameBufferObject'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_restoreFrameBufferObject'", nullptr); return 0; } cobj->restoreFrameBufferObject(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:restoreFrameBufferObject",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_restoreFrameBufferObject'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getViewMatrix(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getViewMatrix'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getViewMatrix'", nullptr); return 0; } const cocos2d::Mat4& ret = cobj->getViewMatrix(); mat4_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getViewMatrix",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getViewMatrix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getNearPlane(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getNearPlane'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getNearPlane'", nullptr); return 0; } double ret = cobj->getNearPlane(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getNearPlane",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getNearPlane'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_project(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_project'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.Camera:project"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_project'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->project(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:project",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_project'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_setCameraFlag(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_setCameraFlag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::CameraFlag arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.Camera:setCameraFlag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_setCameraFlag'", nullptr); return 0; } cobj->setCameraFlag(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:setCameraFlag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_setCameraFlag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getFarPlane(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_getFarPlane'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getFarPlane'", nullptr); return 0; } double ret = cobj->getFarPlane(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:getFarPlane",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getFarPlane'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_applyFrameBufferObject(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_applyFrameBufferObject'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_applyFrameBufferObject'", nullptr); return 0; } cobj->applyFrameBufferObject(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:applyFrameBufferObject",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_applyFrameBufferObject'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_setFrameBufferObject(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_setFrameBufferObject'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::experimental::FrameBuffer* arg0 = nullptr; ok &= luaval_to_object<cocos2d::experimental::FrameBuffer>(tolua_S, 2, "ccexp.FrameBuffer",&arg0, "cc.Camera:setFrameBufferObject"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_setFrameBufferObject'", nullptr); return 0; } cobj->setFrameBufferObject(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:setFrameBufferObject",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_setFrameBufferObject'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_isViewProjectionUpdated(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_isViewProjectionUpdated'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_isViewProjectionUpdated'", nullptr); return 0; } bool ret = cobj->isViewProjectionUpdated(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:isViewProjectionUpdated",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_isViewProjectionUpdated'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_initPerspective(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Camera*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Camera_initPerspective'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { double arg0; double arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Camera:initPerspective"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Camera:initPerspective"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Camera:initPerspective"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Camera:initPerspective"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_initPerspective'", nullptr); return 0; } bool ret = cobj->initPerspective(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:initPerspective",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_initPerspective'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_createOrthographic(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; double arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Camera:createOrthographic"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Camera:createOrthographic"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Camera:createOrthographic"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Camera:createOrthographic"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_createOrthographic'", nullptr); return 0; } cocos2d::Camera* ret = cocos2d::Camera::createOrthographic(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Camera>(tolua_S, "cc.Camera",(cocos2d::Camera*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Camera:createOrthographic",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_createOrthographic'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getVisitingCamera(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getVisitingCamera'", nullptr); return 0; } const cocos2d::Camera* ret = cocos2d::Camera::getVisitingCamera(); object_to_luaval<cocos2d::Camera>(tolua_S, "cc.Camera",(cocos2d::Camera*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Camera:getVisitingCamera",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getVisitingCamera'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_create'", nullptr); return 0; } cocos2d::Camera* ret = cocos2d::Camera::create(); object_to_luaval<cocos2d::Camera>(tolua_S, "cc.Camera",(cocos2d::Camera*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Camera:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_createPerspective(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { double arg0; double arg1; double arg2; double arg3; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Camera:createPerspective"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.Camera:createPerspective"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.Camera:createPerspective"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.Camera:createPerspective"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_createPerspective'", nullptr); return 0; } cocos2d::Camera* ret = cocos2d::Camera::createPerspective(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Camera>(tolua_S, "cc.Camera",(cocos2d::Camera*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Camera:createPerspective",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_createPerspective'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getDefaultViewport(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getDefaultViewport'", nullptr); return 0; } const cocos2d::experimental::Viewport& ret = cocos2d::Camera::getDefaultViewport(); #pragma warning NO CONVERSION FROM NATIVE FOR Viewport; return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Camera:getDefaultViewport",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getDefaultViewport'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_setDefaultViewport(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::experimental::Viewport arg0; #pragma warning NO CONVERSION TO NATIVE FOR Viewport ok = false; if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_setDefaultViewport'", nullptr); return 0; } cocos2d::Camera::setDefaultViewport(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Camera:setDefaultViewport",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_setDefaultViewport'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_getDefaultCamera(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Camera",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_getDefaultCamera'", nullptr); return 0; } cocos2d::Camera* ret = cocos2d::Camera::getDefaultCamera(); object_to_luaval<cocos2d::Camera>(tolua_S, "cc.Camera",(cocos2d::Camera*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Camera:getDefaultCamera",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_getDefaultCamera'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Camera_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Camera* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Camera_constructor'", nullptr); return 0; } cobj = new cocos2d::Camera(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Camera"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Camera:Camera",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Camera_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Camera_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Camera)"); return 0; } int lua_register_cocos2dx_Camera(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Camera"); tolua_cclass(tolua_S,"Camera","cc.Camera","cc.Node",nullptr); tolua_beginmodule(tolua_S,"Camera"); tolua_function(tolua_S,"new",lua_cocos2dx_Camera_constructor); tolua_function(tolua_S,"restore",lua_cocos2dx_Camera_restore); tolua_function(tolua_S,"getDepth",lua_cocos2dx_Camera_getDepth); tolua_function(tolua_S,"getViewProjectionMatrix",lua_cocos2dx_Camera_getViewProjectionMatrix); tolua_function(tolua_S,"applyViewport",lua_cocos2dx_Camera_applyViewport); tolua_function(tolua_S,"setBackgroundBrush",lua_cocos2dx_Camera_setBackgroundBrush); tolua_function(tolua_S,"lookAt",lua_cocos2dx_Camera_lookAt); tolua_function(tolua_S,"apply",lua_cocos2dx_Camera_apply); tolua_function(tolua_S,"getBackgroundBrush",lua_cocos2dx_Camera_getBackgroundBrush); tolua_function(tolua_S,"getProjectionMatrix",lua_cocos2dx_Camera_getProjectionMatrix); tolua_function(tolua_S,"isBrushValid",lua_cocos2dx_Camera_isBrushValid); tolua_function(tolua_S,"getDepthInView",lua_cocos2dx_Camera_getDepthInView); tolua_function(tolua_S,"restoreViewport",lua_cocos2dx_Camera_restoreViewport); tolua_function(tolua_S,"clearBackground",lua_cocos2dx_Camera_clearBackground); tolua_function(tolua_S,"setAdditionalProjection",lua_cocos2dx_Camera_setAdditionalProjection); tolua_function(tolua_S,"setViewport",lua_cocos2dx_Camera_setViewport); tolua_function(tolua_S,"initDefault",lua_cocos2dx_Camera_initDefault); tolua_function(tolua_S,"getCameraFlag",lua_cocos2dx_Camera_getCameraFlag); tolua_function(tolua_S,"getType",lua_cocos2dx_Camera_getType); tolua_function(tolua_S,"initOrthographic",lua_cocos2dx_Camera_initOrthographic); tolua_function(tolua_S,"getRenderOrder",lua_cocos2dx_Camera_getRenderOrder); tolua_function(tolua_S,"isVisibleInFrustum",lua_cocos2dx_Camera_isVisibleInFrustum); tolua_function(tolua_S,"setDepth",lua_cocos2dx_Camera_setDepth); tolua_function(tolua_S,"setScene",lua_cocos2dx_Camera_setScene); tolua_function(tolua_S,"projectGL",lua_cocos2dx_Camera_projectGL); tolua_function(tolua_S,"restoreFrameBufferObject",lua_cocos2dx_Camera_restoreFrameBufferObject); tolua_function(tolua_S,"getViewMatrix",lua_cocos2dx_Camera_getViewMatrix); tolua_function(tolua_S,"getNearPlane",lua_cocos2dx_Camera_getNearPlane); tolua_function(tolua_S,"project",lua_cocos2dx_Camera_project); tolua_function(tolua_S,"setCameraFlag",lua_cocos2dx_Camera_setCameraFlag); tolua_function(tolua_S,"getFarPlane",lua_cocos2dx_Camera_getFarPlane); tolua_function(tolua_S,"applyFrameBufferObject",lua_cocos2dx_Camera_applyFrameBufferObject); tolua_function(tolua_S,"setFrameBufferObject",lua_cocos2dx_Camera_setFrameBufferObject); tolua_function(tolua_S,"isViewProjectionUpdated",lua_cocos2dx_Camera_isViewProjectionUpdated); tolua_function(tolua_S,"initPerspective",lua_cocos2dx_Camera_initPerspective); tolua_function(tolua_S,"createOrthographic", lua_cocos2dx_Camera_createOrthographic); tolua_function(tolua_S,"getVisitingCamera", lua_cocos2dx_Camera_getVisitingCamera); tolua_function(tolua_S,"create", lua_cocos2dx_Camera_create); tolua_function(tolua_S,"createPerspective", lua_cocos2dx_Camera_createPerspective); tolua_function(tolua_S,"getDefaultViewport", lua_cocos2dx_Camera_getDefaultViewport); tolua_function(tolua_S,"setDefaultViewport", lua_cocos2dx_Camera_setDefaultViewport); tolua_function(tolua_S,"getDefaultCamera", lua_cocos2dx_Camera_getDefaultCamera); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Camera).name(); g_luaType[typeName] = "cc.Camera"; g_typeCast["Camera"] = "cc.Camera"; return 1; } int lua_cocos2dx_CameraBackgroundBrush_getBrushType(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundBrush_getBrushType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_getBrushType'", nullptr); return 0; } int ret = (int)cobj->getBrushType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundBrush:getBrushType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_getBrushType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundBrush_drawBackground(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundBrush_drawBackground'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Camera* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Camera>(tolua_S, 2, "cc.Camera",&arg0, "cc.CameraBackgroundBrush:drawBackground"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_drawBackground'", nullptr); return 0; } cobj->drawBackground(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundBrush:drawBackground",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_drawBackground'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundBrush_init(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundBrush_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundBrush:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundBrush_isValid(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundBrush_isValid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_isValid'", nullptr); return 0; } bool ret = cobj->isValid(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundBrush:isValid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_isValid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundBrush_createSkyboxBrush(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.CameraBackgroundBrush",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 6) { std::string arg0; std::string arg1; std::string arg2; std::string arg3; std::string arg4; std::string arg5; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.CameraBackgroundBrush:createSkyboxBrush"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.CameraBackgroundBrush:createSkyboxBrush"); ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.CameraBackgroundBrush:createSkyboxBrush"); ok &= luaval_to_std_string(tolua_S, 5,&arg3, "cc.CameraBackgroundBrush:createSkyboxBrush"); ok &= luaval_to_std_string(tolua_S, 6,&arg4, "cc.CameraBackgroundBrush:createSkyboxBrush"); ok &= luaval_to_std_string(tolua_S, 7,&arg5, "cc.CameraBackgroundBrush:createSkyboxBrush"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_createSkyboxBrush'", nullptr); return 0; } cocos2d::CameraBackgroundSkyBoxBrush* ret = cocos2d::CameraBackgroundBrush::createSkyboxBrush(arg0, arg1, arg2, arg3, arg4, arg5); object_to_luaval<cocos2d::CameraBackgroundSkyBoxBrush>(tolua_S, "cc.CameraBackgroundSkyBoxBrush",(cocos2d::CameraBackgroundSkyBoxBrush*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.CameraBackgroundBrush:createSkyboxBrush",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_createSkyboxBrush'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundBrush_createColorBrush(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.CameraBackgroundBrush",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::Color4F arg0; double arg1; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.CameraBackgroundBrush:createColorBrush"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.CameraBackgroundBrush:createColorBrush"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_createColorBrush'", nullptr); return 0; } cocos2d::CameraBackgroundColorBrush* ret = cocos2d::CameraBackgroundBrush::createColorBrush(arg0, arg1); object_to_luaval<cocos2d::CameraBackgroundColorBrush>(tolua_S, "cc.CameraBackgroundColorBrush",(cocos2d::CameraBackgroundColorBrush*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.CameraBackgroundBrush:createColorBrush",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_createColorBrush'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundBrush_createNoneBrush(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.CameraBackgroundBrush",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_createNoneBrush'", nullptr); return 0; } cocos2d::CameraBackgroundBrush* ret = cocos2d::CameraBackgroundBrush::createNoneBrush(); object_to_luaval<cocos2d::CameraBackgroundBrush>(tolua_S, "cc.CameraBackgroundBrush",(cocos2d::CameraBackgroundBrush*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.CameraBackgroundBrush:createNoneBrush",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_createNoneBrush'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundBrush_createDepthBrush(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.CameraBackgroundBrush",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_createDepthBrush'", nullptr); return 0; } cocos2d::CameraBackgroundDepthBrush* ret = cocos2d::CameraBackgroundBrush::createDepthBrush(); object_to_luaval<cocos2d::CameraBackgroundDepthBrush>(tolua_S, "cc.CameraBackgroundDepthBrush",(cocos2d::CameraBackgroundDepthBrush*)ret); return 1; } if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.CameraBackgroundBrush:createDepthBrush"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_createDepthBrush'", nullptr); return 0; } cocos2d::CameraBackgroundDepthBrush* ret = cocos2d::CameraBackgroundBrush::createDepthBrush(arg0); object_to_luaval<cocos2d::CameraBackgroundDepthBrush>(tolua_S, "cc.CameraBackgroundDepthBrush",(cocos2d::CameraBackgroundDepthBrush*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.CameraBackgroundBrush:createDepthBrush",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_createDepthBrush'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundBrush_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundBrush_constructor'", nullptr); return 0; } cobj = new cocos2d::CameraBackgroundBrush(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.CameraBackgroundBrush"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundBrush:CameraBackgroundBrush",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundBrush_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CameraBackgroundBrush_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CameraBackgroundBrush)"); return 0; } int lua_register_cocos2dx_CameraBackgroundBrush(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CameraBackgroundBrush"); tolua_cclass(tolua_S,"CameraBackgroundBrush","cc.CameraBackgroundBrush","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"CameraBackgroundBrush"); tolua_function(tolua_S,"new",lua_cocos2dx_CameraBackgroundBrush_constructor); tolua_function(tolua_S,"getBrushType",lua_cocos2dx_CameraBackgroundBrush_getBrushType); tolua_function(tolua_S,"drawBackground",lua_cocos2dx_CameraBackgroundBrush_drawBackground); tolua_function(tolua_S,"init",lua_cocos2dx_CameraBackgroundBrush_init); tolua_function(tolua_S,"isValid",lua_cocos2dx_CameraBackgroundBrush_isValid); tolua_function(tolua_S,"createSkyboxBrush", lua_cocos2dx_CameraBackgroundBrush_createSkyboxBrush); tolua_function(tolua_S,"createColorBrush", lua_cocos2dx_CameraBackgroundBrush_createColorBrush); tolua_function(tolua_S,"createNoneBrush", lua_cocos2dx_CameraBackgroundBrush_createNoneBrush); tolua_function(tolua_S,"createDepthBrush", lua_cocos2dx_CameraBackgroundBrush_createDepthBrush); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CameraBackgroundBrush).name(); g_luaType[typeName] = "cc.CameraBackgroundBrush"; g_typeCast["CameraBackgroundBrush"] = "cc.CameraBackgroundBrush"; return 1; } int lua_cocos2dx_CameraBackgroundDepthBrush_setDepth(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundDepthBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundDepthBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundDepthBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundDepthBrush_setDepth'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.CameraBackgroundDepthBrush:setDepth"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundDepthBrush_setDepth'", nullptr); return 0; } cobj->setDepth(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundDepthBrush:setDepth",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundDepthBrush_setDepth'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundDepthBrush_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.CameraBackgroundDepthBrush",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.CameraBackgroundDepthBrush:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundDepthBrush_create'", nullptr); return 0; } cocos2d::CameraBackgroundDepthBrush* ret = cocos2d::CameraBackgroundDepthBrush::create(arg0); object_to_luaval<cocos2d::CameraBackgroundDepthBrush>(tolua_S, "cc.CameraBackgroundDepthBrush",(cocos2d::CameraBackgroundDepthBrush*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.CameraBackgroundDepthBrush:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundDepthBrush_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundDepthBrush_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundDepthBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundDepthBrush_constructor'", nullptr); return 0; } cobj = new cocos2d::CameraBackgroundDepthBrush(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.CameraBackgroundDepthBrush"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundDepthBrush:CameraBackgroundDepthBrush",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundDepthBrush_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CameraBackgroundDepthBrush_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CameraBackgroundDepthBrush)"); return 0; } int lua_register_cocos2dx_CameraBackgroundDepthBrush(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CameraBackgroundDepthBrush"); tolua_cclass(tolua_S,"CameraBackgroundDepthBrush","cc.CameraBackgroundDepthBrush","cc.CameraBackgroundBrush",nullptr); tolua_beginmodule(tolua_S,"CameraBackgroundDepthBrush"); tolua_function(tolua_S,"new",lua_cocos2dx_CameraBackgroundDepthBrush_constructor); tolua_function(tolua_S,"setDepth",lua_cocos2dx_CameraBackgroundDepthBrush_setDepth); tolua_function(tolua_S,"create", lua_cocos2dx_CameraBackgroundDepthBrush_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CameraBackgroundDepthBrush).name(); g_luaType[typeName] = "cc.CameraBackgroundDepthBrush"; g_typeCast["CameraBackgroundDepthBrush"] = "cc.CameraBackgroundDepthBrush"; return 1; } int lua_cocos2dx_CameraBackgroundColorBrush_setColor(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundColorBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundColorBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundColorBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundColorBrush_setColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color4F arg0; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.CameraBackgroundColorBrush:setColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundColorBrush_setColor'", nullptr); return 0; } cobj->setColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundColorBrush:setColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundColorBrush_setColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundColorBrush_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.CameraBackgroundColorBrush",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::Color4F arg0; double arg1; ok &=luaval_to_color4f(tolua_S, 2, &arg0, "cc.CameraBackgroundColorBrush:create"); ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.CameraBackgroundColorBrush:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundColorBrush_create'", nullptr); return 0; } cocos2d::CameraBackgroundColorBrush* ret = cocos2d::CameraBackgroundColorBrush::create(arg0, arg1); object_to_luaval<cocos2d::CameraBackgroundColorBrush>(tolua_S, "cc.CameraBackgroundColorBrush",(cocos2d::CameraBackgroundColorBrush*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.CameraBackgroundColorBrush:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundColorBrush_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundColorBrush_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundColorBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundColorBrush_constructor'", nullptr); return 0; } cobj = new cocos2d::CameraBackgroundColorBrush(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.CameraBackgroundColorBrush"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundColorBrush:CameraBackgroundColorBrush",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundColorBrush_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CameraBackgroundColorBrush_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CameraBackgroundColorBrush)"); return 0; } int lua_register_cocos2dx_CameraBackgroundColorBrush(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CameraBackgroundColorBrush"); tolua_cclass(tolua_S,"CameraBackgroundColorBrush","cc.CameraBackgroundColorBrush","cc.CameraBackgroundDepthBrush",nullptr); tolua_beginmodule(tolua_S,"CameraBackgroundColorBrush"); tolua_function(tolua_S,"new",lua_cocos2dx_CameraBackgroundColorBrush_constructor); tolua_function(tolua_S,"setColor",lua_cocos2dx_CameraBackgroundColorBrush_setColor); tolua_function(tolua_S,"create", lua_cocos2dx_CameraBackgroundColorBrush_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CameraBackgroundColorBrush).name(); g_luaType[typeName] = "cc.CameraBackgroundColorBrush"; g_typeCast["CameraBackgroundColorBrush"] = "cc.CameraBackgroundColorBrush"; return 1; } int lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTextureValid(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundSkyBoxBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundSkyBoxBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundSkyBoxBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTextureValid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.CameraBackgroundSkyBoxBrush:setTextureValid"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTextureValid'", nullptr); return 0; } cobj->setTextureValid(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundSkyBoxBrush:setTextureValid",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTextureValid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundSkyBoxBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundSkyBoxBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundSkyBoxBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TextureCube* arg0 = nullptr; ok &= luaval_to_object<cocos2d::TextureCube>(tolua_S, 2, "cc.TextureCube",&arg0, "cc.CameraBackgroundSkyBoxBrush:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundSkyBoxBrush:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundSkyBoxBrush_setActived(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundSkyBoxBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundSkyBoxBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundSkyBoxBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setActived'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.CameraBackgroundSkyBoxBrush:setActived"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setActived'", nullptr); return 0; } cobj->setActived(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundSkyBoxBrush:setActived",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_setActived'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundSkyBoxBrush_isActived(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundSkyBoxBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.CameraBackgroundSkyBoxBrush",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::CameraBackgroundSkyBoxBrush*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_isActived'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_isActived'", nullptr); return 0; } bool ret = cobj->isActived(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundSkyBoxBrush:isActived",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_isActived'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundSkyBoxBrush_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.CameraBackgroundSkyBoxBrush",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 0) { cocos2d::CameraBackgroundSkyBoxBrush* ret = cocos2d::CameraBackgroundSkyBoxBrush::create(); object_to_luaval<cocos2d::CameraBackgroundSkyBoxBrush>(tolua_S, "cc.CameraBackgroundSkyBoxBrush",(cocos2d::CameraBackgroundSkyBoxBrush*)ret); return 1; } } while (0); ok = true; do { if (argc == 6) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.CameraBackgroundSkyBoxBrush:create"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.CameraBackgroundSkyBoxBrush:create"); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.CameraBackgroundSkyBoxBrush:create"); if (!ok) { break; } std::string arg3; ok &= luaval_to_std_string(tolua_S, 5,&arg3, "cc.CameraBackgroundSkyBoxBrush:create"); if (!ok) { break; } std::string arg4; ok &= luaval_to_std_string(tolua_S, 6,&arg4, "cc.CameraBackgroundSkyBoxBrush:create"); if (!ok) { break; } std::string arg5; ok &= luaval_to_std_string(tolua_S, 7,&arg5, "cc.CameraBackgroundSkyBoxBrush:create"); if (!ok) { break; } cocos2d::CameraBackgroundSkyBoxBrush* ret = cocos2d::CameraBackgroundSkyBoxBrush::create(arg0, arg1, arg2, arg3, arg4, arg5); object_to_luaval<cocos2d::CameraBackgroundSkyBoxBrush>(tolua_S, "cc.CameraBackgroundSkyBoxBrush",(cocos2d::CameraBackgroundSkyBoxBrush*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.CameraBackgroundSkyBoxBrush:create",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_CameraBackgroundSkyBoxBrush_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::CameraBackgroundSkyBoxBrush* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_constructor'", nullptr); return 0; } cobj = new cocos2d::CameraBackgroundSkyBoxBrush(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.CameraBackgroundSkyBoxBrush"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.CameraBackgroundSkyBoxBrush:CameraBackgroundSkyBoxBrush",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_CameraBackgroundSkyBoxBrush_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_CameraBackgroundSkyBoxBrush_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (CameraBackgroundSkyBoxBrush)"); return 0; } int lua_register_cocos2dx_CameraBackgroundSkyBoxBrush(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.CameraBackgroundSkyBoxBrush"); tolua_cclass(tolua_S,"CameraBackgroundSkyBoxBrush","cc.CameraBackgroundSkyBoxBrush","cc.CameraBackgroundBrush",nullptr); tolua_beginmodule(tolua_S,"CameraBackgroundSkyBoxBrush"); tolua_function(tolua_S,"new",lua_cocos2dx_CameraBackgroundSkyBoxBrush_constructor); tolua_function(tolua_S,"setTextureValid",lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTextureValid); tolua_function(tolua_S,"setTexture",lua_cocos2dx_CameraBackgroundSkyBoxBrush_setTexture); tolua_function(tolua_S,"setActived",lua_cocos2dx_CameraBackgroundSkyBoxBrush_setActived); tolua_function(tolua_S,"isActived",lua_cocos2dx_CameraBackgroundSkyBoxBrush_isActived); tolua_function(tolua_S,"create", lua_cocos2dx_CameraBackgroundSkyBoxBrush_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::CameraBackgroundSkyBoxBrush).name(); g_luaType[typeName] = "cc.CameraBackgroundSkyBoxBrush"; g_typeCast["CameraBackgroundSkyBoxBrush"] = "cc.CameraBackgroundSkyBoxBrush"; return 1; } int lua_cocos2dx_GridBase_setGridSize(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_setGridSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.GridBase:setGridSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_setGridSize'", nullptr); return 0; } cobj->setGridSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:setGridSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_setGridSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_setGridRect(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_setGridRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Rect arg0; ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.GridBase:setGridRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_setGridRect'", nullptr); return 0; } cobj->setGridRect(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:setGridRect",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_setGridRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_afterBlit(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_afterBlit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_afterBlit'", nullptr); return 0; } cobj->afterBlit(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:afterBlit",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_afterBlit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_getGridRect(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_getGridRect'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_getGridRect'", nullptr); return 0; } const cocos2d::Rect& ret = cobj->getGridRect(); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:getGridRect",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_getGridRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_afterDraw(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_afterDraw'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Node* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.GridBase:afterDraw"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_afterDraw'", nullptr); return 0; } cobj->afterDraw(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:afterDraw",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_afterDraw'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_beforeDraw(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_beforeDraw'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_beforeDraw'", nullptr); return 0; } cobj->beforeDraw(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:beforeDraw",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_beforeDraw'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_calculateVertexPoints(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_calculateVertexPoints'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_calculateVertexPoints'", nullptr); return 0; } cobj->calculateVertexPoints(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:calculateVertexPoints",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_calculateVertexPoints'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_isTextureFlipped(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_isTextureFlipped'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_isTextureFlipped'", nullptr); return 0; } bool ret = cobj->isTextureFlipped(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:isTextureFlipped",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_isTextureFlipped'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_getGridSize(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_getGridSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_getGridSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getGridSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:getGridSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_getGridSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_getStep(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_getStep'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_getStep'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getStep(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:getStep",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_getStep'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_set2DProjection(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_set2DProjection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_set2DProjection'", nullptr); return 0; } cobj->set2DProjection(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:set2DProjection",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_set2DProjection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_setStep(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_setStep'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.GridBase:setStep"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_setStep'", nullptr); return 0; } cobj->setStep(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:setStep",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_setStep'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_setTextureFlipped(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_setTextureFlipped'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.GridBase:setTextureFlipped"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_setTextureFlipped'", nullptr); return 0; } cobj->setTextureFlipped(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:setTextureFlipped",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_setTextureFlipped'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_blit(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_blit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_blit'", nullptr); return 0; } cobj->blit(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:blit",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_blit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_setActive(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_setActive'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.GridBase:setActive"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_setActive'", nullptr); return 0; } cobj->setActive(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:setActive",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_setActive'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_getReuseGrid(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_getReuseGrid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_getReuseGrid'", nullptr); return 0; } int ret = cobj->getReuseGrid(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:getReuseGrid",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_getReuseGrid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_initWithSize(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_initWithSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.GridBase:initWithSize"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.GridBase:initWithSize"); if (!ok) { break; } bool ret = cobj->initWithSize(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.GridBase:initWithSize"); if (!ok) { break; } bool ret = cobj->initWithSize(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 3) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.GridBase:initWithSize"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.GridBase:initWithSize"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.GridBase:initWithSize"); if (!ok) { break; } bool ret = cobj->initWithSize(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.GridBase:initWithSize"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.GridBase:initWithSize"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.GridBase:initWithSize"); if (!ok) { break; } cocos2d::Rect arg3; ok &= luaval_to_rect(tolua_S, 5, &arg3, "cc.GridBase:initWithSize"); if (!ok) { break; } bool ret = cobj->initWithSize(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:initWithSize",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_initWithSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_beforeBlit(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_beforeBlit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_beforeBlit'", nullptr); return 0; } cobj->beforeBlit(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:beforeBlit",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_beforeBlit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_setReuseGrid(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_setReuseGrid'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GridBase:setReuseGrid"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_setReuseGrid'", nullptr); return 0; } cobj->setReuseGrid(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:setReuseGrid",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_setReuseGrid'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_isActive(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_isActive'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_isActive'", nullptr); return 0; } bool ret = cobj->isActive(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:isActive",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_isActive'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_reuse(lua_State* tolua_S) { int argc = 0; cocos2d::GridBase* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GridBase*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GridBase_reuse'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GridBase_reuse'", nullptr); return 0; } cobj->reuse(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GridBase:reuse",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_reuse'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GridBase_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GridBase",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.GridBase:create"); if (!ok) { break; } cocos2d::GridBase* ret = cocos2d::GridBase::create(arg0); object_to_luaval<cocos2d::GridBase>(tolua_S, "cc.GridBase",(cocos2d::GridBase*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.GridBase:create"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.GridBase:create"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.GridBase:create"); if (!ok) { break; } cocos2d::GridBase* ret = cocos2d::GridBase::create(arg0, arg1, arg2); object_to_luaval<cocos2d::GridBase>(tolua_S, "cc.GridBase",(cocos2d::GridBase*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.GridBase:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GridBase_create'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_GridBase_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (GridBase)"); return 0; } int lua_register_cocos2dx_GridBase(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.GridBase"); tolua_cclass(tolua_S,"GridBase","cc.GridBase","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"GridBase"); tolua_function(tolua_S,"setGridSize",lua_cocos2dx_GridBase_setGridSize); tolua_function(tolua_S,"setGridRect",lua_cocos2dx_GridBase_setGridRect); tolua_function(tolua_S,"afterBlit",lua_cocos2dx_GridBase_afterBlit); tolua_function(tolua_S,"getGridRect",lua_cocos2dx_GridBase_getGridRect); tolua_function(tolua_S,"afterDraw",lua_cocos2dx_GridBase_afterDraw); tolua_function(tolua_S,"beforeDraw",lua_cocos2dx_GridBase_beforeDraw); tolua_function(tolua_S,"calculateVertexPoints",lua_cocos2dx_GridBase_calculateVertexPoints); tolua_function(tolua_S,"isTextureFlipped",lua_cocos2dx_GridBase_isTextureFlipped); tolua_function(tolua_S,"getGridSize",lua_cocos2dx_GridBase_getGridSize); tolua_function(tolua_S,"getStep",lua_cocos2dx_GridBase_getStep); tolua_function(tolua_S,"set2DProjection",lua_cocos2dx_GridBase_set2DProjection); tolua_function(tolua_S,"setStep",lua_cocos2dx_GridBase_setStep); tolua_function(tolua_S,"setTextureFlipped",lua_cocos2dx_GridBase_setTextureFlipped); tolua_function(tolua_S,"blit",lua_cocos2dx_GridBase_blit); tolua_function(tolua_S,"setActive",lua_cocos2dx_GridBase_setActive); tolua_function(tolua_S,"getReuseGrid",lua_cocos2dx_GridBase_getReuseGrid); tolua_function(tolua_S,"initWithSize",lua_cocos2dx_GridBase_initWithSize); tolua_function(tolua_S,"beforeBlit",lua_cocos2dx_GridBase_beforeBlit); tolua_function(tolua_S,"setReuseGrid",lua_cocos2dx_GridBase_setReuseGrid); tolua_function(tolua_S,"isActive",lua_cocos2dx_GridBase_isActive); tolua_function(tolua_S,"reuse",lua_cocos2dx_GridBase_reuse); tolua_function(tolua_S,"create", lua_cocos2dx_GridBase_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::GridBase).name(); g_luaType[typeName] = "cc.GridBase"; g_typeCast["GridBase"] = "cc.GridBase"; return 1; } int lua_cocos2dx_Grid3D_getNeedDepthTestForBlit(lua_State* tolua_S) { int argc = 0; cocos2d::Grid3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Grid3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Grid3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Grid3D_getNeedDepthTestForBlit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Grid3D_getNeedDepthTestForBlit'", nullptr); return 0; } bool ret = cobj->getNeedDepthTestForBlit(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Grid3D:getNeedDepthTestForBlit",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Grid3D_getNeedDepthTestForBlit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Grid3D_setNeedDepthTestForBlit(lua_State* tolua_S) { int argc = 0; cocos2d::Grid3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Grid3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Grid3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Grid3D_setNeedDepthTestForBlit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Grid3D:setNeedDepthTestForBlit"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Grid3D_setNeedDepthTestForBlit'", nullptr); return 0; } cobj->setNeedDepthTestForBlit(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Grid3D:setNeedDepthTestForBlit",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Grid3D_setNeedDepthTestForBlit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Grid3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Grid3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.Grid3D:create"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Grid3D:create"); if (!ok) { break; } cocos2d::Grid3D* ret = cocos2d::Grid3D::create(arg0, arg1); object_to_luaval<cocos2d::Grid3D>(tolua_S, "cc.Grid3D",(cocos2d::Grid3D*)ret); return 1; } } while (0); ok = true; do { if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.Grid3D:create"); if (!ok) { break; } cocos2d::Grid3D* ret = cocos2d::Grid3D::create(arg0); object_to_luaval<cocos2d::Grid3D>(tolua_S, "cc.Grid3D",(cocos2d::Grid3D*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.Grid3D:create"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.Grid3D:create"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.Grid3D:create"); if (!ok) { break; } cocos2d::Grid3D* ret = cocos2d::Grid3D::create(arg0, arg1, arg2); object_to_luaval<cocos2d::Grid3D>(tolua_S, "cc.Grid3D",(cocos2d::Grid3D*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.Grid3D:create"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.Grid3D:create"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.Grid3D:create"); if (!ok) { break; } cocos2d::Rect arg3; ok &= luaval_to_rect(tolua_S, 5, &arg3, "cc.Grid3D:create"); if (!ok) { break; } cocos2d::Grid3D* ret = cocos2d::Grid3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::Grid3D>(tolua_S, "cc.Grid3D",(cocos2d::Grid3D*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.Grid3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Grid3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Grid3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::Grid3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Grid3D_constructor'", nullptr); return 0; } cobj = new cocos2d::Grid3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Grid3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Grid3D:Grid3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Grid3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Grid3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Grid3D)"); return 0; } int lua_register_cocos2dx_Grid3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Grid3D"); tolua_cclass(tolua_S,"Grid3D","cc.Grid3D","cc.GridBase",nullptr); tolua_beginmodule(tolua_S,"Grid3D"); tolua_function(tolua_S,"new",lua_cocos2dx_Grid3D_constructor); tolua_function(tolua_S,"getNeedDepthTestForBlit",lua_cocos2dx_Grid3D_getNeedDepthTestForBlit); tolua_function(tolua_S,"setNeedDepthTestForBlit",lua_cocos2dx_Grid3D_setNeedDepthTestForBlit); tolua_function(tolua_S,"create", lua_cocos2dx_Grid3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Grid3D).name(); g_luaType[typeName] = "cc.Grid3D"; g_typeCast["Grid3D"] = "cc.Grid3D"; return 1; } int lua_cocos2dx_TiledGrid3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TiledGrid3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 2) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TiledGrid3D:create"); if (!ok) { break; } cocos2d::Rect arg1; ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.TiledGrid3D:create"); if (!ok) { break; } cocos2d::TiledGrid3D* ret = cocos2d::TiledGrid3D::create(arg0, arg1); object_to_luaval<cocos2d::TiledGrid3D>(tolua_S, "cc.TiledGrid3D",(cocos2d::TiledGrid3D*)ret); return 1; } } while (0); ok = true; do { if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TiledGrid3D:create"); if (!ok) { break; } cocos2d::TiledGrid3D* ret = cocos2d::TiledGrid3D::create(arg0); object_to_luaval<cocos2d::TiledGrid3D>(tolua_S, "cc.TiledGrid3D",(cocos2d::TiledGrid3D*)ret); return 1; } } while (0); ok = true; do { if (argc == 3) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TiledGrid3D:create"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.TiledGrid3D:create"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.TiledGrid3D:create"); if (!ok) { break; } cocos2d::TiledGrid3D* ret = cocos2d::TiledGrid3D::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TiledGrid3D>(tolua_S, "cc.TiledGrid3D",(cocos2d::TiledGrid3D*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TiledGrid3D:create"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.TiledGrid3D:create"); if (!ok) { break; } bool arg2; ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.TiledGrid3D:create"); if (!ok) { break; } cocos2d::Rect arg3; ok &= luaval_to_rect(tolua_S, 5, &arg3, "cc.TiledGrid3D:create"); if (!ok) { break; } cocos2d::TiledGrid3D* ret = cocos2d::TiledGrid3D::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::TiledGrid3D>(tolua_S, "cc.TiledGrid3D",(cocos2d::TiledGrid3D*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.TiledGrid3D:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TiledGrid3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TiledGrid3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TiledGrid3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TiledGrid3D_constructor'", nullptr); return 0; } cobj = new cocos2d::TiledGrid3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TiledGrid3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TiledGrid3D:TiledGrid3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TiledGrid3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TiledGrid3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TiledGrid3D)"); return 0; } int lua_register_cocos2dx_TiledGrid3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TiledGrid3D"); tolua_cclass(tolua_S,"TiledGrid3D","cc.TiledGrid3D","cc.GridBase",nullptr); tolua_beginmodule(tolua_S,"TiledGrid3D"); tolua_function(tolua_S,"new",lua_cocos2dx_TiledGrid3D_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TiledGrid3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TiledGrid3D).name(); g_luaType[typeName] = "cc.TiledGrid3D"; g_typeCast["TiledGrid3D"] = "cc.TiledGrid3D"; return 1; } int lua_cocos2dx_BaseLight_setEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::BaseLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BaseLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BaseLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BaseLight_setEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.BaseLight:setEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BaseLight_setEnabled'", nullptr); return 0; } cobj->setEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BaseLight:setEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BaseLight_setEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_BaseLight_getIntensity(lua_State* tolua_S) { int argc = 0; cocos2d::BaseLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BaseLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BaseLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BaseLight_getIntensity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BaseLight_getIntensity'", nullptr); return 0; } double ret = cobj->getIntensity(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BaseLight:getIntensity",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BaseLight_getIntensity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_BaseLight_isEnabled(lua_State* tolua_S) { int argc = 0; cocos2d::BaseLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BaseLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BaseLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BaseLight_isEnabled'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BaseLight_isEnabled'", nullptr); return 0; } bool ret = cobj->isEnabled(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BaseLight:isEnabled",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BaseLight_isEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_BaseLight_getLightType(lua_State* tolua_S) { int argc = 0; cocos2d::BaseLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BaseLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BaseLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BaseLight_getLightType'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BaseLight_getLightType'", nullptr); return 0; } int ret = (int)cobj->getLightType(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BaseLight:getLightType",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BaseLight_getLightType'.",&tolua_err); #endif return 0; } int lua_cocos2dx_BaseLight_setLightFlag(lua_State* tolua_S) { int argc = 0; cocos2d::BaseLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BaseLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BaseLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BaseLight_setLightFlag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::LightFlag arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.BaseLight:setLightFlag"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BaseLight_setLightFlag'", nullptr); return 0; } cobj->setLightFlag(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BaseLight:setLightFlag",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BaseLight_setLightFlag'.",&tolua_err); #endif return 0; } int lua_cocos2dx_BaseLight_setIntensity(lua_State* tolua_S) { int argc = 0; cocos2d::BaseLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BaseLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BaseLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BaseLight_setIntensity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.BaseLight:setIntensity"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BaseLight_setIntensity'", nullptr); return 0; } cobj->setIntensity(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BaseLight:setIntensity",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BaseLight_setIntensity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_BaseLight_getLightFlag(lua_State* tolua_S) { int argc = 0; cocos2d::BaseLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.BaseLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::BaseLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_BaseLight_getLightFlag'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_BaseLight_getLightFlag'", nullptr); return 0; } int ret = (int)cobj->getLightFlag(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.BaseLight:getLightFlag",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_BaseLight_getLightFlag'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_BaseLight_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (BaseLight)"); return 0; } int lua_register_cocos2dx_BaseLight(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.BaseLight"); tolua_cclass(tolua_S,"BaseLight","cc.BaseLight","cc.Node",nullptr); tolua_beginmodule(tolua_S,"BaseLight"); tolua_function(tolua_S,"setEnabled",lua_cocos2dx_BaseLight_setEnabled); tolua_function(tolua_S,"getIntensity",lua_cocos2dx_BaseLight_getIntensity); tolua_function(tolua_S,"isEnabled",lua_cocos2dx_BaseLight_isEnabled); tolua_function(tolua_S,"getLightType",lua_cocos2dx_BaseLight_getLightType); tolua_function(tolua_S,"setLightFlag",lua_cocos2dx_BaseLight_setLightFlag); tolua_function(tolua_S,"setIntensity",lua_cocos2dx_BaseLight_setIntensity); tolua_function(tolua_S,"getLightFlag",lua_cocos2dx_BaseLight_getLightFlag); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::BaseLight).name(); g_luaType[typeName] = "cc.BaseLight"; g_typeCast["BaseLight"] = "cc.BaseLight"; return 1; } int lua_cocos2dx_DirectionLight_getDirection(lua_State* tolua_S) { int argc = 0; cocos2d::DirectionLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DirectionLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DirectionLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DirectionLight_getDirection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DirectionLight_getDirection'", nullptr); return 0; } cocos2d::Vec3 ret = cobj->getDirection(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DirectionLight:getDirection",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DirectionLight_getDirection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DirectionLight_getDirectionInWorld(lua_State* tolua_S) { int argc = 0; cocos2d::DirectionLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DirectionLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DirectionLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DirectionLight_getDirectionInWorld'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DirectionLight_getDirectionInWorld'", nullptr); return 0; } cocos2d::Vec3 ret = cobj->getDirectionInWorld(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DirectionLight:getDirectionInWorld",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DirectionLight_getDirectionInWorld'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DirectionLight_setDirection(lua_State* tolua_S) { int argc = 0; cocos2d::DirectionLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.DirectionLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::DirectionLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_DirectionLight_setDirection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.DirectionLight:setDirection"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DirectionLight_setDirection'", nullptr); return 0; } cobj->setDirection(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DirectionLight:setDirection",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DirectionLight_setDirection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DirectionLight_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.DirectionLight",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::Vec3 arg0; cocos2d::Color3B arg1; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.DirectionLight:create"); ok &= luaval_to_color3b(tolua_S, 3, &arg1, "cc.DirectionLight:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DirectionLight_create'", nullptr); return 0; } cocos2d::DirectionLight* ret = cocos2d::DirectionLight::create(arg0, arg1); object_to_luaval<cocos2d::DirectionLight>(tolua_S, "cc.DirectionLight",(cocos2d::DirectionLight*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.DirectionLight:create",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DirectionLight_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_DirectionLight_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::DirectionLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_DirectionLight_constructor'", nullptr); return 0; } cobj = new cocos2d::DirectionLight(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.DirectionLight"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.DirectionLight:DirectionLight",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_DirectionLight_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_DirectionLight_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (DirectionLight)"); return 0; } int lua_register_cocos2dx_DirectionLight(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.DirectionLight"); tolua_cclass(tolua_S,"DirectionLight","cc.DirectionLight","cc.BaseLight",nullptr); tolua_beginmodule(tolua_S,"DirectionLight"); tolua_function(tolua_S,"new",lua_cocos2dx_DirectionLight_constructor); tolua_function(tolua_S,"getDirection",lua_cocos2dx_DirectionLight_getDirection); tolua_function(tolua_S,"getDirectionInWorld",lua_cocos2dx_DirectionLight_getDirectionInWorld); tolua_function(tolua_S,"setDirection",lua_cocos2dx_DirectionLight_setDirection); tolua_function(tolua_S,"create", lua_cocos2dx_DirectionLight_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::DirectionLight).name(); g_luaType[typeName] = "cc.DirectionLight"; g_typeCast["DirectionLight"] = "cc.DirectionLight"; return 1; } int lua_cocos2dx_PointLight_getRange(lua_State* tolua_S) { int argc = 0; cocos2d::PointLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PointLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PointLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PointLight_getRange'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PointLight_getRange'", nullptr); return 0; } double ret = cobj->getRange(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PointLight:getRange",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PointLight_getRange'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PointLight_setRange(lua_State* tolua_S) { int argc = 0; cocos2d::PointLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.PointLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::PointLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_PointLight_setRange'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.PointLight:setRange"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PointLight_setRange'", nullptr); return 0; } cobj->setRange(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PointLight:setRange",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PointLight_setRange'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PointLight_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.PointLight",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { cocos2d::Vec3 arg0; cocos2d::Color3B arg1; double arg2; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.PointLight:create"); ok &= luaval_to_color3b(tolua_S, 3, &arg1, "cc.PointLight:create"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.PointLight:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PointLight_create'", nullptr); return 0; } cocos2d::PointLight* ret = cocos2d::PointLight::create(arg0, arg1, arg2); object_to_luaval<cocos2d::PointLight>(tolua_S, "cc.PointLight",(cocos2d::PointLight*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.PointLight:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PointLight_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_PointLight_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::PointLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_PointLight_constructor'", nullptr); return 0; } cobj = new cocos2d::PointLight(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.PointLight"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.PointLight:PointLight",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_PointLight_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_PointLight_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (PointLight)"); return 0; } int lua_register_cocos2dx_PointLight(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.PointLight"); tolua_cclass(tolua_S,"PointLight","cc.PointLight","cc.BaseLight",nullptr); tolua_beginmodule(tolua_S,"PointLight"); tolua_function(tolua_S,"new",lua_cocos2dx_PointLight_constructor); tolua_function(tolua_S,"getRange",lua_cocos2dx_PointLight_getRange); tolua_function(tolua_S,"setRange",lua_cocos2dx_PointLight_setRange); tolua_function(tolua_S,"create", lua_cocos2dx_PointLight_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::PointLight).name(); g_luaType[typeName] = "cc.PointLight"; g_typeCast["PointLight"] = "cc.PointLight"; return 1; } int lua_cocos2dx_SpotLight_getRange(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_getRange'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_getRange'", nullptr); return 0; } double ret = cobj->getRange(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:getRange",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_getRange'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_setDirection(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_setDirection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.SpotLight:setDirection"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_setDirection'", nullptr); return 0; } cobj->setDirection(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:setDirection",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_setDirection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_getCosInnerAngle(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_getCosInnerAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_getCosInnerAngle'", nullptr); return 0; } double ret = cobj->getCosInnerAngle(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:getCosInnerAngle",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_getCosInnerAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_getOuterAngle(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_getOuterAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_getOuterAngle'", nullptr); return 0; } double ret = cobj->getOuterAngle(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:getOuterAngle",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_getOuterAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_getInnerAngle(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_getInnerAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_getInnerAngle'", nullptr); return 0; } double ret = cobj->getInnerAngle(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:getInnerAngle",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_getInnerAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_getDirection(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_getDirection'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_getDirection'", nullptr); return 0; } cocos2d::Vec3 ret = cobj->getDirection(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:getDirection",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_getDirection'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_getCosOuterAngle(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_getCosOuterAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_getCosOuterAngle'", nullptr); return 0; } double ret = cobj->getCosOuterAngle(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:getCosOuterAngle",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_getCosOuterAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_setOuterAngle(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_setOuterAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SpotLight:setOuterAngle"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_setOuterAngle'", nullptr); return 0; } cobj->setOuterAngle(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:setOuterAngle",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_setOuterAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_setInnerAngle(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_setInnerAngle'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SpotLight:setInnerAngle"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_setInnerAngle'", nullptr); return 0; } cobj->setInnerAngle(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:setInnerAngle",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_setInnerAngle'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_getDirectionInWorld(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_getDirectionInWorld'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_getDirectionInWorld'", nullptr); return 0; } cocos2d::Vec3 ret = cobj->getDirectionInWorld(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:getDirectionInWorld",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_getDirectionInWorld'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_setRange(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpotLight*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpotLight_setRange'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.SpotLight:setRange"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_setRange'", nullptr); return 0; } cobj->setRange(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:setRange",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_setRange'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SpotLight",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 6) { cocos2d::Vec3 arg0; cocos2d::Vec3 arg1; cocos2d::Color3B arg2; double arg3; double arg4; double arg5; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.SpotLight:create"); ok &= luaval_to_vec3(tolua_S, 3, &arg1, "cc.SpotLight:create"); ok &= luaval_to_color3b(tolua_S, 4, &arg2, "cc.SpotLight:create"); ok &= luaval_to_number(tolua_S, 5,&arg3, "cc.SpotLight:create"); ok &= luaval_to_number(tolua_S, 6,&arg4, "cc.SpotLight:create"); ok &= luaval_to_number(tolua_S, 7,&arg5, "cc.SpotLight:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_create'", nullptr); return 0; } cocos2d::SpotLight* ret = cocos2d::SpotLight::create(arg0, arg1, arg2, arg3, arg4, arg5); object_to_luaval<cocos2d::SpotLight>(tolua_S, "cc.SpotLight",(cocos2d::SpotLight*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SpotLight:create",argc, 6); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpotLight_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::SpotLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpotLight_constructor'", nullptr); return 0; } cobj = new cocos2d::SpotLight(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.SpotLight"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpotLight:SpotLight",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpotLight_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_SpotLight_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SpotLight)"); return 0; } int lua_register_cocos2dx_SpotLight(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.SpotLight"); tolua_cclass(tolua_S,"SpotLight","cc.SpotLight","cc.BaseLight",nullptr); tolua_beginmodule(tolua_S,"SpotLight"); tolua_function(tolua_S,"new",lua_cocos2dx_SpotLight_constructor); tolua_function(tolua_S,"getRange",lua_cocos2dx_SpotLight_getRange); tolua_function(tolua_S,"setDirection",lua_cocos2dx_SpotLight_setDirection); tolua_function(tolua_S,"getCosInnerAngle",lua_cocos2dx_SpotLight_getCosInnerAngle); tolua_function(tolua_S,"getOuterAngle",lua_cocos2dx_SpotLight_getOuterAngle); tolua_function(tolua_S,"getInnerAngle",lua_cocos2dx_SpotLight_getInnerAngle); tolua_function(tolua_S,"getDirection",lua_cocos2dx_SpotLight_getDirection); tolua_function(tolua_S,"getCosOuterAngle",lua_cocos2dx_SpotLight_getCosOuterAngle); tolua_function(tolua_S,"setOuterAngle",lua_cocos2dx_SpotLight_setOuterAngle); tolua_function(tolua_S,"setInnerAngle",lua_cocos2dx_SpotLight_setInnerAngle); tolua_function(tolua_S,"getDirectionInWorld",lua_cocos2dx_SpotLight_getDirectionInWorld); tolua_function(tolua_S,"setRange",lua_cocos2dx_SpotLight_setRange); tolua_function(tolua_S,"create", lua_cocos2dx_SpotLight_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::SpotLight).name(); g_luaType[typeName] = "cc.SpotLight"; g_typeCast["SpotLight"] = "cc.SpotLight"; return 1; } int lua_cocos2dx_AmbientLight_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.AmbientLight",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Color3B arg0; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.AmbientLight:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AmbientLight_create'", nullptr); return 0; } cocos2d::AmbientLight* ret = cocos2d::AmbientLight::create(arg0); object_to_luaval<cocos2d::AmbientLight>(tolua_S, "cc.AmbientLight",(cocos2d::AmbientLight*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.AmbientLight:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AmbientLight_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AmbientLight_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::AmbientLight* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AmbientLight_constructor'", nullptr); return 0; } cobj = new cocos2d::AmbientLight(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.AmbientLight"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AmbientLight:AmbientLight",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AmbientLight_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_AmbientLight_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (AmbientLight)"); return 0; } int lua_register_cocos2dx_AmbientLight(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.AmbientLight"); tolua_cclass(tolua_S,"AmbientLight","cc.AmbientLight","cc.BaseLight",nullptr); tolua_beginmodule(tolua_S,"AmbientLight"); tolua_function(tolua_S,"new",lua_cocos2dx_AmbientLight_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_AmbientLight_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::AmbientLight).name(); g_luaType[typeName] = "cc.AmbientLight"; g_typeCast["AmbientLight"] = "cc.AmbientLight"; return 1; } int lua_cocos2dx_GLProgram_getFragmentShaderLog(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_getFragmentShaderLog'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_getFragmentShaderLog'", nullptr); return 0; } std::string ret = cobj->getFragmentShaderLog(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:getFragmentShaderLog",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_getFragmentShaderLog'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_initWithByteArrays(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_initWithByteArrays'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.GLProgram:initWithByteArrays"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } const char* arg1 = nullptr; std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.GLProgram:initWithByteArrays"); arg1 = arg1_tmp.c_str(); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgram:initWithByteArrays"); if (!ok) { break; } bool ret = cobj->initWithByteArrays(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.GLProgram:initWithByteArrays"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } const char* arg1 = nullptr; std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.GLProgram:initWithByteArrays"); arg1 = arg1_tmp.c_str(); if (!ok) { break; } bool ret = cobj->initWithByteArrays(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.GLProgram:initWithByteArrays"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } const char* arg1 = nullptr; std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.GLProgram:initWithByteArrays"); arg1 = arg1_tmp.c_str(); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgram:initWithByteArrays"); if (!ok) { break; } std::string arg3; ok &= luaval_to_std_string(tolua_S, 5,&arg3, "cc.GLProgram:initWithByteArrays"); if (!ok) { break; } bool ret = cobj->initWithByteArrays(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:initWithByteArrays",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_initWithByteArrays'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_initWithFilenames(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_initWithFilenames'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } bool ret = cobj->initWithFilenames(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } bool ret = cobj->initWithFilenames(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 4) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } std::string arg3; ok &= luaval_to_std_string(tolua_S, 5,&arg3, "cc.GLProgram:initWithFilenames"); if (!ok) { break; } bool ret = cobj->initWithFilenames(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:initWithFilenames",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_initWithFilenames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_use(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_use'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_use'", nullptr); return 0; } cobj->use(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:use",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_use'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_getVertexShaderLog(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_getVertexShaderLog'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_getVertexShaderLog'", nullptr); return 0; } std::string ret = cobj->getVertexShaderLog(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:getVertexShaderLog",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_getVertexShaderLog'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_setUniformsForBuiltins(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_setUniformsForBuiltins'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cobj->setUniformsForBuiltins(); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Mat4 arg0; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.GLProgram:setUniformsForBuiltins"); if (!ok) { break; } cobj->setUniformsForBuiltins(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:setUniformsForBuiltins",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_setUniformsForBuiltins'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_updateUniforms(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_updateUniforms'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_updateUniforms'", nullptr); return 0; } cobj->updateUniforms(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:updateUniforms",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_updateUniforms'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_setUniformLocationWith1i(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_setUniformLocationWith1i'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { int arg0; int arg1; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.GLProgram:setUniformLocationWith1i"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.GLProgram:setUniformLocationWith1i"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_setUniformLocationWith1i'", nullptr); return 0; } cobj->setUniformLocationWith1i(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:setUniformLocationWith1i",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_setUniformLocationWith1i'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_reset(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_reset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_reset'", nullptr); return 0; } cobj->reset(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:reset",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_reset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_bindAttribLocation(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_bindAttribLocation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; unsigned int arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgram:bindAttribLocation"); ok &= luaval_to_uint32(tolua_S, 3,&arg1, "cc.GLProgram:bindAttribLocation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_bindAttribLocation'", nullptr); return 0; } cobj->bindAttribLocation(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:bindAttribLocation",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_bindAttribLocation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_getAttribLocation(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_getAttribLocation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgram:getAttribLocation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_getAttribLocation'", nullptr); return 0; } int ret = cobj->getAttribLocation(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:getAttribLocation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_getAttribLocation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_link(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgram*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgram_link'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_link'", nullptr); return 0; } bool ret = cobj->link(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:link",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_link'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_createWithByteArrays(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 3) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.GLProgram:createWithByteArrays"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } const char* arg1 = nullptr; std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.GLProgram:createWithByteArrays"); arg1 = arg1_tmp.c_str(); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgram:createWithByteArrays"); if (!ok) { break; } cocos2d::GLProgram* ret = cocos2d::GLProgram::createWithByteArrays(arg0, arg1, arg2); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.GLProgram:createWithByteArrays"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } const char* arg1 = nullptr; std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.GLProgram:createWithByteArrays"); arg1 = arg1_tmp.c_str(); if (!ok) { break; } cocos2d::GLProgram* ret = cocos2d::GLProgram::createWithByteArrays(arg0, arg1); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { const char* arg0 = nullptr; std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.GLProgram:createWithByteArrays"); arg0 = arg0_tmp.c_str(); if (!ok) { break; } const char* arg1 = nullptr; std::string arg1_tmp; ok &= luaval_to_std_string(tolua_S, 3, &arg1_tmp, "cc.GLProgram:createWithByteArrays"); arg1 = arg1_tmp.c_str(); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgram:createWithByteArrays"); if (!ok) { break; } std::string arg3; ok &= luaval_to_std_string(tolua_S, 5,&arg3, "cc.GLProgram:createWithByteArrays"); if (!ok) { break; } cocos2d::GLProgram* ret = cocos2d::GLProgram::createWithByteArrays(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.GLProgram:createWithByteArrays",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_createWithByteArrays'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_createWithFilenames(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLProgram",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 3) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } cocos2d::GLProgram* ret = cocos2d::GLProgram::createWithFilenames(arg0, arg1, arg2); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } } while (0); ok = true; do { if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } cocos2d::GLProgram* ret = cocos2d::GLProgram::createWithFilenames(arg0, arg1); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } } while (0); ok = true; do { if (argc == 4) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } std::string arg2; ok &= luaval_to_std_string(tolua_S, 4,&arg2, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } std::string arg3; ok &= luaval_to_std_string(tolua_S, 5,&arg3, "cc.GLProgram:createWithFilenames"); if (!ok) { break; } cocos2d::GLProgram* ret = cocos2d::GLProgram::createWithFilenames(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.GLProgram:createWithFilenames",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_createWithFilenames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgram_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgram* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgram_constructor'", nullptr); return 0; } cobj = new cocos2d::GLProgram(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.GLProgram"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgram:GLProgram",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgram_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_GLProgram_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (GLProgram)"); return 0; } int lua_register_cocos2dx_GLProgram(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.GLProgram"); tolua_cclass(tolua_S,"GLProgram","cc.GLProgram","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"GLProgram"); tolua_function(tolua_S,"new",lua_cocos2dx_GLProgram_constructor); tolua_function(tolua_S,"getFragmentShaderLog",lua_cocos2dx_GLProgram_getFragmentShaderLog); tolua_function(tolua_S,"initWithByteArrays",lua_cocos2dx_GLProgram_initWithByteArrays); tolua_function(tolua_S,"initWithFilenames",lua_cocos2dx_GLProgram_initWithFilenames); tolua_function(tolua_S,"use",lua_cocos2dx_GLProgram_use); tolua_function(tolua_S,"getVertexShaderLog",lua_cocos2dx_GLProgram_getVertexShaderLog); tolua_function(tolua_S,"setUniformsForBuiltins",lua_cocos2dx_GLProgram_setUniformsForBuiltins); tolua_function(tolua_S,"updateUniforms",lua_cocos2dx_GLProgram_updateUniforms); tolua_function(tolua_S,"setUniformLocationI32",lua_cocos2dx_GLProgram_setUniformLocationWith1i); tolua_function(tolua_S,"reset",lua_cocos2dx_GLProgram_reset); tolua_function(tolua_S,"bindAttribLocation",lua_cocos2dx_GLProgram_bindAttribLocation); tolua_function(tolua_S,"getAttribLocation",lua_cocos2dx_GLProgram_getAttribLocation); tolua_function(tolua_S,"link",lua_cocos2dx_GLProgram_link); tolua_function(tolua_S,"createWithByteArrays", lua_cocos2dx_GLProgram_createWithByteArrays); tolua_function(tolua_S,"createWithFilenames", lua_cocos2dx_GLProgram_createWithFilenames); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::GLProgram).name(); g_luaType[typeName] = "cc.GLProgram"; g_typeCast["GLProgram"] = "cc.GLProgram"; return 1; } int lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights'", nullptr); return 0; } cobj->reloadDefaultGLProgramsRelativeToLights(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:reloadDefaultGLProgramsRelativeToLights",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramCache_addGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramCache_addGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::GLProgram* arg0 = nullptr; std::string arg1; ok &= luaval_to_object<cocos2d::GLProgram>(tolua_S, 2, "cc.GLProgram",&arg0, "cc.GLProgramCache:addGLProgram"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.GLProgramCache:addGLProgram"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_addGLProgram'", nullptr); return 0; } cobj->addGLProgram(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:addGLProgram",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_addGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramCache_reloadDefaultGLPrograms(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLPrograms'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLPrograms'", nullptr); return 0; } cobj->reloadDefaultGLPrograms(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:reloadDefaultGLPrograms",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLPrograms'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramCache_loadDefaultGLPrograms(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramCache_loadDefaultGLPrograms'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_loadDefaultGLPrograms'", nullptr); return 0; } cobj->loadDefaultGLPrograms(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:loadDefaultGLPrograms",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_loadDefaultGLPrograms'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramCache_getGLProgram(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::GLProgramCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramCache_getGLProgram'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramCache:getGLProgram"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_getGLProgram'", nullptr); return 0; } cocos2d::GLProgram* ret = cobj->getGLProgram(arg0); object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:getGLProgram",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_getGLProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramCache_destroyInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_destroyInstance'", nullptr); return 0; } cocos2d::GLProgramCache::destroyInstance(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLProgramCache:destroyInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_destroyInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramCache_getInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_getInstance'", nullptr); return 0; } cocos2d::GLProgramCache* ret = cocos2d::GLProgramCache::getInstance(); object_to_luaval<cocos2d::GLProgramCache>(tolua_S, "cc.GLProgramCache",(cocos2d::GLProgramCache*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLProgramCache:getInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_getInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLProgramCache_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::GLProgramCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_constructor'", nullptr); return 0; } cobj = new cocos2d::GLProgramCache(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.GLProgramCache"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:GLProgramCache",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_GLProgramCache_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (GLProgramCache)"); return 0; } int lua_register_cocos2dx_GLProgramCache(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.GLProgramCache"); tolua_cclass(tolua_S,"GLProgramCache","cc.GLProgramCache","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"GLProgramCache"); tolua_function(tolua_S,"new",lua_cocos2dx_GLProgramCache_constructor); tolua_function(tolua_S,"reloadDefaultGLProgramsRelativeToLights",lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights); tolua_function(tolua_S,"addGLProgram",lua_cocos2dx_GLProgramCache_addGLProgram); tolua_function(tolua_S,"reloadDefaultGLPrograms",lua_cocos2dx_GLProgramCache_reloadDefaultGLPrograms); tolua_function(tolua_S,"loadDefaultGLPrograms",lua_cocos2dx_GLProgramCache_loadDefaultGLPrograms); tolua_function(tolua_S,"getGLProgram",lua_cocos2dx_GLProgramCache_getGLProgram); tolua_function(tolua_S,"destroyInstance", lua_cocos2dx_GLProgramCache_destroyInstance); tolua_function(tolua_S,"getInstance", lua_cocos2dx_GLProgramCache_getInstance); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::GLProgramCache).name(); g_luaType[typeName] = "cc.GLProgramCache"; g_typeCast["GLProgramCache"] = "cc.GLProgramCache"; return 1; } int lua_cocos2dx_RenderState_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::RenderState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderState_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.RenderState:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderState_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderState:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderState_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderState_getTopmost(lua_State* tolua_S) { int argc = 0; cocos2d::RenderState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderState_getTopmost'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::RenderState* arg0 = nullptr; ok &= luaval_to_object<cocos2d::RenderState>(tolua_S, 2, "cc.RenderState",&arg0, "cc.RenderState:getTopmost"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderState_getTopmost'", nullptr); return 0; } cocos2d::RenderState* ret = cobj->getTopmost(arg0); object_to_luaval<cocos2d::RenderState>(tolua_S, "cc.RenderState",(cocos2d::RenderState*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderState:getTopmost",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderState_getTopmost'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderState_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::RenderState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderState_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderState_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderState:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderState_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderState_bind(lua_State* tolua_S) { int argc = 0; cocos2d::RenderState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderState_bind'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Pass* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Pass>(tolua_S, 2, "cc.Pass",&arg0, "cc.RenderState:bind"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderState_bind'", nullptr); return 0; } cobj->bind(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderState:bind",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderState_bind'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderState_getName(lua_State* tolua_S) { int argc = 0; cocos2d::RenderState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderState_getName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderState_getName'", nullptr); return 0; } std::string ret = cobj->getName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderState:getName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderState_getName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderState_getStateBlock(lua_State* tolua_S) { int argc = 0; cocos2d::RenderState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderState_getStateBlock'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderState_getStateBlock'", nullptr); return 0; } cocos2d::RenderState::StateBlock* ret = cobj->getStateBlock(); object_to_luaval<cocos2d::RenderState::StateBlock>(tolua_S, "cc.RenderState::StateBlock",(cocos2d::RenderState::StateBlock*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderState:getStateBlock",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderState_getStateBlock'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderState_setParent(lua_State* tolua_S) { int argc = 0; cocos2d::RenderState* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.RenderState",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::RenderState*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_RenderState_setParent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::RenderState* arg0 = nullptr; ok &= luaval_to_object<cocos2d::RenderState>(tolua_S, 2, "cc.RenderState",&arg0, "cc.RenderState:setParent"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderState_setParent'", nullptr); return 0; } cobj->setParent(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.RenderState:setParent",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderState_setParent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_RenderState_initialize(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.RenderState",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_RenderState_initialize'", nullptr); return 0; } cocos2d::RenderState::initialize(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.RenderState:initialize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_RenderState_initialize'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_RenderState_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (RenderState)"); return 0; } int lua_register_cocos2dx_RenderState(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.RenderState"); tolua_cclass(tolua_S,"RenderState","cc.RenderState","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"RenderState"); tolua_function(tolua_S,"setTexture",lua_cocos2dx_RenderState_setTexture); tolua_function(tolua_S,"getTopmost",lua_cocos2dx_RenderState_getTopmost); tolua_function(tolua_S,"getTexture",lua_cocos2dx_RenderState_getTexture); tolua_function(tolua_S,"bind",lua_cocos2dx_RenderState_bind); tolua_function(tolua_S,"getName",lua_cocos2dx_RenderState_getName); tolua_function(tolua_S,"getStateBlock",lua_cocos2dx_RenderState_getStateBlock); tolua_function(tolua_S,"setParent",lua_cocos2dx_RenderState_setParent); tolua_function(tolua_S,"initialize", lua_cocos2dx_RenderState_initialize); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::RenderState).name(); g_luaType[typeName] = "cc.RenderState"; g_typeCast["RenderState"] = "cc.RenderState"; return 1; } int lua_cocos2dx_Pass_unbind(lua_State* tolua_S) { int argc = 0; cocos2d::Pass* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Pass*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Pass_unbind'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Pass_unbind'", nullptr); return 0; } cobj->unbind(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Pass:unbind",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_unbind'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Pass_bind(lua_State* tolua_S) { int argc = 0; cocos2d::Pass* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Pass*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Pass_bind'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Mat4 arg0; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.Pass:bind"); if (!ok) { break; } bool arg1; ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.Pass:bind"); if (!ok) { break; } cobj->bind(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { cocos2d::Mat4 arg0; ok &= luaval_to_mat4(tolua_S, 2, &arg0, "cc.Pass:bind"); if (!ok) { break; } cobj->bind(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Pass:bind",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_bind'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Pass_clone(lua_State* tolua_S) { int argc = 0; cocos2d::Pass* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Pass*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Pass_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Pass_clone'", nullptr); return 0; } cocos2d::Pass* ret = cobj->clone(); object_to_luaval<cocos2d::Pass>(tolua_S, "cc.Pass",(cocos2d::Pass*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Pass:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Pass_getGLProgramState(lua_State* tolua_S) { int argc = 0; cocos2d::Pass* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Pass*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Pass_getGLProgramState'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Pass_getGLProgramState'", nullptr); return 0; } cocos2d::GLProgramState* ret = cobj->getGLProgramState(); object_to_luaval<cocos2d::GLProgramState>(tolua_S, "cc.GLProgramState",(cocos2d::GLProgramState*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Pass:getGLProgramState",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_getGLProgramState'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Pass_getVertexAttributeBinding(lua_State* tolua_S) { int argc = 0; cocos2d::Pass* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Pass*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Pass_getVertexAttributeBinding'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Pass_getVertexAttributeBinding'", nullptr); return 0; } cocos2d::VertexAttribBinding* ret = cobj->getVertexAttributeBinding(); object_to_luaval<cocos2d::VertexAttribBinding>(tolua_S, "cc.VertexAttribBinding",(cocos2d::VertexAttribBinding*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Pass:getVertexAttributeBinding",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_getVertexAttributeBinding'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Pass_getHash(lua_State* tolua_S) { int argc = 0; cocos2d::Pass* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Pass*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Pass_getHash'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Pass_getHash'", nullptr); return 0; } unsigned int ret = cobj->getHash(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Pass:getHash",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_getHash'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Pass_setVertexAttribBinding(lua_State* tolua_S) { int argc = 0; cocos2d::Pass* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Pass*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Pass_setVertexAttribBinding'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::VertexAttribBinding* arg0 = nullptr; ok &= luaval_to_object<cocos2d::VertexAttribBinding>(tolua_S, 2, "cc.VertexAttribBinding",&arg0, "cc.Pass:setVertexAttribBinding"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Pass_setVertexAttribBinding'", nullptr); return 0; } cobj->setVertexAttribBinding(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Pass:setVertexAttribBinding",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_setVertexAttribBinding'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Pass_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Technique* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Technique>(tolua_S, 2, "cc.Technique",&arg0, "cc.Pass:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Pass_create'", nullptr); return 0; } cocos2d::Pass* ret = cocos2d::Pass::create(arg0); object_to_luaval<cocos2d::Pass>(tolua_S, "cc.Pass",(cocos2d::Pass*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Pass:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Pass_createWithGLProgramState(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Pass",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::Technique* arg0 = nullptr; cocos2d::GLProgramState* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Technique>(tolua_S, 2, "cc.Technique",&arg0, "cc.Pass:createWithGLProgramState"); ok &= luaval_to_object<cocos2d::GLProgramState>(tolua_S, 3, "cc.GLProgramState",&arg1, "cc.Pass:createWithGLProgramState"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Pass_createWithGLProgramState'", nullptr); return 0; } cocos2d::Pass* ret = cocos2d::Pass::createWithGLProgramState(arg0, arg1); object_to_luaval<cocos2d::Pass>(tolua_S, "cc.Pass",(cocos2d::Pass*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Pass:createWithGLProgramState",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Pass_createWithGLProgramState'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Pass_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Pass)"); return 0; } int lua_register_cocos2dx_Pass(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Pass"); tolua_cclass(tolua_S,"Pass","cc.Pass","cc.RenderState",nullptr); tolua_beginmodule(tolua_S,"Pass"); tolua_function(tolua_S,"unbind",lua_cocos2dx_Pass_unbind); tolua_function(tolua_S,"bind",lua_cocos2dx_Pass_bind); tolua_function(tolua_S,"clone",lua_cocos2dx_Pass_clone); tolua_function(tolua_S,"getGLProgramState",lua_cocos2dx_Pass_getGLProgramState); tolua_function(tolua_S,"getVertexAttributeBinding",lua_cocos2dx_Pass_getVertexAttributeBinding); tolua_function(tolua_S,"getHash",lua_cocos2dx_Pass_getHash); tolua_function(tolua_S,"setVertexAttribBinding",lua_cocos2dx_Pass_setVertexAttribBinding); tolua_function(tolua_S,"create", lua_cocos2dx_Pass_create); tolua_function(tolua_S,"createWithGLProgramState", lua_cocos2dx_Pass_createWithGLProgramState); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Pass).name(); g_luaType[typeName] = "cc.Pass"; g_typeCast["Pass"] = "cc.Pass"; return 1; } int lua_cocos2dx_Technique_getPassCount(lua_State* tolua_S) { int argc = 0; cocos2d::Technique* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Technique",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Technique*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Technique_getPassCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Technique_getPassCount'", nullptr); return 0; } ssize_t ret = cobj->getPassCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Technique:getPassCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Technique_getPassCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Technique_clone(lua_State* tolua_S) { int argc = 0; cocos2d::Technique* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Technique",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Technique*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Technique_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Technique_clone'", nullptr); return 0; } cocos2d::Technique* ret = cobj->clone(); object_to_luaval<cocos2d::Technique>(tolua_S, "cc.Technique",(cocos2d::Technique*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Technique:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Technique_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Technique_addPass(lua_State* tolua_S) { int argc = 0; cocos2d::Technique* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Technique",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Technique*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Technique_addPass'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Pass* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Pass>(tolua_S, 2, "cc.Pass",&arg0, "cc.Technique:addPass"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Technique_addPass'", nullptr); return 0; } cobj->addPass(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Technique:addPass",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Technique_addPass'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Technique_getPasses(lua_State* tolua_S) { int argc = 0; cocos2d::Technique* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Technique",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Technique*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Technique_getPasses'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Technique_getPasses'", nullptr); return 0; } const cocos2d::Vector<cocos2d::Pass *>& ret = cobj->getPasses(); ccvector_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Technique:getPasses",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Technique_getPasses'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Technique_getName(lua_State* tolua_S) { int argc = 0; cocos2d::Technique* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Technique",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Technique*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Technique_getName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Technique_getName'", nullptr); return 0; } std::string ret = cobj->getName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Technique:getName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Technique_getName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Technique_getPassByIndex(lua_State* tolua_S) { int argc = 0; cocos2d::Technique* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Technique",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Technique*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Technique_getPassByIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { ssize_t arg0; ok &= luaval_to_ssize(tolua_S, 2, &arg0, "cc.Technique:getPassByIndex"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Technique_getPassByIndex'", nullptr); return 0; } cocos2d::Pass* ret = cobj->getPassByIndex(arg0); object_to_luaval<cocos2d::Pass>(tolua_S, "cc.Pass",(cocos2d::Pass*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Technique:getPassByIndex",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Technique_getPassByIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Technique_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Technique",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Material* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Material>(tolua_S, 2, "cc.Material",&arg0, "cc.Technique:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Technique_create'", nullptr); return 0; } cocos2d::Technique* ret = cocos2d::Technique::create(arg0); object_to_luaval<cocos2d::Technique>(tolua_S, "cc.Technique",(cocos2d::Technique*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Technique:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Technique_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Technique_createWithGLProgramState(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Technique",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { cocos2d::Material* arg0 = nullptr; cocos2d::GLProgramState* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Material>(tolua_S, 2, "cc.Material",&arg0, "cc.Technique:createWithGLProgramState"); ok &= luaval_to_object<cocos2d::GLProgramState>(tolua_S, 3, "cc.GLProgramState",&arg1, "cc.Technique:createWithGLProgramState"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Technique_createWithGLProgramState'", nullptr); return 0; } cocos2d::Technique* ret = cocos2d::Technique::createWithGLProgramState(arg0, arg1); object_to_luaval<cocos2d::Technique>(tolua_S, "cc.Technique",(cocos2d::Technique*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Technique:createWithGLProgramState",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Technique_createWithGLProgramState'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Technique_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Technique)"); return 0; } int lua_register_cocos2dx_Technique(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Technique"); tolua_cclass(tolua_S,"Technique","cc.Technique","cc.RenderState",nullptr); tolua_beginmodule(tolua_S,"Technique"); tolua_function(tolua_S,"getPassCount",lua_cocos2dx_Technique_getPassCount); tolua_function(tolua_S,"clone",lua_cocos2dx_Technique_clone); tolua_function(tolua_S,"addPass",lua_cocos2dx_Technique_addPass); tolua_function(tolua_S,"getPasses",lua_cocos2dx_Technique_getPasses); tolua_function(tolua_S,"getName",lua_cocos2dx_Technique_getName); tolua_function(tolua_S,"getPassByIndex",lua_cocos2dx_Technique_getPassByIndex); tolua_function(tolua_S,"create", lua_cocos2dx_Technique_create); tolua_function(tolua_S,"createWithGLProgramState", lua_cocos2dx_Technique_createWithGLProgramState); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Technique).name(); g_luaType[typeName] = "cc.Technique"; g_typeCast["Technique"] = "cc.Technique"; return 1; } int lua_cocos2dx_Material_clone(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_clone'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_clone'", nullptr); return 0; } cocos2d::Material* ret = cobj->clone(); object_to_luaval<cocos2d::Material>(tolua_S, "cc.Material",(cocos2d::Material*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:clone",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_clone'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_getTechniqueCount(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_getTechniqueCount'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_getTechniqueCount'", nullptr); return 0; } ssize_t ret = cobj->getTechniqueCount(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:getTechniqueCount",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_getTechniqueCount'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_setName(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_setName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Material:setName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_setName'", nullptr); return 0; } cobj->setName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:setName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_setName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_getTechniqueByIndex(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_getTechniqueByIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { ssize_t arg0; ok &= luaval_to_ssize(tolua_S, 2, &arg0, "cc.Material:getTechniqueByIndex"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_getTechniqueByIndex'", nullptr); return 0; } cocos2d::Technique* ret = cobj->getTechniqueByIndex(arg0); object_to_luaval<cocos2d::Technique>(tolua_S, "cc.Technique",(cocos2d::Technique*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:getTechniqueByIndex",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_getTechniqueByIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_getName(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_getName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_getName'", nullptr); return 0; } std::string ret = cobj->getName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:getName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_getName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_getTechniques(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_getTechniques'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_getTechniques'", nullptr); return 0; } const cocos2d::Vector<cocos2d::Technique *>& ret = cobj->getTechniques(); ccvector_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:getTechniques",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_getTechniques'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_setTechnique(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_setTechnique'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Material:setTechnique"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_setTechnique'", nullptr); return 0; } cobj->setTechnique(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:setTechnique",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_setTechnique'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_getTechniqueByName(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_getTechniqueByName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Material:getTechniqueByName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_getTechniqueByName'", nullptr); return 0; } cocos2d::Technique* ret = cobj->getTechniqueByName(arg0); object_to_luaval<cocos2d::Technique>(tolua_S, "cc.Technique",(cocos2d::Technique*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:getTechniqueByName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_getTechniqueByName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_addTechnique(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_addTechnique'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Technique* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Technique>(tolua_S, 2, "cc.Technique",&arg0, "cc.Material:addTechnique"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_addTechnique'", nullptr); return 0; } cobj->addTechnique(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:addTechnique",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_addTechnique'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_getTechnique(lua_State* tolua_S) { int argc = 0; cocos2d::Material* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Material*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Material_getTechnique'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_getTechnique'", nullptr); return 0; } cocos2d::Technique* ret = cobj->getTechnique(); object_to_luaval<cocos2d::Technique>(tolua_S, "cc.Technique",(cocos2d::Technique*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Material:getTechnique",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_getTechnique'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_createWithFilename(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Material:createWithFilename"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_createWithFilename'", nullptr); return 0; } cocos2d::Material* ret = cocos2d::Material::createWithFilename(arg0); object_to_luaval<cocos2d::Material>(tolua_S, "cc.Material",(cocos2d::Material*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Material:createWithFilename",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_createWithFilename'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_createWithGLStateProgram(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::GLProgramState* arg0 = nullptr; ok &= luaval_to_object<cocos2d::GLProgramState>(tolua_S, 2, "cc.GLProgramState",&arg0, "cc.Material:createWithGLStateProgram"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_createWithGLStateProgram'", nullptr); return 0; } cocos2d::Material* ret = cocos2d::Material::createWithGLStateProgram(arg0); object_to_luaval<cocos2d::Material>(tolua_S, "cc.Material",(cocos2d::Material*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Material:createWithGLStateProgram",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_createWithGLStateProgram'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Material_createWithProperties(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Material",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Properties* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Properties>(tolua_S, 2, "cc.Properties",&arg0, "cc.Material:createWithProperties"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Material_createWithProperties'", nullptr); return 0; } cocos2d::Material* ret = cocos2d::Material::createWithProperties(arg0); object_to_luaval<cocos2d::Material>(tolua_S, "cc.Material",(cocos2d::Material*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Material:createWithProperties",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Material_createWithProperties'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Material_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Material)"); return 0; } int lua_register_cocos2dx_Material(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Material"); tolua_cclass(tolua_S,"Material","cc.Material","cc.RenderState",nullptr); tolua_beginmodule(tolua_S,"Material"); tolua_function(tolua_S,"clone",lua_cocos2dx_Material_clone); tolua_function(tolua_S,"getTechniqueCount",lua_cocos2dx_Material_getTechniqueCount); tolua_function(tolua_S,"setName",lua_cocos2dx_Material_setName); tolua_function(tolua_S,"getTechniqueByIndex",lua_cocos2dx_Material_getTechniqueByIndex); tolua_function(tolua_S,"getName",lua_cocos2dx_Material_getName); tolua_function(tolua_S,"getTechniques",lua_cocos2dx_Material_getTechniques); tolua_function(tolua_S,"setTechnique",lua_cocos2dx_Material_setTechnique); tolua_function(tolua_S,"getTechniqueByName",lua_cocos2dx_Material_getTechniqueByName); tolua_function(tolua_S,"addTechnique",lua_cocos2dx_Material_addTechnique); tolua_function(tolua_S,"getTechnique",lua_cocos2dx_Material_getTechnique); tolua_function(tolua_S,"createWithFilename", lua_cocos2dx_Material_createWithFilename); tolua_function(tolua_S,"createWithGLStateProgram", lua_cocos2dx_Material_createWithGLStateProgram); tolua_function(tolua_S,"createWithProperties", lua_cocos2dx_Material_createWithProperties); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Material).name(); g_luaType[typeName] = "cc.Material"; g_typeCast["Material"] = "cc.Material"; return 1; } int lua_cocos2dx_TextureCache_reloadTexture(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_reloadTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TextureCache:reloadTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_reloadTexture'", nullptr); return 0; } bool ret = cobj->reloadTexture(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:reloadTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_reloadTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_unbindAllImageAsync(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_unbindAllImageAsync'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_unbindAllImageAsync'", nullptr); return 0; } cobj->unbindAllImageAsync(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:unbindAllImageAsync",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_unbindAllImageAsync'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_removeTextureForKey(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_removeTextureForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TextureCache:removeTextureForKey"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_removeTextureForKey'", nullptr); return 0; } cobj->removeTextureForKey(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:removeTextureForKey",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_removeTextureForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_removeAllTextures(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_removeAllTextures'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_removeAllTextures'", nullptr); return 0; } cobj->removeAllTextures(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:removeAllTextures",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_removeAllTextures'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_getDescription(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_getDescription'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_getDescription'", nullptr); return 0; } std::string ret = cobj->getDescription(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:getDescription",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_getDescription'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_getCachedTextureInfo(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_getCachedTextureInfo'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_getCachedTextureInfo'", nullptr); return 0; } std::string ret = cobj->getCachedTextureInfo(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:getCachedTextureInfo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_getCachedTextureInfo'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_addImage(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_addImage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { cocos2d::Image* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Image>(tolua_S, 2, "cc.Image",&arg0, "cc.TextureCache:addImage"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.TextureCache:addImage"); if (!ok) { break; } cocos2d::Texture2D* ret = cobj->addImage(arg0, arg1); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TextureCache:addImage"); if (!ok) { break; } cocos2d::Texture2D* ret = cobj->addImage(arg0); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:addImage",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_addImage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_unbindImageAsync(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_unbindImageAsync'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TextureCache:unbindImageAsync"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_unbindImageAsync'", nullptr); return 0; } cobj->unbindImageAsync(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:unbindImageAsync",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_unbindImageAsync'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_getTextureForKey(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_getTextureForKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TextureCache:getTextureForKey"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_getTextureForKey'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTextureForKey(arg0); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:getTextureForKey",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_getTextureForKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_getTextureFilePath(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_getTextureFilePath'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.TextureCache:getTextureFilePath"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_getTextureFilePath'", nullptr); return 0; } std::string ret = cobj->getTextureFilePath(arg0); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:getTextureFilePath",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_getTextureFilePath'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_renameTextureWithKey(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_renameTextureWithKey'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TextureCache:renameTextureWithKey"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.TextureCache:renameTextureWithKey"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_renameTextureWithKey'", nullptr); return 0; } cobj->renameTextureWithKey(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:renameTextureWithKey",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_renameTextureWithKey'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_removeUnusedTextures(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_removeUnusedTextures'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_removeUnusedTextures'", nullptr); return 0; } cobj->removeUnusedTextures(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:removeUnusedTextures",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_removeUnusedTextures'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_removeTexture(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_removeTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.TextureCache:removeTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_removeTexture'", nullptr); return 0; } cobj->removeTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:removeTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_removeTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_waitForQuit(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TextureCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TextureCache_waitForQuit'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_waitForQuit'", nullptr); return 0; } cobj->waitForQuit(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:waitForQuit",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_waitForQuit'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_setETC1AlphaFileSuffix(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TextureCache:setETC1AlphaFileSuffix"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_setETC1AlphaFileSuffix'", nullptr); return 0; } cocos2d::TextureCache::setETC1AlphaFileSuffix(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TextureCache:setETC1AlphaFileSuffix",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_setETC1AlphaFileSuffix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_getETC1AlphaFileSuffix(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_getETC1AlphaFileSuffix'", nullptr); return 0; } std::string ret = cocos2d::TextureCache::getETC1AlphaFileSuffix(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TextureCache:getETC1AlphaFileSuffix",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_getETC1AlphaFileSuffix'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TextureCache_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TextureCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TextureCache_constructor'", nullptr); return 0; } cobj = new cocos2d::TextureCache(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TextureCache"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TextureCache:TextureCache",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TextureCache_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TextureCache_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TextureCache)"); return 0; } int lua_register_cocos2dx_TextureCache(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TextureCache"); tolua_cclass(tolua_S,"TextureCache","cc.TextureCache","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"TextureCache"); tolua_function(tolua_S,"new",lua_cocos2dx_TextureCache_constructor); tolua_function(tolua_S,"reloadTexture",lua_cocos2dx_TextureCache_reloadTexture); tolua_function(tolua_S,"unbindAllImageAsync",lua_cocos2dx_TextureCache_unbindAllImageAsync); tolua_function(tolua_S,"removeTextureForKey",lua_cocos2dx_TextureCache_removeTextureForKey); tolua_function(tolua_S,"removeAllTextures",lua_cocos2dx_TextureCache_removeAllTextures); tolua_function(tolua_S,"getDescription",lua_cocos2dx_TextureCache_getDescription); tolua_function(tolua_S,"getCachedTextureInfo",lua_cocos2dx_TextureCache_getCachedTextureInfo); tolua_function(tolua_S,"addImage",lua_cocos2dx_TextureCache_addImage); tolua_function(tolua_S,"unbindImageAsync",lua_cocos2dx_TextureCache_unbindImageAsync); tolua_function(tolua_S,"getTextureForKey",lua_cocos2dx_TextureCache_getTextureForKey); tolua_function(tolua_S,"getTextureFilePath",lua_cocos2dx_TextureCache_getTextureFilePath); tolua_function(tolua_S,"renameTextureWithKey",lua_cocos2dx_TextureCache_renameTextureWithKey); tolua_function(tolua_S,"removeUnusedTextures",lua_cocos2dx_TextureCache_removeUnusedTextures); tolua_function(tolua_S,"removeTexture",lua_cocos2dx_TextureCache_removeTexture); tolua_function(tolua_S,"waitForQuit",lua_cocos2dx_TextureCache_waitForQuit); tolua_function(tolua_S,"setETC1AlphaFileSuffix", lua_cocos2dx_TextureCache_setETC1AlphaFileSuffix); tolua_function(tolua_S,"getETC1AlphaFileSuffix", lua_cocos2dx_TextureCache_getETC1AlphaFileSuffix); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TextureCache).name(); g_luaType[typeName] = "cc.TextureCache"; g_typeCast["TextureCache"] = "cc.TextureCache"; return 1; } int lua_cocos2dx_Device_setAccelerometerEnabled(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Device",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Device:setAccelerometerEnabled"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Device_setAccelerometerEnabled'", nullptr); return 0; } cocos2d::Device::setAccelerometerEnabled(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Device:setAccelerometerEnabled",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Device_setAccelerometerEnabled'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Device_setAccelerometerInterval(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Device",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Device:setAccelerometerInterval"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Device_setAccelerometerInterval'", nullptr); return 0; } cocos2d::Device::setAccelerometerInterval(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Device:setAccelerometerInterval",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Device_setAccelerometerInterval'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Device_setKeepScreenOn(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Device",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.Device:setKeepScreenOn"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Device_setKeepScreenOn'", nullptr); return 0; } cocos2d::Device::setKeepScreenOn(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Device:setKeepScreenOn",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Device_setKeepScreenOn'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Device_vibrate(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Device",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Device:vibrate"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Device_vibrate'", nullptr); return 0; } cocos2d::Device::vibrate(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Device:vibrate",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Device_vibrate'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Device_getDPI(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Device",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Device_getDPI'", nullptr); return 0; } int ret = cocos2d::Device::getDPI(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Device:getDPI",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Device_getDPI'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Device_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Device)"); return 0; } int lua_register_cocos2dx_Device(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Device"); tolua_cclass(tolua_S,"Device","cc.Device","",nullptr); tolua_beginmodule(tolua_S,"Device"); tolua_function(tolua_S,"setAccelerometerEnabled", lua_cocos2dx_Device_setAccelerometerEnabled); tolua_function(tolua_S,"setAccelerometerInterval", lua_cocos2dx_Device_setAccelerometerInterval); tolua_function(tolua_S,"setKeepScreenOn", lua_cocos2dx_Device_setKeepScreenOn); tolua_function(tolua_S,"vibrate", lua_cocos2dx_Device_vibrate); tolua_function(tolua_S,"getDPI", lua_cocos2dx_Device_getDPI); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Device).name(); g_luaType[typeName] = "cc.Device"; g_typeCast["Device"] = "cc.Device"; return 1; } int lua_cocos2dx_Application_getTargetPlatform(lua_State* tolua_S) { int argc = 0; cocos2d::Application* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Application",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Application*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Application_getTargetPlatform'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Application_getTargetPlatform'", nullptr); return 0; } int ret = (int)cobj->getTargetPlatform(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Application:getTargetPlatform",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Application_getTargetPlatform'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Application_getCurrentLanguage(lua_State* tolua_S) { int argc = 0; cocos2d::Application* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Application",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Application*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Application_getCurrentLanguage'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Application_getCurrentLanguage'", nullptr); return 0; } int ret = (int)cobj->getCurrentLanguage(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Application:getCurrentLanguage",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Application_getCurrentLanguage'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Application_getCurrentLanguageCode(lua_State* tolua_S) { int argc = 0; cocos2d::Application* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Application",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Application*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Application_getCurrentLanguageCode'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Application_getCurrentLanguageCode'", nullptr); return 0; } const char* ret = cobj->getCurrentLanguageCode(); tolua_pushstring(tolua_S,(const char*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Application:getCurrentLanguageCode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Application_getCurrentLanguageCode'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Application_openURL(lua_State* tolua_S) { int argc = 0; cocos2d::Application* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Application",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Application*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Application_openURL'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Application:openURL"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Application_openURL'", nullptr); return 0; } bool ret = cobj->openURL(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Application:openURL",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Application_openURL'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Application_getVersion(lua_State* tolua_S) { int argc = 0; cocos2d::Application* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Application",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Application*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Application_getVersion'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Application_getVersion'", nullptr); return 0; } std::string ret = cobj->getVersion(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Application:getVersion",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Application_getVersion'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Application_setAnimationInterval(lua_State* tolua_S) { int argc = 0; cocos2d::Application* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.Application",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::Application*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Application_setAnimationInterval'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Application:setAnimationInterval"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Application_setAnimationInterval'", nullptr); return 0; } cobj->setAnimationInterval(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.Application:setAnimationInterval",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Application_setAnimationInterval'.",&tolua_err); #endif return 0; } int lua_cocos2dx_Application_getInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.Application",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_Application_getInstance'", nullptr); return 0; } cocos2d::Application* ret = cocos2d::Application::getInstance(); object_to_luaval<cocos2d::Application>(tolua_S, "cc.Application",(cocos2d::Application*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.Application:getInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Application_getInstance'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_Application_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (Application)"); return 0; } int lua_register_cocos2dx_Application(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.Application"); tolua_cclass(tolua_S,"Application","cc.Application","",nullptr); tolua_beginmodule(tolua_S,"Application"); tolua_function(tolua_S,"getTargetPlatform",lua_cocos2dx_Application_getTargetPlatform); tolua_function(tolua_S,"getCurrentLanguage",lua_cocos2dx_Application_getCurrentLanguage); tolua_function(tolua_S,"getCurrentLanguageCode",lua_cocos2dx_Application_getCurrentLanguageCode); tolua_function(tolua_S,"openURL",lua_cocos2dx_Application_openURL); tolua_function(tolua_S,"getVersion",lua_cocos2dx_Application_getVersion); tolua_function(tolua_S,"setAnimationInterval",lua_cocos2dx_Application_setAnimationInterval); tolua_function(tolua_S,"getInstance", lua_cocos2dx_Application_getInstance); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::Application).name(); g_luaType[typeName] = "cc.Application"; g_typeCast["Application"] = "cc.Application"; return 1; } int lua_cocos2dx_GLViewImpl_createWithRect(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLViewImpl",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { std::string arg0; cocos2d::Rect arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLViewImpl:createWithRect"); ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.GLViewImpl:createWithRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLViewImpl_createWithRect'", nullptr); return 0; } #if CC_TARGET_PLATFORM == CC_PLATFORM_WINRT cocos2d::GLViewImpl* ret = cocos2d::GLViewImpl::sharedOpenGLView(); ret->initWithRect(arg0, arg1, 1); #else cocos2d::GLViewImpl* ret = cocos2d::GLViewImpl::createWithRect(arg0, arg1); #endif object_to_luaval<cocos2d::GLViewImpl>(tolua_S, "cc.GLViewImpl",(cocos2d::GLViewImpl*)ret); return 1; } if (argc == 3) { std::string arg0; cocos2d::Rect arg1; double arg2; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLViewImpl:createWithRect"); ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.GLViewImpl:createWithRect"); ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.GLViewImpl:createWithRect"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLViewImpl_createWithRect'", nullptr); return 0; } #if CC_TARGET_PLATFORM == CC_PLATFORM_WINRT cocos2d::GLViewImpl* ret = cocos2d::GLViewImpl::sharedOpenGLView(); ret->initWithRect(arg0, arg1, arg2); #else cocos2d::GLViewImpl * ret = cocos2d::GLViewImpl::createWithRect(arg0, arg1, arg2); #endif object_to_luaval<cocos2d::GLViewImpl>(tolua_S, "cc.GLViewImpl",(cocos2d::GLViewImpl*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLViewImpl:createWithRect",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLViewImpl_createWithRect'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLViewImpl_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLViewImpl",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLViewImpl:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLViewImpl_create'", nullptr); return 0; } cocos2d::GLViewImpl* ret = cocos2d::GLViewImpl::create(arg0); object_to_luaval<cocos2d::GLViewImpl>(tolua_S, "cc.GLViewImpl",(cocos2d::GLViewImpl*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLViewImpl:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLViewImpl_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_GLViewImpl_createWithFullScreen(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.GLViewImpl",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLViewImpl:createWithFullScreen"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLViewImpl_createWithFullScreen'", nullptr); return 0; } #if CC_TARGET_PLATFORM == CC_PLATFORM_WINRT cocos2d::GLViewImpl* ret = cocos2d::GLViewImpl::sharedOpenGLView(); ret->initWithFullScreen(arg0); #else cocos2d::GLViewImpl* ret = cocos2d::GLViewImpl::createWithFullScreen(arg0); #endif object_to_luaval<cocos2d::GLViewImpl>(tolua_S, "cc.GLViewImpl",(cocos2d::GLViewImpl*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.GLViewImpl:createWithFullScreen",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLViewImpl_createWithFullScreen'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_GLViewImpl_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (GLViewImpl)"); return 0; } int lua_register_cocos2dx_GLViewImpl(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.GLViewImpl"); tolua_cclass(tolua_S,"GLViewImpl","cc.GLViewImpl","cc.GLView",nullptr); tolua_beginmodule(tolua_S,"GLViewImpl"); tolua_function(tolua_S,"createWithRect", lua_cocos2dx_GLViewImpl_createWithRect); tolua_function(tolua_S,"create", lua_cocos2dx_GLViewImpl_create); tolua_function(tolua_S,"createWithFullScreen", lua_cocos2dx_GLViewImpl_createWithFullScreen); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::GLViewImpl).name(); g_luaType[typeName] = "cc.GLViewImpl"; g_typeCast["GLViewImpl"] = "cc.GLViewImpl"; return 1; } int lua_cocos2dx_AnimationCache_getAnimation(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationCache_getAnimation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.AnimationCache:getAnimation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_getAnimation'", nullptr); return 0; } cocos2d::Animation* ret = cobj->getAnimation(arg0); object_to_luaval<cocos2d::Animation>(tolua_S, "cc.Animation",(cocos2d::Animation*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationCache:getAnimation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_getAnimation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationCache_addAnimation(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationCache_addAnimation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Animation* arg0 = nullptr; std::string arg1; ok &= luaval_to_object<cocos2d::Animation>(tolua_S, 2, "cc.Animation",&arg0, "cc.AnimationCache:addAnimation"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.AnimationCache:addAnimation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_addAnimation'", nullptr); return 0; } cobj->addAnimation(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationCache:addAnimation",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_addAnimation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationCache_init(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationCache_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationCache:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationCache_addAnimationsWithDictionary(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationCache_addAnimationsWithDictionary'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::ValueMap arg0; std::string arg1; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.AnimationCache:addAnimationsWithDictionary"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.AnimationCache:addAnimationsWithDictionary"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_addAnimationsWithDictionary'", nullptr); return 0; } cobj->addAnimationsWithDictionary(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationCache:addAnimationsWithDictionary",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_addAnimationsWithDictionary'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationCache_removeAnimation(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationCache_removeAnimation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.AnimationCache:removeAnimation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_removeAnimation'", nullptr); return 0; } cobj->removeAnimation(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationCache:removeAnimation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_removeAnimation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationCache_addAnimationsWithFile(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.AnimationCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::AnimationCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_AnimationCache_addAnimationsWithFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.AnimationCache:addAnimationsWithFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_addAnimationsWithFile'", nullptr); return 0; } cobj->addAnimationsWithFile(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationCache:addAnimationsWithFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_addAnimationsWithFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationCache_destroyInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.AnimationCache",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_destroyInstance'", nullptr); return 0; } cocos2d::AnimationCache::destroyInstance(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.AnimationCache:destroyInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_destroyInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationCache_getInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.AnimationCache",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_getInstance'", nullptr); return 0; } cocos2d::AnimationCache* ret = cocos2d::AnimationCache::getInstance(); object_to_luaval<cocos2d::AnimationCache>(tolua_S, "cc.AnimationCache",(cocos2d::AnimationCache*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.AnimationCache:getInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_getInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_AnimationCache_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::AnimationCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_AnimationCache_constructor'", nullptr); return 0; } cobj = new cocos2d::AnimationCache(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.AnimationCache"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.AnimationCache:AnimationCache",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_AnimationCache_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_AnimationCache_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (AnimationCache)"); return 0; } int lua_register_cocos2dx_AnimationCache(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.AnimationCache"); tolua_cclass(tolua_S,"AnimationCache","cc.AnimationCache","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"AnimationCache"); tolua_function(tolua_S,"new",lua_cocos2dx_AnimationCache_constructor); tolua_function(tolua_S,"getAnimation",lua_cocos2dx_AnimationCache_getAnimation); tolua_function(tolua_S,"addAnimation",lua_cocos2dx_AnimationCache_addAnimation); tolua_function(tolua_S,"init",lua_cocos2dx_AnimationCache_init); tolua_function(tolua_S,"addAnimationsWithDictionary",lua_cocos2dx_AnimationCache_addAnimationsWithDictionary); tolua_function(tolua_S,"removeAnimation",lua_cocos2dx_AnimationCache_removeAnimation); tolua_function(tolua_S,"addAnimations",lua_cocos2dx_AnimationCache_addAnimationsWithFile); tolua_function(tolua_S,"destroyInstance", lua_cocos2dx_AnimationCache_destroyInstance); tolua_function(tolua_S,"getInstance", lua_cocos2dx_AnimationCache_getInstance); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::AnimationCache).name(); g_luaType[typeName] = "cc.AnimationCache"; g_typeCast["AnimationCache"] = "cc.AnimationCache"; return 1; } int lua_cocos2dx_SpriteBatchNode_appendChild(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_appendChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Sprite* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.SpriteBatchNode:appendChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_appendChild'", nullptr); return 0; } cobj->appendChild(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:appendChild",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_appendChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_reorderBatch(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_reorderBatch'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.SpriteBatchNode:reorderBatch"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_reorderBatch'", nullptr); return 0; } cobj->reorderBatch(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:reorderBatch",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_reorderBatch'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteBatchNode:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_removeChildAtIndex(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_removeChildAtIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { ssize_t arg0; bool arg1; ok &= luaval_to_ssize(tolua_S, 2, &arg0, "cc.SpriteBatchNode:removeChildAtIndex"); ok &= luaval_to_boolean(tolua_S, 3,&arg1, "cc.SpriteBatchNode:removeChildAtIndex"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_removeChildAtIndex'", nullptr); return 0; } cobj->removeChildAtIndex(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:removeChildAtIndex",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_removeChildAtIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_removeSpriteFromAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_removeSpriteFromAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Sprite* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.SpriteBatchNode:removeSpriteFromAtlas"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_removeSpriteFromAtlas'", nullptr); return 0; } cobj->removeSpriteFromAtlas(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:removeSpriteFromAtlas",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_removeSpriteFromAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_addSpriteWithoutQuad(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_addSpriteWithoutQuad'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::Sprite* arg0 = nullptr; int arg1; int arg2; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.SpriteBatchNode:addSpriteWithoutQuad"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.SpriteBatchNode:addSpriteWithoutQuad"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.SpriteBatchNode:addSpriteWithoutQuad"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_addSpriteWithoutQuad'", nullptr); return 0; } cocos2d::SpriteBatchNode* ret = cobj->addSpriteWithoutQuad(arg0, arg1, arg2); object_to_luaval<cocos2d::SpriteBatchNode>(tolua_S, "cc.SpriteBatchNode",(cocos2d::SpriteBatchNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:addSpriteWithoutQuad",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_addSpriteWithoutQuad'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_atlasIndexForChild(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_atlasIndexForChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Sprite* arg0 = nullptr; int arg1; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.SpriteBatchNode:atlasIndexForChild"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.SpriteBatchNode:atlasIndexForChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_atlasIndexForChild'", nullptr); return 0; } ssize_t ret = cobj->atlasIndexForChild(arg0, arg1); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:atlasIndexForChild",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_atlasIndexForChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_increaseAtlasCapacity(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_increaseAtlasCapacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_increaseAtlasCapacity'", nullptr); return 0; } cobj->increaseAtlasCapacity(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:increaseAtlasCapacity",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_increaseAtlasCapacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_lowestAtlasIndexInChild(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_lowestAtlasIndexInChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Sprite* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.SpriteBatchNode:lowestAtlasIndexInChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_lowestAtlasIndexInChild'", nullptr); return 0; } ssize_t ret = cobj->lowestAtlasIndexInChild(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:lowestAtlasIndexInChild",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_lowestAtlasIndexInChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_initWithTexture(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_initWithTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteBatchNode:initWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_initWithTexture'", nullptr); return 0; } bool ret = cobj->initWithTexture(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; ssize_t arg1; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteBatchNode:initWithTexture"); ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.SpriteBatchNode:initWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_initWithTexture'", nullptr); return 0; } bool ret = cobj->initWithTexture(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:initWithTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_initWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_setTextureAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_setTextureAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TextureAtlas* arg0 = nullptr; ok &= luaval_to_object<cocos2d::TextureAtlas>(tolua_S, 2, "cc.TextureAtlas",&arg0, "cc.SpriteBatchNode:setTextureAtlas"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_setTextureAtlas'", nullptr); return 0; } cobj->setTextureAtlas(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:setTextureAtlas",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_setTextureAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_reserveCapacity(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_reserveCapacity'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { ssize_t arg0; ok &= luaval_to_ssize(tolua_S, 2, &arg0, "cc.SpriteBatchNode:reserveCapacity"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_reserveCapacity'", nullptr); return 0; } cobj->reserveCapacity(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:reserveCapacity",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_reserveCapacity'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_removeAllChildrenWithCleanup(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_removeAllChildrenWithCleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.SpriteBatchNode:removeAllChildrenWithCleanup"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_removeAllChildrenWithCleanup'", nullptr); return 0; } cobj->removeAllChildrenWithCleanup(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:removeAllChildrenWithCleanup",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_removeAllChildrenWithCleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_insertQuadFromSprite(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_insertQuadFromSprite'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Sprite* arg0 = nullptr; ssize_t arg1; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.SpriteBatchNode:insertQuadFromSprite"); ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.SpriteBatchNode:insertQuadFromSprite"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_insertQuadFromSprite'", nullptr); return 0; } cobj->insertQuadFromSprite(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:insertQuadFromSprite",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_insertQuadFromSprite'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_initWithFile(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_initWithFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteBatchNode:initWithFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_initWithFile'", nullptr); return 0; } bool ret = cobj->initWithFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } if (argc == 2) { std::string arg0; ssize_t arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteBatchNode:initWithFile"); ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.SpriteBatchNode:initWithFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_initWithFile'", nullptr); return 0; } bool ret = cobj->initWithFile(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:initWithFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_initWithFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.SpriteBatchNode:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_rebuildIndexInOrder(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_rebuildIndexInOrder'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Sprite* arg0 = nullptr; ssize_t arg1; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.SpriteBatchNode:rebuildIndexInOrder"); ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.SpriteBatchNode:rebuildIndexInOrder"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_rebuildIndexInOrder'", nullptr); return 0; } ssize_t ret = cobj->rebuildIndexInOrder(arg0, arg1); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:rebuildIndexInOrder",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_rebuildIndexInOrder'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_getTextureAtlas(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_getTextureAtlas'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_getTextureAtlas'", nullptr); return 0; } cocos2d::TextureAtlas* ret = cobj->getTextureAtlas(); object_to_luaval<cocos2d::TextureAtlas>(tolua_S, "cc.TextureAtlas",(cocos2d::TextureAtlas*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:getTextureAtlas",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_getTextureAtlas'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_highestAtlasIndexInChild(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteBatchNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteBatchNode_highestAtlasIndexInChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Sprite* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Sprite>(tolua_S, 2, "cc.Sprite",&arg0, "cc.SpriteBatchNode:highestAtlasIndexInChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_highestAtlasIndexInChild'", nullptr); return 0; } ssize_t ret = cobj->highestAtlasIndexInChild(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:highestAtlasIndexInChild",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_highestAtlasIndexInChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteBatchNode:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_create'", nullptr); return 0; } cocos2d::SpriteBatchNode* ret = cocos2d::SpriteBatchNode::create(arg0); object_to_luaval<cocos2d::SpriteBatchNode>(tolua_S, "cc.SpriteBatchNode",(cocos2d::SpriteBatchNode*)ret); return 1; } if (argc == 2) { std::string arg0; ssize_t arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteBatchNode:create"); ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.SpriteBatchNode:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_create'", nullptr); return 0; } cocos2d::SpriteBatchNode* ret = cocos2d::SpriteBatchNode::create(arg0, arg1); object_to_luaval<cocos2d::SpriteBatchNode>(tolua_S, "cc.SpriteBatchNode",(cocos2d::SpriteBatchNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SpriteBatchNode:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_createWithTexture(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SpriteBatchNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteBatchNode:createWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_createWithTexture'", nullptr); return 0; } cocos2d::SpriteBatchNode* ret = cocos2d::SpriteBatchNode::createWithTexture(arg0); object_to_luaval<cocos2d::SpriteBatchNode>(tolua_S, "cc.SpriteBatchNode",(cocos2d::SpriteBatchNode*)ret); return 1; } if (argc == 2) { cocos2d::Texture2D* arg0 = nullptr; ssize_t arg1; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteBatchNode:createWithTexture"); ok &= luaval_to_ssize(tolua_S, 3, &arg1, "cc.SpriteBatchNode:createWithTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_createWithTexture'", nullptr); return 0; } cocos2d::SpriteBatchNode* ret = cocos2d::SpriteBatchNode::createWithTexture(arg0, arg1); object_to_luaval<cocos2d::SpriteBatchNode>(tolua_S, "cc.SpriteBatchNode",(cocos2d::SpriteBatchNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SpriteBatchNode:createWithTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_createWithTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteBatchNode_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteBatchNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteBatchNode_constructor'", nullptr); return 0; } cobj = new cocos2d::SpriteBatchNode(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.SpriteBatchNode"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteBatchNode:SpriteBatchNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteBatchNode_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_SpriteBatchNode_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SpriteBatchNode)"); return 0; } int lua_register_cocos2dx_SpriteBatchNode(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.SpriteBatchNode"); tolua_cclass(tolua_S,"SpriteBatchNode","cc.SpriteBatchNode","cc.Node",nullptr); tolua_beginmodule(tolua_S,"SpriteBatchNode"); tolua_function(tolua_S,"new",lua_cocos2dx_SpriteBatchNode_constructor); tolua_function(tolua_S,"appendChild",lua_cocos2dx_SpriteBatchNode_appendChild); tolua_function(tolua_S,"reorderBatch",lua_cocos2dx_SpriteBatchNode_reorderBatch); tolua_function(tolua_S,"getTexture",lua_cocos2dx_SpriteBatchNode_getTexture); tolua_function(tolua_S,"setTexture",lua_cocos2dx_SpriteBatchNode_setTexture); tolua_function(tolua_S,"removeChildAtIndex",lua_cocos2dx_SpriteBatchNode_removeChildAtIndex); tolua_function(tolua_S,"removeSpriteFromAtlas",lua_cocos2dx_SpriteBatchNode_removeSpriteFromAtlas); tolua_function(tolua_S,"addSpriteWithoutQuad",lua_cocos2dx_SpriteBatchNode_addSpriteWithoutQuad); tolua_function(tolua_S,"atlasIndexForChild",lua_cocos2dx_SpriteBatchNode_atlasIndexForChild); tolua_function(tolua_S,"increaseAtlasCapacity",lua_cocos2dx_SpriteBatchNode_increaseAtlasCapacity); tolua_function(tolua_S,"lowestAtlasIndexInChild",lua_cocos2dx_SpriteBatchNode_lowestAtlasIndexInChild); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_SpriteBatchNode_getBlendFunc); tolua_function(tolua_S,"initWithTexture",lua_cocos2dx_SpriteBatchNode_initWithTexture); tolua_function(tolua_S,"setTextureAtlas",lua_cocos2dx_SpriteBatchNode_setTextureAtlas); tolua_function(tolua_S,"reserveCapacity",lua_cocos2dx_SpriteBatchNode_reserveCapacity); tolua_function(tolua_S,"removeAllChildrenWithCleanup",lua_cocos2dx_SpriteBatchNode_removeAllChildrenWithCleanup); tolua_function(tolua_S,"insertQuadFromSprite",lua_cocos2dx_SpriteBatchNode_insertQuadFromSprite); tolua_function(tolua_S,"initWithFile",lua_cocos2dx_SpriteBatchNode_initWithFile); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_SpriteBatchNode_setBlendFunc); tolua_function(tolua_S,"rebuildIndexInOrder",lua_cocos2dx_SpriteBatchNode_rebuildIndexInOrder); tolua_function(tolua_S,"getTextureAtlas",lua_cocos2dx_SpriteBatchNode_getTextureAtlas); tolua_function(tolua_S,"highestAtlasIndexInChild",lua_cocos2dx_SpriteBatchNode_highestAtlasIndexInChild); tolua_function(tolua_S,"create", lua_cocos2dx_SpriteBatchNode_create); tolua_function(tolua_S,"createWithTexture", lua_cocos2dx_SpriteBatchNode_createWithTexture); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::SpriteBatchNode).name(); g_luaType[typeName] = "cc.SpriteBatchNode"; g_typeCast["SpriteBatchNode"] = "cc.SpriteBatchNode"; return 1; } int lua_cocos2dx_SpriteFrameCache_reloadTexture(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_reloadTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:reloadTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_reloadTexture'", nullptr); return 0; } bool ret = cobj->reloadTexture(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:reloadTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_reloadTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFileContent(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFileContent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:addSpriteFramesWithFileContent"); ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.SpriteFrameCache:addSpriteFramesWithFileContent"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFileContent'", nullptr); return 0; } cobj->addSpriteFramesWithFileContent(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:addSpriteFramesWithFileContent",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFileContent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_addSpriteFrame(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_addSpriteFrame'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::SpriteFrame* arg0 = nullptr; std::string arg1; ok &= luaval_to_object<cocos2d::SpriteFrame>(tolua_S, 2, "cc.SpriteFrame",&arg0, "cc.SpriteFrameCache:addSpriteFrame"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.SpriteFrameCache:addSpriteFrame"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_addSpriteFrame'", nullptr); return 0; } cobj->addSpriteFrame(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:addSpriteFrame",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_addSpriteFrame'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFile(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:addSpriteFramesWithFile"); if (!ok) { break; } std::string arg1; ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.SpriteFrameCache:addSpriteFramesWithFile"); if (!ok) { break; } cobj->addSpriteFramesWithFile(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:addSpriteFramesWithFile"); if (!ok) { break; } cobj->addSpriteFramesWithFile(arg0); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:addSpriteFramesWithFile"); if (!ok) { break; } cocos2d::Texture2D* arg1 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 3, "cc.Texture2D",&arg1, "cc.SpriteFrameCache:addSpriteFramesWithFile"); if (!ok) { break; } cobj->addSpriteFramesWithFile(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:addSpriteFramesWithFile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_getSpriteFrameByName(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_getSpriteFrameByName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:getSpriteFrameByName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_getSpriteFrameByName'", nullptr); return 0; } cocos2d::SpriteFrame* ret = cobj->getSpriteFrameByName(arg0); object_to_luaval<cocos2d::SpriteFrame>(tolua_S, "cc.SpriteFrame",(cocos2d::SpriteFrame*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:getSpriteFrameByName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_getSpriteFrameByName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFile(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:removeSpriteFramesFromFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFile'", nullptr); return 0; } cobj->removeSpriteFramesFromFile(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:removeSpriteFramesFromFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_init(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_init'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_init'", nullptr); return 0; } bool ret = cobj->init(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:init",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_init'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_removeSpriteFrames(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFrames'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFrames'", nullptr); return 0; } cobj->removeSpriteFrames(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:removeSpriteFrames",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFrames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_removeUnusedSpriteFrames(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_removeUnusedSpriteFrames'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_removeUnusedSpriteFrames'", nullptr); return 0; } cobj->removeUnusedSpriteFrames(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:removeUnusedSpriteFrames",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_removeUnusedSpriteFrames'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFileContent(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFileContent'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:removeSpriteFramesFromFileContent"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFileContent'", nullptr); return 0; } cobj->removeSpriteFramesFromFileContent(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:removeSpriteFramesFromFileContent",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFileContent'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_removeSpriteFrameByName(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFrameByName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:removeSpriteFrameByName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFrameByName'", nullptr); return 0; } cobj->removeSpriteFrameByName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:removeSpriteFrameByName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFrameByName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_isSpriteFramesWithFileLoaded(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_isSpriteFramesWithFileLoaded'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.SpriteFrameCache:isSpriteFramesWithFileLoaded"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_isSpriteFramesWithFileLoaded'", nullptr); return 0; } bool ret = cobj->isSpriteFramesWithFileLoaded(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:isSpriteFramesWithFileLoaded",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_isSpriteFramesWithFileLoaded'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromTexture(lua_State* tolua_S) { int argc = 0; cocos2d::SpriteFrameCache* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::SpriteFrameCache*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.SpriteFrameCache:removeSpriteFramesFromTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromTexture'", nullptr); return 0; } cobj->removeSpriteFramesFromTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.SpriteFrameCache:removeSpriteFramesFromTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_destroyInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_destroyInstance'", nullptr); return 0; } cocos2d::SpriteFrameCache::destroyInstance(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SpriteFrameCache:destroyInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_destroyInstance'.",&tolua_err); #endif return 0; } int lua_cocos2dx_SpriteFrameCache_getInstance(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.SpriteFrameCache",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_SpriteFrameCache_getInstance'", nullptr); return 0; } cocos2d::SpriteFrameCache* ret = cocos2d::SpriteFrameCache::getInstance(); object_to_luaval<cocos2d::SpriteFrameCache>(tolua_S, "cc.SpriteFrameCache",(cocos2d::SpriteFrameCache*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.SpriteFrameCache:getInstance",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_SpriteFrameCache_getInstance'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_SpriteFrameCache_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SpriteFrameCache)"); return 0; } int lua_register_cocos2dx_SpriteFrameCache(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.SpriteFrameCache"); tolua_cclass(tolua_S,"SpriteFrameCache","cc.SpriteFrameCache","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"SpriteFrameCache"); tolua_function(tolua_S,"reloadTexture",lua_cocos2dx_SpriteFrameCache_reloadTexture); tolua_function(tolua_S,"addSpriteFramesWithFileContent",lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFileContent); tolua_function(tolua_S,"addSpriteFrame",lua_cocos2dx_SpriteFrameCache_addSpriteFrame); tolua_function(tolua_S,"addSpriteFrames",lua_cocos2dx_SpriteFrameCache_addSpriteFramesWithFile); tolua_function(tolua_S,"getSpriteFrame",lua_cocos2dx_SpriteFrameCache_getSpriteFrameByName); tolua_function(tolua_S,"removeSpriteFramesFromFile",lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFile); tolua_function(tolua_S,"init",lua_cocos2dx_SpriteFrameCache_init); tolua_function(tolua_S,"removeSpriteFrames",lua_cocos2dx_SpriteFrameCache_removeSpriteFrames); tolua_function(tolua_S,"removeUnusedSpriteFrames",lua_cocos2dx_SpriteFrameCache_removeUnusedSpriteFrames); tolua_function(tolua_S,"removeSpriteFramesFromFileContent",lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromFileContent); tolua_function(tolua_S,"removeSpriteFrameByName",lua_cocos2dx_SpriteFrameCache_removeSpriteFrameByName); tolua_function(tolua_S,"isSpriteFramesWithFileLoaded",lua_cocos2dx_SpriteFrameCache_isSpriteFramesWithFileLoaded); tolua_function(tolua_S,"removeSpriteFramesFromTexture",lua_cocos2dx_SpriteFrameCache_removeSpriteFramesFromTexture); tolua_function(tolua_S,"destroyInstance", lua_cocos2dx_SpriteFrameCache_destroyInstance); tolua_function(tolua_S,"getInstance", lua_cocos2dx_SpriteFrameCache_getInstance); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::SpriteFrameCache).name(); g_luaType[typeName] = "cc.SpriteFrameCache"; g_typeCast["SpriteFrameCache"] = "cc.SpriteFrameCache"; return 1; } int lua_cocos2dx_ParallaxNode_addChild(lua_State* tolua_S) { int argc = 0; cocos2d::ParallaxNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParallaxNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParallaxNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParallaxNode_addChild'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { cocos2d::Node* arg0 = nullptr; int arg1; cocos2d::Vec2 arg2; cocos2d::Vec2 arg3; ok &= luaval_to_object<cocos2d::Node>(tolua_S, 2, "cc.Node",&arg0, "cc.ParallaxNode:addChild"); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ParallaxNode:addChild"); ok &= luaval_to_vec2(tolua_S, 4, &arg2, "cc.ParallaxNode:addChild"); ok &= luaval_to_vec2(tolua_S, 5, &arg3, "cc.ParallaxNode:addChild"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParallaxNode_addChild'", nullptr); return 0; } cobj->addChild(arg0, arg1, arg2, arg3); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParallaxNode:addChild",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParallaxNode_addChild'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParallaxNode_removeAllChildrenWithCleanup(lua_State* tolua_S) { int argc = 0; cocos2d::ParallaxNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ParallaxNode",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ParallaxNode*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ParallaxNode_removeAllChildrenWithCleanup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.ParallaxNode:removeAllChildrenWithCleanup"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParallaxNode_removeAllChildrenWithCleanup'", nullptr); return 0; } cobj->removeAllChildrenWithCleanup(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParallaxNode:removeAllChildrenWithCleanup",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParallaxNode_removeAllChildrenWithCleanup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParallaxNode_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ParallaxNode",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParallaxNode_create'", nullptr); return 0; } cocos2d::ParallaxNode* ret = cocos2d::ParallaxNode::create(); object_to_luaval<cocos2d::ParallaxNode>(tolua_S, "cc.ParallaxNode",(cocos2d::ParallaxNode*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ParallaxNode:create",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParallaxNode_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ParallaxNode_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ParallaxNode* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ParallaxNode_constructor'", nullptr); return 0; } cobj = new cocos2d::ParallaxNode(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ParallaxNode"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ParallaxNode:ParallaxNode",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ParallaxNode_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ParallaxNode_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ParallaxNode)"); return 0; } int lua_register_cocos2dx_ParallaxNode(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ParallaxNode"); tolua_cclass(tolua_S,"ParallaxNode","cc.ParallaxNode","cc.Node",nullptr); tolua_beginmodule(tolua_S,"ParallaxNode"); tolua_function(tolua_S,"new",lua_cocos2dx_ParallaxNode_constructor); tolua_function(tolua_S,"addChild",lua_cocos2dx_ParallaxNode_addChild); tolua_function(tolua_S,"removeAllChildrenWithCleanup",lua_cocos2dx_ParallaxNode_removeAllChildrenWithCleanup); tolua_function(tolua_S,"create", lua_cocos2dx_ParallaxNode_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ParallaxNode).name(); g_luaType[typeName] = "cc.ParallaxNode"; g_typeCast["ParallaxNode"] = "cc.ParallaxNode"; return 1; } int lua_cocos2dx_TMXObjectGroup_setPositionOffset(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_setPositionOffset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.TMXObjectGroup:setPositionOffset"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_setPositionOffset'", nullptr); return 0; } cobj->setPositionOffset(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:setPositionOffset",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_setPositionOffset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_getProperty(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_getProperty'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXObjectGroup:getProperty"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_getProperty'", nullptr); return 0; } cocos2d::Value ret = cobj->getProperty(arg0); ccvalue_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:getProperty",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_getProperty'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_getPositionOffset(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_getPositionOffset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_getPositionOffset'", nullptr); return 0; } const cocos2d::Vec2& ret = cobj->getPositionOffset(); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:getPositionOffset",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_getPositionOffset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_getObject(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_getObject'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXObjectGroup:getObject"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_getObject'", nullptr); return 0; } cocos2d::ValueMap ret = cobj->getObject(arg0); ccvaluemap_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:getObject",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_getObject'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_getObjects(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_getObjects'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::ValueVector& ret = cobj->getObjects(); ccvaluevector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::ValueVector& ret = cobj->getObjects(); ccvaluevector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:getObjects",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_getObjects'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_setGroupName(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_setGroupName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXObjectGroup:setGroupName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_setGroupName'", nullptr); return 0; } cobj->setGroupName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:setGroupName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_setGroupName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_getProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_getProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::ValueMap& ret = cobj->getProperties(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::ValueMap& ret = cobj->getProperties(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:getProperties",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_getProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_getGroupName(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_getGroupName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_getGroupName'", nullptr); return 0; } const std::string& ret = cobj->getGroupName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:getGroupName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_getGroupName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_setProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_setProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.TMXObjectGroup:setProperties"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_setProperties'", nullptr); return 0; } cobj->setProperties(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:setProperties",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_setProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_setObjects(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXObjectGroup",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXObjectGroup*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXObjectGroup_setObjects'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueVector arg0; ok &= luaval_to_ccvaluevector(tolua_S, 2, &arg0, "cc.TMXObjectGroup:setObjects"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_setObjects'", nullptr); return 0; } cobj->setObjects(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:setObjects",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_setObjects'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXObjectGroup_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TMXObjectGroup* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXObjectGroup_constructor'", nullptr); return 0; } cobj = new cocos2d::TMXObjectGroup(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TMXObjectGroup"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXObjectGroup:TMXObjectGroup",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXObjectGroup_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TMXObjectGroup_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TMXObjectGroup)"); return 0; } int lua_register_cocos2dx_TMXObjectGroup(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TMXObjectGroup"); tolua_cclass(tolua_S,"TMXObjectGroup","cc.TMXObjectGroup","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"TMXObjectGroup"); tolua_function(tolua_S,"new",lua_cocos2dx_TMXObjectGroup_constructor); tolua_function(tolua_S,"setPositionOffset",lua_cocos2dx_TMXObjectGroup_setPositionOffset); tolua_function(tolua_S,"getProperty",lua_cocos2dx_TMXObjectGroup_getProperty); tolua_function(tolua_S,"getPositionOffset",lua_cocos2dx_TMXObjectGroup_getPositionOffset); tolua_function(tolua_S,"getObject",lua_cocos2dx_TMXObjectGroup_getObject); tolua_function(tolua_S,"getObjects",lua_cocos2dx_TMXObjectGroup_getObjects); tolua_function(tolua_S,"setGroupName",lua_cocos2dx_TMXObjectGroup_setGroupName); tolua_function(tolua_S,"getProperties",lua_cocos2dx_TMXObjectGroup_getProperties); tolua_function(tolua_S,"getGroupName",lua_cocos2dx_TMXObjectGroup_getGroupName); tolua_function(tolua_S,"setProperties",lua_cocos2dx_TMXObjectGroup_setProperties); tolua_function(tolua_S,"setObjects",lua_cocos2dx_TMXObjectGroup_setObjects); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TMXObjectGroup).name(); g_luaType[typeName] = "cc.TMXObjectGroup"; g_typeCast["TMXObjectGroup"] = "cc.TMXObjectGroup"; return 1; } int lua_cocos2dx_TMXLayerInfo_setProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayerInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayerInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayerInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayerInfo_setProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.TMXLayerInfo:setProperties"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayerInfo_setProperties'", nullptr); return 0; } cobj->setProperties(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayerInfo:setProperties",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayerInfo_setProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayerInfo_getProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayerInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayerInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayerInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayerInfo_getProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayerInfo_getProperties'", nullptr); return 0; } cocos2d::ValueMap& ret = cobj->getProperties(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayerInfo:getProperties",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayerInfo_getProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayerInfo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayerInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayerInfo_constructor'", nullptr); return 0; } cobj = new cocos2d::TMXLayerInfo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TMXLayerInfo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayerInfo:TMXLayerInfo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayerInfo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TMXLayerInfo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TMXLayerInfo)"); return 0; } int lua_register_cocos2dx_TMXLayerInfo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TMXLayerInfo"); tolua_cclass(tolua_S,"TMXLayerInfo","cc.TMXLayerInfo","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"TMXLayerInfo"); tolua_function(tolua_S,"new",lua_cocos2dx_TMXLayerInfo_constructor); tolua_function(tolua_S,"setProperties",lua_cocos2dx_TMXLayerInfo_setProperties); tolua_function(tolua_S,"getProperties",lua_cocos2dx_TMXLayerInfo_getProperties); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TMXLayerInfo).name(); g_luaType[typeName] = "cc.TMXLayerInfo"; g_typeCast["TMXLayerInfo"] = "cc.TMXLayerInfo"; return 1; } int lua_cocos2dx_TMXTilesetInfo_getRectForGID(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTilesetInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTilesetInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTilesetInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTilesetInfo_getRectForGID'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { unsigned int arg0; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.TMXTilesetInfo:getRectForGID"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTilesetInfo_getRectForGID'", nullptr); return 0; } cocos2d::Rect ret = cobj->getRectForGID(arg0); rect_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTilesetInfo:getRectForGID",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTilesetInfo_getRectForGID'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTilesetInfo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTilesetInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTilesetInfo_constructor'", nullptr); return 0; } cobj = new cocos2d::TMXTilesetInfo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TMXTilesetInfo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTilesetInfo:TMXTilesetInfo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTilesetInfo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TMXTilesetInfo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TMXTilesetInfo)"); return 0; } int lua_register_cocos2dx_TMXTilesetInfo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TMXTilesetInfo"); tolua_cclass(tolua_S,"TMXTilesetInfo","cc.TMXTilesetInfo","cc.Ref",nullptr); tolua_beginmodule(tolua_S,"TMXTilesetInfo"); tolua_function(tolua_S,"new",lua_cocos2dx_TMXTilesetInfo_constructor); tolua_function(tolua_S,"getRectForGID",lua_cocos2dx_TMXTilesetInfo_getRectForGID); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TMXTilesetInfo).name(); g_luaType[typeName] = "cc.TMXTilesetInfo"; g_typeCast["TMXTilesetInfo"] = "cc.TMXTilesetInfo"; return 1; } int lua_cocos2dx_TMXMapInfo_setCurrentString(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setCurrentString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXMapInfo:setCurrentString"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setCurrentString'", nullptr); return 0; } cobj->setCurrentString(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setCurrentString",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setCurrentString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getHexSideLength(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getHexSideLength'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getHexSideLength'", nullptr); return 0; } int ret = cobj->getHexSideLength(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getHexSideLength",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getHexSideLength'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setTileSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setTileSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TMXMapInfo:setTileSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setTileSize'", nullptr); return 0; } cobj->setTileSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setTileSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setTileSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_initWithTMXFile(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_initWithTMXFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXMapInfo:initWithTMXFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_initWithTMXFile'", nullptr); return 0; } bool ret = cobj->initWithTMXFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:initWithTMXFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_initWithTMXFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getOrientation(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getOrientation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getOrientation'", nullptr); return 0; } int ret = cobj->getOrientation(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getOrientation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getOrientation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setObjectGroups(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setObjectGroups'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::TMXObjectGroup *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.TMXMapInfo:setObjectGroups"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setObjectGroups'", nullptr); return 0; } cobj->setObjectGroups(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setObjectGroups",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setObjectGroups'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setLayers(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setLayers'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::TMXLayerInfo *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.TMXMapInfo:setLayers"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setLayers'", nullptr); return 0; } cobj->setLayers(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setLayers",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setLayers'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_parseXMLFile(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_parseXMLFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXMapInfo:parseXMLFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_parseXMLFile'", nullptr); return 0; } bool ret = cobj->parseXMLFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:parseXMLFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_parseXMLFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getParentElement(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getParentElement'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getParentElement'", nullptr); return 0; } int ret = cobj->getParentElement(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getParentElement",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getParentElement'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setTMXFileName(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setTMXFileName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXMapInfo:setTMXFileName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setTMXFileName'", nullptr); return 0; } cobj->setTMXFileName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setTMXFileName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setTMXFileName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_parseXMLString(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_parseXMLString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXMapInfo:parseXMLString"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_parseXMLString'", nullptr); return 0; } bool ret = cobj->parseXMLString(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:parseXMLString",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_parseXMLString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getLayers(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getLayers'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::Vector<cocos2d::TMXLayerInfo *>& ret = cobj->getLayers(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::Vector<cocos2d::TMXLayerInfo *>& ret = cobj->getLayers(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getLayers",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getLayers'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getStaggerAxis(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getStaggerAxis'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getStaggerAxis'", nullptr); return 0; } int ret = cobj->getStaggerAxis(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getStaggerAxis",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getStaggerAxis'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setHexSideLength(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setHexSideLength'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXMapInfo:setHexSideLength"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setHexSideLength'", nullptr); return 0; } cobj->setHexSideLength(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setHexSideLength",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setHexSideLength'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getTilesets(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getTilesets'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::Vector<cocos2d::TMXTilesetInfo *>& ret = cobj->getTilesets(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::Vector<cocos2d::TMXTilesetInfo *>& ret = cobj->getTilesets(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getTilesets",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getTilesets'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getParentGID(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getParentGID'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getParentGID'", nullptr); return 0; } int ret = cobj->getParentGID(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getParentGID",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getParentGID'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setParentElement(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setParentElement'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXMapInfo:setParentElement"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setParentElement'", nullptr); return 0; } cobj->setParentElement(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setParentElement",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setParentElement'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_initWithXML(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_initWithXML'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXMapInfo:initWithXML"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.TMXMapInfo:initWithXML"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_initWithXML'", nullptr); return 0; } bool ret = cobj->initWithXML(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:initWithXML",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_initWithXML'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setParentGID(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setParentGID'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXMapInfo:setParentGID"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setParentGID'", nullptr); return 0; } cobj->setParentGID(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setParentGID",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setParentGID'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getLayerAttribs(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getLayerAttribs'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getLayerAttribs'", nullptr); return 0; } int ret = cobj->getLayerAttribs(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getLayerAttribs",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getLayerAttribs'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getTileSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getTileSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getTileSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getTileSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getTileSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getTileSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getTileProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getTileProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getTileProperties'", nullptr); return 0; } cocos2d::ValueMapIntKey& ret = cobj->getTileProperties(); ccvaluemapintkey_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getTileProperties",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getTileProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_isStoringCharacters(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_isStoringCharacters'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_isStoringCharacters'", nullptr); return 0; } bool ret = cobj->isStoringCharacters(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:isStoringCharacters",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_isStoringCharacters'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getExternalTilesetFileName(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getExternalTilesetFileName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getExternalTilesetFileName'", nullptr); return 0; } const std::string& ret = cobj->getExternalTilesetFileName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getExternalTilesetFileName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getExternalTilesetFileName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getObjectGroups(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getObjectGroups'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::Vector<cocos2d::TMXObjectGroup *>& ret = cobj->getObjectGroups(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::Vector<cocos2d::TMXObjectGroup *>& ret = cobj->getObjectGroups(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getObjectGroups",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getObjectGroups'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getTMXFileName(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getTMXFileName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getTMXFileName'", nullptr); return 0; } const std::string& ret = cobj->getTMXFileName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getTMXFileName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getTMXFileName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setStaggerIndex(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setStaggerIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXMapInfo:setStaggerIndex"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setStaggerIndex'", nullptr); return 0; } cobj->setStaggerIndex(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setStaggerIndex",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setStaggerIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.TMXMapInfo:setProperties"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setProperties'", nullptr); return 0; } cobj->setProperties(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setProperties",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setOrientation(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setOrientation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXMapInfo:setOrientation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setOrientation'", nullptr); return 0; } cobj->setOrientation(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setOrientation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setOrientation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setTileProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setTileProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueMapIntKey arg0; ok &= luaval_to_ccvaluemapintkey(tolua_S, 2, &arg0, "cc.TMXMapInfo:setTileProperties"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setTileProperties'", nullptr); return 0; } cobj->setTileProperties(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setTileProperties",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setTileProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setMapSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setMapSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TMXMapInfo:setMapSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setMapSize'", nullptr); return 0; } cobj->setMapSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setMapSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setMapSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getCurrentString(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getCurrentString'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getCurrentString'", nullptr); return 0; } const std::string& ret = cobj->getCurrentString(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getCurrentString",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getCurrentString'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setStoringCharacters(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setStoringCharacters'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.TMXMapInfo:setStoringCharacters"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setStoringCharacters'", nullptr); return 0; } cobj->setStoringCharacters(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setStoringCharacters",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setStoringCharacters'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setStaggerAxis(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setStaggerAxis'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXMapInfo:setStaggerAxis"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setStaggerAxis'", nullptr); return 0; } cobj->setStaggerAxis(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setStaggerAxis",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setStaggerAxis'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getMapSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getMapSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getMapSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getMapSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getMapSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getMapSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setTilesets(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setTilesets'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::TMXTilesetInfo *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.TMXMapInfo:setTilesets"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setTilesets'", nullptr); return 0; } cobj->setTilesets(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setTilesets",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setTilesets'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::ValueMap& ret = cobj->getProperties(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::ValueMap& ret = cobj->getProperties(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getProperties",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_getStaggerIndex(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_getStaggerIndex'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_getStaggerIndex'", nullptr); return 0; } int ret = cobj->getStaggerIndex(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:getStaggerIndex",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_getStaggerIndex'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_setLayerAttribs(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXMapInfo*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXMapInfo_setLayerAttribs'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXMapInfo:setLayerAttribs"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_setLayerAttribs'", nullptr); return 0; } cobj->setLayerAttribs(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:setLayerAttribs",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_setLayerAttribs'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXMapInfo:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_create'", nullptr); return 0; } cocos2d::TMXMapInfo* ret = cocos2d::TMXMapInfo::create(arg0); object_to_luaval<cocos2d::TMXMapInfo>(tolua_S, "cc.TMXMapInfo",(cocos2d::TMXMapInfo*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TMXMapInfo:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_createWithXML(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TMXMapInfo",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXMapInfo:createWithXML"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.TMXMapInfo:createWithXML"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_createWithXML'", nullptr); return 0; } cocos2d::TMXMapInfo* ret = cocos2d::TMXMapInfo::createWithXML(arg0, arg1); object_to_luaval<cocos2d::TMXMapInfo>(tolua_S, "cc.TMXMapInfo",(cocos2d::TMXMapInfo*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TMXMapInfo:createWithXML",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_createWithXML'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXMapInfo_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TMXMapInfo* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXMapInfo_constructor'", nullptr); return 0; } cobj = new cocos2d::TMXMapInfo(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TMXMapInfo"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXMapInfo:TMXMapInfo",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXMapInfo_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TMXMapInfo_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TMXMapInfo)"); return 0; } int lua_register_cocos2dx_TMXMapInfo(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TMXMapInfo"); tolua_cclass(tolua_S,"TMXMapInfo","cc.TMXMapInfo","",nullptr); tolua_beginmodule(tolua_S,"TMXMapInfo"); tolua_function(tolua_S,"new",lua_cocos2dx_TMXMapInfo_constructor); tolua_function(tolua_S,"setCurrentString",lua_cocos2dx_TMXMapInfo_setCurrentString); tolua_function(tolua_S,"getHexSideLength",lua_cocos2dx_TMXMapInfo_getHexSideLength); tolua_function(tolua_S,"setTileSize",lua_cocos2dx_TMXMapInfo_setTileSize); tolua_function(tolua_S,"initWithTMXFile",lua_cocos2dx_TMXMapInfo_initWithTMXFile); tolua_function(tolua_S,"getOrientation",lua_cocos2dx_TMXMapInfo_getOrientation); tolua_function(tolua_S,"setObjectGroups",lua_cocos2dx_TMXMapInfo_setObjectGroups); tolua_function(tolua_S,"setLayers",lua_cocos2dx_TMXMapInfo_setLayers); tolua_function(tolua_S,"parseXMLFile",lua_cocos2dx_TMXMapInfo_parseXMLFile); tolua_function(tolua_S,"getParentElement",lua_cocos2dx_TMXMapInfo_getParentElement); tolua_function(tolua_S,"setTMXFileName",lua_cocos2dx_TMXMapInfo_setTMXFileName); tolua_function(tolua_S,"parseXMLString",lua_cocos2dx_TMXMapInfo_parseXMLString); tolua_function(tolua_S,"getLayers",lua_cocos2dx_TMXMapInfo_getLayers); tolua_function(tolua_S,"getStaggerAxis",lua_cocos2dx_TMXMapInfo_getStaggerAxis); tolua_function(tolua_S,"setHexSideLength",lua_cocos2dx_TMXMapInfo_setHexSideLength); tolua_function(tolua_S,"getTilesets",lua_cocos2dx_TMXMapInfo_getTilesets); tolua_function(tolua_S,"getParentGID",lua_cocos2dx_TMXMapInfo_getParentGID); tolua_function(tolua_S,"setParentElement",lua_cocos2dx_TMXMapInfo_setParentElement); tolua_function(tolua_S,"initWithXML",lua_cocos2dx_TMXMapInfo_initWithXML); tolua_function(tolua_S,"setParentGID",lua_cocos2dx_TMXMapInfo_setParentGID); tolua_function(tolua_S,"getLayerAttribs",lua_cocos2dx_TMXMapInfo_getLayerAttribs); tolua_function(tolua_S,"getTileSize",lua_cocos2dx_TMXMapInfo_getTileSize); tolua_function(tolua_S,"getTileProperties",lua_cocos2dx_TMXMapInfo_getTileProperties); tolua_function(tolua_S,"isStoringCharacters",lua_cocos2dx_TMXMapInfo_isStoringCharacters); tolua_function(tolua_S,"getExternalTilesetFileName",lua_cocos2dx_TMXMapInfo_getExternalTilesetFileName); tolua_function(tolua_S,"getObjectGroups",lua_cocos2dx_TMXMapInfo_getObjectGroups); tolua_function(tolua_S,"getTMXFileName",lua_cocos2dx_TMXMapInfo_getTMXFileName); tolua_function(tolua_S,"setStaggerIndex",lua_cocos2dx_TMXMapInfo_setStaggerIndex); tolua_function(tolua_S,"setProperties",lua_cocos2dx_TMXMapInfo_setProperties); tolua_function(tolua_S,"setOrientation",lua_cocos2dx_TMXMapInfo_setOrientation); tolua_function(tolua_S,"setTileProperties",lua_cocos2dx_TMXMapInfo_setTileProperties); tolua_function(tolua_S,"setMapSize",lua_cocos2dx_TMXMapInfo_setMapSize); tolua_function(tolua_S,"getCurrentString",lua_cocos2dx_TMXMapInfo_getCurrentString); tolua_function(tolua_S,"setStoringCharacters",lua_cocos2dx_TMXMapInfo_setStoringCharacters); tolua_function(tolua_S,"setStaggerAxis",lua_cocos2dx_TMXMapInfo_setStaggerAxis); tolua_function(tolua_S,"getMapSize",lua_cocos2dx_TMXMapInfo_getMapSize); tolua_function(tolua_S,"setTilesets",lua_cocos2dx_TMXMapInfo_setTilesets); tolua_function(tolua_S,"getProperties",lua_cocos2dx_TMXMapInfo_getProperties); tolua_function(tolua_S,"getStaggerIndex",lua_cocos2dx_TMXMapInfo_getStaggerIndex); tolua_function(tolua_S,"setLayerAttribs",lua_cocos2dx_TMXMapInfo_setLayerAttribs); tolua_function(tolua_S,"create", lua_cocos2dx_TMXMapInfo_create); tolua_function(tolua_S,"createWithXML", lua_cocos2dx_TMXMapInfo_createWithXML); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TMXMapInfo).name(); g_luaType[typeName] = "cc.TMXMapInfo"; g_typeCast["TMXMapInfo"] = "cc.TMXMapInfo"; return 1; } int lua_cocos2dx_TMXLayer_getPositionAt(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getPositionAt'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.TMXLayer:getPositionAt"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_getPositionAt'", nullptr); return 0; } cocos2d::Vec2 ret = cobj->getPositionAt(arg0); vec2_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getPositionAt",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getPositionAt'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_setLayerOrientation(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_setLayerOrientation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXLayer:setLayerOrientation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_setLayerOrientation'", nullptr); return 0; } cobj->setLayerOrientation(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:setLayerOrientation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_setLayerOrientation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_releaseMap(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_releaseMap'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_releaseMap'", nullptr); return 0; } cobj->releaseMap(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:releaseMap",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_releaseMap'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_getLayerSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getLayerSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_getLayerSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getLayerSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getLayerSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getLayerSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_setMapTileSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_setMapTileSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TMXLayer:setMapTileSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_setMapTileSize'", nullptr); return 0; } cobj->setMapTileSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:setMapTileSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_setMapTileSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_getLayerOrientation(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getLayerOrientation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_getLayerOrientation'", nullptr); return 0; } int ret = cobj->getLayerOrientation(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getLayerOrientation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getLayerOrientation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_setProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_setProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.TMXLayer:setProperties"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_setProperties'", nullptr); return 0; } cobj->setProperties(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:setProperties",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_setProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_setLayerName(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_setLayerName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXLayer:setLayerName"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_setLayerName'", nullptr); return 0; } cobj->setLayerName(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:setLayerName",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_setLayerName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_removeTileAt(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_removeTileAt'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.TMXLayer:removeTileAt"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_removeTileAt'", nullptr); return 0; } cobj->removeTileAt(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:removeTileAt",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_removeTileAt'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_initWithTilesetInfo(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_initWithTilesetInfo'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 3) { cocos2d::TMXTilesetInfo* arg0 = nullptr; cocos2d::TMXLayerInfo* arg1 = nullptr; cocos2d::TMXMapInfo* arg2 = nullptr; ok &= luaval_to_object<cocos2d::TMXTilesetInfo>(tolua_S, 2, "cc.TMXTilesetInfo",&arg0, "cc.TMXLayer:initWithTilesetInfo"); ok &= luaval_to_object<cocos2d::TMXLayerInfo>(tolua_S, 3, "cc.TMXLayerInfo",&arg1, "cc.TMXLayer:initWithTilesetInfo"); ok &= luaval_to_object<cocos2d::TMXMapInfo>(tolua_S, 4, "cc.TMXMapInfo",&arg2, "cc.TMXLayer:initWithTilesetInfo"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_initWithTilesetInfo'", nullptr); return 0; } bool ret = cobj->initWithTilesetInfo(arg0, arg1, arg2); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:initWithTilesetInfo",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_initWithTilesetInfo'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_setupTiles(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_setupTiles'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_setupTiles'", nullptr); return 0; } cobj->setupTiles(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:setupTiles",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_setupTiles'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_setTileGID(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_setTileGID'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 3) { unsigned int arg0; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.TMXLayer:setTileGID"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.TMXLayer:setTileGID"); if (!ok) { break; } cocos2d::TMXTileFlags_ arg2; ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TMXLayer:setTileGID"); if (!ok) { break; } cobj->setTileGID(arg0, arg1, arg2); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; do{ if (argc == 2) { unsigned int arg0; ok &= luaval_to_uint32(tolua_S, 2,&arg0, "cc.TMXLayer:setTileGID"); if (!ok) { break; } cocos2d::Vec2 arg1; ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.TMXLayer:setTileGID"); if (!ok) { break; } cobj->setTileGID(arg0, arg1); lua_settop(tolua_S, 1); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:setTileGID",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_setTileGID'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_getMapTileSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getMapTileSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_getMapTileSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getMapTileSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getMapTileSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getMapTileSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_getProperty(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getProperty'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXLayer:getProperty"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_getProperty'", nullptr); return 0; } cocos2d::Value ret = cobj->getProperty(arg0); ccvalue_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getProperty",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getProperty'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_setLayerSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_setLayerSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TMXLayer:setLayerSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_setLayerSize'", nullptr); return 0; } cobj->setLayerSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:setLayerSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_setLayerSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_getLayerName(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getLayerName'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_getLayerName'", nullptr); return 0; } const std::string& ret = cobj->getLayerName(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getLayerName",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getLayerName'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_setTileSet(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_setTileSet'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::TMXTilesetInfo* arg0 = nullptr; ok &= luaval_to_object<cocos2d::TMXTilesetInfo>(tolua_S, 2, "cc.TMXTilesetInfo",&arg0, "cc.TMXLayer:setTileSet"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_setTileSet'", nullptr); return 0; } cobj->setTileSet(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:setTileSet",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_setTileSet'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_getTileSet(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getTileSet'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_getTileSet'", nullptr); return 0; } cocos2d::TMXTilesetInfo* ret = cobj->getTileSet(); object_to_luaval<cocos2d::TMXTilesetInfo>(tolua_S, "cc.TMXTilesetInfo",(cocos2d::TMXTilesetInfo*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getTileSet",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getTileSet'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_getProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::ValueMap& ret = cobj->getProperties(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::ValueMap& ret = cobj->getProperties(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getProperties",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_getTileAt(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXLayer*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXLayer_getTileAt'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.TMXLayer:getTileAt"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_getTileAt'", nullptr); return 0; } cocos2d::Sprite* ret = cobj->getTileAt(arg0); object_to_luaval<cocos2d::Sprite>(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:getTileAt",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_getTileAt'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TMXLayer",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 3) { cocos2d::TMXTilesetInfo* arg0 = nullptr; cocos2d::TMXLayerInfo* arg1 = nullptr; cocos2d::TMXMapInfo* arg2 = nullptr; ok &= luaval_to_object<cocos2d::TMXTilesetInfo>(tolua_S, 2, "cc.TMXTilesetInfo",&arg0, "cc.TMXLayer:create"); ok &= luaval_to_object<cocos2d::TMXLayerInfo>(tolua_S, 3, "cc.TMXLayerInfo",&arg1, "cc.TMXLayer:create"); ok &= luaval_to_object<cocos2d::TMXMapInfo>(tolua_S, 4, "cc.TMXMapInfo",&arg2, "cc.TMXLayer:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_create'", nullptr); return 0; } cocos2d::TMXLayer* ret = cocos2d::TMXLayer::create(arg0, arg1, arg2); object_to_luaval<cocos2d::TMXLayer>(tolua_S, "cc.TMXLayer",(cocos2d::TMXLayer*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TMXLayer:create",argc, 3); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXLayer_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TMXLayer* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXLayer_constructor'", nullptr); return 0; } cobj = new cocos2d::TMXLayer(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TMXLayer"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXLayer:TMXLayer",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXLayer_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TMXLayer_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TMXLayer)"); return 0; } int lua_register_cocos2dx_TMXLayer(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TMXLayer"); tolua_cclass(tolua_S,"TMXLayer","cc.TMXLayer","cc.SpriteBatchNode",nullptr); tolua_beginmodule(tolua_S,"TMXLayer"); tolua_function(tolua_S,"new",lua_cocos2dx_TMXLayer_constructor); tolua_function(tolua_S,"getPositionAt",lua_cocos2dx_TMXLayer_getPositionAt); tolua_function(tolua_S,"setLayerOrientation",lua_cocos2dx_TMXLayer_setLayerOrientation); tolua_function(tolua_S,"releaseMap",lua_cocos2dx_TMXLayer_releaseMap); tolua_function(tolua_S,"getLayerSize",lua_cocos2dx_TMXLayer_getLayerSize); tolua_function(tolua_S,"setMapTileSize",lua_cocos2dx_TMXLayer_setMapTileSize); tolua_function(tolua_S,"getLayerOrientation",lua_cocos2dx_TMXLayer_getLayerOrientation); tolua_function(tolua_S,"setProperties",lua_cocos2dx_TMXLayer_setProperties); tolua_function(tolua_S,"setLayerName",lua_cocos2dx_TMXLayer_setLayerName); tolua_function(tolua_S,"removeTileAt",lua_cocos2dx_TMXLayer_removeTileAt); tolua_function(tolua_S,"initWithTilesetInfo",lua_cocos2dx_TMXLayer_initWithTilesetInfo); tolua_function(tolua_S,"setupTiles",lua_cocos2dx_TMXLayer_setupTiles); tolua_function(tolua_S,"setTileGID",lua_cocos2dx_TMXLayer_setTileGID); tolua_function(tolua_S,"getMapTileSize",lua_cocos2dx_TMXLayer_getMapTileSize); tolua_function(tolua_S,"getProperty",lua_cocos2dx_TMXLayer_getProperty); tolua_function(tolua_S,"setLayerSize",lua_cocos2dx_TMXLayer_setLayerSize); tolua_function(tolua_S,"getLayerName",lua_cocos2dx_TMXLayer_getLayerName); tolua_function(tolua_S,"setTileSet",lua_cocos2dx_TMXLayer_setTileSet); tolua_function(tolua_S,"getTileSet",lua_cocos2dx_TMXLayer_getTileSet); tolua_function(tolua_S,"getProperties",lua_cocos2dx_TMXLayer_getProperties); tolua_function(tolua_S,"getTileAt",lua_cocos2dx_TMXLayer_getTileAt); tolua_function(tolua_S,"create", lua_cocos2dx_TMXLayer_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TMXLayer).name(); g_luaType[typeName] = "cc.TMXLayer"; g_typeCast["TMXLayer"] = "cc.TMXLayer"; return 1; } int lua_cocos2dx_TMXTiledMap_setObjectGroups(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_setObjectGroups'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vector<cocos2d::TMXObjectGroup *> arg0; ok &= luaval_to_ccvector(tolua_S, 2, &arg0, "cc.TMXTiledMap:setObjectGroups"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_setObjectGroups'", nullptr); return 0; } cobj->setObjectGroups(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:setObjectGroups",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_setObjectGroups'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getProperty(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getProperty'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXTiledMap:getProperty"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getProperty'", nullptr); return 0; } cocos2d::Value ret = cobj->getProperty(arg0); ccvalue_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getProperty",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getProperty'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getLayerNum(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getLayerNum'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getLayerNum'", nullptr); return 0; } int ret = cobj->getLayerNum(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getLayerNum",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getLayerNum'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_setMapSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_setMapSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TMXTiledMap:setMapSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_setMapSize'", nullptr); return 0; } cobj->setMapSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:setMapSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_setMapSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getObjectGroup(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getObjectGroup'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXTiledMap:getObjectGroup"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getObjectGroup'", nullptr); return 0; } cocos2d::TMXObjectGroup* ret = cobj->getObjectGroup(arg0); object_to_luaval<cocos2d::TMXObjectGroup>(tolua_S, "cc.TMXObjectGroup",(cocos2d::TMXObjectGroup*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getObjectGroup",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getObjectGroup'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getObjectGroups(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getObjectGroups'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 0) { cocos2d::Vector<cocos2d::TMXObjectGroup *>& ret = cobj->getObjectGroups(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; do{ if (argc == 0) { const cocos2d::Vector<cocos2d::TMXObjectGroup *>& ret = cobj->getObjectGroups(); ccvector_to_luaval(tolua_S, ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getObjectGroups",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getObjectGroups'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getResourceFile(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getResourceFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getResourceFile'", nullptr); return 0; } const std::string& ret = cobj->getResourceFile(); lua_pushlstring(tolua_S,ret.c_str(),ret.length()); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getResourceFile",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getResourceFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_initWithTMXFile(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_initWithTMXFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXTiledMap:initWithTMXFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_initWithTMXFile'", nullptr); return 0; } bool ret = cobj->initWithTMXFile(arg0); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:initWithTMXFile",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_initWithTMXFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getTileSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getTileSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getTileSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getTileSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getTileSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getTileSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getMapSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getMapSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getMapSize'", nullptr); return 0; } const cocos2d::Size& ret = cobj->getMapSize(); size_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getMapSize",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getMapSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_initWithXML(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_initWithXML'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXTiledMap:initWithXML"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.TMXTiledMap:initWithXML"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_initWithXML'", nullptr); return 0; } bool ret = cobj->initWithXML(arg0, arg1); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:initWithXML",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_initWithXML'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getProperties'", nullptr); return 0; } cocos2d::ValueMap& ret = cobj->getProperties(); ccvaluemap_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getProperties",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_setTileSize(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_setTileSize'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Size arg0; ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.TMXTiledMap:setTileSize"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_setTileSize'", nullptr); return 0; } cobj->setTileSize(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:setTileSize",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_setTileSize'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_setProperties(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_setProperties'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::ValueMap arg0; ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0, "cc.TMXTiledMap:setProperties"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_setProperties'", nullptr); return 0; } cobj->setProperties(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:setProperties",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_setProperties'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getLayer(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getLayer'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXTiledMap:getLayer"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getLayer'", nullptr); return 0; } cocos2d::TMXLayer* ret = cobj->getLayer(arg0); object_to_luaval<cocos2d::TMXLayer>(tolua_S, "cc.TMXLayer",(cocos2d::TMXLayer*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getLayer",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getLayer'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_getMapOrientation(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_getMapOrientation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_getMapOrientation'", nullptr); return 0; } int ret = cobj->getMapOrientation(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:getMapOrientation",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_getMapOrientation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_setMapOrientation(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TMXTiledMap_setMapOrientation'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.TMXTiledMap:setMapOrientation"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_setMapOrientation'", nullptr); return 0; } cobj->setMapOrientation(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:setMapOrientation",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_setMapOrientation'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXTiledMap:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_create'", nullptr); return 0; } cocos2d::TMXTiledMap* ret = cocos2d::TMXTiledMap::create(arg0); object_to_luaval<cocos2d::TMXTiledMap>(tolua_S, "cc.TMXTiledMap",(cocos2d::TMXTiledMap*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TMXTiledMap:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_createWithXML(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 2) { std::string arg0; std::string arg1; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TMXTiledMap:createWithXML"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.TMXTiledMap:createWithXML"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_createWithXML'", nullptr); return 0; } cocos2d::TMXTiledMap* ret = cocos2d::TMXTiledMap::createWithXML(arg0, arg1); object_to_luaval<cocos2d::TMXTiledMap>(tolua_S, "cc.TMXTiledMap",(cocos2d::TMXTiledMap*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TMXTiledMap:createWithXML",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_createWithXML'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TMXTiledMap_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TMXTiledMap* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TMXTiledMap_constructor'", nullptr); return 0; } cobj = new cocos2d::TMXTiledMap(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TMXTiledMap"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TMXTiledMap:TMXTiledMap",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TMXTiledMap_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TMXTiledMap_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TMXTiledMap)"); return 0; } int lua_register_cocos2dx_TMXTiledMap(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TMXTiledMap"); tolua_cclass(tolua_S,"TMXTiledMap","cc.TMXTiledMap","cc.Node",nullptr); tolua_beginmodule(tolua_S,"TMXTiledMap"); tolua_function(tolua_S,"new",lua_cocos2dx_TMXTiledMap_constructor); tolua_function(tolua_S,"setObjectGroups",lua_cocos2dx_TMXTiledMap_setObjectGroups); tolua_function(tolua_S,"getProperty",lua_cocos2dx_TMXTiledMap_getProperty); tolua_function(tolua_S,"getLayerNum",lua_cocos2dx_TMXTiledMap_getLayerNum); tolua_function(tolua_S,"setMapSize",lua_cocos2dx_TMXTiledMap_setMapSize); tolua_function(tolua_S,"getObjectGroup",lua_cocos2dx_TMXTiledMap_getObjectGroup); tolua_function(tolua_S,"getObjectGroups",lua_cocos2dx_TMXTiledMap_getObjectGroups); tolua_function(tolua_S,"getResourceFile",lua_cocos2dx_TMXTiledMap_getResourceFile); tolua_function(tolua_S,"initWithTMXFile",lua_cocos2dx_TMXTiledMap_initWithTMXFile); tolua_function(tolua_S,"getTileSize",lua_cocos2dx_TMXTiledMap_getTileSize); tolua_function(tolua_S,"getMapSize",lua_cocos2dx_TMXTiledMap_getMapSize); tolua_function(tolua_S,"initWithXML",lua_cocos2dx_TMXTiledMap_initWithXML); tolua_function(tolua_S,"getProperties",lua_cocos2dx_TMXTiledMap_getProperties); tolua_function(tolua_S,"setTileSize",lua_cocos2dx_TMXTiledMap_setTileSize); tolua_function(tolua_S,"setProperties",lua_cocos2dx_TMXTiledMap_setProperties); tolua_function(tolua_S,"getLayer",lua_cocos2dx_TMXTiledMap_getLayer); tolua_function(tolua_S,"getMapOrientation",lua_cocos2dx_TMXTiledMap_getMapOrientation); tolua_function(tolua_S,"setMapOrientation",lua_cocos2dx_TMXTiledMap_setMapOrientation); tolua_function(tolua_S,"create", lua_cocos2dx_TMXTiledMap_create); tolua_function(tolua_S,"createWithXML", lua_cocos2dx_TMXTiledMap_createWithXML); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TMXTiledMap).name(); g_luaType[typeName] = "cc.TMXTiledMap"; g_typeCast["TMXTiledMap"] = "cc.TMXTiledMap"; return 1; } int lua_cocos2dx_TileMapAtlas_initWithTileFile(lua_State* tolua_S) { int argc = 0; cocos2d::TileMapAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TileMapAtlas",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TileMapAtlas*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TileMapAtlas_initWithTileFile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 4) { std::string arg0; std::string arg1; int arg2; int arg3; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TileMapAtlas:initWithTileFile"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.TileMapAtlas:initWithTileFile"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TileMapAtlas:initWithTileFile"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.TileMapAtlas:initWithTileFile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TileMapAtlas_initWithTileFile'", nullptr); return 0; } bool ret = cobj->initWithTileFile(arg0, arg1, arg2, arg3); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TileMapAtlas:initWithTileFile",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TileMapAtlas_initWithTileFile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TileMapAtlas_releaseMap(lua_State* tolua_S) { int argc = 0; cocos2d::TileMapAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TileMapAtlas",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TileMapAtlas*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TileMapAtlas_releaseMap'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TileMapAtlas_releaseMap'", nullptr); return 0; } cobj->releaseMap(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TileMapAtlas:releaseMap",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TileMapAtlas_releaseMap'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TileMapAtlas_getTileAt(lua_State* tolua_S) { int argc = 0; cocos2d::TileMapAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TileMapAtlas",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TileMapAtlas*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TileMapAtlas_getTileAt'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec2 arg0; ok &= luaval_to_vec2(tolua_S, 2, &arg0, "cc.TileMapAtlas:getTileAt"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TileMapAtlas_getTileAt'", nullptr); return 0; } cocos2d::Color3B ret = cobj->getTileAt(arg0); color3b_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TileMapAtlas:getTileAt",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TileMapAtlas_getTileAt'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TileMapAtlas_setTile(lua_State* tolua_S) { int argc = 0; cocos2d::TileMapAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.TileMapAtlas",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::TileMapAtlas*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_TileMapAtlas_setTile'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 2) { cocos2d::Color3B arg0; cocos2d::Vec2 arg1; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.TileMapAtlas:setTile"); ok &= luaval_to_vec2(tolua_S, 3, &arg1, "cc.TileMapAtlas:setTile"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TileMapAtlas_setTile'", nullptr); return 0; } cobj->setTile(arg0, arg1); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TileMapAtlas:setTile",argc, 2); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TileMapAtlas_setTile'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TileMapAtlas_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.TileMapAtlas",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 4) { std::string arg0; std::string arg1; int arg2; int arg3; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.TileMapAtlas:create"); ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.TileMapAtlas:create"); ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2, "cc.TileMapAtlas:create"); ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3, "cc.TileMapAtlas:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TileMapAtlas_create'", nullptr); return 0; } cocos2d::TileMapAtlas* ret = cocos2d::TileMapAtlas::create(arg0, arg1, arg2, arg3); object_to_luaval<cocos2d::TileMapAtlas>(tolua_S, "cc.TileMapAtlas",(cocos2d::TileMapAtlas*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.TileMapAtlas:create",argc, 4); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TileMapAtlas_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_TileMapAtlas_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::TileMapAtlas* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_TileMapAtlas_constructor'", nullptr); return 0; } cobj = new cocos2d::TileMapAtlas(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TileMapAtlas"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.TileMapAtlas:TileMapAtlas",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TileMapAtlas_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_TileMapAtlas_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TileMapAtlas)"); return 0; } int lua_register_cocos2dx_TileMapAtlas(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.TileMapAtlas"); tolua_cclass(tolua_S,"TileMapAtlas","cc.TileMapAtlas","cc.AtlasNode",nullptr); tolua_beginmodule(tolua_S,"TileMapAtlas"); tolua_function(tolua_S,"new",lua_cocos2dx_TileMapAtlas_constructor); tolua_function(tolua_S,"initWithTileFile",lua_cocos2dx_TileMapAtlas_initWithTileFile); tolua_function(tolua_S,"releaseMap",lua_cocos2dx_TileMapAtlas_releaseMap); tolua_function(tolua_S,"getTileAt",lua_cocos2dx_TileMapAtlas_getTileAt); tolua_function(tolua_S,"setTile",lua_cocos2dx_TileMapAtlas_setTile); tolua_function(tolua_S,"create", lua_cocos2dx_TileMapAtlas_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TileMapAtlas).name(); g_luaType[typeName] = "cc.TileMapAtlas"; g_typeCast["TileMapAtlas"] = "cc.TileMapAtlas"; return 1; } int lua_cocos2dx_MotionStreak3D_reset(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_reset'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_reset'", nullptr); return 0; } cobj->reset(); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:reset",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_reset'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_setTexture(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_setTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Texture2D* arg0 = nullptr; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 2, "cc.Texture2D",&arg0, "cc.MotionStreak3D:setTexture"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_setTexture'", nullptr); return 0; } cobj->setTexture(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:setTexture",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_setTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_getTexture(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_getTexture'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_getTexture'", nullptr); return 0; } cocos2d::Texture2D* ret = cobj->getTexture(); object_to_luaval<cocos2d::Texture2D>(tolua_S, "cc.Texture2D",(cocos2d::Texture2D*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:getTexture",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_getTexture'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_tintWithColor(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_tintWithColor'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Color3B arg0; ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.MotionStreak3D:tintWithColor"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_tintWithColor'", nullptr); return 0; } cobj->tintWithColor(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:tintWithColor",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_tintWithColor'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_getSweepAxis(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_getSweepAxis'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_getSweepAxis'", nullptr); return 0; } const cocos2d::Vec3& ret = cobj->getSweepAxis(); vec3_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:getSweepAxis",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_getSweepAxis'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_setBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_setBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::BlendFunc arg0; ok &= luaval_to_blendfunc(tolua_S, 2, &arg0, "cc.MotionStreak3D:setBlendFunc"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_setBlendFunc'", nullptr); return 0; } cobj->setBlendFunc(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:setBlendFunc",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_setBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_setStartingPositionInitialized(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_setStartingPositionInitialized'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { bool arg0; ok &= luaval_to_boolean(tolua_S, 2,&arg0, "cc.MotionStreak3D:setStartingPositionInitialized"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_setStartingPositionInitialized'", nullptr); return 0; } cobj->setStartingPositionInitialized(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:setStartingPositionInitialized",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_setStartingPositionInitialized'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_getBlendFunc(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_getBlendFunc'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_getBlendFunc'", nullptr); return 0; } const cocos2d::BlendFunc& ret = cobj->getBlendFunc(); blendfunc_to_luaval(tolua_S, ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:getBlendFunc",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_getBlendFunc'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_isStartingPositionInitialized(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_isStartingPositionInitialized'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_isStartingPositionInitialized'", nullptr); return 0; } bool ret = cobj->isStartingPositionInitialized(); tolua_pushboolean(tolua_S,(bool)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:isStartingPositionInitialized",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_isStartingPositionInitialized'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_getStroke(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_getStroke'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_getStroke'", nullptr); return 0; } double ret = cobj->getStroke(); tolua_pushnumber(tolua_S,(lua_Number)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:getStroke",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_getStroke'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_initWithFade(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_initWithFade'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; do{ if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } cocos2d::Color3B arg3; ok &= luaval_to_color3b(tolua_S, 5, &arg3, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } cocos2d::Texture2D* arg4; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 6, "cc.Texture2D",&arg4, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } bool ret = cobj->initWithFade(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; do{ if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } cocos2d::Color3B arg3; ok &= luaval_to_color3b(tolua_S, 5, &arg3, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } std::string arg4; ok &= luaval_to_std_string(tolua_S, 6,&arg4, "cc.MotionStreak3D:initWithFade"); if (!ok) { break; } bool ret = cobj->initWithFade(arg0, arg1, arg2, arg3, arg4); tolua_pushboolean(tolua_S,(bool)ret); return 1; } }while(0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:initWithFade",argc, 5); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_initWithFade'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_setSweepAxis(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_setSweepAxis'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { cocos2d::Vec3 arg0; ok &= luaval_to_vec3(tolua_S, 2, &arg0, "cc.MotionStreak3D:setSweepAxis"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_setSweepAxis'", nullptr); return 0; } cobj->setSweepAxis(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:setSweepAxis",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_setSweepAxis'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_setStroke(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::MotionStreak3D*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_MotionStreak3D_setStroke'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak3D:setStroke"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_setStroke'", nullptr); return 0; } cobj->setStroke(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:setStroke",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_setStroke'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.MotionStreak3D",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S)-1; do { if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak3D:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.MotionStreak3D:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.MotionStreak3D:create"); if (!ok) { break; } cocos2d::Color3B arg3; ok &= luaval_to_color3b(tolua_S, 5, &arg3, "cc.MotionStreak3D:create"); if (!ok) { break; } cocos2d::Texture2D* arg4; ok &= luaval_to_object<cocos2d::Texture2D>(tolua_S, 6, "cc.Texture2D",&arg4, "cc.MotionStreak3D:create"); if (!ok) { break; } cocos2d::MotionStreak3D* ret = cocos2d::MotionStreak3D::create(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::MotionStreak3D>(tolua_S, "cc.MotionStreak3D",(cocos2d::MotionStreak3D*)ret); return 1; } } while (0); ok = true; do { if (argc == 5) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.MotionStreak3D:create"); if (!ok) { break; } double arg1; ok &= luaval_to_number(tolua_S, 3,&arg1, "cc.MotionStreak3D:create"); if (!ok) { break; } double arg2; ok &= luaval_to_number(tolua_S, 4,&arg2, "cc.MotionStreak3D:create"); if (!ok) { break; } cocos2d::Color3B arg3; ok &= luaval_to_color3b(tolua_S, 5, &arg3, "cc.MotionStreak3D:create"); if (!ok) { break; } std::string arg4; ok &= luaval_to_std_string(tolua_S, 6,&arg4, "cc.MotionStreak3D:create"); if (!ok) { break; } cocos2d::MotionStreak3D* ret = cocos2d::MotionStreak3D::create(arg0, arg1, arg2, arg3, arg4); object_to_luaval<cocos2d::MotionStreak3D>(tolua_S, "cc.MotionStreak3D",(cocos2d::MotionStreak3D*)ret); return 1; } } while (0); ok = true; luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d", "cc.MotionStreak3D:create",argc, 5); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_MotionStreak3D_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::MotionStreak3D* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_MotionStreak3D_constructor'", nullptr); return 0; } cobj = new cocos2d::MotionStreak3D(); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.MotionStreak3D"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.MotionStreak3D:MotionStreak3D",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_MotionStreak3D_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_MotionStreak3D_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (MotionStreak3D)"); return 0; } int lua_register_cocos2dx_MotionStreak3D(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.MotionStreak3D"); tolua_cclass(tolua_S,"MotionStreak3D","cc.MotionStreak3D","cc.Node",nullptr); tolua_beginmodule(tolua_S,"MotionStreak3D"); tolua_function(tolua_S,"new",lua_cocos2dx_MotionStreak3D_constructor); tolua_function(tolua_S,"reset",lua_cocos2dx_MotionStreak3D_reset); tolua_function(tolua_S,"setTexture",lua_cocos2dx_MotionStreak3D_setTexture); tolua_function(tolua_S,"getTexture",lua_cocos2dx_MotionStreak3D_getTexture); tolua_function(tolua_S,"tintWithColor",lua_cocos2dx_MotionStreak3D_tintWithColor); tolua_function(tolua_S,"getSweepAxis",lua_cocos2dx_MotionStreak3D_getSweepAxis); tolua_function(tolua_S,"setBlendFunc",lua_cocos2dx_MotionStreak3D_setBlendFunc); tolua_function(tolua_S,"setStartingPositionInitialized",lua_cocos2dx_MotionStreak3D_setStartingPositionInitialized); tolua_function(tolua_S,"getBlendFunc",lua_cocos2dx_MotionStreak3D_getBlendFunc); tolua_function(tolua_S,"isStartingPositionInitialized",lua_cocos2dx_MotionStreak3D_isStartingPositionInitialized); tolua_function(tolua_S,"getStroke",lua_cocos2dx_MotionStreak3D_getStroke); tolua_function(tolua_S,"initWithFade",lua_cocos2dx_MotionStreak3D_initWithFade); tolua_function(tolua_S,"setSweepAxis",lua_cocos2dx_MotionStreak3D_setSweepAxis); tolua_function(tolua_S,"setStroke",lua_cocos2dx_MotionStreak3D_setStroke); tolua_function(tolua_S,"create", lua_cocos2dx_MotionStreak3D_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::MotionStreak3D).name(); g_luaType[typeName] = "cc.MotionStreak3D"; g_typeCast["MotionStreak3D"] = "cc.MotionStreak3D"; return 1; } int lua_cocos2dx_ComponentLua_getScriptObject(lua_State* tolua_S) { int argc = 0; cocos2d::ComponentLua* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ComponentLua",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ComponentLua*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ComponentLua_getScriptObject'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 0) { if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ComponentLua_getScriptObject'", nullptr); return 0; } void* ret = cobj->getScriptObject(); #pragma warning NO CONVERSION FROM NATIVE FOR void*; return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ComponentLua:getScriptObject",argc, 0); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ComponentLua_getScriptObject'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ComponentLua_update(lua_State* tolua_S) { int argc = 0; cocos2d::ComponentLua* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertype(tolua_S,1,"cc.ComponentLua",0,&tolua_err)) goto tolua_lerror; #endif cobj = (cocos2d::ComponentLua*)tolua_tousertype(tolua_S,1,0); #if COCOS2D_DEBUG >= 1 if (!cobj) { tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_ComponentLua_update'", nullptr); return 0; } #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { double arg0; ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.ComponentLua:update"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ComponentLua_update'", nullptr); return 0; } cobj->update(arg0); lua_settop(tolua_S, 1); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ComponentLua:update",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ComponentLua_update'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ComponentLua_create(lua_State* tolua_S) { int argc = 0; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif #if COCOS2D_DEBUG >= 1 if (!tolua_isusertable(tolua_S,1,"cc.ComponentLua",0,&tolua_err)) goto tolua_lerror; #endif argc = lua_gettop(tolua_S) - 1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.ComponentLua:create"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ComponentLua_create'", nullptr); return 0; } cocos2d::ComponentLua* ret = cocos2d::ComponentLua::create(arg0); object_to_luaval<cocos2d::ComponentLua>(tolua_S, "cc.ComponentLua",(cocos2d::ComponentLua*)ret); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d\n ", "cc.ComponentLua:create",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ComponentLua_create'.",&tolua_err); #endif return 0; } int lua_cocos2dx_ComponentLua_constructor(lua_State* tolua_S) { int argc = 0; cocos2d::ComponentLua* cobj = nullptr; bool ok = true; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; #endif argc = lua_gettop(tolua_S)-1; if (argc == 1) { std::string arg0; ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.ComponentLua:ComponentLua"); if(!ok) { tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_ComponentLua_constructor'", nullptr); return 0; } cobj = new cocos2d::ComponentLua(arg0); cobj->autorelease(); int ID = (int)cobj->_ID ; int* luaID = &cobj->_luaID ; toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.ComponentLua"); return 1; } luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.ComponentLua:ComponentLua",argc, 1); return 0; #if COCOS2D_DEBUG >= 1 tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_ComponentLua_constructor'.",&tolua_err); #endif return 0; } static int lua_cocos2dx_ComponentLua_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (ComponentLua)"); return 0; } int lua_register_cocos2dx_ComponentLua(lua_State* tolua_S) { tolua_usertype(tolua_S,"cc.ComponentLua"); tolua_cclass(tolua_S,"ComponentLua","cc.ComponentLua","cc.Component",nullptr); tolua_beginmodule(tolua_S,"ComponentLua"); tolua_function(tolua_S,"new",lua_cocos2dx_ComponentLua_constructor); tolua_function(tolua_S,"getScriptObject",lua_cocos2dx_ComponentLua_getScriptObject); tolua_function(tolua_S,"update",lua_cocos2dx_ComponentLua_update); tolua_function(tolua_S,"create", lua_cocos2dx_ComponentLua_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::ComponentLua).name(); g_luaType[typeName] = "cc.ComponentLua"; g_typeCast["ComponentLua"] = "cc.ComponentLua"; return 1; } TOLUA_API int register_all_cocos2dx(lua_State* tolua_S) { tolua_open(tolua_S); tolua_module(tolua_S,"cc",0); tolua_beginmodule(tolua_S,"cc"); lua_register_cocos2dx_Ref(tolua_S); lua_register_cocos2dx_RenderState(tolua_S); lua_register_cocos2dx_Material(tolua_S); lua_register_cocos2dx_Console(tolua_S); lua_register_cocos2dx_Node(tolua_S); lua_register_cocos2dx_Scene(tolua_S); lua_register_cocos2dx_TransitionScene(tolua_S); lua_register_cocos2dx_TransitionEaseScene(tolua_S); lua_register_cocos2dx_TransitionMoveInL(tolua_S); lua_register_cocos2dx_TransitionMoveInB(tolua_S); lua_register_cocos2dx_AtlasNode(tolua_S); lua_register_cocos2dx_TileMapAtlas(tolua_S); lua_register_cocos2dx_TransitionMoveInT(tolua_S); lua_register_cocos2dx_TMXTilesetInfo(tolua_S); lua_register_cocos2dx_TransitionMoveInR(tolua_S); lua_register_cocos2dx_Action(tolua_S); lua_register_cocos2dx_FiniteTimeAction(tolua_S); lua_register_cocos2dx_ActionInstant(tolua_S); lua_register_cocos2dx_Hide(tolua_S); lua_register_cocos2dx_ParticleSystem(tolua_S); lua_register_cocos2dx_ParticleSystemQuad(tolua_S); lua_register_cocos2dx_ParticleSpiral(tolua_S); lua_register_cocos2dx_GridBase(tolua_S); lua_register_cocos2dx_AnimationCache(tolua_S); lua_register_cocos2dx_ActionInterval(tolua_S); lua_register_cocos2dx_ActionCamera(tolua_S); lua_register_cocos2dx_ProgressFromTo(tolua_S); lua_register_cocos2dx_MoveBy(tolua_S); lua_register_cocos2dx_MoveTo(tolua_S); lua_register_cocos2dx_JumpBy(tolua_S); lua_register_cocos2dx_EventListener(tolua_S); lua_register_cocos2dx_EventListenerKeyboard(tolua_S); #if CC_TARGET_PLATFORM != CC_PLATFORM_WIN32 register_all_cocos2dx_controller(tolua_S); #endif lua_register_cocos2dx_ActionEase(tolua_S); lua_register_cocos2dx_EaseBounceIn(tolua_S); lua_register_cocos2dx_TransitionRotoZoom(tolua_S); lua_register_cocos2dx_Director(tolua_S); lua_register_cocos2dx_Scheduler(tolua_S); lua_register_cocos2dx_EaseElastic(tolua_S); lua_register_cocos2dx_EaseElasticOut(tolua_S); lua_register_cocos2dx_EaseQuadraticActionInOut(tolua_S); lua_register_cocos2dx_EaseBackOut(tolua_S); lua_register_cocos2dx_Texture2D(tolua_S); lua_register_cocos2dx_TransitionSceneOriented(tolua_S); lua_register_cocos2dx_TransitionFlipX(tolua_S); lua_register_cocos2dx_CameraBackgroundBrush(tolua_S); lua_register_cocos2dx_CameraBackgroundDepthBrush(tolua_S); lua_register_cocos2dx_CameraBackgroundColorBrush(tolua_S); lua_register_cocos2dx_GridAction(tolua_S); lua_register_cocos2dx_TiledGrid3DAction(tolua_S); lua_register_cocos2dx_FadeOutTRTiles(tolua_S); lua_register_cocos2dx_FadeOutUpTiles(tolua_S); lua_register_cocos2dx_FadeOutDownTiles(tolua_S); lua_register_cocos2dx_StopGrid(tolua_S); lua_register_cocos2dx_Technique(tolua_S); lua_register_cocos2dx_SkewTo(tolua_S); lua_register_cocos2dx_SkewBy(tolua_S); lua_register_cocos2dx_EaseQuadraticActionOut(tolua_S); lua_register_cocos2dx_TransitionProgress(tolua_S); lua_register_cocos2dx_TransitionProgressVertical(tolua_S); lua_register_cocos2dx_Layer(tolua_S); lua_register_cocos2dx_TMXTiledMap(tolua_S); lua_register_cocos2dx_Grid3DAction(tolua_S); lua_register_cocos2dx_BaseLight(tolua_S); lua_register_cocos2dx_SpotLight(tolua_S); lua_register_cocos2dx_FadeTo(tolua_S); lua_register_cocos2dx_FadeIn(tolua_S); lua_register_cocos2dx_DirectionLight(tolua_S); lua_register_cocos2dx_ShakyTiles3D(tolua_S); lua_register_cocos2dx_EventListenerCustom(tolua_S); lua_register_cocos2dx_FlipX3D(tolua_S); lua_register_cocos2dx_FlipY3D(tolua_S); lua_register_cocos2dx_EaseSineInOut(tolua_S); lua_register_cocos2dx_TransitionFlipAngular(tolua_S); lua_register_cocos2dx_EaseElasticInOut(tolua_S); lua_register_cocos2dx_EaseBounce(tolua_S); lua_register_cocos2dx_Show(tolua_S); lua_register_cocos2dx_FadeOut(tolua_S); lua_register_cocos2dx_CallFunc(tolua_S); lua_register_cocos2dx_Event(tolua_S); lua_register_cocos2dx_EventMouse(tolua_S); lua_register_cocos2dx_GLView(tolua_S); lua_register_cocos2dx_EaseBezierAction(tolua_S); lua_register_cocos2dx_ParticleFireworks(tolua_S); lua_register_cocos2dx_MenuItem(tolua_S); lua_register_cocos2dx_MenuItemSprite(tolua_S); lua_register_cocos2dx_MenuItemImage(tolua_S); lua_register_cocos2dx_AutoPolygon(tolua_S); lua_register_cocos2dx_ParticleSmoke(tolua_S); lua_register_cocos2dx_TransitionZoomFlipAngular(tolua_S); lua_register_cocos2dx_EaseRateAction(tolua_S); lua_register_cocos2dx_EaseIn(tolua_S); lua_register_cocos2dx_EaseExponentialInOut(tolua_S); lua_register_cocos2dx_CardinalSplineTo(tolua_S); lua_register_cocos2dx_CatmullRomTo(tolua_S); lua_register_cocos2dx_Waves3D(tolua_S); lua_register_cocos2dx_EaseExponentialOut(tolua_S); lua_register_cocos2dx_Label(tolua_S); lua_register_cocos2dx_Application(tolua_S); lua_register_cocos2dx_DelayTime(tolua_S); lua_register_cocos2dx_FontAtlas(tolua_S); lua_register_cocos2dx_LabelAtlas(tolua_S); lua_register_cocos2dx_SpriteBatchNode(tolua_S); lua_register_cocos2dx_TMXLayer(tolua_S); lua_register_cocos2dx_AsyncTaskPool(tolua_S); lua_register_cocos2dx_ParticleSnow(tolua_S); lua_register_cocos2dx_EaseElasticIn(tolua_S); lua_register_cocos2dx_EaseCircleActionInOut(tolua_S); lua_register_cocos2dx_TransitionFadeTR(tolua_S); lua_register_cocos2dx_EaseQuarticActionOut(tolua_S); lua_register_cocos2dx_EventAcceleration(tolua_S); lua_register_cocos2dx_EaseCubicActionIn(tolua_S); lua_register_cocos2dx_TextureCache(tolua_S); lua_register_cocos2dx_ActionTween(tolua_S); lua_register_cocos2dx_TransitionFadeDown(tolua_S); lua_register_cocos2dx_ParticleSun(tolua_S); lua_register_cocos2dx_TransitionProgressHorizontal(tolua_S); lua_register_cocos2dx_TMXObjectGroup(tolua_S); lua_register_cocos2dx_ParticleFire(tolua_S); lua_register_cocos2dx_FlipX(tolua_S); lua_register_cocos2dx_FlipY(tolua_S); lua_register_cocos2dx_EventKeyboard(tolua_S); lua_register_cocos2dx_TransitionSplitCols(tolua_S); lua_register_cocos2dx_Timer(tolua_S); lua_register_cocos2dx_RepeatForever(tolua_S); lua_register_cocos2dx_Place(tolua_S); lua_register_cocos2dx_EventListenerAcceleration(tolua_S); lua_register_cocos2dx_TiledGrid3D(tolua_S); lua_register_cocos2dx_EaseBounceOut(tolua_S); lua_register_cocos2dx_RenderTexture(tolua_S); lua_register_cocos2dx_TintBy(tolua_S); lua_register_cocos2dx_TransitionShrinkGrow(tolua_S); lua_register_cocos2dx_ClippingNode(tolua_S); lua_register_cocos2dx_ActionFloat(tolua_S); lua_register_cocos2dx_ParticleFlower(tolua_S); lua_register_cocos2dx_EaseCircleActionIn(tolua_S); lua_register_cocos2dx_Image(tolua_S); lua_register_cocos2dx_LayerMultiplex(tolua_S); lua_register_cocos2dx_Blink(tolua_S); lua_register_cocos2dx_JumpTo(tolua_S); lua_register_cocos2dx_ParticleExplosion(tolua_S); lua_register_cocos2dx_TransitionJumpZoom(tolua_S); lua_register_cocos2dx_Pass(tolua_S); lua_register_cocos2dx_Touch(tolua_S); lua_register_cocos2dx_CardinalSplineBy(tolua_S); lua_register_cocos2dx_CatmullRomBy(tolua_S); lua_register_cocos2dx_NodeGrid(tolua_S); lua_register_cocos2dx_TMXLayerInfo(tolua_S); lua_register_cocos2dx_EaseSineIn(tolua_S); lua_register_cocos2dx_EventListenerMouse(tolua_S); lua_register_cocos2dx_Camera(tolua_S); lua_register_cocos2dx_GLProgram(tolua_S); lua_register_cocos2dx_ParticleGalaxy(tolua_S); lua_register_cocos2dx_Twirl(tolua_S); lua_register_cocos2dx_MenuItemLabel(tolua_S); lua_register_cocos2dx_EaseQuinticActionIn(tolua_S); lua_register_cocos2dx_LayerColor(tolua_S); lua_register_cocos2dx_FadeOutBLTiles(tolua_S); lua_register_cocos2dx_LayerGradient(tolua_S); lua_register_cocos2dx_EventListenerTouchAllAtOnce(tolua_S); lua_register_cocos2dx_GLViewImpl(tolua_S); lua_register_cocos2dx_ToggleVisibility(tolua_S); lua_register_cocos2dx_Repeat(tolua_S); lua_register_cocos2dx_TransitionFlipY(tolua_S); lua_register_cocos2dx_TurnOffTiles(tolua_S); lua_register_cocos2dx_TintTo(tolua_S); lua_register_cocos2dx_EaseBackInOut(tolua_S); lua_register_cocos2dx_TransitionFadeBL(tolua_S); lua_register_cocos2dx_TargetedAction(tolua_S); lua_register_cocos2dx_DrawNode(tolua_S); lua_register_cocos2dx_TransitionTurnOffTiles(tolua_S); lua_register_cocos2dx_RotateTo(tolua_S); lua_register_cocos2dx_TransitionSplitRows(tolua_S); lua_register_cocos2dx_Device(tolua_S); lua_register_cocos2dx_TransitionProgressRadialCCW(tolua_S); lua_register_cocos2dx_ScaleTo(tolua_S); lua_register_cocos2dx_TransitionPageTurn(tolua_S); lua_register_cocos2dx_Properties(tolua_S); lua_register_cocos2dx_BezierBy(tolua_S); lua_register_cocos2dx_BezierTo(tolua_S); lua_register_cocos2dx_ParticleMeteor(tolua_S); lua_register_cocos2dx_SpriteFrame(tolua_S); lua_register_cocos2dx_Liquid(tolua_S); lua_register_cocos2dx_UserDefault(tolua_S); lua_register_cocos2dx_TransitionZoomFlipX(tolua_S); lua_register_cocos2dx_EventFocus(tolua_S); lua_register_cocos2dx_TransitionFade(tolua_S); lua_register_cocos2dx_EaseQuinticActionInOut(tolua_S); lua_register_cocos2dx_SpriteFrameCache(tolua_S); lua_register_cocos2dx_PointLight(tolua_S); lua_register_cocos2dx_TransitionCrossFade(tolua_S); lua_register_cocos2dx_Ripple3D(tolua_S); lua_register_cocos2dx_Lens3D(tolua_S); lua_register_cocos2dx_EventListenerFocus(tolua_S); lua_register_cocos2dx_Spawn(tolua_S); lua_register_cocos2dx_EaseQuarticActionInOut(tolua_S); lua_register_cocos2dx_GLProgramState(tolua_S); lua_register_cocos2dx_PageTurn3D(tolua_S); lua_register_cocos2dx_PolygonInfo(tolua_S); lua_register_cocos2dx_TransitionSlideInL(tolua_S); lua_register_cocos2dx_TransitionSlideInT(tolua_S); lua_register_cocos2dx_Grid3D(tolua_S); lua_register_cocos2dx_EaseCircleActionOut(tolua_S); lua_register_cocos2dx_TransitionProgressInOut(tolua_S); lua_register_cocos2dx_EaseCubicActionInOut(tolua_S); lua_register_cocos2dx_ParticleData(tolua_S); lua_register_cocos2dx_EaseBackIn(tolua_S); lua_register_cocos2dx_SplitRows(tolua_S); lua_register_cocos2dx_Follow(tolua_S); lua_register_cocos2dx_Animate(tolua_S); lua_register_cocos2dx_ShuffleTiles(tolua_S); lua_register_cocos2dx_CameraBackgroundSkyBoxBrush(tolua_S); lua_register_cocos2dx_ProgressTimer(tolua_S); lua_register_cocos2dx_EaseQuarticActionIn(tolua_S); lua_register_cocos2dx_Menu(tolua_S); lua_register_cocos2dx_EaseInOut(tolua_S); lua_register_cocos2dx_TransitionZoomFlipY(tolua_S); lua_register_cocos2dx_ScaleBy(tolua_S); lua_register_cocos2dx_EventTouch(tolua_S); lua_register_cocos2dx_Animation(tolua_S); lua_register_cocos2dx_TMXMapInfo(tolua_S); lua_register_cocos2dx_EaseExponentialIn(tolua_S); lua_register_cocos2dx_ReuseGrid(tolua_S); lua_register_cocos2dx_EaseQuinticActionOut(tolua_S); lua_register_cocos2dx_EventDispatcher(tolua_S); lua_register_cocos2dx_MenuItemAtlasFont(tolua_S); lua_register_cocos2dx_ActionManager(tolua_S); lua_register_cocos2dx_OrbitCamera(tolua_S); lua_register_cocos2dx_ParallaxNode(tolua_S); lua_register_cocos2dx_ClippingRectangleNode(tolua_S); lua_register_cocos2dx_EventCustom(tolua_S); lua_register_cocos2dx_ParticleBatchNode(tolua_S); lua_register_cocos2dx_Component(tolua_S); lua_register_cocos2dx_EaseCubicActionOut(tolua_S); lua_register_cocos2dx_EventListenerTouchOneByOne(tolua_S); lua_register_cocos2dx_ParticleRain(tolua_S); lua_register_cocos2dx_Waves(tolua_S); lua_register_cocos2dx_ComponentLua(tolua_S); lua_register_cocos2dx_MotionStreak3D(tolua_S); lua_register_cocos2dx_EaseOut(tolua_S); lua_register_cocos2dx_MenuItemFont(tolua_S); lua_register_cocos2dx_TransitionFadeUp(tolua_S); lua_register_cocos2dx_EaseSineOut(tolua_S); lua_register_cocos2dx_JumpTiles3D(tolua_S); lua_register_cocos2dx_MenuItemToggle(tolua_S); lua_register_cocos2dx_RemoveSelf(tolua_S); lua_register_cocos2dx_SplitCols(tolua_S); lua_register_cocos2dx_ProtectedNode(tolua_S); lua_register_cocos2dx_MotionStreak(tolua_S); lua_register_cocos2dx_RotateBy(tolua_S); lua_register_cocos2dx_FileUtils(tolua_S); lua_register_cocos2dx_Sprite(tolua_S); lua_register_cocos2dx_ProgressTo(tolua_S); lua_register_cocos2dx_TransitionProgressOutIn(tolua_S); lua_register_cocos2dx_AnimationFrame(tolua_S); lua_register_cocos2dx_Sequence(tolua_S); lua_register_cocos2dx_Shaky3D(tolua_S); lua_register_cocos2dx_TransitionProgressRadialCW(tolua_S); lua_register_cocos2dx_EaseBounceInOut(tolua_S); lua_register_cocos2dx_TransitionSlideInR(tolua_S); lua_register_cocos2dx_AmbientLight(tolua_S); lua_register_cocos2dx_GLProgramCache(tolua_S); lua_register_cocos2dx_EaseQuadraticActionIn(tolua_S); lua_register_cocos2dx_WavesTiles3D(tolua_S); lua_register_cocos2dx_TransitionSlideInB(tolua_S); lua_register_cocos2dx_Speed(tolua_S); lua_register_cocos2dx_ShatteredTiles3D(tolua_S); tolua_endmodule(tolua_S); return 1; }
97473d06039345abb14c14cafd0e395fbecc8740
833dc03ee2fd3e03a4b877435065cd86d7077132
/CSC375/Program Assignments/prog03/Huffman.cpp
5dcb65afbacaf6e6a98a826e9d274281ba789e1c
[]
no_license
popebob/collegefiles
a0c715b946a82c6863ffdbb10b4cbf58e6d57a82
843b186aee826dd6a586c115c0c1a58a234ea399
refs/heads/master
2020-03-09T01:47:34.861814
2018-06-13T15:56:26
2018-06-13T15:56:26
128,524,326
0
0
null
null
null
null
UTF-8
C++
false
false
1,657
cpp
/*********** Cody Adams CSC375-01 prog03 Winter 2009 Dev-C++ 4.9.9.2 Compiled on Windows 7 x64 Build 7000 freq.cpp -- letter frequency source file ***********/ #include <list> #include <iostream> #include "Huffman.h" using namespace std; //*************************void freq()****************************// void frequ( list<Huffman> & huffList, char let) { int makenew = 1; //default value, character does exist yet, make new list<Huffman>::iterator iter = huffList.begin(); for (list<Huffman>::iterator iter = huffList.begin(); iter != huffList.end(); iter++) { if ( let == ( *iter ).letter ) //character is in list, increment freq. { ( *iter ).frequen++; makenew = 0; } } if ( makenew ) //process based on above decision { Huffman temp; temp.letter = let; temp.frequen = 1; huffList.push_front(temp); return; } } //****************************end*********************************// //******************Overloaded << operator************************// ostream & operator << ( ostream & output, const Huffman & huf ) { output << "letter: '" << huf.letter << "', times: " << huf.frequen << " "; return output; // for multiple << operators. } //***************************end**********************************// //***Overloaded < operator to sort by frequency least to greatest*// bool operator < ( const Huffman & lhs, const Huffman & rhs ) { return lhs.frequen < rhs.frequen; //compare .frequen members } //****************************end*********************************//
d522967f9bb61e9b0386d95d00b4d86ac0411033
b6d90e5c2071a910631b33650aff8cfad9c026b3
/src/driversform.cpp
9beb68663c5bd1a4aea02e63b1d3732e6e8ad304
[]
no_license
DatabasesWorks/qtaxi
1b61b822155405c3383a83865bb0170ec63fd75d
7c9cc34aec8aed6488bcffa6ed6dfb35591d5838
refs/heads/master
2020-07-09T08:53:16.670548
2015-03-16T09:52:05
2015-03-16T09:52:05
null
0
0
null
null
null
null
WINDOWS-1252
C++
false
false
4,491
cpp
#include "driversform.h" #include "drivercardform.h" //Constructor DriversForm::DriversForm(QWidget *parent):QDialog(parent){ setupUi(this); connect(findlineEdit, SIGNAL(textChanged(const QString &)), this, SLOT(FindDrivers(QString))); connect(tableView, SIGNAL(activated(const QModelIndex &)), this, SLOT(EditDriver(const QModelIndex &))); connect(addpushButton, SIGNAL(clicked()), this, SLOT(AddDriver())); tableView->setAlternatingRowColors(true); tableView->verticalHeader()->setDefaultSectionSize(25); LoadDrivers(); SetStartSize(); } //Load drivers and shoing in QTableView void DriversForm::LoadDrivers(){ driversmodel=new QSqlQueryModel(this); driversmodel->setQuery("SELECT drivers.fullname, drivers.psn, drivers.born_date, cities.city_name, streets.street_name, drivers.home, cars.car_name_num, drivers.nickname, drivers.phone_home, drivers.phone_mob FROM drivers, cities, streets, cars WHERE drivers.city=cities.key AND drivers.street=streets.key AND drivers.car=cars.key ORDER BY 1;"); driversmodel->setHeaderData(0,Qt::Horizontal,tr("Full name")); driversmodel->setHeaderData(1,Qt::Horizontal,tr("Personal ยน")); driversmodel->setHeaderData(2,Qt::Horizontal,tr("Born")); driversmodel->setHeaderData(3,Qt::Horizontal,tr("City")); driversmodel->setHeaderData(4,Qt::Horizontal,tr("Street")); driversmodel->setHeaderData(5,Qt::Horizontal,tr("Home")); driversmodel->setHeaderData(6,Qt::Horizontal,tr("Car")); driversmodel->setHeaderData(7,Qt::Horizontal,tr("Nick")); driversmodel->setHeaderData(8,Qt::Horizontal,tr("Phone")); driversmodel->setHeaderData(9,Qt::Horizontal,tr("Mobile")); tableView->setModel(driversmodel); driverselection=tableView->selectionModel(); connect(driverselection, SIGNAL(currentChanged(const QModelIndex &, const QModelIndex &)), this, SLOT(SetDriverIndex(const QModelIndex &))); tableView->resizeColumnsToContents(); tableView->resizeRowsToContents(); } //Set start size void DriversForm::SetStartSize(){ QDesktopWidget *dwidget=new QDesktopWidget(); QRect *rect=new QRect(dwidget->screenGeometry(0)); int width=rect->width(); int height=rect->height(); this->setMinimumSize(width-100, height-100); delete dwidget; delete rect; } //Find drivers in database void DriversForm::FindDrivers(QString finddriver){ driversmodel=new QSqlQueryModel(this); driversmodel->setQuery("SELECT drivers.fullname, drivers.psn, drivers.born_date, cities.city_name, streets.street_name, drivers.home, cars.car_name_num, drivers.nickname, drivers.phone_home, drivers.phone_mob FROM drivers, cities, streets, cars WHERE drivers.city=cities.key AND drivers.street=streets.key AND drivers.car=cars.key AND (fullname LIKE '"+finddriver+"%' OR psn LIKE '" +finddriver+"%') ORDER BY 1"); driversmodel->setHeaderData(0,Qt::Horizontal,tr("Full name")); driversmodel->setHeaderData(1,Qt::Horizontal,tr("Personal ยน")); driversmodel->setHeaderData(2,Qt::Horizontal,tr("Born")); driversmodel->setHeaderData(3,Qt::Horizontal,tr("City")); driversmodel->setHeaderData(4,Qt::Horizontal,tr("Street")); driversmodel->setHeaderData(5,Qt::Horizontal,tr("Home")); driversmodel->setHeaderData(6,Qt::Horizontal,tr("Car")); driversmodel->setHeaderData(7,Qt::Horizontal,tr("Nick")); driversmodel->setHeaderData(8,Qt::Horizontal,tr("Phone")); driversmodel->setHeaderData(9,Qt::Horizontal,tr("Mobile")); tableView->setModel(driversmodel); driverselection=tableView->selectionModel(); connect(driverselection, SIGNAL(currentChanged(const QModelIndex &, const QModelIndex &)), this, SLOT(SetDriverIndex(const QModelIndex &))); tableView->resizeColumnsToContents(); tableView->resizeRowsToContents(); } //Method for set index where selection in tableView is changed void DriversForm::SetDriverIndex(const QModelIndex &index){ driverindex=index; } //Method calling DriverCardForm for edit record void DriversForm::EditDriver(const QModelIndex &index){ driverindex=index; DriverCardForm *dlg=new DriverCardForm(true, driversmodel->data(driversmodel->index(index.row(), 1), 0).toInt(), this); if (dlg->exec()) { if (!findlineEdit->text().isEmpty()) { findlineEdit->setText(NULL); } else{ LoadDrivers(); } } delete dlg; } //Method calling DriverCardForm for add new record void DriversForm::AddDriver(){ DriverCardForm *dlg=new DriverCardForm(false, this); if (dlg->exec()) { LoadDrivers(); } delete dlg; }
8d7c41541aa3722969ea1b22d1babd1402816f86
b367fe5f0c2c50846b002b59472c50453e1629bc
/xbox_leak_may_2020/xbox trunk/xbox/private/xdktools/Producer/SegmentDesigner/SegmentAboutBox.cpp
8a8b251f99ed2ab9de7da1a7102ffb9f9eb0f1aa
[]
no_license
sgzwiz/xbox_leak_may_2020
11b441502a659c8da8a1aa199f89f6236dd59325
fd00b4b3b2abb1ea6ef9ac64b755419741a3af00
refs/heads/master
2022-12-23T16:14:54.706755
2020-09-27T18:24:48
2020-09-27T18:24:48
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,701
cpp
// SegmentAboutBox.cpp : implementation file // #include "stdafx.h" #include "SegmentDesignerDLL.h" #include "SegmentAboutBox.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] = __FILE__; #endif ///////////////////////////////////////////////////////////////////////////// // CSegmentAboutBox dialog CSegmentAboutBox::CSegmentAboutBox(CWnd* pParent /*=NULL*/) : CDialog(CSegmentAboutBox::IDD, pParent) { //{{AFX_DATA_INIT(CSegmentAboutBox) // NOTE: the ClassWizard will add member initialization here //}}AFX_DATA_INIT } void CSegmentAboutBox::DoDataExchange(CDataExchange* pDX) { CDialog::DoDataExchange(pDX); //{{AFX_DATA_MAP(CSegmentAboutBox) // NOTE: the ClassWizard will add DDX and DDV calls here //}}AFX_DATA_MAP } BEGIN_MESSAGE_MAP(CSegmentAboutBox, CDialog) //{{AFX_MSG_MAP(CSegmentAboutBox) //}}AFX_MSG_MAP END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// // CSegmentAboutBox message handlers BOOL CSegmentAboutBox::OnInitDialog() { CDialog::OnInitDialog(); // Get version information TCHAR achJazzExeName[MAX_PATH + 1]; TCHAR achFileVersion[MAX_PATH]; if( GetModuleFileName ( theApp.m_hInstance, achJazzExeName, MAX_PATH ) ) { if( theApp.GetFileVersion( achJazzExeName, achFileVersion, MAX_PATH ) ) { CString strFileVersion; AfxFormatString1( strFileVersion, IDS_SEGMENT_VERSION_TEXT, achFileVersion ); SetDlgItemText( IDC_FILE_VERSION, strFileVersion ); } } return TRUE; // return TRUE unless you set the focus to a control // EXCEPTION: OCX Property Pages should return FALSE }
869e74a8c5e507b36a70c76f768106f0e9ec91d0
285618c5be55cfa321842d799615708428d26805
/TB6612FNG.h
dd301706b42c55d7981e75f9b1eaf208056d0947
[ "MIT" ]
permissive
Nandopolis/TB6612FNG
d25cb079aee52c2717ff09143657ad33d4338d50
68d6e4dccc8cad4f8c1c2724ea52d362ec10ee28
refs/heads/master
2021-01-10T15:51:37.426475
2018-07-10T04:04:07
2018-07-10T04:04:07
46,181,090
5
2
null
null
null
null
UTF-8
C++
false
false
2,338
h
/** * @brief An arduino library in order to control the TB6612FNG driver * * @file TB6612FNG.h * @author Nandopolis * @date 2018-07-09 * * this library implements an abstraction to control the TB6612FNG driver * for dc motors. * implements brake and standby control, speed and direction are * extracted from a signed integer from -255 to 255 */ #ifndef TB6612FNG_h #define TB6612FNG_h #include "Arduino.h" /** * @brief TB6612FNG * * A class for a H-bridge drive, TB6612FNG driver supports 2 H-bridges so * it is possible to have two instnces of this class for the same driver */ class TB6612FNG { private: uint8_t pwmPin; /**< the pwm pin number */ uint8_t in1Pin; /**< the first direction pin number */ uint8_t in2Pin; /**< the second direction pin number */ uint8_t stbyPin; /**< the standby pin number */ boolean dir; /**< a boolean to change direction logic */ /** * @brief MoveRaw function * * indicates the pwm and direction at which the load is drived * * @param in1 the first direction pin value * @param in2 the second direction pin value * @param velocity the pwm value, from 0 to 255 (8 bits) */ void MoveRaw(bool in1, bool in2, uint8_t velocity); public: /** * @brief Construct a new TB6612FNG object * * @param pwmA the pwm pin * @param in1A the first pin for direction * @param in2A the second pin for direction * @param stby the standby pin * @param d the direction logic */ TB6612FNG (uint8_t pwmA, uint8_t in1A, uint8_t in2A, uint8_t stby, bool d=1); const bool standby=0; /**< constant for the standby mode */ const bool normal=1; /**< constant for the normal mode */ /** * @brief Setup function * * sets OUTPUT pinMode for every pin */ void Setup(); /** * @brief Move function * * sets the MoveRaw with the direction derived from the sign of velovity * and the pwm as the absolute value of velocity * * @param velocity signed integer from -255 to 255 */ void Move(int16_t velocity); /** * @brief Brake function * * sets in1 and in2 in order to do a fast brake */ void Brake(); /** * @brief Mode function * * sets the stbyPin * * @param mode 0 for standby, 1 for normal mode */ void Mode(bool mode); }; #endif
1c98d376d09a729bf3f660275769ec11902628da
a5768698b8aa648115dd062ebdd4c64211b6b99b
/playerbot/strategy/priest/PriestNonCombatStrategy.cpp
1535ca753aee6c6654ce366c0f1126c06a767766
[]
no_license
apock69/mangosbot-bots
c9c2f788fae688d26ed11313fe9fe736b52fb0f6
11019bbce622c781e9323972d3c9de0f28ee214f
refs/heads/master
2020-04-22T05:15:19.250425
2019-11-11T15:54:04
2019-11-11T15:54:04
170,153,405
4
1
null
2019-02-19T21:44:43
2019-02-11T15:34:15
C++
UTF-8
C++
false
false
2,968
cpp
#include "botpch.h" #include "../../playerbot.h" #include "PriestMultipliers.h" #include "PriestNonCombatStrategy.h" #include "PriestNonCombatStrategyActionNodeFactory.h" using namespace ai; PriestNonCombatStrategy::PriestNonCombatStrategy(PlayerbotAI* ai) : NonCombatStrategy(ai) { actionNodeFactories.Add(new PriestNonCombatStrategyActionNodeFactory()); } void PriestNonCombatStrategy::InitTriggers(std::list<TriggerNode*> &triggers) { NonCombatStrategy::InitTriggers(triggers); triggers.push_back(new TriggerNode( "power word: fortitude", NextAction::array(0, new NextAction("power word: fortitude", 12.0f), NULL))); triggers.push_back(new TriggerNode( "power word: fortitude on party", NextAction::array(0, new NextAction("power word: fortitude on party", 11.0f), NULL))); triggers.push_back(new TriggerNode( "divine spirit", NextAction::array(0, new NextAction("divine spirit", 14.0f), NULL))); triggers.push_back(new TriggerNode( "divine spirit on party", NextAction::array(0, new NextAction("divine spirit on party", 13.0f), NULL))); triggers.push_back(new TriggerNode( "inner fire", NextAction::array(0, new NextAction("inner fire", 10.0f), NULL))); triggers.push_back(new TriggerNode( "critical health", NextAction::array(0, new NextAction("power word: shield", 70.0f), new NextAction("greater heal", 70.0f), NULL))); triggers.push_back(new TriggerNode( "party member critical health", NextAction::array(0, new NextAction("power word: shield on party", 60.0f), new NextAction("greater heal on party", 60.0f), NULL))); triggers.push_back(new TriggerNode( "low health", NextAction::array(0, new NextAction("flash heal", 21.0f), NULL))); triggers.push_back(new TriggerNode( "party member low health", NextAction::array(0, new NextAction("flash heal on party", 20.0f), NULL))); triggers.push_back(new TriggerNode( "medium aoe heal", NextAction::array(0, new NextAction("circle of healing", 27.0f), NULL))); triggers.push_back(new TriggerNode( "party member dead", NextAction::array(0, new NextAction("resurrection", 30.0f), NULL))); triggers.push_back(new TriggerNode( "dispel magic", NextAction::array(0, new NextAction("dispel magic", 41.0f), NULL))); triggers.push_back(new TriggerNode( "dispel magic on party", NextAction::array(0, new NextAction("dispel magic on party", 40.0f), NULL))); triggers.push_back(new TriggerNode( "cure disease", NextAction::array(0, new NextAction("abolish disease", 31.0f), NULL))); triggers.push_back(new TriggerNode( "party member cure disease", NextAction::array(0, new NextAction("abolish disease on party", 30.0f), NULL))); }
afe8636ddfb1bb0c07f81b51a23d24952ab999e4
3f1e0d8ac4800db05ce37d698a026ec085e3304c
/doric-Qt/example/doric/shader/list/DoricListAdapter.cpp
5f393db9b70d1e5e56a70e1d7e3ddc2eed87c059
[ "Apache-2.0" ]
permissive
doric-pub/Doric
e8080e6e8091018e49e39fa35c7d737fc5323aed
ff92ac5b16de12b139f59156e8005dfddb645b41
refs/heads/master
2023-08-16T18:11:51.849633
2023-08-11T12:19:03
2023-08-11T12:36:52
216,160,126
170
25
Apache-2.0
2023-09-14T06:14:23
2019-10-19T06:28:35
JavaScript
UTF-8
C++
false
false
217
cpp
#include "DoricListAdapter.h" #include <QDebug> DoricListAdapter::DoricListAdapter() {} void DoricListAdapter::bind(QVariant rectangle, int position) { qDebug() << "==========" << rectangle << " " << position; }
0f8489071dcd90b00a81b0ca9d2fd320d9220bf0
0bb108c8b4a781ccf507fea4e7a4581b933cd595
/src/xde_shape_property_owner.cpp
3df65d76d046dee4e2dd9a04ed662e8362351286
[ "LicenseRef-scancode-unknown-license-reference", "BSD-2-Clause" ]
permissive
thiagovespa/igscontroler
323d6cdf9a5e1f60c3c68257c732c09073e824c3
4e3996f7b125b83ff455917f8db258965781faed
refs/heads/master
2020-06-23T05:01:36.633149
2019-07-23T23:48:47
2019-07-23T23:48:47
198,523,342
1
0
null
null
null
null
UTF-8
C++
false
false
5,982
cpp
/**************************************************************************** ** Copyright (c) 2019, Fougue Ltd. <http://www.fougue.pro> ** All rights reserved. ** See license at https://github.com/fougue/mayo/blob/master/LICENSE.txt ****************************************************************************/ #include "xde_shape_property_owner.h" #include "string_utils.h" namespace Mayo { XdeShapePropertyOwner::XdeShapePropertyOwner( const XdeDocumentItem *docItem, const TDF_Label &label, XdeDocumentItem::ShapePropertiesOption opt) : m_propertyName(this, tr("Name")), m_propertyShapeType(this, tr("Shape")), m_propertyXdeShapeKind(this, tr("XDE shape")), m_propertyColor(this, tr("Color")), m_propertyReferenceLocation(this, tr("Location")), m_propertyValidationCentroid(this, tr("Centroid")), m_propertyValidationArea(this, tr("Area")), m_propertyValidationVolume(this, tr("Volume")), m_propertyReferredName(this, tr("[Referred]Name")), m_propertyReferredColor(this, tr("[Referred]Color")), m_propertyReferredValidationCentroid(this, tr("[Referred]Centroid")), m_propertyReferredValidationArea(this, tr("[Referred]Area")), m_propertyReferredValidationVolume(this, tr("[Referred]Volume")), m_docItem(docItem), m_label(label) { // Name m_propertyName.setValue(XdeDocumentItem::findLabelName(label)); // Shape type const TopAbs_ShapeEnum shapeType = XCAFDoc_ShapeTool::GetShape(label).ShapeType(); m_propertyShapeType.setValue( QString(StringUtils::rawText(shapeType)).remove("TopAbs_")); // XDE shape kind QStringList listXdeShapeKind; if (XdeDocumentItem::isShapeAssembly(label)) listXdeShapeKind.push_back(tr("Assembly")); if (XdeDocumentItem::isShapeReference(label)) listXdeShapeKind.push_back(tr("Reference")); if (XdeDocumentItem::isShapeComponent(label)) listXdeShapeKind.push_back(tr("Component")); if (XdeDocumentItem::isShapeCompound(label)) listXdeShapeKind.push_back(tr("Compound")); if (XdeDocumentItem::isShapeSimple(label)) listXdeShapeKind.push_back(tr("Simple")); if (XdeDocumentItem::isShapeSub(label)) listXdeShapeKind.push_back(tr("Sub")); m_propertyXdeShapeKind.setValue(listXdeShapeKind.join('+')); // Reference location if (XdeDocumentItem::isShapeReference(label)) { const TopLoc_Location loc = XdeDocumentItem::shapeReferenceLocation(label); m_propertyReferenceLocation.setValue(loc.Transformation()); } else { this->removeProperty(&m_propertyReferenceLocation); } // Color if (docItem->hasShapeColor(label)) m_propertyColor.setValue(docItem->shapeColor(label)); else this->removeProperty(&m_propertyColor); // Validation properties { const XdeDocumentItem::ValidationProperties validProps = XdeDocumentItem::validationProperties(label); m_propertyValidationCentroid.setValue(validProps.centroid); if (!validProps.hasCentroid) this->removeProperty(&m_propertyValidationCentroid); m_propertyValidationArea.setQuantity(validProps.area); if (!validProps.hasArea) this->removeProperty(&m_propertyValidationArea); m_propertyValidationVolume.setQuantity(validProps.volume); if (!validProps.hasVolume) this->removeProperty(&m_propertyValidationVolume); } // Referred entity's properties if (XdeDocumentItem::isShapeReference(label) && opt == XdeDocumentItem::ShapePropertiesOption::MergeReferred) { m_labelReferred = XdeDocumentItem::shapeReferred(label); m_propertyReferredName.setValue(XdeDocumentItem::findLabelName(m_labelReferred)); const XdeDocumentItem::ValidationProperties validProps = XdeDocumentItem::validationProperties(m_labelReferred); m_propertyReferredValidationCentroid.setValue(validProps.centroid); if (!validProps.hasCentroid) this->removeProperty(&m_propertyReferredValidationCentroid); m_propertyReferredValidationArea.setQuantity(validProps.area); if (!validProps.hasArea) this->removeProperty(&m_propertyReferredValidationArea); m_propertyReferredValidationVolume.setQuantity(validProps.volume); if (!validProps.hasVolume) this->removeProperty(&m_propertyReferredValidationVolume); if (docItem->hasShapeColor(m_labelReferred)) m_propertyReferredColor.setValue(docItem->shapeColor(m_labelReferred)); else this->removeProperty(&m_propertyReferredColor); } else { this->removeProperty(&m_propertyReferredName); this->removeProperty(&m_propertyReferredValidationCentroid); this->removeProperty(&m_propertyReferredValidationArea); this->removeProperty(&m_propertyReferredValidationVolume); this->removeProperty(&m_propertyReferredColor); } for (Property* prop : this->properties()) prop->setUserReadOnly(true); m_propertyName.setUserReadOnly(false); m_propertyReferredName.setUserReadOnly(false); } const XdeDocumentItem *XdeShapePropertyOwner::xdeDocumentItem() const { return m_docItem; } const TDF_Label &XdeShapePropertyOwner::label() const { return m_label; } const TDF_Label &XdeShapePropertyOwner::referredLabel() const { return m_labelReferred; } void XdeShapePropertyOwner::onPropertyChanged(Property *prop) { if (prop == &m_propertyName) { XdeDocumentItem::setLabelName(m_label, m_propertyName.value()); emit nameChanged(); } else if (prop == &m_propertyReferredName) { XdeDocumentItem::setLabelName(m_labelReferred, m_propertyReferredName.value()); emit referredNameChanged(); } else { PropertyOwner::onPropertyChanged(prop); } } } // namespace Mayo
32e5069d537c7d9030acfe01fbf25bed45d49125
2e3cad4f0c42ffade3d7897cc2584e249a19310f
/src/core.hpp
d6e28bfab7b41ea8a63845d8a4c8d16ed8624acf
[ "Beerware" ]
permissive
Sweet-Peas/SP3000
52af7e6e1175083f782a5870e85a279f1c4c1594
2ff0a43221867cbc5ff2b575ef30197a6e4f3929
refs/heads/master
2020-05-09T17:07:30.303905
2015-12-24T14:04:34
2015-12-24T14:04:34
12,900,332
0
1
null
2015-12-24T14:04:34
2013-09-17T16:17:53
C++
UTF-8
C++
false
false
3,781
hpp
/************************************************************************** * * This file is part of the ArduinoCC3000 library. * Version 1.0.1b * * Copyright (C) 2013 Chris Magagna - [email protected] * Adapted to Sweet Pea products by Pontus Oldberg - Electronic Sweet Peas * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * Don't sue me if my code blows up your board and burns down your house * * * This file is the main module for the Arduino CC3000 library. * Your program must call CC3000_Init() before any other API calls. * ****************************************************************************/ #ifndef __CORE_HPP_GUARD__ #define __CORE_HPP_GUARD__ #include <Arduino.h> #include "digitalWriteFast.hpp" #include "settings.hpp" /* * The following pin definitions define to what Arduino pin you have connected * each shield pin function to. * * There are some product specific limitations that need to be observed: * * Guidelines for the Sweet Pea WiFi Shield (SP3001) * The Wifi shield is compatible with all Rev3 Arduino boards and have some * configuration options for the interrupt pin as well as the enable and * chip select pin. Please check the data sheet to see what options are * available to you. * * Guidelines for Sweet Pea LeoFi (SP3011) * The LeoFi is a Leonardo compatible CPU board with the CC3000 chip mounted * on it. The LeoFi has a ficed configuration which can not be changed (unless * you bring out your hardware hacking skillz). For the LeoFi The * CC3000_init must be called like this: CC3000_Init (0, 6, 5, 7, 3) * */ extern uint8_t WLAN_CS; // Arduino pin connected to CC3000 WLAN_SPI_CS extern uint8_t WLAN_EN; // Arduino pin connected to CC3000 VBAT_SW_EN extern uint8_t WLAN_IRQ; // Arduino pin connected to CC3000 WLAN_SPI_IRQ extern uint8_t WLAN_IRQ_INTNUM; // The attachInterrupt() number that corresponds // to WLAN_IRQ extern void sp_wifi_init (byte mode, uint8_t WLAN_CS, uint8_t WLAN_EN, uint8_t WLAN_IRQ, uint8_t WLAN_IRQ__NUM); /* * Differently from the original author of these files we decided to include * the digitalFastWrite header file with this library. At least until the * Arduino framework actually supports this feature properly. */ #define irq_read() digitalReadFast(WLAN_IRQ) #define negate_cs() digitalWriteFast(WLAN_CS, HIGH) #define assert_cs() digitalWriteFast(WLAN_CS, LOW) #define MAC_ADDR_LEN 6 #define DISABLE (0) #define ENABLE (1) enum interrupt_state { INT_DISABLED = 0, INT_ENABLED = 1 }; extern enum interrupt_state wlan_int_status; extern byte asyncNotificationWaiting; extern long lastAsyncEvent; extern byte dhcpIPAddress[]; extern volatile unsigned long ulSmartConfigFinished; extern volatile unsigned long ulCC3000Connected; extern volatile unsigned long ulCC3000DHCP; extern volatile unsigned long OkToDoShutDown; extern volatile unsigned long ulCC3000DHCP_configured; extern volatile unsigned char ucStopSmartConfig; /* Function Prototypes */ inline long ReadWlanInterruptPin(void); void WriteWlanEnablePin(unsigned char val); void WlanInterruptEnable(void); void WlanInterruptDisable(void); void CC3000_AsyncCallback(long lEventType, char * data, unsigned char length); char *SendFirmwarePatch(unsigned long *Length); char *SendDriverPatch(unsigned long *Length); char *SendBootloaderPatch(unsigned long *Length); void sp_core_register_event_cb (void (*cb_ptr)(uint32_t EventType, char *data, uint8_t len)); #endif
49083daf87d2711442914fc8b8927b2ad47a2506
14e18690460ab3fbfdaa24190838c4643dce0089
/src/examples/gwQingXie/main.cpp
dda06a2cdccdffe4ed99c16c85a0d0739f74a38b
[]
no_license
MrBigDog/MyProject
e864265b3e299bf6b3b05e3af33cbfcfd7d043ea
a0326b0d5f4c56cd8d269b3efbb61b402d61430c
refs/heads/master
2021-09-10T21:56:22.886786
2018-04-03T01:10:57
2018-04-03T01:10:57
113,719,751
3
0
null
null
null
null
GB18030
C++
false
false
9,686
cpp
#include <osg/Group> #include <osg/PagedLOD> #include <osgDB/ReadFile> #include <osgDB/WriteFile> #include <osgDB/FileUtils> #include <osgDB/FileNameUtils> #include <windows.h> #include "st_tree.h" #include "FileUtils.h" #include "StringUtils.h" class PagedLodVisitor : public osg::NodeVisitor { public: PagedLodVisitor() :osg::NodeVisitor(osg::NodeVisitor::TRAVERSE_ALL_CHILDREN) {} void apply(osg::PagedLOD& pl) { for (unsigned int i = 0; i < pl.getNumFileNames(); ++i) { std::string filename = pl.getFileName(i); if (filename.empty()) continue; _filenames.push_back(filename); } } std::vector<std::string> _filenames; }; void CreatTileTree(st_tree::tree<std::string>::node_type& tree_node, const std::string& tile_path/*, const std::string& tile_name*/) { std::string fullname = tree_node.data();// osgDB::concatPaths(tile_path, tile_name); osg::ref_ptr<osg::Node> node = osgDB::readNodeFile(fullname); if (!node) return; PagedLodVisitor plv; node->accept(plv); if (plv._filenames.empty()) return; for (unsigned int i = 0; i < plv._filenames.size(); ++i) { std::string filename = plv._filenames.at(i); if (filename.empty()) continue; st_tree::tree<std::string>::node_type::iterator it = tree_node.insert(osgDB::concatPaths(tile_path, filename)); CreatTileTree(*it, tile_path); } } class TextureAndImageVisitor : public osg::NodeVisitor { public: TextureAndImageVisitor(const std::string& rootPath) : osg::NodeVisitor() , _outpath(rootPath) { setNodeMaskOverride(~0L); setTraversalMode(TRAVERSE_ALL_CHILDREN); } virtual ~TextureAndImageVisitor() { } public: virtual void apply(osg::Texture& texture) { for (unsigned k = 0; k < texture.getNumImages(); ++k) { osg::Image* image = texture.getImage(k); if (image) apply(*image); } } virtual void apply(osg::Image& image) { std::string imageName = image.getFileName(); std::string sname = osgDB::getSimpleFileName(imageName); image.setFileName(sname); std::string filename = osgDB::concatPaths(_outpath, sname); if (!osgDB::fileExists(filename)) { gwUtil::makeDirectoryForFile(filename); osgDB::writeImageFile(image, filename); } } public: virtual void apply(osg::Node& node) { if (node.getStateSet()) apply(*node.getStateSet()); traverse(node); } virtual void apply(osg::Geode& geode) { if (geode.getStateSet()) apply(*geode.getStateSet()); for (unsigned i = 0; i < geode.getNumDrawables(); ++i) { apply(*geode.getDrawable(i)); //if (geode.getDrawable(i) && geode.getDrawable(i)->getStateSet()) // apply(*geode.getDrawable(i)->getStateSet()); } //traverse(geode); } virtual void apply(osg::Drawable& drawable) { if (drawable.getStateSet()) apply(*drawable.getStateSet()); //traverse(drawable); } virtual void apply(osg::StateSet& stateSet) { osg::StateSet::TextureAttributeList& a = stateSet.getTextureAttributeList(); for (osg::StateSet::TextureAttributeList::iterator i = a.begin(); i != a.end(); ++i) { osg::StateSet::AttributeList& b = *i; for (osg::StateSet::AttributeList::iterator j = b.begin(); j != b.end(); ++j) { osg::StateAttribute* sa = j->second.first.get(); if (sa) { osg::Texture* tex = dynamic_cast<osg::Texture*>(sa); if (tex) { apply(*tex); } } } } } private: std::string _outpath; }; class DirectoryVisitor { private: bool _isonlysm1; public: DirectoryVisitor::DirectoryVisitor(const std::string& inPath, const std::string& outPath, const std::string& ext, int lodLevel, int maxDirNum, bool isonlysm1) : _inPath(inPath) , _outPath(outPath) , _ext(ext) , _isonlysm1(isonlysm1) { if (!gwUtil::startsWith(_ext, ".")) { _ext = "." + _ext; } gwUtil::makeDirectory(_outPath); if (osgDB::fileType(inPath) == osgDB::DIRECTORY) { traverseDirectory(inPath); } } private: void DirectoryVisitor::traverseDirectory(const std::string& path) { if (osgDB::fileType(path) == osgDB::DIRECTORY) { if (!handleDir(path)) return; osgDB::DirectoryContents files = osgDB::getDirectoryContents(path); std::stringstream ss; ss << files.size() - 2; std::string filenumstr = ss.str(); unsigned int fnum = 0; for (osgDB::DirectoryContents::const_iterator f = files.begin(); f != files.end(); ++f) { if (f->compare(".") == 0 || f->compare("..") == 0) continue; fnum++; std::stringstream subss; subss << fnum; std::string inf = "ๆ€ปๅ…ฑ" + filenumstr + "ไธชๆ–‡ไปถๅคน๏ผŒๆญฃๅœจๅค„็†็ฌฌ" + subss.str() + "ไธช......"; std::cout << inf << std::endl; std::string filepath = osgDB::concatPaths(path, *f); std::string fullname = osgDB::concatPaths(filepath, *f + ".osgb"); //ๅ†™ๅ‡บๆœ€็ฒ—็ณ™็บงๅˆซsm1 if (_isSm1) { std::string sm1path = osgDB::concatPaths(_outPath, "sm1"); writeToLocal(fullname, sm1path, _ext); } if (_isSm || _isCm) { st_tree::tree<std::string> tree; tree.insert(fullname); CreatTileTree(tree.root(), filepath); //้ๅކๆ ‘๏ผŒๅ†™ๅ‡บ็›ธๅบ”ๆจกๅž‹; if (_ext == ".3ds") { osg::ref_ptr<osg::Group> cmRoot = new osg::Group; osg::ref_ptr<osg::Group> smRoot = new osg::Group; for (st_tree::tree<std::string>::df_pre_iterator j(tree.df_pre_begin()); j != tree.df_pre_end(); ++j) { if (j->depth() == 3 && _isSm) { //็ฌฌไบŒ็บงsm; osg::ref_ptr<osg::Node> node = osgDB::readNodeFile(j->data()); if (node.valid()) smRoot->addChild(node); } else if (j->depth() == 1 && _isCm) { //ๅ†™ๅ‡บๅˆฐๆœ€้ซ˜็บงๅˆซcm; osg::ref_ptr<osg::Node> node = osgDB::readNodeFile(j->data()); if (node.valid()) cmRoot->addChild(node); } } if (_isSm) { std::string smrelpath = osgDB::concatPaths("sm", *f); std::string smpath = osgDB::concatPaths(_outPath, smrelpath); //std::string smname = osgDB::concatPaths(smpath, *f + _ext); writeToLocal(smRoot, smpath, *f, _ext); } if (_isCm) { std::string cmrelpath = osgDB::concatPaths("cm", *f); std::string cmpath = osgDB::concatPaths(_outPath, cmrelpath); //std::string cmname = osgDB::concatPaths(cmpath, *f + _ext); writeToLocal(cmRoot, cmpath, *f, _ext); } } else if (_ext == ".obj") { std::string smpath = osgDB::concatPaths(_outPath, "sm"); std::string cmpath = osgDB::concatPaths(_outPath, "cm"); for (st_tree::tree<std::string>::df_pre_iterator j(tree.df_pre_begin()); j != tree.df_pre_end(); ++j) { if (j->depth() == 3 && _isSm) { //็ฌฌไบŒ็บงsm; writeToLocal(j->data(), smpath, _ext); } else if (j->depth() == 1 && _isCm) { //ๅ†™ๅ‡บๅˆฐๆœ€้ซ˜็บงๅˆซcm; writeToLocal(j->data(), cmpath, _ext); } } } tree.clear(); } } } } bool handleDir(const std::string& path) { return true; } private: void writeToLocal(osg::Node* node, const std::string& path, const std::string& name, const std::string& ext) { std::string filename = osgDB::concatPaths(path, name + ext); if (!osgDB::fileExists(filename)) { gwUtil::makeDirectoryForFile(filename); } osg::ref_ptr<osgDB::Options> opts = 0L; if (ext == "3ds" || ext == ".3ds") { opts = new osgDB::Options("extended3dsFilePaths"); } osgDB::writeNodeFile(*node, filename, opts); if (ext == ".obj" || ext == "obj") { TextureAndImageVisitor tv(path); node->accept(tv); } } void writeToLocal(const std::string& filename, const std::string& outpath, const std::string& ext) { osg::ref_ptr<osg::Node> node = osgDB::readNodeFile(filename); if (!node.valid()) return; std::string stripname = osgDB::getStrippedName(filename); std::vector<std::string> out_elements; osgDB::getPathElements(filename, out_elements); std::string newPath = osgDB::concatPaths(outpath, out_elements[out_elements.size() - 2]); std::string newName = osgDB::concatPaths(newPath, stripname + ext); if (!osgDB::fileExists(newName)) { gwUtil::makeDirectoryForFile(newName); } osg::ref_ptr<osgDB::Options> opts = 0L; if (ext == "3ds" || ext == ".3ds") { opts = new osgDB::Options("extended3dsFilePaths"); } if (ext == ".obj" || ext == "obj") { TextureAndImageVisitor tv(newPath); node->accept(tv); } osgDB::writeNodeFile(*node, newName, opts); } private: std::string _inPath; std::string _outPath; std::string _ext; bool _isSm1; bool _isSm; bool _isCm; //bool _isCombine; }; //"E:/DATA/qxmx/qxmx/osgb,E:/DATA/qxmx/qxmx/test,3ds,23" //"H:/Tile_1321013303332233120/osgb,H:/Tile_1321013303332233120/test, 3ds, 23" //"E:/DATA/qxmx/qxmx/Tile_132102312010120213/Tile_132102312010120213/,E:/DATA/qxmx/qxmx/Tile_132102312010120213/test,3ds,18,1" int main(int argc, char ** argv) { osg::ArgumentParser arguments(&argc, argv); std::string parasStr;// = argv[3]; arguments.read("-f", parasStr); gwUtil::StringVector paras; gwUtil::StringTokenizer stk(parasStr, paras, ","); if (paras.size() < 4) { MessageBox(NULL, "ๅ‚ๆ•ฐ็š„ๆ•ฐ้‡ไธๅฏน, ่ฏทๆฃ€ๆŸฅ่พ“ๅ…ฅ็š„ๅ‚ๆ•ฐ", "้”™่ฏฏ", 1); return 0; } std::string inPath = paras[0]; std::string outPath = paras[1]; std::string outExt = osgDB::convertToLowerCase(paras[2]); std::string only = paras[5]; int isonlysm1 = atoi(only.c_str()); bool isonly = isonlysm1 ? true : false; int lodLevel = 0; int maxDirNum = 1; DirectoryVisitor dv(inPath, outPath, outExt, lodLevel, maxDirNum, isonly); //DirectoryVisitor dv("E:/DATA/qstt", "E:/DATA/qxmx/qxmx/test111/ttt/tt", "3ds", 22, 1); //system("pause"); return 0; }
42a58036c94fb09f6eaf4edc6b5684e7a0911744
67f9f7bfb2b17743a02fc91bcd64c9b30412d372
/include/spiderdb/core/file.h
5124024ad73c8fdc3e02cee5df50ea193eda3d3e
[]
no_license
chungphb/spiderdb
6f5913eaa920133f6ebfe5a798d1755476681d89
37367917ab06a1a2a0789a0418959ea59e9c15d6
refs/heads/master
2023-06-10T21:16:01.568259
2021-07-06T14:54:17
2021-07-06T17:30:58
358,644,047
8
0
null
null
null
null
UTF-8
C++
false
false
2,849
h
// // Created by chungphb on 27/4/21. // #pragma once #include <spiderdb/core/page.h> #include <spiderdb/core/config.h> #include <seastar/core/file.hh> #include <seastar/core/semaphore.hh> #include <chrono> namespace spiderdb { struct file_impl; struct file; struct file_header { public: seastar::future<> flush(seastar::file file); seastar::future<> load(seastar::file file); virtual seastar::future<> write(seastar::temporary_buffer<char> buffer); virtual seastar::future<> read(seastar::temporary_buffer<char> buffer); static constexpr size_t size() noexcept { return sizeof(_page_size) + sizeof(_page_count) + sizeof(_first_free_page) + sizeof(_last_free_page); } friend file_impl; protected: uint16_t _size = 0; uint32_t _page_size = 0; uint64_t _page_count = 0; page_id _first_free_page = null_page; page_id _last_free_page = null_page; bool _dirty = true; }; struct file_impl : seastar::weakly_referencable<file_impl> { public: file_impl() = delete; file_impl(std::string name, spiderdb_config config); ~file_impl(); virtual seastar::future<> open(); virtual seastar::future<> flush(); virtual seastar::future<> close(); seastar::future<page_id> write(string data); seastar::future<> write(page_id id, string data); seastar::future<string> read(page_id id); seastar::future<> unlink_pages_from(page_id id); seastar::future<> write(page first, string data); seastar::future<string> read(page first); seastar::future<> unlink_pages_from(page first); virtual void log() const noexcept; virtual bool is_open() const noexcept; friend file; protected: virtual seastar::shared_ptr<file_header> get_new_file_header(); virtual seastar::shared_ptr<page_header> get_new_page_header(); seastar::future<page> get_free_page(); seastar::future<page> get_or_create_page(page_id id); public: spiderdb_config _config; protected: seastar::shared_ptr<file_header> _file_header = nullptr; private: const std::string _name; seastar::file _file; std::unordered_map<page_id, seastar::weak_ptr<page_impl>> _pages; seastar::semaphore _file_lock{1}; seastar::semaphore _get_free_page_lock{1}; }; struct file { public: file() = delete; file(std::string name, spiderdb_config config = spiderdb_config()); ~file() = default; file(const file& other); file(file&& other) noexcept; file& operator=(const file& other); file& operator=(file&& other) noexcept; const spiderdb_config& get_config() const; seastar::future<> open() const; seastar::future<> close() const; seastar::future<page_id> write(string data) const; seastar::future<string> read(page_id id) const; void log() const; private: seastar::lw_shared_ptr<file_impl> _impl; }; }
6a63f4814db8bb6a127810b20f176bc6823074f7
600df3590cce1fe49b9a96e9ca5b5242884a2a70
/chromecast/app/android/cast_jni_loader.cc
03211a89a09125bf19ab9b31423d0e9dacdb2c5d
[ "BSD-3-Clause" ]
permissive
metux/chromium-suckless
efd087ba4f4070a6caac5bfbfb0f7a4e2f3c438a
72a05af97787001756bae2511b7985e61498c965
refs/heads/orig
2022-12-04T23:53:58.681218
2017-04-30T10:59:06
2017-04-30T23:35:58
89,884,931
5
3
BSD-3-Clause
2022-11-23T20:52:53
2017-05-01T00:09:08
null
UTF-8
C++
false
false
1,642
cc
// Copyright 2014 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "base/android/jni_android.h" #include "base/bind.h" #include "chromecast/android/cast_jni_registrar.h" #include "chromecast/android/platform_jni_loader.h" #include "chromecast/app/cast_main_delegate.h" #include "content/public/app/content_jni_onload.h" #include "content/public/app/content_main.h" #include "content/public/browser/android/compositor.h" namespace { bool RegisterJNI(JNIEnv* env) { // To be called only from the UI thread. If loading the library is done on // a separate thread, this should be moved elsewhere. if (!chromecast::android::RegisterJni(env)) return false; // Allow platform-specific implementations to perform more JNI registration. if (!chromecast::android::PlatformRegisterJni(env)) return false; return true; } bool Init() { content::Compositor::Initialize(); content::SetContentMainDelegate(new chromecast::shell::CastMainDelegate); return true; } } // namespace // This is called by the VM when the shared library is first loaded. JNI_EXPORT jint JNI_OnLoad(JavaVM* vm, void* reserved) { std::vector<base::android::RegisterCallback> register_callbacks; register_callbacks.push_back(base::Bind(&RegisterJNI)); std::vector<base::android::InitCallback> init_callbacks; init_callbacks.push_back(base::Bind(&Init)); if (!content::android::OnJNIOnLoadRegisterJNI(vm, register_callbacks) || !content::android::OnJNIOnLoadInit(init_callbacks)) { return -1; } return JNI_VERSION_1_4; }
b441d6a1bdd38847687f8db87739699a3d6be659
63ad414665fe9cdbdad02798df0e8763da07eb28
/tigre.h
430d4e225c83456246553e6a5ae363700199136b
[]
no_license
KoxyZ24/Zoo
dd7a6e91a77da3e01bc356488d83b02a838fe08b
ed484a7d5f4c495ee6db275cafd038a137994252
refs/heads/master
2023-06-05T20:54:45.848688
2021-06-20T18:27:46
2021-06-20T18:27:46
374,992,662
0
0
null
null
null
null
UTF-8
C++
false
false
218
h
#ifndef TIGRE_H #define TIGRE_H #include "ianimal.h" #include <string> using namespace std; class Tigre:public IAnimal { public: Tigre(); Tigre(string name); virtual void fire(); }; #endif // TIGRE_H
9d55d6878d7ed519f3d53f6c7a3a699074db27df
fb160f3b4909891de3ff1e0f714ffd5749949126
/c++/3/main.cpp
f3fcf08e619eac7eb181d97aa44b5a76d068909e
[]
no_license
Jonathan2251/ex
92f026a3c4d4f2d711b6a5cc0882042c40d5bfd1
db43bc7921f897e8e79136a694dcc9d8f56ede80
refs/heads/master
2023-02-08T00:48:00.324415
2023-02-04T01:20:43
2023-02-04T01:20:43
226,456,202
2
0
null
null
null
null
UTF-8
C++
false
false
333
cpp
#include <iostream> namespace N1 { class DataNode { public: int x; int y; }; } // namespace class A { public: int id; }; namespace N1 { class B { public: N1::DataNode dn; A a; }; } // namespace using namespace std; int main() { N1::B b; b.a.id = 1; std::cout << "id: " << b.a.id << std::endl; return 0; }
08cc0c5534107857a4938f2c81eb1a0ac2b7cf8b
d0b4d85604c1e447712bafeba22ac33265c0f03c
/์ œ1ํšŒ ์ฒœํ•˜์ œ์ผ ์ฝ”๋”ฉ๋Œ€ํšŒ ๋ณธ์„ /14658.cpp
097e6be70a5a06a711505ac4abd4ec9be112762c
[]
no_license
EunsungKoh/BOJproblem
24f2594705ce91016b70676b838034946652dd10
70098df80c262738c25018fcc9396be9b8dbd151
refs/heads/master
2020-03-23T17:36:41.582630
2018-08-30T12:23:39
2018-08-30T12:23:39
141,867,242
1
0
null
null
null
null
UTF-8
C++
false
false
814
cpp
//ํ•˜๋Š˜์—์„œ ๋ณ„๋˜ฅ๋ณ„์ด ๋น—๋ฐœ์นœ๋‹ค (์‹œ๊ฐ„์ดˆ๊ณผ) #include <cstdio> #include <iostream> #include <vector> #include <utility> #include <map> using namespace std; int N,M,L,K; int tempX,tempY,now; int big=0; vector< pair<int,int> > star; map < pair<int, int> , int> total; int main(){ scanf("%d %d %d %d",&N,&M,&L,&K); star.resize(K); for (auto it=star.begin(); it!= star.end();it++){ scanf("%d %d",&tempX,&tempY); *it=(make_pair(tempX,tempY)); for(int i = tempX-L;i<=tempX;i++){ if (i<=0) i=1; if (i>N) break; for (int j=tempY-L; j<=tempY;j++){ if (j<=0) j=1; if (j>M) break; now= total.find(make_pair(i,j))->second+1; total[(make_pair(i,j))] = now; if (now>big) big = now; } } } printf("%d",K-big); return 0 ; }
5963fa636fa690e749d2f2a33689c1f16f6958bf
851bd0ee496284670120b49885949c2106ff7551
/133A_HQ9+.cpp
d406b3ab7808a97b7c7efb377db920dbb661a75e
[]
no_license
PlamenKoynov/CPP
fb9e60609139186eaa4f354686e51c76896c9304
3eedaf152354aaf1b13ec6296a371997bad20158
refs/heads/master
2021-01-22T04:33:46.525060
2015-04-30T07:51:00
2015-04-30T07:51:00
34,841,543
0
0
null
null
null
null
UTF-8
C++
false
false
615
cpp
#include<iostream> #include<string> using namespace std; int main() { string line; cin>>line; int size = line.length() - 1, current = 0, ascii; bool flag = false; while(current <= size && flag == false) { ascii = int(line[current]); if(ascii == 57 || ascii == 72 || ascii == 81) { flag = true; cout<<"YES"<<endl; return 0; } current++; } if(flag == false) cout<<"NO"<<endl; system("pause"); return 0; }
894c6dc5348c03b03846e19e28b3f87a9bb30495
6296dea55e3fb4e04a2c75d0ccad52a13dc8a286
/RegLATAM2016/e.cc
fab6fdffaf145a688bd028a7f70a6d870bc0f1ae
[]
no_license
andres-rad/Programming-Challenges
08a5c67c20edd120885ef18a73a30429345decef
904f27be76557a1d6077adf33e6b0f86af52d192
refs/heads/master
2021-01-18T11:26:22.163338
2019-04-17T16:35:47
2019-04-17T16:35:47
58,432,729
0
0
null
null
null
null
UTF-8
C++
false
false
472
cc
#include <bits/stdc++.h> #define forsn(i,s,n) for(int i=s; i<n; i++) #define forn(i,n) forsn(i,0,n) #define dforsn(i,s,n) for(int i=n-1; i>=s; i--) #define dforn(i,n) dforsn(i,0,n) #define pb push_back #define snd second #define fst first using namespace std; struct RMQ{ #define LVL 10 tipo vec[LVL][1<<(LVL+1)]; tipo &operator[](int p){return vec[0][p];} tipo get(int i, int j){ int p=31-__builtin_clz(j-i); return operacion } }; int main() { return 0; }
ea1d3ef33b491086d8483ab5c41e0ea190e1564e
7fb9ef104301ac7c807daf05dd4aabf1b9c4ccc4
/src/roboperation/src/cartesian_controller_copy.cpp
1390e2a4bb9c956abdf912f4b24bb48c2213c825
[]
no_license
AdrianMalaran/Roboperation
0bacb9246c0810c50d5dcbb191f6aa185503eeda
9a26154980b2579a4f4a2b889e1e26d1b258a071
refs/heads/master
2020-12-21T21:04:15.922578
2020-03-12T20:00:55
2020-03-12T20:00:55
236,560,321
0
0
null
null
null
null
UTF-8
C++
false
false
10,948
cpp
// Copyright (c) 2017 Franka Emika GmbH // Use of this source code is governed by the Apache-2.0 license, see LICENSE #include <roboperation/cartesian_controller_copy.h> #include <cmath> #include <memory> #include <controller_interface/controller_base.h> #include <franka/robot_state.h> #include <pluginlib/class_list_macros.h> #include <ros/ros.h> #include "pseudo_inversion.h" namespace franka_example_controllers { bool CartesianImpedanceExampleController::init(hardware_interface::RobotHW* robot_hw, ros::NodeHandle& node_handle) { std::vector<double> cartesian_stiffness_vector; std::vector<double> cartesian_damping_vector; sub_equilibrium_pose_ = node_handle.subscribe( "/equilibrium_pose", 20, &CartesianImpedanceExampleController::equilibriumPoseCallback, this, ros::TransportHints().reliable().tcpNoDelay()); std::string arm_id; if (!node_handle.getParam("arm_id", arm_id)) { ROS_ERROR_STREAM("CartesianImpedanceExampleController: Could not read parameter arm_id"); return false; } std::vector<std::string> joint_names; if (!node_handle.getParam("joint_names", joint_names) || joint_names.size() != 7) { ROS_ERROR( "CartesianImpedanceExampleController: Invalid or no joint_names parameters provided, " "aborting controller init!"); return false; } auto* model_interface = robot_hw->get<franka_hw::FrankaModelInterface>(); if (model_interface == nullptr) { ROS_ERROR_STREAM( "CartesianImpedanceExampleController: Error getting model interface from hardware"); return false; } try { model_handle_ = std::make_unique<franka_hw::FrankaModelHandle>( model_interface->getHandle(arm_id + "_model")); } catch (hardware_interface::HardwareInterfaceException& ex) { ROS_ERROR_STREAM( "CartesianImpedanceExampleController: Exception getting model handle from interface: " << ex.what()); return false; } auto* state_interface = robot_hw->get<franka_hw::FrankaStateInterface>(); if (state_interface == nullptr) { ROS_ERROR_STREAM( "CartesianImpedanceExampleController: Error getting state interface from hardware"); return false; } try { state_handle_ = std::make_unique<franka_hw::FrankaStateHandle>( state_interface->getHandle(arm_id + "_robot")); } catch (hardware_interface::HardwareInterfaceException& ex) { ROS_ERROR_STREAM( "CartesianImpedanceExampleController: Exception getting state handle from interface: " << ex.what()); return false; } auto* effort_joint_interface = robot_hw->get<hardware_interface::EffortJointInterface>(); if (effort_joint_interface == nullptr) { ROS_ERROR_STREAM( "CartesianImpedanceExampleController: Error getting effort joint interface from hardware"); return false; } for (size_t i = 0; i < 7; ++i) { try { joint_handles_.push_back(effort_joint_interface->getHandle(joint_names[i])); } catch (const hardware_interface::HardwareInterfaceException& ex) { ROS_ERROR_STREAM( "CartesianImpedanceExampleController: Exception getting joint handles: " << ex.what()); return false; } } dynamic_reconfigure_compliance_param_node_ = ros::NodeHandle("dynamic_reconfigure_compliance_param_node"); dynamic_server_compliance_param_ = std::make_unique< dynamic_reconfigure::Server<franka_example_controllers::compliance_paramConfig>>( dynamic_reconfigure_compliance_param_node_); dynamic_server_compliance_param_->setCallback( boost::bind(&CartesianImpedanceExampleController::complianceParamCallback, this, _1, _2)); position_d_.setZero(); orientation_d_.coeffs() << 0.0, 0.0, 0.0, 1.0; position_d_target_.setZero(); orientation_d_target_.coeffs() << 0.0, 0.0, 0.0, 1.0; cartesian_stiffness_.setZero(); cartesian_damping_.setZero(); return true; } void CartesianImpedanceExampleController::starting(const ros::Time& /*time*/) { // compute initial velocity with jacobian and set x_attractor and q_d_nullspace // to initial configuration franka::RobotState initial_state = state_handle_->getRobotState(); // get jacobian std::array<double, 42> jacobian_array = model_handle_->getZeroJacobian(franka::Frame::kEndEffector); // convert to eigen Eigen::Map<Eigen::Matrix<double, 6, 7>> jacobian(jacobian_array.data()); Eigen::Map<Eigen::Matrix<double, 7, 1>> dq_initial(initial_state.dq.data()); Eigen::Map<Eigen::Matrix<double, 7, 1>> q_initial(initial_state.q.data()); Eigen::Affine3d initial_transform(Eigen::Matrix4d::Map(initial_state.O_T_EE.data())); // set equilibrium point to current state position_d_ = initial_transform.translation(); orientation_d_ = Eigen::Quaterniond(initial_transform.linear()); position_d_target_ = initial_transform.translation(); orientation_d_target_ = Eigen::Quaterniond(initial_transform.linear()); // set nullspace equilibrium configuration to initial q q_d_nullspace_ = q_initial; } void CartesianImpedanceExampleController::update(const ros::Time& /*time*/, const ros::Duration& /*period*/) { // get state variables franka::RobotState robot_state = state_handle_->getRobotState(); std::array<double, 7> coriolis_array = model_handle_->getCoriolis(); std::array<double, 42> jacobian_array = model_handle_->getZeroJacobian(franka::Frame::kEndEffector); // convert to Eigen Eigen::Map<Eigen::Matrix<double, 7, 1>> coriolis(coriolis_array.data()); Eigen::Map<Eigen::Matrix<double, 6, 7>> jacobian(jacobian_array.data()); Eigen::Map<Eigen::Matrix<double, 7, 1>> q(robot_state.q.data()); Eigen::Map<Eigen::Matrix<double, 7, 1>> dq(robot_state.dq.data()); Eigen::Map<Eigen::Matrix<double, 7, 1>> tau_J_d( // NOLINT (readability-identifier-naming) robot_state.tau_J_d.data()); Eigen::Affine3d transform(Eigen::Matrix4d::Map(robot_state.O_T_EE.data())); Eigen::Vector3d position(transform.translation()); Eigen::Quaterniond orientation(transform.linear()); // compute error to desired pose // position error Eigen::Matrix<double, 6, 1> error; error.head(3) << position - position_d_; // orientation error if (orientation_d_.coeffs().dot(orientation.coeffs()) < 0.0) { orientation.coeffs() << -orientation.coeffs(); } // "difference" quaternion Eigen::Quaterniond error_quaternion(orientation * orientation_d_.inverse()); // convert to axis angle Eigen::AngleAxisd error_quaternion_angle_axis(error_quaternion); // compute "orientation error" error.tail(3) << error_quaternion_angle_axis.axis() * error_quaternion_angle_axis.angle(); // compute control // allocate variables Eigen::VectorXd tau_task(7), tau_nullspace(7), tau_d(7); // pseudoinverse for nullspace handling // kinematic pseuoinverse Eigen::MatrixXd jacobian_transpose_pinv; pseudoInverse(jacobian.transpose(), jacobian_transpose_pinv); // Cartesian PD control with damping ratio = 1 tau_task << jacobian.transpose() * (-cartesian_stiffness_ * error - cartesian_damping_ * (jacobian * dq)); // nullspace PD control with damping ratio = 1 tau_nullspace << (Eigen::MatrixXd::Identity(7, 7) - jacobian.transpose() * jacobian_transpose_pinv) * (nullspace_stiffness_ * (q_d_nullspace_ - q) - (2.0 * sqrt(nullspace_stiffness_)) * dq); // Desired torque tau_d << tau_task + tau_nullspace + coriolis; // Saturate torque rate to avoid discontinuities tau_d << saturateTorqueRate(tau_d, tau_J_d); for (size_t i = 0; i < 7; ++i) { joint_handles_[i].setCommand(tau_d(i)); } // update parameters changed online either through dynamic reconfigure or through the interactive // target by filtering cartesian_stiffness_ = filter_params_ * cartesian_stiffness_target_ + (1.0 - filter_params_) * cartesian_stiffness_; cartesian_damping_ = filter_params_ * cartesian_damping_target_ + (1.0 - filter_params_) * cartesian_damping_; nullspace_stiffness_ = filter_params_ * nullspace_stiffness_target_ + (1.0 - filter_params_) * nullspace_stiffness_; position_d_ = filter_params_ * position_d_target_ + (1.0 - filter_params_) * position_d_; Eigen::AngleAxisd aa_orientation_d(orientation_d_); Eigen::AngleAxisd aa_orientation_d_target(orientation_d_target_); aa_orientation_d.axis() = filter_params_ * aa_orientation_d_target.axis() + (1.0 - filter_params_) * aa_orientation_d.axis(); aa_orientation_d.angle() = filter_params_ * aa_orientation_d_target.angle() + (1.0 - filter_params_) * aa_orientation_d.angle(); orientation_d_ = Eigen::Quaterniond(aa_orientation_d); } Eigen::Matrix<double, 7, 1> CartesianImpedanceExampleController::saturateTorqueRate( const Eigen::Matrix<double, 7, 1>& tau_d_calculated, const Eigen::Matrix<double, 7, 1>& tau_J_d) { // NOLINT (readability-identifier-naming) Eigen::Matrix<double, 7, 1> tau_d_saturated{}; for (size_t i = 0; i < 7; i++) { double difference = tau_d_calculated[i] - tau_J_d[i]; tau_d_saturated[i] = tau_J_d[i] + std::max(std::min(difference, delta_tau_max_), -delta_tau_max_); } return tau_d_saturated; } void CartesianImpedanceExampleController::complianceParamCallback( franka_example_controllers::compliance_paramConfig& config, uint32_t /*level*/) { cartesian_stiffness_target_.setIdentity(); cartesian_stiffness_target_.topLeftCorner(3, 3) << config.translational_stiffness * Eigen::Matrix3d::Identity(); cartesian_stiffness_target_.bottomRightCorner(3, 3) << config.rotational_stiffness * Eigen::Matrix3d::Identity(); cartesian_damping_target_.setIdentity(); // Damping ratio = 1 cartesian_damping_target_.topLeftCorner(3, 3) << 2.0 * sqrt(config.translational_stiffness) * Eigen::Matrix3d::Identity(); cartesian_damping_target_.bottomRightCorner(3, 3) << 2.0 * sqrt(config.rotational_stiffness) * Eigen::Matrix3d::Identity(); nullspace_stiffness_target_ = config.nullspace_stiffness; } void CartesianImpedanceExampleController::equilibriumPoseCallback( const geometry_msgs::PoseStampedConstPtr& msg) { position_d_target_ << msg->pose.position.x, msg->pose.position.y, msg->pose.position.z; Eigen::Quaterniond last_orientation_d_target(orientation_d_target_); orientation_d_target_.coeffs() << msg->pose.orientation.x, msg->pose.orientation.y, msg->pose.orientation.z, msg->pose.orientation.w; if (last_orientation_d_target.coeffs().dot(orientation_d_target_.coeffs()) < 0.0) { orientation_d_target_.coeffs() << -orientation_d_target_.coeffs(); } } } // namespace franka_example_controllers PLUGINLIB_EXPORT_CLASS(franka_example_controllers::CartesianImpedanceExampleController, controller_interface::ControllerBase)
d706fe13972c603aa75b7905add1725ef0559c1a
29a48eef73d41b00260007c7260aed075c0983cd
/lib/util/string/utils.h
9c6be908945e1670434433344f40abcbbdd5cd97
[ "MIT" ]
permissive
koloshmet/koloshmet_lib
02bc79be130f34f53af569d04b1416528b8fadfe
5b0e447e33ecb4880a19d721d0c7058db0b197a0
refs/heads/master
2022-12-10T14:18:46.863594
2020-09-12T17:33:38
2020-09-12T17:33:38
202,592,920
0
0
null
null
null
null
UTF-8
C++
false
false
1,545
h
#pragma once #include <util/container/slice.h> #include <charconv> #include <string> #include <string_view> std::string ToLower(std::string_view str); std::string ToUpper(std::string_view str); template <typename T> std::string ToString(const T& t) { if constexpr (std::is_integral_v<T> || std::is_floating_point_v<T>) { return std::to_string(t); } else { return static_cast<std::string>(t); } } template <typename T, typename... TParams> T FromString(std::string_view str, TParams&&... param) { if constexpr (std::is_integral_v<T>) { T res{}; std::from_chars(str.data(), str.data() + str.size(), res, std::forward<TParams>(param)...); return res; } else if constexpr (std::is_floating_point_v<T>) { if constexpr (std::is_same_v<T, float>) { return std::stof(std::string{str}); } else if constexpr (std::is_same_v<T, double>) { return std::stod(std::string{str}); } else { return std::stold(std::string{str}); } } else { return T(str); } } template <> struct TSlicer<std::string_view> { template <typename TIter> std::string_view operator()( TIter begin, TIter end, std::string_view sequence) const { auto first = std::distance(sequence.begin(), begin); auto len = std::distance(begin, end); return sequence.substr(first, len); } }; TSlice<std::string_view, std::string_view> Split(std::string_view seq, std::string_view delim);
a6398ff8a587564af5b5f093429cf0cab3da826c
574b01ad81acc8dc4b072b8d175623f1440797cc
/examples/face/face_detect.cpp
a17cbf60f175e8fa50c281be50c27bb0fd430ed2
[ "MIT" ]
permissive
HungMingWu/ncnn_example
22812ca78f82f89c55034d40c1d7e4d2f4185f25
6604eab8d76a5e49280e3f840847c84244c0fb2b
refs/heads/master
2023-01-11T09:20:25.357764
2020-11-19T07:03:34
2020-11-19T07:03:34
312,984,805
1
0
null
null
null
null
UTF-8
C++
false
false
1,169
cpp
#define FACE_EXPORTS #include "opencv2/opencv.hpp" #include "../image_helper.h" #include <orbwebai/face/detecter.h> int main(int argc, char* argv[]) { const char* img_file = "../../../..//data/images/4.jpg"; cv::Mat img_src = cv::imread(img_file); const char* root_path = "../../../..//data/models"; auto faceDetector = make_unique<orbwebai::face::Detector>(); faceDetector->LoadModel(root_path); double start = static_cast<double>(cv::getTickCount()); auto faces = faceDetector->DetectFace(toImageInfo(img_src)); double end = static_cast<double>(cv::getTickCount()); double time_cost = (end - start) / cv::getTickFrequency() * 1000; std::cout << "time cost: " << time_cost << "ms" << std::endl; for (const auto& face_info : faces) { cv::rectangle(img_src, toRect(face_info.location_), cv::Scalar(0, 255, 0), 2); for (int num = 0; num < 5; ++num) { cv::Point curr_pt = cv::Point(face_info.keypoints_[num], face_info.keypoints_[num + 5]); cv::circle(img_src, curr_pt, 2, cv::Scalar(255, 0, 255), 2); } } cv::imwrite("../../../../data/images/retinaface_result.jpg", img_src); cv::imshow("result", img_src); cv::waitKey(0); return 0; }